put https://yourapihubdomain.io/v1/campaigns//deployments/
This API is used to update an SMS deployment.
Do not use thie API to activate a deployment. You can use this API to update the SMS deployment details such as content, target group, router, schedule and so on.
Know your endpoint
Based on the domain you use to log in to Webex Campaign, the endpoint domain for your API varies. For more information, refer to the Know Your API Endpoints section.
Headers
The following table describes the request headers:
Request Header | Description |
---|---|
content-type | application/json |
authorization | Access token or API Secret Key in Bearer format Example: Bearer $(key) |
Request Parameters
Parameter | Type | Mandatory | Description |
---|---|---|---|
milestone | Integer | Yes | Specifies the deployment milestone. |
deploymentInfo | Object | Yes | Specifies the deployment info object. * deploymentName: Specifies the deployment name. * contentType: * deploymentType: 1, * promotionType: 1, * channel: 0, * scheduleMode: "1", * instantType: 0 |
targetGroup | Object | Yes | Specifies the target group object. * targetGroupIds: Specifies an array of target group ids. * policyConfigurationEnabled: Specifies if the policy configuration is enabled. * globalExclusionEnabled: Specifies if the global exclusion is enabled. * exclusionOptionnEnabled: Specifies if the exclusion option is enabled. * removeDuplicates: Specifies if the duplicates have to be removed. * controlGroupEnabled: Specifies if the control group is enabled. * controlType: Specifies the control type. * limitContactsEnabled: Specifies if the limit contacts is enabled. * limitContactsCondition: Specifies the limit contacts condition. * seedlistEnabled: Specifies if the seed list is enabled. * addNoteToSeedMessage: Specifies if a note has to be added to the seed message. * waitInterval: Specifies the wait interval in minutes. |
reportTags | Object | Yes | * pandls: Specifies the P and L object. id: Specifies the id of the P and L. name: Specifies the name of P and L. * purposes: Specifies the purposes object. _ categoryId: Specifies the category id. * categoryGroup: Specifies the category group. The default option is DEFAULT. * categoryName: Specifies the category name. * segment code: Specifies the segment code": * optOutCategory: Specifies the opt-out category. |
router | Object | Yes | Specifies the router details. * routerId: Specifies the router id. * tps: Specifies the TPS (transactions per second) for the router. * isAutoTps: Specifies if the auto TPS is enabled. Note: Please check with your account manager or L2 on the router Id to be used and the tps it supports. |
schedule | Object | Yes | Specifies the schedule details. * immediateCalendar: Specifies the calendar. |
advancedOptions | Object | Yes | Specifies the details of the advanced options: * drRequired: Specifies if the delivery receipt is needed or not. * messageValidityEnabled: Specifies if the message validity is enabled. * messageValidity: Specifies the message validity in numbers. * messageValidityFormat: Specifies the message validity format. The options are D (days), H(hours), and M (minutes). * offerValidityEnabled: Specifies if the offer validity is enabled or not. * isRetryNeeded: Specifies if the retry is needed or not. * maximumAttempts: Specifies the maximum attempts to deliver the message. |
smsDeploymentInfo | Object | Yes | Specifies the SMS deployment details. * smscontent: Specifies the SMS content object. Refer to the below table. |
reserveDaysType | String | Yes | Specifies exclusion days. |
reserveTimingsType | String | Yes | Specifies exclusion timings. |
ruleBasedSuppressionIds | Array of Strings | No | Specifies the rule based suppression ids. |
sms content parameters
Parameter | Type | Mandatory | Description |
---|---|---|---|
content | base 64 | Yes | Specifies the content in base 64 format. |
linkTrackInfo | Object | No | Specifies the object of link tracking info. Refer to the below table |
messageType | String | Yes | Specifies the message type. The options are: * normal * flash * unicode * binary |
senderId | String | Yes | Specifies the id through which the message will be sent. |
traiTemplateId | String | No | Specifies the trai template id. |
linkTrackInfo parameters
parameter | Type | Mandatory | Description |
---|---|---|---|
linkid | String | No | Specifies the link id. |
shortLinkSendingOption | Integer | No | Specifies if the short link has to be unique or common. the options are: * 1- unique * 0 - common |
expectedCtr | Integer | No | Specifies the expected click-to ratio. |
linkName | String | No | Specifies the name of the link for tracking |
linkTracking | Boolean | No | Specifies if the link tracking has to be enabled for the link |
mainUrl | String | No | Specifies the mail URL in base 64 encoded format. |
shortUrl | String | No | Specifies the short URL in base 64 encoded format. |
Request Example
{
"advancedOptions": {
"drRequired": 1,
"isRetryNeeded": false,
"maximumAttempts": 0,
"messageValidity": 0,
"messageValidityEnabled": true,
"messageValidityFormat": "D",
"offerValidityEnabled": false,
"retryNeeded": false
},
"campaignInfo": {
"campaignId": "16902745160049"
},
"deploymentid": "SMS_1706089469571008101",
"deploymentInfo": {
"channel": 0,
"contentType": 1,
"deploymentName": "sample_test1_1234",
"deploymentType": 1,
"instantType": 0,
"promotionType": 1,
"scheduleMode": 1
},
"isPrepareTGEnabled": true,
"milestone": "Draft",
"notifications": [],
"prepareTGEnabled": true,
"reportTags": {
"optOutCategory": "-1",
"segmentCode": "2112"
},
"reserveDaysType": "1",
"reserveTimingsType": "1",
"router": {
"isautotps": false,
"routerId": "LIVEROUTE",
"tps": 2
},
"ruleBasedSuppressionIds": "",
"schedule": {
"calendarId": "Default",
"immediateCalendar": true,
"runPeriod": 0,
"runScheduleType": 0,
"scheduleType": 7,
"waitPeriod": 0
},
"smsDeploymentInfo": {
"smscontent": [
{
"content": "e2Fzc2V0X2xpbmtzXzE3MDQyOTE3MjYwMDExfQ==",
"linkTrackInfo": [
{
"linkId": "17042917260011",
"shortLinkSendingOption": 1,
"expectedCtr": 0,
"linkName": "QA_Link_030120243",
"linkTracking": true,
"mainUrl": "aHR0cDovL3d3dy5pbWltb2JpbGUuY29tLw==",
"shortUrl": "aHR0cDovL3RzMi5zbXJ0Lm14L3h4eHh4eA=="
}
],
"messageType": "normal",
"senderId": "CONNCTT",
"traiTemplateId": "16582198681091"
}
]
},
"stakeholders": [],
"targetGroup": {
"addNoteToSeedMessage": false,
"controlGroupEnabled": false,
"controlType": 0,
"exclusionOptionnEnabled": false,
"globalExclusionEnabled": true,
"limitContactsCondition": 0,
"limitContactsEnabled": false,
"policyConfigurationEnabled": true,
"removeDuplicates": true,
"seedlistEnabled": false,
"targetGroupIds": [
"17043674830125"
],
"waitInterval": 0
}
}
Response Parameters
This API will return the following response parameters:
Parameter | Description |
---|---|
name | Returns the name of the Purpose. |
id | Returns the id of the Purpose. |
message | Returns a confirmation message. |
Response Example
{
"id": "SMS_1706089469571008101",
"name": "sample_test1_1234",
"message": "Deployment - sample_test1_1234 - has been saved successfully."
}
Failure Response Codes
The API will return code within the response as per the following table in case of failure scenarios.
HTTP Status Code | Code within API Response | Description |
---|---|---|
400 | 400 | I/O error on post request. Cannot retry due to server authentication, in streaming mode. |
401 | 430 | Authorization failed. This resource is not allowed to access using this TOKEN or KEY |
401 | 498 | Invalid token or Access token expired |
404 | 404 | Not found |
405 | 405 | Method not supported |
500 | 500 | Internal server error |
500 | 1001 | Invalid input JSON |