POST Create Template​
POST
/templates
Create a new email template. If template_id is provided, the request is forwarded to the update endpoint instead. The template data should be passed as a nested template object containing the post fields, email subject, edit type, design template, and settings.
Authorizations​
ApplicationPasswords
WordPress Application Passwords — use Basic auth with your WordPress username and an application password in the format: username:application_password
Type
API Key (header: Authorization)
Request Body​
application/json
JSON
{
"template_id": 0,
"template": {
"post_title": "string",
"post_content": "string",
"post_excerpt": "string",
"email_subject": "string",
"edit_type": "html",
"design_template": "string",
"settings": {
"template_config": {
"content_padding": 20,
"additionalProperties": "string"
},
"footer_settings": {
"custom_footer": "no",
"footer_content": "string"
}
}
}
}
Responses​
Template created successfully.
application/json
JSON
{
"message": "string",
"template_id": 0
}