How do I insert an opt out message with the API?

When sending messages via the API, the opt-out text is not added automatically. You need to include it yourself as part of the message content.

The opt-out wording depends on the sender you are using.

If you are sending from a Mobile Message dedicated number, replies are supported. In this case, we recommend adding the text “Reply STOP to optout”. When a recipient replies with STOP, the opt-out is handled automatically for you.

If you are sending from a business name (custom sender ID) or from your own phone number, replies cannot be processed by the platform. In these cases, you must use a link-based opt-out instead. The recommended format is “Optout ”.

To get the correct opt-out link for your account, log in to your Mobile Message account and go to Send Messages. Click the [i] icon next to Insert Opt Out Message. This will display the opt-out link that should be included in your API messages.

Including the correct opt-out text helps ensure your messages comply with Australian spam requirements and makes it easy for recipients to unsubscribe.