Unlayer API

Unlayer API as documented publicly. Contract generated from the documentation by API Evangelist (2026-11-27); not the provider's own document.

GitHub OpenAPI

Operations 24

GET /v2/editor/blocks Retrieve the blocks for a specific user #
GET /v2/editor/inbox-previews/clients GET /v2/editor/inbox-previews/clients #
GET /v3/blocks GET /v3/blocks #
POST /v3/emails Send transactional email from a verified domain using raw HTML. #
POST /v3/emails/template Send transactional email from a verified domain using a saved template. #
POST /v3/images/generate Generate an image (AI) #
GET /v3/projects/{id} Inbox Previews API #
GET /v3/projects/{id}/ai-credits Get credit balance #
DELETE /v3/projects/{id}/ai-credits/end-users Remove an end user's cap #
GET /v3/projects/{id}/ai-credits/end-users Get an end user's cap #
PUT /v3/projects/{id}/ai-credits/end-users Set an end user's cap #
GET /v3/projects/{id}/ai-credits/settings Read settings #
PUT /v3/projects/{id}/ai-credits/settings Update settings #
POST /v3/projects/{id}/ai-credits/settings/rotate-secret Rotating the signing secret #
GET /v3/projects/{id}/ai-credits/usage Get usage breakdown #
GET /v3/projects/{id}/ai-credits/webhooks/deliveries List deliveries #
GET /v3/projects/{id}/ai-credits/webhooks/deliveries/{deliveryid}/attempts List a delivery's attempts #
POST /v3/projects/{id}/ai-credits/webhooks/deliveries/{deliveryid}/retry Retry a delivery #
GET /v3/projects/{id}/inbox-previews/usage Inbox Previews API #
DELETE /v3/projects/{id}/inbox-previews/usage/end-users Inbox Previews API #
GET /v3/projects/{id}/inbox-previews/usage/runs Inbox Previews API #
PATCH /v3/projects/{projectid} PATCH /v3/projects/{projectId} #
POST /v3/templates/generate Generate a template (AI) #
POST /v3/templates/import Import a template (AI) #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/unlayer-com:unlayer-com-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

unlayer-com-openapi-generated.yml Raw ↑
openapi: 3.1.0
info:
  title: Unlayer API
  version: '2026-11-27'
  description: 'GENERATED FROM DOCUMENTATION by API Evangelist on 2026-11-27: 24 operation(s) read from 7 public documentation page(s) (each operation
    names its page in x-source). This is not the provider''s published contract; Unlayer has published no machine-readable contract that the pipeline
    could find. Engine: local.'
  x-evidence-tiers:
    code-example: 3
    documentation: 21
    pages-with-code: 3
    pages-read: 7
  x-generated-from: documentation
  x-provenance: generated
  x-authored-by: API Evangelist
  x-generated: '2026-11-27'
  x-generator: generate-contract-from-docs.py
  x-engine: local
  x-sources:
  - https://docs.unlayer.com/server/cloud-api/blocks
  - https://docs.unlayer.com/server/cloud-api/overview
  - https://docs.unlayer.com/server/cloud-api/ai-credits
  - https://docs.unlayer.com/server/cloud-api/inbox-previews
  - https://help.unlayer.com/en/articles/16005255-retrieving-user-saved-blocks-using-the-unlayer-api
  - https://docs.unlayer.com/server/cloud-api
  - https://docs.unlayer.com/server/cloud-api/images
servers:
- url: https://api.unlayer.com
paths:
  /v2/editor/blocks:
    get:
      operationId: get_v2_editor_blocks
      tags:
      - Editor
      summary: Retrieve the blocks for a specific user
      description: Use this endpoint to retrieve User Saved Blocks and Shared Project Blocks for a specific user and display mode.
      x-source: https://help.unlayer.com/en/articles/16005255-retrieving-user-saved-blocks-using-the-unlayer-api
      parameters:
      - name: displayMode
        in: query
        required: true
        schema:
          type: string
        description: 'One of the supported display modes: email, web, document, popup'
      - name: userId
        in: query
        required: true
        schema:
          type: string
        description: Specific user ID
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v2/editor/inbox-previews/clients:
    get:
      operationId: get_v2_editor_inbox_previews_clients
      tags:
      - Editor
      summary: GET /v2/editor/inbox-previews/clients
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: code-example
        language: curl
        snippet: curl 'https://api.unlayer.com/v2/editor/inbox-previews/clients' Previous Authentication Next Images Read the defaults Update
          the defaults Read usage Remove end-user attribution Email-client IDs Builders Email Builder Page Builder Document Builder Popup Builder
          Templates Developers Hyper Elements CLI SDK Design Schema Email Sending API Reference AI AI Assistant AI Template Importer Unlayer MCP
          AI A
  /v3/blocks:
    get:
      operationId: get_v3_blocks
      tags:
      - Blocks
      summary: GET /v3/blocks
      x-source: https://docs.unlayer.com/server/cloud-api/blocks
      parameters:
      - name: displayMode
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3BlocksResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl \"https://api.unlayer.com/v3/blocks?displayMode=email\" \\ -H \"Authorization: Bearer unlayer_sk_your_api_key\" \n Query\
          \ parameters ​ \n Parameter Type Default Description limit integer 20 Blocks per page (1–100). cursor string — Pagination cursor from\
          \ the previous response. displayMode string — Filter by display mode: email , web , popup , or document . Omit to list blocks across\
          \ all display modes."
  /v3/emails:
    post:
      operationId: post_v3_emails
      tags:
      - Emails
      summary: Send transactional email from a verified domain using raw HTML.
      x-source: https://docs.unlayer.com/server/cloud-api/overview
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/emails/template:
    post:
      operationId: post_v3_emails_template
      tags:
      - Emails
      summary: Send transactional email from a verified domain using a saved template.
      x-source: https://docs.unlayer.com/server/cloud-api/overview
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/images/generate:
    post:
      operationId: post_v3_images_generate
      tags:
      - Images
      summary: Generate an image (AI)
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostV3ImagesGenerateRequest'
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/projects/{id}:
    get:
      operationId: get_v3_projects_id
      tags:
      - Projects
      summary: Inbox Previews API
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits:
    get:
      operationId: get_v3_projects_id_ai_credits
      tags:
      - Projects
      summary: Get credit balance
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/end-users:
    delete:
      operationId: delete_v3_projects_id_ai_credits_end_users
      tags:
      - Projects
      summary: Remove an end user's cap
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: end_user_id
        in: query
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeleteV3ProjectsIdAiCreditsEndUsersResponse'
      x-evidence:
        kind: documentation
    get:
      operationId: get_v3_projects_id_ai_credits_end_users
      tags:
      - Projects
      summary: Get an end user's cap
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: end_user_id
        in: query
        required: true
        schema:
          type: string
        description: The user.id you pass to the builder
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsEndUsersResponse'
      x-evidence:
        kind: documentation
    put:
      operationId: put_v3_projects_id_ai_credits_end_users
      tags:
      - Projects
      summary: Set an end user's cap
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PutV3ProjectsIdAiCreditsEndUsersRequest'
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PutV3ProjectsIdAiCreditsEndUsersResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/settings:
    get:
      operationId: get_v3_projects_id_ai_credits_settings
      tags:
      - Projects
      summary: Read settings
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsSettingsResponse'
      x-evidence:
        kind: documentation
    put:
      operationId: put_v3_projects_id_ai_credits_settings
      tags:
      - Projects
      summary: Update settings
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PutV3ProjectsIdAiCreditsSettingsRequest'
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PutV3ProjectsIdAiCreditsSettingsResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/settings/rotate-secret:
    post:
      operationId: post_v3_projects_id_ai_credits_settings_rotate_secret
      tags:
      - Projects
      summary: Rotating the signing secret
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/usage:
    get:
      operationId: get_v3_projects_id_ai_credits_usage
      tags:
      - Projects
      summary: Get usage breakdown
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: start
        in: query
        required: false
        schema:
          type: string
        description: Start date (inclusive), YYYY-MM-DD
      - name: end
        in: query
        required: false
        schema:
          type: string
        description: End date (inclusive), YYYY-MM-DD
      - name: end_user_id
        in: query
        required: false
        schema:
          type: string
        description: Filter to a single end user
      - name: feature_type
        in: query
        required: false
        schema:
          type: string
        description: Filter to a single feature type
      - name: limit
        in: query
        required: false
        schema:
          type: string
        description: Max breakdown rows to return (1–1000)
      - name: offset
        in: query
        required: false
        schema:
          type: string
        description: Number of breakdown rows to skip
      - name: sort
        in: query
        required: false
        schema:
          type: string
        description: Field the breakdown is ordered by
      - name: order
        in: query
        required: false
        schema:
          type: string
        description: 'Sort direction: asc or desc'
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsUsageResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/webhooks/deliveries:
    get:
      operationId: get_v3_projects_id_ai_credits_webhooks_deliveries
      tags:
      - Projects
      summary: List deliveries
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: status
        in: query
        required: false
        schema:
          type: string
      - name: event
        in: query
        required: false
        schema:
          type: string
      - name: limit
        in: query
        required: false
        schema:
          type: string
      - name: offset
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsWebhooksDeliveriesResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/webhooks/deliveries/{deliveryid}/attempts:
    get:
      operationId: get_v3_projects_id_ai_credits_webhooks_deliveries_deliveryid_attempts
      tags:
      - Projects
      summary: List a delivery's attempts
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: deliveryid
        in: path
        required: true
        schema:
          type: string
      - name: limit
        in: query
        required: false
        schema:
          type: string
      - name: offset
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdAiCreditsWebhooksDeliveriesDeliveryidAttempts'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/ai-credits/webhooks/deliveries/{deliveryid}/retry:
    post:
      operationId: post_v3_projects_id_ai_credits_webhooks_deliveries_deliveryid_retry
      tags:
      - Projects
      summary: Retry a delivery
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: deliveryid
        in: path
        required: true
        schema:
          type: string
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/projects/{id}/inbox-previews/usage:
    get:
      operationId: get_v3_projects_id_inbox_previews_usage
      tags:
      - Projects
      summary: Inbox Previews API
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: start
        in: query
        required: false
        schema:
          type: string
        description: Start date (inclusive) for usage report, format YYYY-MM-DD
      - name: end
        in: query
        required: false
        schema:
          type: string
        description: End date (inclusive) for usage report, format YYYY-MM-DD
      - name: limit
        in: query
        required: false
        schema:
          type: string
        description: Maximum number of end‑users to return (default and max 100)
      - name: offset
        in: query
        required: false
        schema:
          type: string
        description: Offset for pagination (up to 100,000)
      - name: end_user_id
        in: query
        required: false
        schema:
          type: string
        description: Scope usage to a specific end‑user
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdInboxPreviewsUsageResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{id}/inbox-previews/usage/end-users:
    delete:
      operationId: delete_v3_projects_id_inbox_previews_usage_end_users
      tags:
      - Projects
      summary: Inbox Previews API
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/projects/{id}/inbox-previews/usage/runs:
    get:
      operationId: get_v3_projects_id_inbox_previews_usage_runs
      tags:
      - Projects
      summary: Inbox Previews API
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      - name: start
        in: query
        required: false
        schema:
          type: string
        description: Start date (inclusive) for runs list, format YYYY-MM-DD
      - name: end
        in: query
        required: false
        schema:
          type: string
        description: End date (inclusive) for runs list, format YYYY-MM-DD
      - name: limit
        in: query
        required: false
        schema:
          type: string
        description: Number of runs per page (default 25)
      - name: offset
        in: query
        required: false
        schema:
          type: string
        description: Pagination offset
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetV3ProjectsIdInboxPreviewsUsageRunsResponse'
      x-evidence:
        kind: documentation
  /v3/projects/{projectid}:
    patch:
      operationId: patch_v3_projects_projectid
      tags:
      - Projects
      summary: PATCH /v3/projects/{projectId}
      x-source: https://docs.unlayer.com/server/cloud-api/inbox-previews
      parameters:
      - name: projectid
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchV3ProjectsProjectidRequest'
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl --request PATCH 'https://api.unlayer.com/v3/projects/1234' \\ --header 'Authorization: Bearer unlayer_sk_...' \\ --header\
          \ 'Content-Type: application/json' \\ --data '{ \"inboxPreviews\": { \"clients\": [\"outlook19\", \"iphone16gmail_26\"], \"dataRegion\"\
          : \"eu\" } }' \n Field Value clients A non-empty list of current IDs, or null to use the recommended set. dataRegion us , eu , or null\
          \ to choose automatical"
  /v3/templates/generate:
    post:
      operationId: post_v3_templates_generate
      tags:
      - Templates
      summary: Generate a template (AI)
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostV3TemplatesGenerateRequest'
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /v3/templates/import:
    post:
      operationId: post_v3_templates_import
      tags:
      - Templates
      summary: Import a template (AI)
      x-source: https://docs.unlayer.com/server/cloud-api/ai-credits
      requestBody:
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostV3TemplatesImportRequest'
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
components:
  schemas:
    GetV3BlocksResponse:
      type: object
      properties:
        data:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              userId:
                type: string
              displayMode:
                type: string
              category:
                type: string
              tags:
                type: array
                items:
                  type: string
              data:
                type: object
                properties:
                  columns:
                    type: array
                    items:
                      type: string
              thumbnailUrl:
                type: string
              syncId:
                type:
                - string
                - 'null'
              isSyncEnabled:
                type: boolean
              createdAt:
                type: string
                format: date-time
              updatedAt:
                type: string
                format: date-time
        next_cursor:
          type: string
        has_more:
          type: boolean
    PostV3ImagesGenerateRequest:
      type: object
      properties:
        end_user_id:
          type: string
    GetV3ProjectsIdResponse:
      type: object
      properties:
        data.inboxPreviews:
          type: object
          description: Defaults for inbox previews; null means recommended clients or automatic region are active
    GetV3ProjectsIdAiCreditsResponse:
      type: object
      properties:
        is_capped:
          type: boolean
          description: whether enforcement can constrain AI usage
        credits_total:
          type: integer
          description: total credits allocated
        credits_used:
          type: integer
          description: credits consumed
        credits_remaining:
          type: integer
          description: credits left
        reset_date:
          type: string
          description: end timestamp for the current credit window
    DeleteV3ProjectsIdAiCreditsEndUsersResponse:
      type: object
      properties:
        end_user_id:
          type: string
        monthly_cap:
          type: integer
        monthly_cap_source:
          type: string
        credits_used:
          type: integer
        credits_remaining:
          type: integer
        reset_date:
          type: string
    GetV3ProjectsIdAiCreditsEndUsersResponse:
      type: object
      properties:
        end_user_id:
          type: string
        monthly_cap:
          type: integer
        monthly_cap_source:
          type: string
        credits_used:
          type: integer
        credits_remaining:
          type: integer
        reset_date:
          type: string
    PutV3ProjectsIdAiCreditsEndUsersRequest:
      type: object
      properties:
        end_user_id:
          type: string
        monthly_cap:
          type: string
      required:
      - end_user_id
      - monthly_cap
    PutV3ProjectsIdAiCreditsEndUsersResponse:
      type: object
      properties:
        end_user_id:
          type: string
        monthly_cap:
          type: integer
        monthly_cap_source:
          type: string
        credits_used:
          type: integer
        credits_remaining:
          type: integer
        reset_date:
          type: string
    GetV3ProjectsIdAiCreditsSettingsResponse:
      type: object
      properties:
        exhaustion_behavior:
          type: string
        threshold_alerts:
          type: array
        webhook_url:
          type: string
        has_signing_secret:
          type: boolean
        project_monthly_cap:
          type: integer
        end_user_monthly_cap:
          type: integer
    PutV3ProjectsIdAiCreditsSettingsRequest:
      type: object
      properties:
        exhaustion_behavior:
          type: string
        threshold_alerts:
          type: string
        webhook_url:
          type: string
        project_monthly_cap:
          type: string
        end_user_monthly_cap:
          type: string
    PutV3ProjectsIdAiCreditsSettingsResponse:
      type: object
      properties:
        exhaustion_behavior:
          type: string
        threshold_alerts:
          type: array
        webhook_url:
          type: string
        has_signing_secret:
          type: boolean
        signing_secret:
          type: string
        project_monthly_cap:
          type: integer
        end_user_monthly_cap:
          type: integer
    GetV3ProjectsIdAiCreditsUsageResponse:
      type: object
      properties:
        total_credits_used:
          type: integer
        total:
          type: integer
        breakdown:
          type: array
          description: list of usage rows
    GetV3ProjectsIdAiCreditsWebhooksDeliveriesResponse:
      type: object
      properties:
        event:
          type: string
        status:
          type: string
        attempts:
          type: integer
        last_status_code:
          type: integer
        end_user_id:
          type: string
        created_at:
          type: string
        delivered_at:
          type: string
        total:
          type: integer
    GetV3ProjectsIdAiCreditsWebhooksDeliveriesDeliveryidAttempts:
      type: object
      properties:
        attempt:
          type: integer
        status_code:
          type: integer
        error:
          type: string
        attempted_at:
          type: string
        total:
          type: integer
    GetV3ProjectsIdInboxPreviewsUsageResponse:
      type: object
      properties:
        generations:
          type: integer
          description: Number of inbox preview generations
        credits:
          type: integer
          description: Credits consumed
        daily_trend:
          type: array
          description: Credits per day
        usage_by_email_client:
          type: object
          description: Breakdown of usage per email client
        usage_by_end_user:
          type: object
          description: Breakdown of usage per end user
    GetV3ProjectsIdInboxPreviewsUsageRunsResponse:
      type: object
      properties:
        billing_model:
          type: string
          description: Either per-device or per-generation
        credits_used:
          type: integer
          description: Credits charged for the run
        credit_details_available:
          type: boolean
          description: Whether credit details are available
        clients:
          type: array
          description: Selected email clients for the run
        viewed_clients:
          type: object
          description: Details of how clients were viewed
        end_user_id:
          type: string
          description: Associated end‑user identifier, if known
        template_id:
          type: string
          description: Template used for the generation
        data_region:
          type: string
          description: Region where data was stored
        configuration_source:
          type: string
          description: Source of configuration (editor, console, api, project, or recommended)
    PatchV3ProjectsProjectidRequest:
      type: object
      properties:
        inboxPreviews:
          type: object
          properties:
            clients:
              type: array
              items:
                type: string
            dataRegion:
              type: string
    PostV3TemplatesGenerateRequest:
      type: object
      properties:
        end_user_id:
          type: string
          description: Identify the end user for attribution
    PostV3TemplatesImportRequest:
      type: object
      properties:
        end_user_id:
          type: string
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
security:
- bearer: []
tags:
- name: Blocks
- name: Editor
- name: Emails
- name: Images
- name: Projects
- name: Templates