Send message with vars by CSV.

This endpoint allows you to send a list of messages through a CSV file.

Receives the format to generate the message to send in JSON format. This format must be composed with the template data to be used, with special emphasis on the namespace, the template name and the variables used in the template components.

The CSV, for each destination, must have information about the variables defined in the template. The header of the file must correspond to the JSON sent that corresponds to a given template.

Note: For repeated contacts in the CSV, only the first occurrence will set the context for that contact.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required

ApplicationId ID.

string
required

JSON with the necessary information for sending the messages, including context. Variables for substitution should be enclosed in {{variableName}}.


{
  "to": "{{destination}}",
  "channel": "whatsapp",
  "sendType": "operator",
  "contentType": "template",
  "context": {
    "name": "{{name}}",
    "age": "{{age}}"
  },
  "content": {
      "template": {
          "namespace": "xxxxx_xxx_xxx_xxxxxxxx",
          "name": "new_ticket",
          "language": {
              "policy": "deterministic",
              "code": "es"
          },
          "components": [
              {
                  "type": "header",
                  "parameters": [
                      {
                          "type": "multimedia",
                          "multimediaId": "{{multimediaId}}"
                      }
                  ]
              },
              {
                  "type": "body",
                  "parameters": [
                      {
                          "type": "text",
                          "text": "{{name}}"
                      }
                  ]
              }
          ]
      }
  }
}
file
required

.CSV file with messages, context, and their recipients. Parameters:

  • The column names MUST match the jsonData variables.

Format:


  destination, multimediaId, name, age

Example:

  destination, multimediaId, name, age
  34666666666, 25, name1, 30
  349685478, 98, name2, 25
  ...
Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json