> ## Documentation Index
> Fetch the complete documentation index at: https://developers.hubspot.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieve email revisions

> Get a list of all versions of a marketing email, with each entry including the full state of that particular version. To view the most recent version, sort by the updatedAt parameter. 

export const ScopesList = ({scopes = [], description = "This API requires one of the following scopes:"}) => {
  if (!scopes || scopes.length === 0) {
    return null;
  }
  const sortedScopes = scopes.sort((a, b) => a.localeCompare(b));
  return <div>
      <div className="text-sm mb-2">{description}</div>
      <div>
        {sortedScopes.map((scope, index) => <div key={index}>
            <code>
              <span className="text-xs">{scope}</span>
            </code>
          </div>)}
      </div>
    </div>;
};

export const SupportedProducts = ({marketing, sales, service, cms, data, commerce, crm, marketingLevel, salesLevel, serviceLevel, cmsLevel, dataLevel, commerceLevel, crmLevel}) => {
  const translations = {
    description: "Requires one of the following products or higher.",
    productNames: {
      marketing: "Marketing Hub",
      sales: "Sales Hub",
      service: "Service Hub",
      cms: "Content Hub",
      data: "Data Hub",
      commerce: "Revenue Hub",
      crm: "Smart CRM"
    },
    tiers: {
      free: "Free",
      starter: "Starter",
      professional: "Professional",
      enterprise: "Enterprise"
    }
  };
  const translateTier = tier => {
    if (!tier) return '';
    const lowerTier = tier.toLowerCase();
    return translations.tiers[lowerTier] || tier;
  };
  const products = [{
    name: marketing ? translations.productNames.marketing : '',
    level: translateTier(marketingLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/MarketingHub.svg",
    alt: "Marketing Hub"
  }, {
    name: sales ? translations.productNames.sales : '',
    level: translateTier(salesLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/SalesHub.svg",
    alt: "Sales Hub"
  }, {
    name: service ? translations.productNames.service : '',
    level: translateTier(serviceLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/ServiceHub.svg",
    alt: "Service Hub"
  }, {
    name: cms ? translations.productNames.cms : '',
    level: translateTier(cmsLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/ContentHub.svg",
    alt: "Content Hub"
  }, {
    name: data ? translations.productNames.data : '',
    level: translateTier(dataLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/DataHub.svg",
    alt: "Data Hub"
  }, {
    name: commerce ? translations.productNames.commerce : '',
    level: translateTier(commerceLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base/subscription_key_icons/commerce_icon.svg",
    alt: "Revenue Hub"
  }, {
    name: crm ? translations.productNames.crm : '',
    level: translateTier(crmLevel),
    icon: "https://www.hubspot.com/hubfs/Knowledge_Base_2023-24-25/developer/icons/SmartCRM.svg",
    alt: "Smart CRM"
  }].filter(product => product.name && product.level);
  if (products.length === 0) return null;
  return <div>
      <div className="text-sm mb-2">{translations.description}</div>
      <div className={`grid ${products.length === 1 ? 'grid-cols-1' : 'grid-cols-2'} gap-1.5`}>
        {products.map((product, index) => <div key={index} style={{
    display: 'flex',
    alignItems: 'center'
  }}>
            <img src={product.icon} alt={product.alt} className="w-3.5 h-3.5 mr-1.5 mt-2.5 mb-2.5 flex-shrink-0 align-middle" />
            <span className="font-medium mr-1 text-sm">{product.name} -</span>
            <span className="text-sm">{product.level}</span>
          </div>)}
      </div>
    </div>;
};

<AccordionGroup>
  <Accordion title="Supported products" defaultOpen="true" icon="cubes">
    <SupportedProducts marketing={true} sales={true} service={true} cms={true} marketingLevel="FREE" salesLevel="FREE" serviceLevel="FREE" cmsLevel="FREE" />
  </Accordion>

  <Accordion title="Required Scopes" icon="key">
    <ScopesList
      scopes={[
  'content'
]}
    />
  </Accordion>
</AccordionGroup>


## OpenAPI

````yaml specs/2026-03/marketing-marketing-emails-v2026-03.json GET /marketing/emails/2026-03/{emailId}/revisions
openapi: 3.0.1
info:
  title: Marketing Emails
  description: Basepom for all HubSpot Projects
  version: 2026-03
  x-hubspot-product-tier-requirements:
    marketing: FREE
    sales: FREE
    service: FREE
    cms: FREE
    commerce: FREE
    crmHub: FREE
    dataHub: FREE
  x-hubspot-api-use-case: >-
    You want to programmatically create marketing emails, then retrieve their
    send statistics at a later time.
  x-hubspot-introduction: >-
    Use the marketing email API to create, manage, and retrieve details about
    marketing emails. You can also this use API to retrieve statistics related
    to email sends, similar to what you can see in HubSpot.
servers:
  - url: https://api.hubapi.com
security: []
tags:
  - name: Basic
  - name: Emails
paths:
  /marketing/emails/2026-03/{emailId}/revisions:
    get:
      tags:
        - Emails
      summary: Get revisions of a marketing email
      description: >-
        Get a list of all versions of a marketing email, with each entry
        including the full state of that particular version. To view the most
        recent version, sort by the updatedAt parameter. 
      operationId: get-/marketing/emails/2026-03/{emailId}/revisions_getRevisions
      parameters:
        - name: emailId
          in: path
          description: The unique identifier of the email for which to retrieve revisions.
          required: true
          style: simple
          explode: false
          schema:
            type: string
        - name: after
          in: query
          description: >-
            The paging cursor token of the last successfully read resource will
            be returned as the `paging.next.after` JSON property of a paged
            response containing more results.
          required: false
          style: form
          explode: true
          schema:
            type: string
        - name: before
          in: query
          description: >-
            A cursor token for pagination to retrieve results before a specific
            point.
          required: false
          style: form
          explode: true
          schema:
            type: string
        - name: limit
          in: query
          description: The maximum number of results to display per page.
          required: false
          style: form
          explode: true
          schema:
            type: integer
            format: int32
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/CollectionResponseWithTotalPublicEmailVersion
        default:
          $ref: '#/components/responses/Error'
          description: ''
      security:
        - oauth2:
            - marketing.email.read
        - oauth2:
            - marketing.email.write
        - oauth2:
            - content
components:
  schemas:
    CollectionResponseWithTotalPublicEmailVersion:
      required:
        - results
        - total
      type: object
      properties:
        paging:
          $ref: '#/components/schemas/Paging'
        results:
          type: array
          description: >-
            An array of email version objects, each conforming to the
            VersionPublicEmail schema.
          items:
            $ref: '#/components/schemas/VersionPublicEmail'
        total:
          type: integer
          description: >-
            An integer representing the total number of email version results
            available.
          format: int32
    Paging:
      type: object
      properties:
        next:
          $ref: '#/components/schemas/NextPage'
        prev:
          $ref: '#/components/schemas/PreviousPage'
      description: >-
        Represents the pagination information for navigating through a list of
        results in the API. It provides details on how to access the previous or
        next set of results.
    VersionPublicEmail:
      required:
        - id
        - object
        - updatedAt
        - user
      type: object
      properties:
        id:
          type: string
          description: ID of this marketing email version.
        object:
          $ref: '#/components/schemas/PublicEmail'
        updatedAt:
          type: string
          description: >-
            The date and time of the last update to the email, in ISO8601
            representation.
          format: date-time
        user:
          $ref: '#/components/schemas/VersionUser'
    Error:
      required:
        - category
        - correlationId
        - message
      type: object
      properties:
        category:
          type: string
          description: The error category
        context:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: Context about the error condition
          example: >-
            {invalidPropertyName=[propertyValue], missingScopes=[scope1,
            scope2]}
        correlationId:
          type: string
          description: >-
            A unique identifier for the request. Include this value with any
            error reports or support tickets
          format: uuid
          example: aeb5f871-7f07-4993-9211-075dc63e7cbf
        errors:
          type: array
          description: further information about the error
          items:
            $ref: '#/components/schemas/ErrorDetail'
        links:
          type: object
          additionalProperties:
            type: string
          description: >-
            A map of link names to associated URIs containing documentation
            about the error or recommended remediation steps
        message:
          type: string
          description: >-
            A human readable message describing the error along with remediation
            steps where appropriate
          example: An error occurred
        subCategory:
          type: string
          description: >-
            A specific category that contains more specific detail about the
            error
      description: >-
        Represents an error response returned by the API when an operation
        fails. This component is used in various endpoints to provide detailed
        information about the error encountered.
      example:
        message: Invalid input (details will vary based on the error)
        correlationId: aeb5f871-7f07-4993-9211-075dc63e7cbf
        category: VALIDATION_ERROR
        links:
          knowledge-base: https://www.hubspot.com/products/service/knowledge-base
    NextPage:
      required:
        - after
      type: object
      properties:
        after:
          type: string
          description: >-
            The cursor token value to get the next set of results. Use this
            value as query parameter (&after=...) to obtain the next page.
        link:
          type: string
          description: The link to the next page.
      description: >-
        Specifies the paging information needed to retrieve the next set of
        results in a paginated API response
    PreviousPage:
      required:
        - before
      type: object
      properties:
        before:
          type: string
          description: >-
            The cursor token value to get the previous set of results. Use this
            value as query parameter (&before=...) to obtain the previous page.
        link:
          type: string
          description: The link to the previous page.
      description: >-
        specifies the paging information needed to retrieve the previous set of
        results in a paginated API response
    PublicEmail:
      required:
        - isAb
      type: object
      properties:
        activeDomain:
          type: string
          description: The active domain of the email.
        allEmailCampaignIds:
          type: array
          description: List of emailCampaignIds.
          items:
            type: string
        archived:
          type: boolean
          description: Determines if the email is archived or not.
        businessUnitId:
          type: string
          description: The ID of the business unit associated with the email.
        campaign:
          type: string
          description: The ID of the campaign this email is associated to.
        campaignName:
          type: string
          description: The name of the campaign.
        campaignUtm:
          type: string
          description: The UTM parameters associated with the email's campaign.
        clonedFrom:
          type: string
          description: The ID of the email this email was cloned from.
        content:
          $ref: '#/components/schemas/PublicEmailContent'
        createdAt:
          type: string
          description: >-
            The date and time of the email's creation, in ISO8601
            representation.
          format: date-time
        createdById:
          type: string
          description: The id of the user who created the email.
        deletedAt:
          type: string
          description: >-
            The date and time the email was deleted at, in ISO8601
            representation.
          format: date-time
        emailCampaignGroupId:
          type: string
          description: The ID of the email campaign group associated with the email.
        emailTemplateMode:
          type: string
          description: >-
            The mode of the email template, such as 'DESIGN_MANAGER' or
            'DRAG_AND_DROP'.
          enum:
            - DESIGN_MANAGER
            - DRAG_AND_DROP
        feedbackSurveyId:
          type: string
          description: The ID of the feedback survey linked to the email.
        folderId:
          type: integer
          description: >-
            Deprecated — this field is no longer functional. Use folderIdV2
            instead.
          format: int64
        folderIdV2:
          type: integer
          description: >-
            The version 2 ID of the folder where the email is stored, as a
            64-bit integer.
          format: int64
        from:
          $ref: '#/components/schemas/PublicEmailFromDetails'
        id:
          type: string
          description: The email ID.
        isAb:
          type: boolean
          description: A boolean indicating whether the email is part of an A/B test.
        isPublished:
          type: boolean
          description: Returns the published status of the email. This is read only.
        isTransactional:
          type: boolean
          description: >-
            Returns whether the email is a transactional email or not. This is
            read only.
        jitterSendTime:
          type: boolean
          description: A boolean indicating whether to apply a jitter to the send time.
        language:
          type: string
          description: >-
            The language code of the email, following ISO 639-1 and ISO 3166-1
            standards.
          enum:
            - aa
            - ab
            - ae
            - af
            - af-na
            - af-za
            - agq
            - agq-cm
            - ak
            - ak-gh
            - am
            - am-et
            - an
            - ann
            - ann-ng
            - ar
            - ar-001
            - ar-ae
            - ar-bh
            - ar-dj
            - ar-dz
            - ar-eg
            - ar-eh
            - ar-er
            - ar-il
            - ar-iq
            - ar-jo
            - ar-km
            - ar-kw
            - ar-lb
            - ar-ly
            - ar-ma
            - ar-mr
            - ar-om
            - ar-ps
            - ar-qa
            - ar-sa
            - ar-sd
            - ar-so
            - ar-ss
            - ar-sy
            - ar-td
            - ar-tn
            - ar-ye
            - as
            - as-in
            - asa
            - asa-tz
            - ast
            - ast-es
            - av
            - ay
            - az
            - az-az
            - ba
            - bal
            - bal-pk
            - bas
            - bas-cm
            - be
            - be-by
            - bem
            - bem-zm
            - bez
            - bez-tz
            - bg
            - bg-bg
            - bgc
            - bgc-in
            - bho
            - bho-in
            - bi
            - blo
            - blo-bj
            - bm
            - bm-ml
            - bn
            - bn-bd
            - bn-in
            - bo
            - bo-cn
            - bo-in
            - br
            - br-fr
            - brx
            - brx-in
            - bs
            - bs-ba
            - ca
            - ca-ad
            - ca-es
            - ca-fr
            - ca-it
            - ccp
            - ccp-bd
            - ccp-in
            - ce
            - ce-ru
            - ceb
            - ceb-ph
            - cgg
            - cgg-ug
            - ch
            - chr
            - chr-us
            - ckb
            - ckb-iq
            - ckb-ir
            - co
            - cr
            - cs
            - cs-cz
            - csw
            - csw-ca
            - cu
            - cu-ru
            - cv
            - cv-ru
            - cy
            - cy-gb
            - da
            - da-dk
            - da-gl
            - dav
            - dav-ke
            - de
            - de-at
            - de-be
            - de-ch
            - de-de
            - de-gr
            - de-it
            - de-li
            - de-lu
            - dje
            - dje-ne
            - doi
            - doi-in
            - dsb
            - dsb-de
            - dua
            - dua-cm
            - dv
            - dyo
            - dyo-sn
            - dz
            - dz-bt
            - ebu
            - ebu-ke
            - ee
            - ee-gh
            - ee-tg
            - el
            - el-cy
            - el-gr
            - en
            - en-001
            - en-150
            - en-ae
            - en-ag
            - en-ai
            - en-as
            - en-at
            - en-au
            - en-bb
            - en-be
            - en-bi
            - en-bm
            - en-bs
            - en-bw
            - en-bz
            - en-ca
            - en-cc
            - en-ch
            - en-ck
            - en-cm
            - en-cn
            - en-cx
            - en-cy
            - en-cz
            - en-de
            - en-dg
            - en-dk
            - en-dm
            - en-ee
            - en-eg
            - en-er
            - en-es
            - en-fi
            - en-fj
            - en-fk
            - en-fm
            - en-fr
            - en-gb
            - en-gd
            - en-gg
            - en-gh
            - en-gi
            - en-gm
            - en-gs
            - en-gu
            - en-gy
            - en-hk
            - en-hu
            - en-id
            - en-ie
            - en-il
            - en-im
            - en-in
            - en-io
            - en-it
            - en-je
            - en-jm
            - en-ke
            - en-ki
            - en-kn
            - en-ky
            - en-lc
            - en-lr
            - en-ls
            - en-lu
            - en-mg
            - en-mh
            - en-mo
            - en-mp
            - en-ms
            - en-mt
            - en-mu
            - en-mv
            - en-mw
            - en-mx
            - en-my
            - en-na
            - en-nf
            - en-ng
            - en-nl
            - en-no
            - en-nr
            - en-nu
            - en-nz
            - en-pg
            - en-ph
            - en-pk
            - en-pl
            - en-pn
            - en-pr
            - en-pt
            - en-pw
            - en-ro
            - en-rw
            - en-sb
            - en-sc
            - en-sd
            - en-se
            - en-sg
            - en-sh
            - en-si
            - en-sk
            - en-sl
            - en-ss
            - en-sx
            - en-sz
            - en-tc
            - en-th
            - en-tk
            - en-tn
            - en-to
            - en-tt
            - en-tv
            - en-tz
            - en-ug
            - en-um
            - en-us
            - en-vc
            - en-vg
            - en-vi
            - en-vn
            - en-vu
            - en-ws
            - en-za
            - en-zm
            - en-zw
            - eo
            - eo-001
            - es
            - es-419
            - es-ar
            - es-bo
            - es-br
            - es-bz
            - es-cl
            - es-co
            - es-cr
            - es-cu
            - es-do
            - es-ea
            - es-ec
            - es-es
            - es-gq
            - es-gt
            - es-hn
            - es-ic
            - es-mx
            - es-ni
            - es-pa
            - es-pe
            - es-ph
            - es-pr
            - es-py
            - es-sv
            - es-us
            - es-uy
            - es-ve
            - et
            - et-ee
            - eu
            - eu-es
            - ewo
            - ewo-cm
            - fa
            - fa-af
            - fa-ir
            - ff
            - ff-bf
            - ff-cm
            - ff-gh
            - ff-gm
            - ff-gn
            - ff-gw
            - ff-lr
            - ff-mr
            - ff-ne
            - ff-ng
            - ff-sl
            - ff-sn
            - fi
            - fi-fi
            - fil
            - fil-ph
            - fj
            - fo
            - fo-dk
            - fo-fo
            - fr
            - fr-be
            - fr-bf
            - fr-bi
            - fr-bj
            - fr-bl
            - fr-ca
            - fr-cd
            - fr-cf
            - fr-cg
            - fr-ch
            - fr-ci
            - fr-cm
            - fr-dj
            - fr-dz
            - fr-fr
            - fr-ga
            - fr-gf
            - fr-gn
            - fr-gp
            - fr-gq
            - fr-ht
            - fr-km
            - fr-lu
            - fr-ma
            - fr-mc
            - fr-mf
            - fr-mg
            - fr-ml
            - fr-mq
            - fr-mr
            - fr-mu
            - fr-nc
            - fr-ne
            - fr-pf
            - fr-pm
            - fr-re
            - fr-rw
            - fr-sc
            - fr-sn
            - fr-sy
            - fr-td
            - fr-tg
            - fr-tn
            - fr-vu
            - fr-wf
            - fr-yt
            - frr
            - frr-de
            - fur
            - fur-it
            - fy
            - fy-nl
            - ga
            - ga-gb
            - ga-ie
            - gaa
            - gaa-gh
            - gd
            - gd-gb
            - gl
            - gl-es
            - gn
            - gsw
            - gsw-ch
            - gsw-fr
            - gsw-li
            - gu
            - gu-in
            - guz
            - guz-ke
            - gv
            - gv-im
            - ha
            - ha-gh
            - ha-ne
            - ha-ng
            - haw
            - haw-us
            - he
            - he-il
            - hi
            - hi-in
            - hmn
            - ho
            - hr
            - hr-ba
            - hr-hr
            - hsb
            - hsb-de
            - ht
            - ht-ht
            - hu
            - hu-hu
            - hy
            - hy-am
            - hz
            - ia
            - ia-001
            - id
            - id-id
            - ie
            - ie-ee
            - ig
            - ig-ng
            - ii
            - ii-cn
            - ik
            - io
            - is
            - is-is
            - it
            - it-ch
            - it-it
            - it-sm
            - it-va
            - iu
            - ja
            - ja-jp
            - jgo
            - jgo-cm
            - jmc
            - jmc-tz
            - jv
            - jv-id
            - ka
            - ka-ge
            - kab
            - kab-dz
            - kam
            - kam-ke
            - kar
            - kde
            - kde-tz
            - kea
            - kea-cv
            - kg
            - kgp
            - kgp-br
            - kh
            - khq
            - khq-ml
            - ki
            - ki-ke
            - kj
            - kk
            - kk-kz
            - kkj
            - kkj-cm
            - kl
            - kl-gl
            - kln
            - kln-ke
            - km
            - km-kh
            - kn
            - kn-in
            - ko
            - ko-cn
            - ko-kp
            - ko-kr
            - kok
            - kok-in
            - kr
            - ks
            - ks-in
            - ksb
            - ksb-tz
            - ksf
            - ksf-cm
            - ksh
            - ksh-de
            - ku
            - ku-tr
            - kv
            - kw
            - kw-gb
            - kxv
            - kxv-in
            - ky
            - ky-kg
            - la
            - lag
            - lag-tz
            - lb
            - lb-lu
            - lg
            - lg-ug
            - li
            - lij
            - lij-it
            - lkt
            - lkt-us
            - lmo
            - lmo-it
            - ln
            - ln-ao
            - ln-cd
            - ln-cf
            - ln-cg
            - lo
            - lo-la
            - lrc
            - lrc-iq
            - lrc-ir
            - lt
            - lt-lt
            - lu
            - lu-cd
            - luo
            - luo-ke
            - luy
            - luy-ke
            - lv
            - lv-lv
            - mai
            - mai-in
            - mas
            - mas-ke
            - mas-tz
            - mdf
            - mdf-ru
            - mer
            - mer-ke
            - mfe
            - mfe-mu
            - mg
            - mg-mg
            - mgh
            - mgh-mz
            - mgo
            - mgo-cm
            - mh
            - mi
            - mi-nz
            - mk
            - mk-mk
            - ml
            - ml-in
            - mn
            - mn-mn
            - mni
            - mni-in
            - mr
            - mr-in
            - ms
            - ms-bn
            - ms-id
            - ms-my
            - ms-sg
            - mt
            - mt-mt
            - mua
            - mua-cm
            - my
            - my-mm
            - mzn
            - mzn-ir
            - na
            - naq
            - naq-na
            - nb
            - nb-no
            - nb-sj
            - nd
            - nd-zw
            - nds
            - nds-de
            - nds-nl
            - ne
            - ne-in
            - ne-np
            - ng
            - nl
            - nl-aw
            - nl-be
            - nl-bq
            - nl-ch
            - nl-cw
            - nl-lu
            - nl-nl
            - nl-sr
            - nl-sx
            - nmg
            - nmg-cm
            - nn
            - nn-no
            - nnh
            - nnh-cm
            - 'no'
            - no-no
            - nqo
            - nqo-gn
            - nr
            - nso
            - nso-za
            - nus
            - nus-ss
            - nv
            - ny
            - nyn
            - nyn-ug
            - oc
            - oc-es
            - oc-fr
            - oj
            - om
            - om-et
            - om-ke
            - or
            - or-in
            - os
            - os-ge
            - os-ru
            - pa
            - pa-in
            - pa-pk
            - pcm
            - pcm-ng
            - pi
            - pis
            - pis-sb
            - pl
            - pl-pl
            - prg
            - prg-001
            - ps
            - ps-af
            - ps-pk
            - pt
            - pt-ao
            - pt-br
            - pt-ch
            - pt-cv
            - pt-gq
            - pt-gw
            - pt-lu
            - pt-mo
            - pt-mz
            - pt-pt
            - pt-st
            - pt-tl
            - qu
            - qu-bo
            - qu-ec
            - qu-pe
            - raj
            - raj-in
            - rm
            - rm-ch
            - rn
            - rn-bi
            - ro
            - ro-md
            - ro-ro
            - rof
            - rof-tz
            - ru
            - ru-by
            - ru-kg
            - ru-kz
            - ru-md
            - ru-ru
            - ru-ua
            - rw
            - rw-rw
            - rwk
            - rwk-tz
            - sa
            - sa-in
            - sah
            - sah-ru
            - saq
            - saq-ke
            - sat
            - sat-in
            - sbp
            - sbp-tz
            - sc
            - sc-it
            - sd
            - sd-in
            - sd-pk
            - se
            - se-fi
            - se-no
            - se-se
            - seh
            - seh-mz
            - ses
            - ses-ml
            - sg
            - sg-cf
            - shi
            - shi-ma
            - si
            - si-lk
            - sk
            - sk-sk
            - sl
            - sl-si
            - sm
            - smn
            - smn-fi
            - sms
            - sms-fi
            - sn
            - sn-zw
            - so
            - so-dj
            - so-et
            - so-ke
            - so-so
            - sq
            - sq-al
            - sq-mk
            - sq-xk
            - sr
            - sr-ba
            - sr-cs
            - sr-me
            - sr-rs
            - sr-xk
            - ss
            - st
            - st-ls
            - st-za
            - su
            - su-id
            - sv
            - sv-ax
            - sv-fi
            - sv-se
            - sw
            - sw-cd
            - sw-ke
            - sw-tz
            - sw-ug
            - sy
            - syr
            - syr-iq
            - syr-sy
            - szl
            - szl-pl
            - ta
            - ta-in
            - ta-lk
            - ta-my
            - ta-sg
            - te
            - te-in
            - teo
            - teo-ke
            - teo-ug
            - tg
            - tg-tj
            - th
            - th-th
            - ti
            - ti-er
            - ti-et
            - tk
            - tk-tm
            - tl
            - tn
            - tn-bw
            - tn-za
            - to
            - to-to
            - tok
            - tok-001
            - tr
            - tr-cy
            - tr-tr
            - ts
            - tt
            - tt-ru
            - tw
            - twq
            - twq-ne
            - ty
            - tzm
            - tzm-ma
            - ug
            - ug-cn
            - uk
            - uk-ua
            - ur
            - ur-in
            - ur-pk
            - uz
            - uz-af
            - uz-uz
            - vai
            - vai-lr
            - ve
            - vec
            - vec-it
            - vi
            - vi-vn
            - vmw
            - vmw-mz
            - vo
            - vo-001
            - vun
            - vun-tz
            - wa
            - wae
            - wae-ch
            - wo
            - wo-sn
            - xh
            - xh-za
            - xnr
            - xnr-in
            - xog
            - xog-ug
            - yav
            - yav-cm
            - yi
            - yi-001
            - yi-ua
            - yo
            - yo-bj
            - yo-ng
            - yrl
            - yrl-br
            - yrl-co
            - yrl-ve
            - yue
            - yue-cn
            - yue-hk
            - yue-mo
            - za
            - za-cn
            - zgh
            - zgh-ma
            - zh
            - zh-cn
            - zh-hans
            - zh-hant
            - zh-hk
            - zh-mo
            - zh-my
            - zh-sg
            - zh-tw
            - zu
            - zu-za
        name:
          type: string
          description: The name of the email, as displayed on the email dashboard.
        previewKey:
          type: string
          description: The preview key for the email.
        primaryEmailCampaignId:
          type: string
          description: The primary email campaign ID associated with the email.
        publishDate:
          type: string
          description: >-
            The date and time the email is scheduled for, in ISO8601
            representation. This is only used in local time or scheduled emails.
          format: date-time
        publishedAt:
          type: string
          description: >-
            The date and time the email was published at, in ISO8601
            representation.
          format: date-time
        publishedByEmail:
          type: string
          description: Email of the user who published/sent the email.
        publishedById:
          type: string
          description: The ID of the user who published the email.
        publishedByName:
          type: string
          description: Name of the user who published the email.
        rssData:
          $ref: '#/components/schemas/PublicRssEmailDetails'
        sendOnPublish:
          type: boolean
          description: Determines whether the email will be sent immediately on publish.
        state:
          type: string
          description: The email state.
          enum:
            - AGENT_GENERATED
            - AUTOMATED
            - AUTOMATED_AB
            - AUTOMATED_AB_VARIANT
            - AUTOMATED_DRAFT
            - AUTOMATED_DRAFT_AB
            - AUTOMATED_DRAFT_ABVARIANT
            - AUTOMATED_FOR_FORM
            - AUTOMATED_FOR_FORM_BUFFER
            - AUTOMATED_FOR_FORM_DRAFT
            - AUTOMATED_FOR_FORM_LEGACY
            - AUTOMATED_LOSER_ABVARIANT
            - AUTOMATED_SENDING
            - BLOG_EMAIL_DRAFT
            - BLOG_EMAIL_PUBLISHED
            - DRAFT
            - DRAFT_AB
            - DRAFT_AB_VARIANT
            - ERROR
            - LOSER_AB_VARIANT
            - PAGE_STUB
            - PRE_PROCESSING
            - PROCESSING
            - PUBLISHED
            - PUBLISHED_AB
            - PUBLISHED_AB_VARIANT
            - PUBLISHED_OR_SCHEDULED
            - RSS_TO_EMAIL_DRAFT
            - RSS_TO_EMAIL_PUBLISHED
            - SCHEDULED
            - SCHEDULED_AB
            - SCHEDULED_OR_PUBLISHED
        stats:
          $ref: '#/components/schemas/EmailStatisticsData'
        subcategory:
          type: string
          description: The email subcategory.
        subject:
          type: string
          description: The subject of the email.
        subscriptionDetails:
          $ref: '#/components/schemas/PublicEmailSubscriptionDetails'
        teamsWithAccess:
          type: array
          description: An array of team IDs who have access to the email.
          items:
            type: string
        testing:
          $ref: '#/components/schemas/PublicEmailTestingDetails'
        to:
          $ref: '#/components/schemas/PublicEmailToDetails'
        type:
          type: string
          description: >-
            The email type, this is derived from other properties on the email
            such as subcategory.
          enum:
            - AB_EMAIL
            - AUTOMATED_AB_EMAIL
            - AUTOMATED_EMAIL
            - BATCH_EMAIL
            - BLOG_EMAIL
            - BLOG_EMAIL_CHILD
            - FEEDBACK_CES_EMAIL
            - FEEDBACK_CUSTOM_EMAIL
            - FEEDBACK_CUSTOM_SURVEY_EMAIL
            - FEEDBACK_NPS_EMAIL
            - FOLLOWUP_EMAIL
            - LEADFLOW_EMAIL
            - LOCALTIME_EMAIL
            - MANAGE_PREFERENCES_EMAIL
            - MARKETING_SINGLE_SEND_API
            - MEMBERSHIP_EMAIL_VERIFICATION_EMAIL
            - MEMBERSHIP_FOLLOW_UP_EMAIL
            - MEMBERSHIP_OTP_LOGIN_EMAIL
            - MEMBERSHIP_PASSWORD_RESET_EMAIL
            - MEMBERSHIP_PASSWORD_SAVED_EMAIL
            - MEMBERSHIP_PASSWORDLESS_AUTH_EMAIL
            - MEMBERSHIP_REGISTRATION_EMAIL
            - MEMBERSHIP_REGISTRATION_FOLLOW_UP_EMAIL
            - MEMBERSHIP_VERIFICATION_EMAIL
            - OPTIN_EMAIL
            - OPTIN_FOLLOWUP_EMAIL
            - RESUBSCRIBE_EMAIL
            - RSS_EMAIL
            - RSS_EMAIL_CHILD
            - SINGLE_SEND_API
            - SMTP_TOKEN
            - TICKET_EMAIL
        unpublishedAt:
          type: string
          description: >-
            The date and time when the email was unpublished, in ISO 8601
            format.
          format: date-time
        updatedAt:
          type: string
          description: >-
            The date and time of the last update to the email, in ISO8601
            representation.
          format: date-time
        updatedById:
          type: string
          description: The id of the user who last updated the email.
        usersWithAccess:
          type: array
          description: An array of user IDs who have access to the email.
          items:
            type: string
        webversion:
          $ref: '#/components/schemas/PublicWebversionDetails'
        workflowNames:
          type: array
          description: >-
            Names of workflows in which the email is used within a "send email"
            action.
          items:
            type: string
    VersionUser:
      required:
        - email
        - fullName
        - id
      type: object
      properties:
        email:
          type: string
          description: Email address of the user.
        fullName:
          type: string
          description: First and last name of the user.
        id:
          type: string
          description: ID of the user.
    ErrorDetail:
      required:
        - message
      type: object
      properties:
        code:
          type: string
          description: The status code associated with the error detail
        context:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: Context about the error condition
          example: '{missingScopes=[scope1, scope2]}'
        in:
          type: string
          description: The name of the field or parameter in which the error was found.
        message:
          type: string
          description: >-
            A human readable message describing the error along with remediation
            steps where appropriate
        subCategory:
          type: string
          description: >-
            A specific category that contains more specific detail about the
            error
      description: >-
        Represents detailed information about an error that occurred in the API.
        This component is used to provide additional context and specifics about
        errors, typically as part of an error response.
    PublicEmailContent:
      type: object
      properties:
        flexAreas:
          type: object
          additionalProperties:
            type: object
            properties: {}
          description: >-
            An object containing flexible area configurations, where each key is
            an area identifier and the value is an object with area properties.
        plainTextVersion:
          type: string
          description: A string containing the plain text version of the email content.
        smartFields:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/SmartEmailField'
          description: >-
            An object containing smart field configurations, where each key is a
            field identifier and the value is a SmartEmailField object.
        styleSettings:
          $ref: '#/components/schemas/PublicEmailStyleSettings'
        templatePath:
          type: string
          description: >-
            A string representing the path to the email template used for this
            email.
        themeSettingsValues:
          type: object
          additionalProperties:
            type: object
            properties: {}
          description: >-
            An object containing theme settings values, where each key is a
            setting identifier and the value is an object with setting
            properties.
        widgetContainers:
          type: object
          additionalProperties:
            type: object
            properties: {}
          description: >-
            An object containing widget container configurations, where each key
            is a container identifier and the value is an object with container
            properties.
        widgets:
          type: object
          additionalProperties:
            type: object
            properties: {}
          description: >-
            An object containing widget configurations, where each key is a
            widget identifier and the value is an object with widget properties.
    PublicEmailFromDetails:
      type: object
      properties:
        customReplyTo:
          type: string
          description: The reply to recipients will see.
        fromName:
          type: string
          description: The name recipients will see.
        replyTo:
          type: string
          description: >-
            The from address and reply to email address (if no customReplyTo
            defined) recipients will see.
    PublicRssEmailDetails:
      type: object
      properties:
        blogEmailType:
          type: string
          description: A string representing the type of blog email.
        blogImageMaxWidth:
          type: integer
          description: The maximum width for images in the blog, specified as an integer.
          format: int32
        blogLayout:
          type: string
          description: >-
            The layout of the blog in the email. Valid values include
            'SUMMARY_NO_FEATURED_IMAGE', 'SUMMARY_WITH_FEATURED_IMAGE', and
            'FULL_POST'.
          enum:
            - FULL_POST
            - SUMMARY_NO_FEATURED_IMAGE
            - SUMMARY_WITH_FEATURED_IMAGE
        hubspotBlogId:
          type: string
          description: >-
            The unique identifier of the HubSpot blog associated with the RSS
            email. It is a string.
        maxEntries:
          type: integer
          description: >-
            The maximum number of entries to include from the RSS feed. It is an
            integer value.
          format: int32
        rssEntryTemplate:
          type: string
          description: >-
            A string representing the template used for each RSS entry in the
            email.
        timing:
          type: object
          additionalProperties:
            type: object
            properties: {}
          description: >-
            An object representing the timing configuration for the RSS email.
            The specific properties of this object are not detailed in the
            specification.
        url:
          type: string
          description: The URL of the RSS feed to be used in the email. It is a string.
        useHeadlineAsSubject:
          type: boolean
          description: >-
            A boolean indicating whether to use the headline of the RSS entry as
            the subject of the email.
    EmailStatisticsData:
      required:
        - counters
        - deviceBreakdown
        - qualifierStats
        - ratios
      type: object
      properties:
        counters:
          type: object
          additionalProperties:
            type: integer
            format: int64
          description: Counters like number of `sent`, `open` or `delivered`.
        deviceBreakdown:
          type: object
          additionalProperties:
            type: object
            additionalProperties:
              type: integer
              format: int64
          description: Statistics by device.
        qualifierStats:
          type: object
          additionalProperties:
            type: object
            additionalProperties:
              type: integer
              format: int64
          description: Number of emails that were dropped and bounced.
        ratios:
          type: object
          additionalProperties:
            type: number
          description: Ratios like `openratio` or `clickratio`
    PublicEmailSubscriptionDetails:
      type: object
      properties:
        officeLocationId:
          type: string
          description: ID of the selected office location.
        preferencesGroupId:
          type: string
          description: >-
            The identifier for the preferences group associated with the
            subscription. It is a string value.
        subscriptionId:
          type: string
          description: ID of the subscription.
        subscriptionName:
          type: string
          description: The name of the email subscription. It is a string value.
    PublicEmailTestingDetails:
      required:
        - isAbVariation
      type: object
      properties:
        abSampleSizeDefault:
          type: string
          description: >-
            Version of the email that should be sent if there are too few
            recipients to conduct an AB test.
          enum:
            - automated_loser_variant
            - automated_master
            - automated_variant
            - loser_variant
            - mab_master
            - mab_variant
            - master
            - variant
        abSamplingDefault:
          type: string
          description: >-
            Version of the email that should be sent if the results are
            inconclusive after the test period, master or variant.
          enum:
            - automated_loser_variant
            - automated_master
            - automated_variant
            - loser_variant
            - mab_master
            - mab_variant
            - master
            - variant
        abStatus:
          type: string
          description: Status of the AB test.
          enum:
            - automated_loser_variant
            - automated_master
            - automated_variant
            - loser_variant
            - mab_master
            - mab_variant
            - master
            - variant
        abSuccessMetric:
          type: string
          description: >-
            Metric to determine the version that will be sent to the remaining
            contacts.
          enum:
            - CLICKS_BY_DELIVERED
            - CLICKS_BY_OPENS
            - OPENS_BY_DELIVERED
        abTestPercentage:
          type: integer
          description: The size of your test group.
          format: int32
        hoursToWait:
          type: integer
          description: >-
            Time limit on gathering test results. After this time is up, the
            winning version will be sent to the remaining contacts.
          format: int32
        isAbVariation:
          type: boolean
          description: A boolean indicating whether the email is an A/B test variation.
        testId:
          type: string
          description: The ID of the AB test.
    PublicEmailToDetails:
      type: object
      properties:
        contactIds:
          $ref: '#/components/schemas/PublicEmailRecipients'
        contactIlsLists:
          $ref: '#/components/schemas/PublicEmailRecipients'
        contactLists:
          $ref: '#/components/schemas/PublicEmailRecipients'
        limitSendFrequency:
          type: boolean
          description: >-
            A boolean indicating whether the frequency of sending emails to the
            recipients should be limited.
        suppressGraymail:
          type: boolean
          description: Whether to send to unengaged contacts (false) or not (true).
    PublicWebversionDetails:
      type: object
      properties:
        domain:
          type: string
          description: >-
            A string specifying the domain where the web version of the email is
            hosted.
        enabled:
          type: boolean
          description: >-
            A boolean indicating whether the web version of the email is
            enabled.
        expiresAt:
          type: string
          description: >-
            A string in date-time format specifying when the web version page
            will expire.
          format: date-time
        isPageRedirected:
          type: boolean
          description: >-
            A boolean indicating whether the web version page is redirected to
            another URL.
        metaDescription:
          type: string
          description: >-
            A string providing the meta description for the web version of the
            email.
        pageExpiryEnabled:
          type: boolean
          description: A boolean indicating whether the web version page has an expiry set.
        redirectToPageId:
          type: string
          description: >-
            A string representing the ID of the page to which the web version is
            redirected.
        redirectToUrl:
          type: string
          description: >-
            A string containing the URL to which the web version page is
            redirected.
        slug:
          type: string
          description: >-
            A string representing the unique slug for the web version of the
            email.
        title:
          type: string
          description: A string representing the title of the web version of the email.
        url:
          type: string
          description: A string containing the full URL of the web version of the email.
    SmartEmailField:
      type: object
      properties: {}
    PublicEmailStyleSettings:
      type: object
      properties:
        backgroundColor:
          type: string
          description: The background color of the email, represented as a string.
        backgroundImage:
          type: string
          description: The URL of the background image used in the email.
        backgroundImageType:
          type: string
          description: >-
            The type of background image display, with valid values including
            'SINGLE', 'STRETCH', and 'REPEAT'.
          enum:
            - REPEAT
            - SINGLE
            - STRETCH
        bodyBorderColor:
          type: string
          description: The color of the border around the email body.
        bodyBorderColorChoice:
          type: string
          description: A string representing the choice of border color for the email body.
        bodyBorderWidth:
          type: number
          description: >-
            The width of the border around the email body, represented as a
            number.
        bodyColor:
          type: string
          description: The color of the email body, represented as a string.
        buttonStyleSettings:
          $ref: '#/components/schemas/PublicButtonStyleSettings'
        colorPickerFavorite1:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        colorPickerFavorite2:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        colorPickerFavorite3:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        colorPickerFavorite4:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        colorPickerFavorite5:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        colorPickerFavorite6:
          type: string
          description: >-
            A favorite color option available in the color picker, represented
            as a string.
        dividerStyleSettings:
          $ref: '#/components/schemas/PublicDividerStyleSettings'
        emailBodyPadding:
          type: string
          description: The padding applied to the email body, represented as a string.
        emailBodyWidth:
          type: string
          description: The width of the email body, represented as a string.
        headingOneFont:
          $ref: '#/components/schemas/PublicFontStyle'
        headingTwoFont:
          $ref: '#/components/schemas/PublicFontStyle'
        linksFont:
          $ref: '#/components/schemas/PublicFontStyle'
        primaryAccentColor:
          type: string
          description: The primary accent color used in the email.
        primaryFont:
          type: string
          description: The primary font used in the email, represented as a string.
        primaryFontColor:
          type: string
          description: The color of the primary font.
        primaryFontLineHeight:
          type: string
          description: The line height of the primary font, represented as a string.
        primaryFontSize:
          type: number
          description: The size of the primary font, represented as a number.
        secondaryAccentColor:
          type: string
          description: The secondary accent color used in the email.
        secondaryFont:
          type: string
          description: The secondary font used in the email, represented as a string.
        secondaryFontColor:
          type: string
          description: The color of the secondary font.
        secondaryFontLineHeight:
          type: string
          description: The line height of the secondary font, represented as a string.
        secondaryFontSize:
          type: number
          description: The size of the secondary font, represented as a number.
    PublicEmailRecipients:
      type: object
      properties:
        exclude:
          type: array
          description: Excluded IDs.
          items:
            type: string
        include:
          type: array
          description: Included IDs.
          items:
            type: string
    PublicButtonStyleSettings:
      type: object
      properties:
        backgroundColor:
          type: object
          properties: {}
          description: An object representing the background color of the button.
        cornerRadius:
          type: integer
          description: An integer specifying the radius of the button's corners.
          format: int32
        fontStyle:
          $ref: '#/components/schemas/PublicFontStyle'
    PublicDividerStyleSettings:
      type: object
      properties:
        color:
          type: object
          properties: {}
          description: An object representing the color settings of the divider.
        height:
          type: integer
          description: An integer representing the height of the divider.
          format: int32
        lineType:
          type: string
          description: A string indicating the type of line used for the divider.
    PublicFontStyle:
      type: object
      properties:
        bold:
          type: boolean
          description: A boolean indicating whether the text should be bold.
        color:
          type: string
          description: The color of the font, represented as a string.
        font:
          type: string
          description: The type of font to be used, represented as a string.
        italic:
          type: boolean
          description: A boolean indicating whether the text should be italicized.
        size:
          type: integer
          description: The size of the font, represented as an integer.
          format: int32
        underline:
          type: boolean
          description: A boolean indicating whether the text should be underlined.
  responses:
    Error:
      description: An error occurred.
      content:
        '*/*':
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        authorizationCode:
          authorizationUrl: https://app.hubspot.com/oauth/authorize
          tokenUrl: https://api.hubapi.com/oauth/v1/token
          scopes:
            content: ''
            marketing-email: ''
            marketing.email.read: ''
            marketing.email.write: ''
            transactional-email: ''

````