templates

Update a template

Partial update, org-scoped. Last-write-wins unless ifUnmodifiedSince is sent. When source changes, a new templateVersion row is written (skipped if the source is unchanged from the latest version).

patch/v1/templates/{id}

Request

  • Base URL: https://api.wraps.dev
  • URL: https://api.wraps.dev/v1/templates/{id}
  • Auth: HTTP bearer

Path parameters

idstring required

Request body

namestring
subjectstring
previewTextstring
descriptionstring
sourcestring

React Email TSX source

compiledHtmlstring
compiledTextstring
ifUnmodifiedSincestring date-time

Optimistic-concurrency guard. When present and the stored updatedAt is later, the update is rejected with 409 instead of overwriting.

Response

idstring required
namestring required
descriptionstring required
subjectstring required
previewTextstring required
emailTypestring required
channelstring required
statusstring required
slugstring required
publishedAtstring required
createdAtstring required
updatedAtstring required
sourceHashstring required
lastEditedFromstring required
sourcestring
compiledHtmlstring
compiledTextstring

Changes

No recorded changes to this operation across all 1 revision of this API.