This API is used to add MSISDNs or Email IDs to the opt-out list to filter out customers based on various scenarios like Global Level, Channel Level, Category Level, and Deployment Level from the target group before deploying any deployment.
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.
Go to the Postman Collection section to learn how to import a Postman collection. Click the below button, If you already know how to import a postman collection.
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) |
Body Parameters
The following table describes the elements in the request body:
Parameter | Type | Mandatory | Description |
---|---|---|---|
exclusion-type | String | Yes | Specifies the type of exclusion applied on the target group. The options are: _ 1- Global _ 2- Channel * 3- Suppression Category |
channel | String | Conditionally Mandatory | This parameter is applicable if the exclusion-type is set as channel. Select the required channel. The options are: _ 0- SMS _ 1- MMS _ 6- OBD _ 7- EMAIL _ 8- APP |
deployment-id | String | Conditionally Mandatory | Specifies the id of the deployment. If the exclusion-type is set as 4, then pass campaign_id. |
suppressioncategory-id | String | Conditionally Mandatory | Specifies the suppression category list. The options are: _ 0-Marketing _ 1-SMS Offers These options may change based on ID generated during the Category creation. |
operation-mode | String | Yes | Specifies the operation mode. The options are: _ single _ bulk |
key | String | Conditionally Mandatory | Specifies the key if operation-mode is set as single. The key can be MSISDN _or _Email ID that needs to be excluded. The country code should be prefixed for MSISDN. |
file-path | String | Conditionally Mandatory | Specifies the path of the file when the operation-mode is set as bulk. |
source | String | Yes | Specifies the source from which the API is called. _ 0- Self Care _ 1- Customer Care _ 2- TeleSales _ 3- Email _ 4- SMS _ 5- MobileApp _ 6- OBD |
file-mode | String | Conditionally Mandatory | Specifies the file mode. The options are: * append : If this option is set, after applying filters on the target groups, the current excluded group is appended to the existing final target group. * overwrite: if this option is set, after applying filters on the target groups, the existing final target group is replaced with the current excluded group list. |
Request Example
{
"exclusion-type":"1",
"channel":"0",
"suppressioncategory-id":"57",
"operation-mode":"single",
"key":"9778688808371",
"source":"0"
}
{
"exclusion-type":"1",
"channel":"0",
"suppressioncategory-id":"57",
"operation-mode":"bulk",
"file-path":"\apps\datafiles\3213\msisdns.txt",
"file-mode":"append",
"source":"0"
}
Response Parameters
This API will return the following response parameters:
Parameter | Description |
---|---|
code | Returns the response code in case of failure. |
description | Returns the description of the response in case of failure. |
transaction-id | Returns the unique Transaction ID of the operation in case of success. |
Failure Response Codes
The API will return a code within the response as per the following table in case of failure scenarios.
HTTP Status Code | Code within API Response | Description |
---|---|---|
200 | 1010 | The request was not processed. |
401 | 498 | Invalid token or Access token expired |
405 | 405 | Method not supported |
429 | 429 | Too many requests. Throttle limit reached for the time window. |
404 | 404 | Request failed. Check the exact reason of failure in application code and description of error stream. |
500 | 500 | Internal server error |
500 | 1001 | Invalid input JSON |
500 | 1002 | Mandatory field missing |