Two way SMS system - Ozeki NG

What is a two way SMS system?

An SMS system that can send and receive SMS messages.

When we are talking about two way SMS system we usually refer to systems, that can submit messages to mobile users and can process SMS messages sent by mobile users.

When a mobile user replies to my SMS, can I tell which message did he originally reply to?

No, this is not possible.

The SMS technology does not provide any way to check if an incoming message is a reply to a previously sent SMS or not. The reason for this is that there is no such thing as a session identifier or discussion identifier in the SMS protocol data unit (PDU). All message are independent from each other and are treated as a single entity.

The only thing you can do is rely on keywords included in the message text, or if you are lucky and you use IP SMS connection and your SMS service provider supports long codes, you can include some extra digits in the sender telephone number to identify the sent message.

Can I use keywords to match replies to submitted messages?


Although the SMS technology does not provide any way to check if an incoming message is a reply to a previously sent SMS or not, you can work around this issue, by putting in a keyword into the message text itself. You can tell the person who replies to the message to include that keyword in the message text. If you use a unique keyword for a submitted message and the keyword is included in the response, you can tell which message does the response message belong to. The problem with this approach is that the mobile user might forget to include the keyword in the message text.

Can I use long codes to match replies to submitted messages?

Yes, if you have an IP SMS connection, and a network that allows this.

The good news is that in some networks long codes are allowed to be used as telephone numbers. A long code is a telephone number that has a postfix. E.g.: +36201234678888, where 8888 is the postfix appended to the standard telephone number +3620123467. Long codes can be used through IP SMS connections in some networks. In these networks the recipient (e.g.: +3620123467) will receive messages sent to any telephone number that start with +3620123467. For example if an SMS message is sent to +36201234678888 or to +36201234679999999, the receiver, that has a phone number of +3620123467 will receive both. If you can use a long code as the sender telephone number, because your network supports it, you can include a message identifier in the tail of the sender telephone number. This way if a reply comes back to the long telephone number, you can tell which originally submitted message it belongs to.

The problem with this approach that only a very limited number of Mobile Networks allow long code telephone number formats.

Are there any threats with autoresponding systems?

Yes, the biggest threat is a message loop.

If two autoresponding systems start to communicate with each other a message loop can occur. Information on this can be found at: This loop can create huge telephone bills for both parties in the loop. Luckily Ozeki NG SMS Gateway has built in message loop prevention. It does not allow message submission to the same telephone number with the same text more then 10 times per hour.

Are there any threats with autoresponding systems? Can I query a database and return data in a response SMS?


The best way to do this is to setup an autoreply database user in Ozeki NG SMS Gateway. More information about this can be found at:

Can I return a webpage if I receive a certain keyword in SMS?

You cannot return a webpage, but you can return a link to a webpage.

To create such a service, you need to use the WAP Push message type, that allows you to send a webpage link to a cellphone. The cellphone can automatically read this link and can open a webpage.

To create this service, please use the Autoreply easy user built into Ozeki NG.

Can I send automatic reply messages to an incoming SMS message?

Yes, you can.

You can send automatic reply message with Ozeki NG SMS gateway. It is also possible to query the reply based on a keyword of the incoming SMS message. FOr this purpose, you can use Autoreply user or autoreply database user.

More information