Create a new template
Changed onCreates a new message template with header, body, footer, and buttons. The template can be submitted for review immediately or saved as draft for later submission. There is no name field on create — the display name is derived from the template's content and can be changed afterwards with PUT /v3/templates/{id}.
Request
- Base URLhttps://api.sent.dm
- URLhttps://api.sent.dm/v3/templates
- Auth
- API key in header x-api-key
- or HTTP bearer
Headers
Unique key to ensure idempotent request processing. Must be 1-255 alphanumeric characters, hyphens, or underscores. Responses are cached for 24 hours per key per customer.
Profile UUID to scope the request to a child profile. Only organization API keys can use this header. The profile must belong to the calling organization.
Request body
Example request
{
"category": "MARKETING",
"language": "en_US",
"definition": {
"body": {
"multiChannel": {
"type": "text",
"template": "Hello {{0:variable}}! Welcome to {{1:variable}}. We are glad to have you on board.",
"variables": [
{
"id": 0,
"name": "name",
"type": "variable",
"props": {
"variableType": "text",
"sample": "John"
}
},
{
"id": 1,
"name": "company",
"type": "variable",
"props": {
"variableType": "text",
"sample": "SentDM"
}
}
]
}
},
"definitionVersion": "1.0"
},
"auto_create_for_sp": false,
"submit_for_review": false,
"sandbox": false
}Response
Template created successfully
Changes
- breaking
added
subschema #2: SentDmServicesEndpointsCustomerAPIv3TemplatesRequestsCreateTemplateRequest_Propertiesto the request bodyallOflist - breaking
added to the
response propertyoneOflist for the response status - breaking
added to the
response propertyoneOflist for the response status - breaking
added to the
response propertyoneOflist for the response status - warning
removed
subschema #2: SentDmServicesEndpointsCustomerAPIv3RequestsCreateTemplateRequest_Propertiesfrom the request bodyallOflist - info
the endpoint scheme security
BearerAuthwas added to the API - info
added to the
response propertyallOflist for the response status - info
added to the
response propertyallOflist for the response status - info
added to the
response propertyallOflist for the response status - info
added to the
response propertyallOflist for the response status - info
removed from the
response propertyallOflist for the response status - info
removed from the
response propertyallOflist for the response status - info
removed from the
response propertyallOflist for the response status - info
removed from the
response propertyallOflist for the response status - info
removed from the
response propertyoneOflist for the response status - info
removed from the
response propertyoneOflist for the response status - info
removed from the
response propertyoneOflist for the response status
- breaking