Save an email template

Save your custom version of an email type; it's used from now on. A save replaces all four regions (header, body, footer, signature): any you leave out is reset to the default, and a missing subject_override is cleared. template_mode and custom_html are kept when left out. Regions are base64-encoded HTML, and only the type's merge fields are accepted.

Prerequisites: a bearer token, the account's id (company_id) and the email type from List email types.

Authentication: Partner or Account token. company_id must be inside your own account tree (a Partner token reaches any account under the partner, an Account token only its own); otherwise 422. The account's partner must have the email templates section turned on; otherwise 403. Types managed centrally by the platform return 403.

Rate limit: none.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
integer
required
Defaults to 5994

The account. Must exist and be inside your account tree.

string
enum
required
Defaults to user_welcome

The email type, from List email types.

string

The header region. Base64-encoded HTML, up to 80,000 characters. Only merge fields from List an email's merge fields for this type are allowed. Left out or empty: the default is used.

string
Defaults to PHA+SGVsbG8gW2N1c3RvbWVyTmFtZV08L3A+

The body region. Base64-encoded HTML, up to 80,000 characters. Only merge fields from List an email's merge fields for this type are allowed. Left out or empty: the default is used.

string

The signature region. Base64-encoded HTML, up to 80,000 characters. Only merge fields from List an email's merge fields for this type are allowed. Left out or empty: the default is used.

string
length ≤ 255
Defaults to Welcome to [partnerTitle]!

The subject, as plain text (not base64), up to 255 characters. Merge fields allowed. Left out: cleared, so the default subject is used.

string
enum
Defaults to regions

regions (header, body, footer and signature) or html (one full-HTML body in custom_html). Left out: unchanged.

Allowed:
string

The full-HTML body for html mode, base64-encoded, up to 400,000 characters. Left out: the saved full-HTML version is kept.

Responses

Language
Credentials
Bearer
JWT
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json