PUT /smtp/templates/{templateId}

Update an existing transactional email template by its numeric ID or custom template identifier string. All fields in the request body are optional; only the provided fields will be updated. You can update the template name, subject, sender, reply-to address, HTML content (via htmlContent or htmlUrl), active status, tag, attachment URL, and the personalized toField. Only one of sender email or sender ID should be provided per request.

Servers

Path parameters

Name Type Required Description
templateId Yes

ID of the template. Can be a numeric template ID or a custom template identifier string.

Request headers

Name Type Required Description
Content-Type String Yes The media type of the request body.

Default value: "application/json"

Request body fields

Name Type Required Description
htmlContent String No

Required if htmlUrl is empty. If the template is designed using Drag & Drop editor via HTML content, then the design page will not have Drag & Drop editor access for that template. Body of the message (HTML must have more than 10 characters)

htmlUrl String No

Required if htmlContent is empty. URL to the body of the email (HTML)

replyTo String No

Email on which campaign recipients will be able to reply to

isActive Boolean No

Status of the template. isActive = false means template is inactive, isActive = true means template is active

sender Object No

Sender details including id or email and name (optional). Only one of either Sender's email or Sender's ID shall be passed in one request at a time. For example: {"name":"xyz", "email":"example@abc.com"} {"name":"xyz", "id":123}

sender.id Integer No

Select the sender for the template on the basis of sender id. In order to select a sender with specific pool of IP’s, dedicated ip users shall pass id (instead of email).

sender.email String No

Email of the sender

sender.name String No

Name of the sender

templateName String No

Name of the template

subject String No

Subject of the email

toField String No

To personalize the To Field. If you want to include the first name and last name of your recipient, add {FNAME} {LNAME}. These contact attributes must already exist in your Brevo account. If input parameter params used please use {{contact.FNAME}} {{contact.LNAME}} for personalization

attachmentUrl String No

Absolute url of the attachment (no local file). Extensions allowed: #### xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

tag String No

Tag of the template

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.