Skip to main content
PUT
/
api
/
v1
/
admin
/
email
/
templates
/
{template_id}
Update Email Template
curl --request PUT \
  --url https://api.example.com/api/v1/admin/email/templates/{template_id} \
  --header 'Content-Type: application/json' \
  --data '
{
  "subject": "<string>",
  "html_body": "<string>",
  "text_body": "<string>",
  "enabled": true
}
'
{
  "id": "<string>",
  "account_id": "<string>",
  "template_type": "<string>",
  "locale": "<string>",
  "subject": "<string>",
  "html_body": "<string>",
  "text_body": "<string>",
  "enabled": true,
  "is_builtin": true,
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Headers

authorization
string | null

Path Parameters

template_id
string
required

Body

application/json

Request schema for updating an email template.

Attributes: subject: Optional new subject line. html_body: Optional new HTML body. text_body: Optional new plain text body. enabled: Optional new enabled status.

subject
string | null
html_body
string | null
text_body
string | null
enabled
boolean | null

Response

Successful Response

Response schema for email template data.

Attributes: id: Template ID (UUID string). account_id: Account ID this template belongs to. template_type: Template type identifier (e.g., 'email_verification'). locale: Language/locale code (e.g., 'en', 'es'). subject: Email subject line with Jinja2 variables. html_body: HTML email body with Jinja2 variables. text_body: Plain text email body with Jinja2 variables. enabled: Whether this template is active. is_builtin: Whether this is a built-in system template. created_at: Timestamp when the template was created. updated_at: Timestamp when the template was last updated.

id
string
required
account_id
string
required
template_type
string
required
locale
string
required
subject
string
required
html_body
string
required
text_body
string
required
enabled
boolean
required
is_builtin
boolean
required
created_at
string<date-time>
required
updated_at
string<date-time>
required