The Opt-in Postback API notifies you of an opt-in or opt-out status change for each number subscribed to your campaigns.
Mobile Subscribe
This postback notification triggers when a mobile phone number subscribes to a specific campaign. We send the notification again even if someone who is already opted-in triggers the opt-in process a second time.
Variable | Description |
---|---|
ORIGIN | SUB. |
CODE | N301. |
MOBILE | Subscriber’s mobile number. |
CAMPAIGNREF | The campaign reference ID (string) to which the user is subscribed. |
TIMESTAMP | Timestamp of the subscription. |
SHORTCODE | The shortcode. |
CAMPAIGNTITLE | The title of the campaign. |
BRANDNAME | The brand name associated with the account or campaign. |
SOURCE | The source of the subscription: MANAGER, API, MO, WEB. MANAGER indicates the number was imported or manually added in your campaign audience manager. API indicates it came from a subscribe call to our API. MO indicates the phone number opted-in by texting campaign keyword. WEB indicates they subscribed via mobile web landing page. |
<?xml version='1.0'?>
<POSTBACK>
<ORIGIN>SUB</ORIGIN>
<CODE>N301</CODE>
<MOBILE>16501112222</MOBILE>
<CAMPAIGNREF>1478</CAMPAIGNREF>
<TIMESTAMP>2014-07-02T14:32:23-04</TIMESTAMP>
<SHORTCODE>123456</SHORTCODE>
<CAMPAIGNTITLE>My Campaign Name</CAMPAIGNTITLE>
<BRANDNAME>My Brand Name</BRANDNAME>
<SOURCE>API</SOURCE>
</POSTBACK>
Mobile Unsubscribe
This postback notification triggers when a mobile phone number unsubscribes to a specific campaign.
Variable | Description |
---|---|
ORIGIN | SUB. |
CODE | N302. |
MOBILE | Subscriber’s mobile number. |
CAMPAIGNREF | The campaign reference ID (string) to which the user is subscribed. |
TIMESTAMP | Timestamp of the unsubscription. |
SHORTCODE | The shortcode. |
CAMPAIGNTITLE | The title of the campaign. |
BRANDNAME | The brand name associated with the account or campaign. |
SOURCE | The source of the unsubscription: MANAGER, API, MO, IMPORTED AS UNSUBSCRIBED. MANAGER indicates the number was deported or manually removed in your campaign audience manager. API indicates it came from a unsubscribe call to our API. MO indicates the phone number opted-out by texting STOP. IMPORTED AS UNSUBSCRIBED indicates the number was attempted to be imported or manually added, but was imported as unsubscribed due to a previous opt-out. |
<?xml version='1.0'?>
<POSTBACK>
<ORIGIN>SUB</ORIGIN>
<CODE>N302</CODE>
<MOBILE>16502424956</MOBILE>
<CAMPAIGNREF>1478</CAMPAIGNREF>
<TIMESTAMP>2014-07-02T14:32:23-04</TIMESTAMP>
<SHORTCODE>123456</SHORTCODE>
<CAMPAIGNTITLE>My Campaign Name</CAMPAIGNTITLE>
<BRANDNAME>My Brand Name</BRANDNAME>
<SOURCE>API</SOURCE>
</POSTBACK>