How to Build a Two-Way SMS System with the DataFlows API

How to Build a Two-Way SMS System with the DataFlows API

A step-by-step guide to building a two way SMS system with the DataFlows API — send outbound texts, receive inbound replies via webhook, and automate customer responses in real time.

Text messages get read. Most arrive on a phone that's already in someone's hand, and most get opened within minutes. But a lot of business SMS is still one-way: a reminder goes out, and if the customer wants to respond, they have to call, email, or open an app instead. That gap costs businesses time and costs customers convenience.

Two-way SMS closes that gap by letting customers reply directly to a text and have that reply land somewhere useful — your CRM, your booking system, or an automated workflow that responds instantly. In this guide, we'll walk through what two-way SMS is, why it matters for Australian businesses, and exactly how to build a two-way SMS system using the DataFlows API, from sending your first message to handling inbound replies with a webhook.

What Is Two-Way SMS

Two-way SMS is a messaging setup where a business can both send text messages to customers and receive their replies within the same conversation. Unlike a one-way notification — where a customer gets an appointment reminder or a delivery update but has no way to respond — two-way SMS gives the customer a direct channel to text back "YES" to confirm a booking, ask a quick question, or reply "STOP" to opt out. Technically, two-way SMS relies on a number that can accept inbound messages, paired with a webhook that forwards those replies to your system the moment they arrive. The DataFlows API supports this pattern directly: outbound messages go out through the SMS API, and inbound replies are pushed to your application in real time via webhook. This makes two-way SMS a practical foundation for appointment confirmations, customer support, surveys, and compliant opt-out handling, without asking the customer to open an app or check their email.

Why Two-Way SMS Matters for Australian Businesses

Australians check text messages quickly, but many local businesses still only send one-way alerts. That means a customer who wants to reschedule an appointment has to call, a customer with a question about their order has to email, and a customer who wants to opt out has no easy way to do so from within the message itself.

Two-way SMS removes those extra steps. A customer can reply "1" to confirm a booking, text "STOP" to opt out, or ask a short question and get an answer without leaving their messaging app. For businesses managing appointments, deliveries, or support requests, this cuts down phone volume, reduces no-shows, and gives customers a direct line that matches how they already communicate day to day.

Key Benefits

Faster confirmations — customers can confirm or cancel a booking with a single reply instead of a phone call.

Lower no-show rates — a simple "reply YES to confirm" prompt captures intent immediately, rather than relying on a customer remembering to call back.

Reduced support load — routine questions like opening hours, order status, or rescheduling can be answered instantly by an automated reply, freeing staff for more complex enquiries.

Built-in opt-out handling — customers can text STOP directly, keeping your contact lists compliant without extra admin work.

Real-time visibility — inbound replies arrive via webhook the moment they're sent, so your team or your automation can act immediately.

Step-by-Step: Building a Two-Way SMS System

Step 1: Get a virtual number and API token

Two-way conversations need a number your customers can reply to. In your DataFlows dashboard, provision a Virtual Number so replies have a consistent destination instead of scattering across shared numbers. Then head to the Developer section of the DataFlows dashboard to generate your API Token — you'll need it to authenticate every request to the SMS API.

Step 2: Send your first outbound message

With your token and virtual number in hand, send a test message through the SMS API. A typical outbound request includes the recipient's number, the sender (your virtual number or approved Sender ID), and the message body. Keep the first message simple and tell the customer how to respond, for example: "Reply YES to confirm your appointment or STOP to opt out."

Step 3: Set up a webhook to receive inbound replies

In your DataFlows dashboard, configure a webhook URL that points to an endpoint in your application. When a customer replies to your virtual number, DataFlows sends that message — sender number, body, and timestamp — to your webhook as an HTTP POST. This is the core of two-way SMS: instead of polling for new messages, your system is notified the instant a reply comes in.

Step 4: Parse and route incoming replies

On your server, parse the incoming payload and decide what to do with it. Simple keyword matching works well for most use cases: check if the message body matches "YES", "1", "STOP", or a custom keyword, then route it to the right action — update a booking status, flag an opt-out, or forward the message to a support queue for a human reply.

Step 5: Send an automated response

Once you've processed the reply, send an acknowledgement back through the SMS API so the customer knows their message was received — something like "Thanks, your appointment is confirmed." This closes the loop and keeps the conversation feeling responsive rather than one-sided.

Step 6: Test the full loop

Before rolling this out to customers, send yourself a test message, reply from a personal phone, and confirm the webhook fires, the reply is parsed correctly, and the automated response arrives. Test edge cases too — replies with unexpected wording, extra whitespace, or emoji — so your keyword matching doesn't silently drop a real customer reply.

Common Two-Way SMS Use Cases

Two-way SMS isn't limited to appointment confirmations. Once you have inbound replies flowing into your system, the same setup supports a range of everyday business scenarios.

Appointment and booking confirmations

Send a reminder the day before an appointment and ask the customer to reply YES to confirm or RESCHEDULE if the time doesn't suit. This gives staff advance notice of cancellations instead of finding out when the customer simply doesn't show up.

Delivery and order updates

After a shipping notification, let customers reply with a question like "WHERE" to get a status update, or "CHANGE" to request a different delivery time. This reduces inbound phone calls to a support line that could be answered automatically.

Customer feedback and surveys

A short survey sent by SMS, such as "Reply 1-5 to rate your experience," gets a far higher response rate than an email survey link. Because the reply is a single character, most customers will respond within minutes of receiving the message.

Opt-in and opt-out management

Two-way SMS is also how compliant opt-out works in practice. A customer replying STOP should be removed from future sends immediately, and your webhook is what makes that update happen in real time rather than in a nightly batch job.

Support triage

For simple support questions, an automated first response can handle the common cases — business hours, location, order status — while anything that doesn't match a known keyword gets forwarded to a staff member to reply to personally.

How DataFlows Helps

DataFlows Virtual Numbers give you a dedicated number customers can reply to, so inbound responses land in one place instead of scattering across different numbers. The SMS API handles both directions of the conversation: outbound sends and inbound webhook delivery, so you're not stitching together separate tools for sending and receiving.

If you'd rather build the workflow without writing custom webhook-handling code, DataFlows connects to Zapier with a "New SMS Received" trigger and a "Send SMS" action, so you can route inbound replies into a spreadsheet, a CRM, or a support tool, and send an automated reply, all without hosting your own endpoint.

For businesses sending marketing or transactional messages at volume, Sender IDs and Contact Lists keep your outbound messages recognisable and your audience organised, while SMS Automation lets you trigger two-way conversations from events in your existing systems rather than sending messages manually.

Best Practices

Keep replies simple — ask for single-word or single-character responses like YES/NO or 1/2/3 so replying takes no effort.

Confirm receipt — always send a short acknowledgement so customers know their reply was received and acted on.

Respect opt-outs immediately — process STOP requests in real time and stop sending further messages to that number straight away.

Log every conversation — store inbound and outbound messages against the customer record so support staff have full context.

Set expectations up front — tell customers how to reply in your very first message so they know what response you're expecting.

Conclusion

Two-way SMS turns a broadcast channel into a real conversation. Instead of hoping a customer calls back after a reminder, you give them a direct, low-effort way to confirm, ask, or opt out — and you get their reply the moment they send it. Sign up at dataflows.com.au to get your virtual number, generate an API token, and start building your own two-way SMS workflow today.

You May Also Like

SMS API Integration Guide

How to Trigger Zapier Workflows with New SMS Received

Keyword-Matched SMS Replies with DataFlows and Zapier

How to Send SMS with Node.js and the DataFlows API

Best SMS API in Australia (2026)