There are use cases where enterprises need to handle operations based on Mobile Originated (MO) messages. A typical example is processing opt-out messages from customers. Depending on the enterprise's strategy, processing can be specific to the sender ID. For a particular sender ID, the enterprise can set up a webhook to handle a specific case.
Selective Webhooks
Let's say we need to set up a webhook that triggers when a customer sends a "stop" or "optout" or "cancel" message, but only to the marketing sender address (for example: sender id 'RiPkzdoxKfcUenh1xxxxxx').
In this example the webhook must have the MO subscription matching criteria to filter and callback only when the destination is the marketing sender address.
The matching criteria could be:
sender_id_id = 'RiPkzdoxKfcUenh1xxxxxx' and message_body = 'stop' or message_body = 'optout' or message_body = 'cancel'
Adding more sender addresses
When only one address needs the webhook, it is easily handled as described above.
However, as the number of sender addresses grows and new addresses need to be included, the matching criteria can become increasingly complex. Updating the matching criteria for production webhooks also introduces the risk of downtime, which may not be acceptable.
Identifying Groups of Sender addresses
This example highlights the need to identify multiple sender addresses using a single ID.
SCG maintains a one-to-many relationship between application_id and sender addresses. When creating a sender address, SCG assigns the application_id based on the application that initiated the sender address creation.
Additionally, Syniverse Operations Team can assign an application ID to a sender upon customer request, allowing you to group sender IDs for easier management.
This enables you to assign an SDC application to a group of selected sender IDs by submitting a ticket to Syniverse Operations and requesting the application ID be set for the chosen sender IDs.
Once the senders are grouped under a defined application ID, this application ID can be used as a reference in the MO event matching criteria.
When a Mobile Originated (MO) message arrives at an SCG address, the event processor identifies the sender_id and its application_id, includes this information in the webhook payload. This allows us to use it as a reference in the subscription matching criteria.
In our example, assuming that only the selected sender IDs are associated with a specific application ID, such as 4425, you can use the application_id field in the subscription matching criteria to target the applications sender IDs.
application_id = '4425' and message_body = 'stop' or message_body = 'optout' or message_body = 'cancel'.
Here application_id = '4425' identifies all our marketing sender ids.
Additional information
Event Subscription Messaging Events User Guide v1.2
Set up Event Subscriptions Matching Criteria Fields
How to setup a Webhook for Receiving Messages and Notifications
Terminating Carrier ID and Carrier Name available in message state change event for SMS channel
0 Comments