How it Works

Use this API to get the status and other attributes for a given SMS Program ID.

Requirements to use this API

  1. Your Watson Campaign Automation org must have SMS enabled by provisioning.
  2. A database in your Watson Campaign Automation org must have SMS enabled.
  3. The user making the API call must have valid Oauth credentials.

Note: Up to 10 concurrent requests are allowed to our API servers at any given time when using the OAuth method for authentication.

 

Endpoint

GET /channels/sms/program/{programId}

 

Request Parameter

Specify the SMS Program ID for which you want to retrieve information in the request URL. See How to find SMS program ID.

 

SMS Program Attributes Returned in Response

Attribute

Description

Example

id

SMS program ID

123456

programName

SMS program name

Presidents Sale

campaignName

SMS campaign name (as specified in SMS Campaign Manager)

Spring Promo 2018

code

Short/long code for the SMS program

87767

senderId

SMS sender ID (Note: not supported for all countries)

FASHION4YOU

status

SMS program status

ACTIVE

type

SMS program type

TEXT_TO_JOIN

country

SMS program country

US

 

Sample Response Body – Success

{
“meta”: {
“attributes”: {},
“generalErrors”: [],
“fieldErrors”: {},
“links”: [],
“nextPageUrl”: null
},
“data”: {
“id”: 123456,
“programName”: “Presidents Sale”,
“campaignName”: “Spring 2018 Sale”,
“code”: “87767”,
“senderId”: “”,
“status”: “ACTIVE”,
“type”: “TEXT_TO_JOIN”,
“country”: “US”
}
}

Sample Response Body – Failure

{
“meta”: {
“attributes”: {},
“generalErrors”: [
“Unable to locate sms program id 148070”
],
“fieldErrors”: {},
“links”: [],
“nextPageUrl”: null
},
“data”: null
}

 

Response Codes

Scenario

Response Code

Message

Success

200

 

User is not on an SMS-enabled Org

403

Forbidden

Invalid Program ID

404

Unable to locate sms program id {invalid value}.

 

Test Your API Call

Use Swagger to test your API call. To access the Swagger environment for your Org, replace {POD#} with the Pod where your Org exists:

https://api{POD#}.silverpop.com/restdoc/#!/channels/getSmsProgramById_get_5

For example, here’s the link to use if your Org is on Pod 1:

https://api1.silverpop.com/restdoc/#!/channels/getSmsProgramById_get_5

Join The Discussion

Your email address will not be published. Required fields are marked *