Perform batch operations on select Conversation API resources.
Conversation API - Batch API | Sinch (0.0.1)
Download OpenAPI description
Overview
support at sinch
License
Languages
Servers
The {region} variable must be set to either us or eu
https://{region}.conversationbatch.api.sinch.com/
Messages
Send a message to one or many recipients. This API supports the same channels as Conversation API.
Operations
Path
Bodyapplication/jsonrequiredThe unique ID of the project. You can find this on the Sinch Dashboard.
The ID of the Conversation API app under which the consent records are to be stored.
A list of consent records to create. Each record must include an identification
field, which uniquely identifies the subject (e.g., phone number or contact ID), and a consent_type
.
- The {region} variable must be set to either us or eu
https://us.conversationbatch.api.sinch.com/v1/projects/{project_id}/consents
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://us.conversationbatch.api.sinch.com/v1/projects/{project_id}/consents' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"app_id": "{{APP_ID}}",
"consent_records": [
{
"identification": "{{PHONE_NUMBER_1}}",
"consent_type": "OPT_OUT_ALL"
},
{
"identification": "{{PHONE_NUMBER_2}}",
"consent_type": "OPT_OUT_MARKETING"
},
{
"identification": "{{PHONE_NUMBER_3}}",
"consent_type": "OPT_OUT_NOTIFICATION"
}
]
}'
Response
application/json
{ "batch_id": "string" }