---
title: "Update email template"
method: POST
path: "/api/templates/email/update"
tags: ["templates"]
---

# Update email template

`POST /api/templates/email/update`

## Request body

- ApiEmailTemplateModel
  - `bccEmails` string[] — BCC emails
  - `cacheDataFeed` object — Cache data feed lookups for 1 hour
  - `campaignDataFields` object — Campaign-level data fields available as {{field}} merge parameters during message rendering. These fields are overridden by user and event data fields of the same name.
  - `ccEmails` string[] — CC emails
  - `clientTemplateId` string — Client template ID. Used as a secondary key to reference the template
  - `creatorUserId` string — Creator User Id
  - `dataFeedId` number — [Deprecated - use dataFeedIds instead] Id for data feed used in template rendering
  - `dataFeedIds` number[] — Ids for data feeds used in template rendering
  - `fromEmail` string — From email (must be an authorized sender)
  - `fromName` string — From name
  - `googleAnalyticsCampaignName` string — Google analytics utm_campaign value
  - `html` string — HTML contents
  - `isDefaultLocale` boolean — Ask your Iterable CSM to enroll you in the beta for this feature. Identifies if the locale associated with the response is the template’s default. If empty or flexible default locales are not enabled for the project, the project’s default locale is assigned.
  - `linkParams` LinkParam[] — Parameters to append to each URL in html contents
    - `key` string, required — Link parameter key
    - `value` string, required — Link parameter value
  - `locale` string — The locale for the content in this request. Leave empty for default locale. Iterable will automatically send the content with locale that matches a 'locale' field in the user profile.
  - `mergeDataFeedContext` object — Merge data feed contents into user context, so fields be referenced by {{field}} instead of [[field]]
  - `messageTypeId` number — Message Type Id
  - `metadata` ApiTemplateResponse
    - `campaignId` integer — Campaign ID
    - `clientTemplateId` string — Client template ID. Used as a secondary key to reference the template
    - `createdAt` string, date-time, required — Date created
    - `creatorUserId` string, required — Creator email
    - `messageTypeId` integer, required — Message type ID
    - `name` string, required — Name of the template
    - `templateId` integer, required — Template ID
    - `updatedAt` string, date-time, required — Date last updated
  - `name` string — Name of the template
  - `plainText` string — Plain text contents
  - `preheaderText` string — Preheader text
  - `replyToEmail` string — Reply to email
  - `subject` string — Subject
  - `templateId` integer, required — Email Template ID

## Response `200`

successful operation

## Other responses

- `400` — Invalid parameters
- `401` — Invalid API key

---

[API](https://skmtc.net/iterable/apis/iterable-api.md) · [All operations](https://skmtc.net/iterable/apis/iterable-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/iterable/iterable-api/revisions/afaab604b58c/schema)
