Templates

Update a template

Changed on

Updates an existing template's name, category, language, definition, or submits it for review. While the template is in review (status PENDING, or any channel awaiting a verdict) its definition, category and language are frozen and a resubmission is refused — those requests answer 409 CONFLICT_006. The display name stays editable throughout.

definition, category and language are editable only from status DRAFT, REJECTED or APPROVED. An edit to any of them on a template in another state (PAUSED, DISABLED or REVOKED) is refused with 400 VALIDATION_001 and the detail "Template (except display name) cannot be updated unless it is in draft or rejected status"; name stays editable in every state. submit_for_review on a PAUSED, DISABLED or REVOKED template is accepted and answers 200, but opens no review and does not move the status — only the reviewer can reinstate it.

Editing an APPROVED template is a live edit: the new content is stored immediately, and sending submit_for_review: true re-opens review, which returns the affected channels to PENDING so they stop sending until they are approved again. The previously approved content is never sent during re-review. Watch the per-channel templates webhook events rather than assuming the template-level status.

Templates provisioned by Sent (light-onboarding templates, whose names carry the reserved sent_ prefix) are read-only: every field is refused with 400 VALIDATION_001 and the detail "This template is read-only. Only 'submit for review' is allowed.", and only submit_for_review is accepted. A name starting with sent_ is refused for the same reason — the prefix is reserved.

put/v3/templates/{id}

Request

  • Base URL
    https://api.sent.dm
  • URL
    https://api.sent.dm/v3/templates/{id}
  • Auth
    • API key in header x-api-key
    • or HTTP bearer

Path parameters

idstring uuid required

Template ID from route parameter

Headers

Idempotency-Keystring

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.

x-profile-idstring uuid

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

sandboxboolean

Sandbox flag - when true, the operation is simulated without side effects Useful for testing integrations without actual execution

namestring nullable

Template display name

categorystring nullable

Template category: MARKETING, UTILITY, AUTHENTICATION

languagestring nullable

Template language code (e.g., en_US)

submit_for_reviewboolean

Whether to submit the template for review after updating (default: false)

Example request

{
  "name": "Updated Welcome Message",
  "category": "MARKETING",
  "submit_for_review": false,
  "sandbox": false
}

Response

Template updated successfully

successboolean

Indicates whether the request was successful

Changes

    • breaking

      added subschema #2: SentDmServicesEndpointsCustomerAPIv3TemplatesRequestsUpdateTemplateRequest_Properties to the request body allOf list

    • breaking

      added to the response property oneOf list for the response status

    • breaking

      added to the response property oneOf list for the response status

    • breaking

      added to the response property oneOf list for the response status

    • breaking

      added to the response property oneOf list for the response status

    • warning

      removed subschema #2: SentDmServicesEndpointsCustomerAPIv3RequestsUpdateTemplateRequest_Properties from the request body allOf list

    • info

      the endpoint scheme security BearerAuth was added to the API

    • info

      added the non-success response with the status

    • info

      added to the response property allOf list for the response status

    • info

      added to the response property allOf list for the response status

    • info

      added to the response property allOf list for the response status

    • info

      added to the response property allOf list for the response status

    • info

      added to the response property allOf list for the response status

    • info

      removed from the response property allOf list for the response status

    • info

      removed from the response property allOf list for the response status

    • info

      removed from the response property allOf list for the response status

    • info

      removed from the response property allOf list for the response status

    • info

      removed from the response property allOf list for the response status

    • info

      removed from the response property oneOf list for the response status

    • info

      removed from the response property oneOf list for the response status

    • info

      removed from the response property oneOf list for the response status

    • info

      removed from the response property oneOf list for the response status