Select the default email template

posthttps://api.expiryedge.com/v1/emailTemplateSelect
editor or admin60/minJede Methode
Anfrage
curl -X POST 'https://api.expiryedge.com/v1/emailTemplateSelect' \
  -H "Authorization: Bearer $EXPIRYEDGE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "templateId": "et_Qw81zd",
  "type": "expiry_reminder"
}'
Antwort
{
  "selected": {
    "expiry_reminder": "et_Qw81zd"
  }
}

Sets the organization default template for a type. templateId: null reverts to the built-in default (allowed on any plan); selecting a custom template requires the plan feature (402).

Body-Parameter

application/json
  • templateIdstring | null
    Template id, or null / empty to deselect.
  • typestring
    Defaults to expiry_reminder.
    Erlaubtexpiry_reminder

Rückgabe

200
The selection after the change.
  • selectedmap of string
    Template type -> selected template id after the change.

Fehler

400
The request is missing required fields or contains invalid values.
401
Missing, expired or invalid bearer token.
402
The organization plan does not include custom email templates.
403
Authenticated, but your role or organization does not allow this action.
404
The record does not exist or is not in your organization.
429
Too many requests for this endpoint from your IP. Wait Retry-After seconds.
500
Unexpected server error. Retry later; quote requestId to support.