textbee Logotextbee.dev
Plans from $9.99/mo.View Plans

Two-way SMS: definition and how it works

Published and updated

Two-way SMS is messaging where recipients can reply to the number that texted them and the sender's software receives and acts on those replies.

How it works

Most business texting is one-way: a code, a receipt, an alert. Two-way SMS closes the loop. The recipient replies, the reply reaches the sender's application, and the application does something with it: confirms an appointment, records an opt-out, answers a question, or hands the thread to a person.

Two-way needs a sender that can receive. Long codes and short codes can; alphanumeric sender IDs cannot, since a name is not an address. The reply then has to get from the network into your code, by webhook when it arrives or by polling a messages endpoint with a cursor so nothing is missed.

The patterns are well established. Keyword responses handle YES to confirm, C to cancel, STOP to opt out, and a help word. Conversational support routes inbound messages into an inbox where staff answer from the same number, so the customer sees one thread. Surveys ask one question at a time and parse short answers. Each pattern needs the application to keep state per phone number: which question is open, what the last outbound message was, whether the person has opted out.

Two-way changes how recipients perceive the sender. A message from a number that answers back is treated as a contact, not a broadcast, and reply rates on confirmations and reminders reflect that.

How this applies with textbee

Every textbee message comes from a real number, so every recipient can reply, and replies land in your account. Read them with GET /gateway/messages using the cursor, or receive them instantly as MESSAGE_RECEIVED webhooks, then answer from the same number with POST /gateway/send-sms.

Related terms

  • Webhook: A webhook is an HTTP request a service sends to a URL you own when something happens, so your code learns about an inbound SMS or a delivery event the moment it occurs instead of polling for it.
  • STOP keyword: STOP is the conventional reply a recipient sends to opt out of a sender's text messages, which the sender must recognise and honour by ending the messages and confirming once.
  • Sender ID: The sender ID is what the recipient sees in the from field of a text message: a phone number, a short code, or a registered brand name.
  • Long code: A long code is a standard full-length phone number, such as a ten-digit United States number, used as the sender of SMS.

Read next