Skip to main content
POST
/
emails
/
builder
/
data
Update a template
curl --request POST \
  --url https://services.leadconnectorhq.com/emails/builder/data \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'Version: <version>' \
  --data '
{
  "locationId": "ve9EPM428h8vShlRW1KT",
  "templateId": "zYy3YOUuHxgomU1uYJty",
  "updatedBy": "zYy3YOUuHxgomU1uYJty",
  "dnd": "{elements:[], attrs:{}, templateSettings:{}}",
  "html": "",
  "editorType": "html",
  "previewText": "zYy3YOUuHxgomU1uYJty",
  "isPlainText": "false",
  "usedEmailAI": false
}
'
{
  "ok": "true",
  "traceId": "0c52e980-41f6-4be7-8c4b-32332ss",
  "previewUrl": "https://example.com",
  "templateDownloadUrl": "https://example.com",
  "versionId": "507f1f77bcf86cd799439011"
}

Authorizations

Authorization
string
header
required

Use the Access Token generated with user type as Sub-Account (OR) Private Integration Token of Sub-Account.

Headers

Version
enum<string>
required

API Version

Available options:
2021-07-28
Example:

"2021-07-28"

Body

application/json
locationId
string
required
Example:

"ve9EPM428h8vShlRW1KT"

templateId
string
required
Example:

"zYy3YOUuHxgomU1uYJty"

updatedBy
string
required
Example:

"zYy3YOUuHxgomU1uYJty"

dnd
object
required
Example:

"{elements:[], attrs:{}, templateSettings:{}}"

html
string
required
Example:

""

editorType
enum<string>
required
Available options:
html,
builder
previewText
string
Example:

"zYy3YOUuHxgomU1uYJty"

isPlainText
boolean
Example:

"false"

usedEmailAI
boolean

Whether Email AI was used

Example:

false

Response

Success

ok
string

ok

Example:

"true"

traceId
string

trace id

Example:

"0c52e980-41f6-4be7-8c4b-32332ss"

previewUrl
string

preview url

Example:

"https://example.com"

templateDownloadUrl
string

template data download url

Example:

"https://example.com"

versionId
string

version id of the saved template

Example:

"507f1f77bcf86cd799439011"

Last modified on March 4, 2026