(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.data-privacy-src= 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-TT9ZP96');

Knowledge Base

Subscribe API

subscribe

Synopsis:

This API will subscribe users to a particular campaign. Once a user is subscribed to a campaign they will receive all auto responders and scheduled messages for that campaign until they are unsubscribed. You may not import via CSV someone who has unsubscribed themselves from a campaign however you may re-subscribe someone who has unsubscribed through this API.

Request: XML

<REQUEST>
    <ACTION>subscribe</ACTION>
    <API_KEY>YourApiKey</API_KEY>
    <CAMPAIGNREF>CampaignReferenceID</CAMPAIGNREF>
    <MOBILE>Phone Number to subscribe</MOBILE>
    <DATA>
        <FIRST_NAME>First Name</FIRST_NAME>
        <LAST_NAME>Last Name</LAST_NAME>
        <GENDER>Gender</GENDER>
        ...
    </DATA>
    <TIMEZONE>Timezone abbreviation: EST, CST, MST, PST, etc.</TIMEZONE>
</REQUEST>

Click here for more timezone options. Note that the difference between standard and daylight time does not matter here. The system will use the current time offset for the geographic region.

Request Parameters:

TermMandatory/OptionalDescription
ACTIONMandatory This is the name of the function you want to execute with the API.
API_KEYMandatoryThe API key that is assigned to your account that is used for authentication. You can find this key on the API Settings page.
CAMPAIGNREFMandatoryThis is the identifier of the Campaign you would like to subscribe the number to. You generated the campaignRef when you created the Campaign.
MOBILEMandatoryA Phone Number to subscribe to a campaign.
DATAOptionalAdditional data about the subscriber which can be used within future messaging.
TIMEZONEOptional A time zone abbreviation associated with the phone number.

Response Parameters:

Param NamePresenceDescription
STATUSAlways“Success” or “Failure”.
CAMPAIGNREFAlwaysThis is the identifier of the Campaign you would like to subscribe the number to. You generated the campaignRef when you created the Campaign.
MOBILEAlways A Phone Number to subscribe to a campaign.
ERRORCODEError response onlyError code associated with the error.
ERRORINFOError response onlyError message explaining the error code.

Request Example: XML

<REQUEST>
    <ACTION>subscribe</ACTION>
    <API_KEY>xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</API_KEY>
    <CAMPAIGNREF>1116</CAMPAIGNREF>
    <MOBILE>11111111111</MOBILE>
    <DATA>
        <FIRST_NAME>John</FIRST_NAME>
        <LAST_NAME>Smith</LAST_NAME>
        <AGE>29</AGE>
        <PET>Dog</PET>
    </DATA>
</REQUEST>

Response Example: Success

<RESPONSE>
    <STATUS>Success</STATUS>
    <CAMPAIGNREF>1116</CAMPAIGNREF>
    <MOBILE>11111111111</MOBILE>
</RESPONSE>

Response Example: Failure

<RESPONSE>
    <STATUS>Failure</STATUS>
    <ERRORCODE>E721</ERRORCODE>
    <MOBILE>11111111111</MOBILE>
    <CAMPAIGNREF>1116</CAMPAIGNREF>
    <ERRORINFO>Invalid campaignref</ERRORINFO>
</RESPONSE>

Postback Notification:

Upon subscribing a number successfully through any channel, the system will generate a notification. For more details please visit the Mobile Subscribe section of the Opt-in Status Postback documentation.

General Error Codes:

CodeDescription
E100Invalid request. Make a valid request via GET/POST/XML with all the required variables.
E104User Authentication Failed.
E105This account has no API rights.
E106You can call API every X seconds.
E107This account has no rights to use this action.
E108XML Parse error: $error.
E109API not activated.
E112IP was not whitelisted. API call rejected.
E113Set throughput exceeded for this API action. API call rejected.
E114Phone number is blacklisted. API call rejected.
E120Account has reached the API request limit.
E503Internal error.
CodeDescription
E718The ‘campaignref’ is required
E721Invalid campaignref
E901The ‘mobile’ number is required
E904Could not subscribe this number

Timezones:

AbbreviationNameUTC offset
ACDTAustralian Central Daylight Savings TimeUTC+10:30
ACSTAustralian Central Standard TimeUTC+09:30
ACTAcre TimeUTC−05
ACTASEAN Common TimeUTC+08
ADTAtlantic Daylight TimeUTC−03
AEDTAustralian Eastern Daylight Savings TimeUTC+11
AESTAustralian Eastern Standard TimeUTC+10
AFTAfghanistan TimeUTC+04:30
AKDTAlaska Daylight TimeUTC−08
AKSTAlaska Standard TimeUTC−09
AMSTAmazon Summer Time (Brazil)UTC−03
AMTAmazon Time (Brazil)UTC−04
AMTArmenia TimeUTC+04
ARTArgentina TimeUTC−03
ASTArabia Standard TimeUTC+03
ASTAtlantic Standard TimeUTC−04
AWDTAustralian Western Daylight TimeUTC+09
AWSTAustralian Western Standard TimeUTC+08
AZOSTAzores Standard TimeUTC−01
AZTAzerbaijan TimeUTC+04
BDTBrunei TimeUTC+08
BDTBangladesh Daylight TimeUTC+06
BIOTBritish Indian Ocean TimeUTC+06
BITBaker Island TimeUTC−12
BOTBolivia TimeUTC−04
BRSTBrasilia Summer TimeUTC−02
BRTBrasilia TimeUTC−03
BSTBangladesh Standard TimeUTC+06
BSTBougainville Standard TimeUTC+11
BSTBritish Summer Time (British Standard Time from Feb 1968 to Oct 1971)UTC+01
BTTBhutan TimeUTC+06
CATCentral Africa TimeUTC+02
CCTCocos Islands TimeUTC+06:30
CDTCentral Daylight Time (North America)UTC−05
CDTCuba Daylight TimeUTC−04
CEDTCentral European Daylight TimeUTC+02
CESTCentral European Summer Time (Cf. HAEC)UTC+02
CETCentral European TimeUTC+01
CHADTChatham Daylight TimeUTC+13:45
CHASTChatham Standard TimeUTC+12:45
CHOTChoibalsanUTC+08
ChSTChamorro Standard TimeUTC+10
CHUTChuuk TimeUTC+10
CISTClipperton Island Standard TimeUTC−08
CITCentral Indonesia TimeUTC+08
CKTCook Island TimeUTC−10
CLSTChile Summer TimeUTC−03
CLTChile Standard TimeUTC−04
COSTColombia Summer TimeUTC−04
COTColombia TimeUTC−05
CSTCentral Standard Time (North America)UTC−06
CSTChina Standard TimeUTC+08
CSTCentral Standard Time (Australia)UTC+09:30
CSTCentral Summer Time (Australia)UTC+10:30
CSTCuba Standard TimeUTC−05
CTChina timeUTC+08
CVTCape Verde TimeUTC−01
CWSTCentral Western Standard Time (Australia) unofficialUTC+08:45
CXTChristmas Island TimeUTC+07
DAVTDavis TimeUTC+07
DDUTDumont d’Urville TimeUTC+10
DFTAIX specific equivalent of Central European TimeUTC+01
EASSTEaster Island Standard Summer TimeUTC−05
EASTEaster Island Standard TimeUTC−06
EATEast Africa TimeUTC+03
ECTEastern Caribbean Time (does not recognise DST)UTC−04
ECTEcuador TimeUTC−05
EDTEastern Daylight Time (North America)UTC−04
EEDTEastern European Daylight TimeUTC+03
EESTEastern European Summer TimeUTC+03
EETEastern European TimeUTC+02
EGSTEastern Greenland Summer TimeUTC+00
EGTEastern Greenland TimeUTC−01
EITEastern Indonesian TimeUTC+09
ESTEastern Standard Time (North America)UTC−05
ESTEastern Standard Time (Australia)UTC+10
FETFurther-eastern European TimeUTC+03
FJTFiji TimeUTC+12
FKSTFalkland Islands Standard TimeUTC−03
FKSTFalkland Islands Summer TimeUTC−03
FKTFalkland Islands TimeUTC−04
FNTFernando de Noronha TimeUTC−02
GALTGalapagos TimeUTC−06
GAMTGambier IslandsUTC−09
GETGeorgia Standard TimeUTC+04
GFTFrench Guiana TimeUTC−03
GILTGilbert Island TimeUTC+12
GITGambier Island TimeUTC−09
GMTGreenwich Mean TimeUTC
GSTSouth Georgia and the South Sandwich IslandsUTC−02
GSTGulf Standard TimeUTC+04
GYTGuyana TimeUTC−04
HADTHawaii-Aleutian Daylight TimeUTC−09
HAECHeure Avancée d’Europe Centrale franchised name for CESTUTC+02
HASTHawaii-Aleutian Standard TimeUTC−10
HKTHong Kong TimeUTC+08
HMTHeard and McDonald Islands TimeUTC+05
HOVTKhovd TimeUTC+07
HSTHawaii Standard TimeUTC−10
IBSTInternational Business Standard TimeUTC
ICTIndochina TimeUTC+07
IDTIsrael Daylight TimeUTC+03
IOTIndian Ocean TimeUTC+03
IRDTIran Daylight TimeUTC+04:30
IRKTIrkutsk TimeUTC+08
IRSTIran Standard TimeUTC+03:30
ISTIndian Standard TimeUTC+05:30
ISTIrish Standard TimeUTC+01
ISTIsrael Standard TimeUTC+02
JSTJapan Standard TimeUTC+09
KGTKyrgyzstan timeUTC+06
KOSTKosrae TimeUTC+11
KRATKrasnoyarsk TimeUTC+07
KSTKorea Standard TimeUTC+09
LHSTLord Howe Standard TimeUTC+10:30
LHSTLord Howe Summer TimeUTC+11
LINTLine Islands TimeUTC+14
MAGTMagadan TimeUTC+12
MARTMarquesas Islands TimeUTC−09:30
MAWTMawson Station TimeUTC+05
MDTMountain Daylight Time (North America)UTC−06
METMiddle European Time Same zone as CETUTC+01
MESTMiddle European Summer Time Same zone as CESTUTC+02
MHTMarshall IslandsUTC+12
MISTMacquarie Island Station TimeUTC+11
MITMarquesas Islands TimeUTC−09:30
MMTMyanmar TimeUTC+06:30
MSKMoscow TimeUTC+03
MSTMalaysia Standard TimeUTC+08
MSTMountain Standard Time (North America)UTC−07
MSTMyanmar Standard TimeUTC+06:30
MUTMauritius TimeUTC+04
MVTMaldives TimeUTC+05
MYTMalaysia TimeUTC+08
NCTNew Caledonia TimeUTC+11
NDTNewfoundland Daylight TimeUTC−02:30
NFTNorfolk TimeUTC+11:00
NPTNepal TimeUTC+05:45
NSTNewfoundland Standard TimeUTC−03:30
NTNewfoundland TimeUTC−03:30
NUTNiue TimeUTC−11
NZDTNew Zealand Daylight TimeUTC+13
NZSTNew Zealand Standard TimeUTC+12
OMSTOmsk TimeUTC+06
ORATOral TimeUTC+05
PDTPacific Daylight Time (North America)UTC−07
PETPeru TimeUTC−05
PETTKamchatka TimeUTC+12
PGTPapua New Guinea TimeUTC+10
PHOTPhoenix Island TimeUTC+13
PKTPakistan Standard TimeUTC+05
PMDTSaint Pierre and Miquelon Daylight timeUTC−02
PMSTSaint Pierre and Miquelon Standard TimeUTC−03
PONTPohnpei Standard TimeUTC+11
PSTPacific Standard Time (North America)UTC−08
PSTPhilippine Standard TimeUTC+08
PYSTParaguay Summer Time (South America)UTC−03
PYTParaguay Time (South America)UTC−04
RETRéunion TimeUTC+04
ROTTRothera Research Station TimeUTC−03
SAKTSakhalin Island timeUTC+11
SAMTSamara TimeUTC+04
SASTSouth African Standard TimeUTC+02
SBTSolomon Islands TimeUTC+11
SCTSeychelles TimeUTC+04
SGTSingapore TimeUTC+08
SLSTSri Lanka Standard TimeUTC+05:30
SRETSrednekolymsk TimeUTC+11
SRTSuriname TimeUTC−03
SSTSamoa Standard TimeUTC−11
SSTSingapore Standard TimeUTC+08
SYOTShowa Station TimeUTC+03
TAHTTahiti TimeUTC−10
THAThailand Standard TimeUTC+07
TFTIndian/KerguelenUTC+05
TJTTajikistan TimeUTC+05
TKTTokelau TimeUTC+13
TLTTimor Leste TimeUTC+09
TMTTurkmenistan TimeUTC+05
TOTTonga TimeUTC+13
TVTTuvalu TimeUTC+12
UCTCoordinated Universal TimeUTC
ULATUlaanbaatar TimeUTC+08
USZ1Kaliningrad TimeUTC+02
UTCCoordinated Universal TimeUTC
UYSTUruguay Summer TimeUTC−02
UYTUruguay Standard TimeUTC−03
UZTUzbekistan TimeUTC+05
VETVenezuelan Standard TimeUTC−04:30
VLATVladivostok TimeUTC+10
VOLTVolgograd TimeUTC+04
VOSTVostok Station TimeUTC+06
VUTVanuatu TimeUTC+11
WAKTWake Island TimeUTC+12
WASTWest Africa Summer TimeUTC+02
WATWest Africa TimeUTC+01
WEDTWestern European Daylight TimeUTC+01
WESTWestern European Summer TimeUTC+01
WETWestern European TimeUTC
WITWestern Indonesian TimeUTC+07
WSTWestern Standard TimeUTC+08
YAKTYakutsk TimeUTC+09
YEKTYekaterinburg TimeUTC+05
ZZulu Time (Coordinated Universal Time)UTC
Go to Top