Use this API to add data to any outbound campaign(dialer) with basic authentication. Create an outbound campaign in your CloudAgent account, and use this API to add data/records for the same.
Note:
- Make sure the admin setting 'API Authentication' is set to 'BASIC_AUTH', If you are using this API.
- In the body params, if no priority value is specified, the system defaults to 1.
Rate Limit:A maximum of 100 requests per minute is allowed for this API.
Possible responses
Adding data when the admin setting is TOKEN_AUTH/NONE | "{ ""status"": ""false"", ""message"": ""Invalid action."", ""data"": null }" |
Missing api_key parameter | "{ ""status"": ""false"", ""message"": ""Api Key Should Not be Null or Empty."", ""data"": null }" |
Invalid api_key / Empty api_key value | "{ ""status"": ""false"", ""message"": ""Invalid User Details"", ""data"": null }" |
Empty campaign name key / Invalid camapign name key/ campaign name value missing | "{ ""status"": ""Error"", ""message"": ""Please provide campaign details"" }" |
Invalid campaign name value | "{""status"": ""FAIL"", ""message"": ""No User Found or Campaign Name is Invalid""}" |
phone number key missing / Invalid phone number Key / Invalid phone number value / Empty phone number value | "{""status"": ""error"", ""message"": ""phone number should be numeric and must be between 3 to 16 digits and allows prefix +""}" |
Valid phone number value | """{ """"status"""": """"Success"""", """"message"""": """"Campaign xxxxx Is Already Started"""" }""" |
action key is invalid | "{ ""status"": ""Success"", ""message"": ""SuccessFully Updated xxxx Campaign"" }" |
"Success response when action = stop" | "{ ""status"": ""Success"", ""message"": ""SuccessFully Updated Progressive Campaign Stoped"" }" |
"Success response when action = start" | {"status": "SUCCESS", "message": "SuccessFully Updated, IVR was started"} |
"Success response when action is blank / missing / invalid | "{ ""status"": ""Success"", ""message"": ""Please pass the valid Campaign action SuccessFully Updated xxxxx Campaign Data"" }" |
A number already exists and parameter passed checkDuplicate=true | {"status": "SUCCESS", "message": "Number Already Exist"} |
A number already exists and parameter passed checkDuplicate=false / blank / missing / invalid | {"status": "SUCCESS", "message": "SuccessFully Updated, xxx was started"} |
checkDuplicate key is missing | "{ ""status"": ""Success"", ""message"": ""Campaign xxxxx Is Already Started"" }" |
username key is missing / username key empty OR null / username key is invalid | "{ ""status"": ""false"", ""message"": ""Username Should Not be Null or Empty."", ""data"": null }" |
username value is valid | """""""{ """"""""status"""""""": """"""""Success"""""""", """"""""message"""""""": """"""""Campaign xxxx Is Already Started"""""""" }""""""" |
username value is invalid | "{ ""status"": ""false"", ""message"": ""Invalid User Details"", ""data"": null }" |
priority key is missing / priority key with invalid priority value / priority key is invalid and value is valid / priority value is invalid / priority value is valid | "{ ""status"": ""Success"", ""message"": ""SuccessFully Updated xxxxx Campaign"" }" |
priority value is missing | "{ ""status"": ""Error"", ""message"": ""The priority value must be numeric and range from 0 to 99."" }" |
Invalid expiryDate Value | "{ ""status"": ""Error"", ""message"": ""Invalid date format. Please pass date in format yyyy-MM-dd HH:mm:ss or yyyy-MM-dd"" }" |
Missing expiryDate Value | "{ ""status"": ""Error"", ""message"": ""Invalid date format. Please pass date in format yyyy-MM-dd HH:mm:ss or yyyy-MM-dd"" }" |
Passing past date as expiryDate value | "{ ""status"": ""Error"", ""message"": ""The expiry date and time must be in the future"" }" |
Passing future date as expiryDate value | "{ ""status"": ""Success"", ""message"": ""Campaign progressive Is Already Started"" }" |
ExpiryDate value is valid | "{ ""status"": ""Success"", ""message"": ""SuccessFully Updated Progressive Campaign"" }" |
username value is empty/null | "{ ""status"": ""false"", ""message"": ""Username Should Not be Null or Empty."", ""data"": null }" |
Adding phone number to Agentwise campaign and agentId missing | "status": "FAIL", "message": "Agent Is Empty!" |
Adding phone number to Agentwise campaign and agentId empty | """status"": ""FAIL"", ""message"": ""Agent Is Empty!""" |
Adding a phone number to Agentwise campaign and agentId invalid | """status"": ""FAIL"", ""message"": ""Agent is not correctly mapped!""" |
Adding a phone number to Agentwise campaign and agentId valid | {"status": "SUCCESS", "message": "SuccessFully Updated"} |
Adding a phone number to skill wise campaign and skill is missing | """status"": ""FAIL"", ""message"": ""Please provide valid skill""" |
Adding a phone number to skill wise campaign and skill is empty | """status"": ""FAIL"", ""message"": ""Please provide valid skill""" |
Adding a phone number to skill wise campaign and skill is invalid | """status"": ""FAIL"", ""message"": ""Please provide valid skill""" |
Adding a phone number to skill wise campaign and skill is valid | {"status": "SUCCESS", "message": "SuccessFully Updated"} |
Adding a phone number to skill wise campaign with other valid skill | "{ ""status"": ""Success"", ""message"": ""Number Already Existed"" }" |
Uploading phone numbers to non-mandatory mapped columns like name, address missing/ invalid. | {"status": "SUCCESS", "message": "SuccessFully Updated"} |
Giving same name to a different number | {"status": "SUCCESS", "message": "SuccessFully Updated, xxx was started"} |
Giving same number and different name | {"status": "SUCCESS", "message": "Number Already Exist"} |
Adding data to inbound campaign | "no, we should not { ""status"": ""Fail"", ""message"": ""The selected campaign is not outbound"" }" |
Data added to the campaign when the setting "Api authentication" is "Basic_Auth" | {"status": "SUCCESS", "message": "SuccessFully Updated, IVR was started"} |
Data added to campaign when the setting "Api authentication" is "None" | "{ ""status"": ""false"", ""message"": ""Invalid action."", ""data"": null }" |
Data added to campaign when the setting "Api authentiction" is "Token_Auth" | "{ ""status"": ""false"", ""message"": ""Invalid action."", ""data"": null }" |