ONLINEDeliverability
Bento

Email Templates

Email Templates are the building blocks of your email marketing. They contain the subject line, HTML content, and track performance metrics like open and click rates. Templates are used in sequences, workflows, and broadcasts. The Email Templates API allows you to retrieve template details and update template content programmatically.

Available Endpoints

MethodEndpointName
GETfetch/emails/templates/:idGet Email Template
PATCHfetch/emails/templates/:idUpdate Email Template

The Email Template Model

The email template model represents a reusable email with its content and performance statistics.

Properties

  • Name
    id
    Type
    integer
    Description

    The unique identifier for the template

  • Name
    name
    Type
    string
    Description

    The name of the template

  • Name
    subject
    Type
    string
    Description

    The email subject line

  • Name
    html
    Type
    string
    Description

    The HTML content of the email

  • Name
    created_at
    Type
    datetime
    Description

    When the template was created

  • Name
    stats
    Type
    object
    Description

    Performance statistics including open_rate and click_rate


GET/v1/fetch/emails/templates/:id

Get Email Template

Retrieves a single email template by its ID, including the full HTML content and performance statistics.

Path Parameters

  • Name
    id
    Type
    integer
    Description

    The template ID

Query Parameters

  • Name
    site_uuid
    Type
    string
    Description

    Your site's unique identifier



Response

Returns the email template with its full content and stats.


PATCH/v1/fetch/emails/templates/:id

Update Email Template

Updates an existing email template. You can update the subject line, HTML content, or both.

Path Parameters

  • Name
    id
    Type
    integer
    Description

    The template ID

Query Parameters

  • Name
    site_uuid
    Type
    string
    Description

    Your site's unique identifier

Request Body

  • Name
    email_template.subject
    Type
    string
    Description

    The new email subject line (optional)

  • Name
    email_template.html
    Type
    string
    Description

    The new HTML content (optional)



Response

Returns the updated email template.