Appearance
PATCH
/communication/template-text/template-texts/{id}/statusRequired scope:
templatetext:updateSets the template status to 'active', 'inactive', or 'draft'. Flips active_flg on all notificationtemplate rows for the group accordingly.
Request body ​
JSON
{
"status": "active"
}
Response ​
The template status was updated successfully.
JSON
{
"templateCode": "order-confirmation",
"name": "Order confirmation",
"channel": "email",
"contentType": "text/html",
"editorType": "html",
"mediaEnv": "prod",
"status": "active",
"templateType": 0,
"populateSource": 500,
"updatedAt": "2024-08-14T12:34:56.412",
"showInEditors": [
1099,
1056
],
"allLanguages": true
}
| Error code | Description |
|---|---|
invalid-status | status must be one of 'active', 'inactive', 'draft'. |
template-changed | Another request changed the template after it was read, so nothing was saved. Reload the template and try again. |
template-not-found | No template with the given code exists for the current company. |