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

# Send an email



## OpenAPI

````yaml /openapi.json post /email
openapi: 3.0.0
info:
  title: JetEmail API
  version: 1.0.0
  description: API documentation for JetEmail's transactional email service.
servers:
  - url: https://api.jetemail.com
    description: Production
security:
  - apiKeyAuth: []
externalDocs:
  description: Download OpenAPI Specification
  url: /openapi.json
paths:
  /email:
    post:
      tags:
        - Email
      summary: Send an email
      parameters:
        - name: Idempotency-Key
          in: header
          required: false
          schema:
            type: string
            minLength: 1
            maxLength: 256
          description: >-
            Opaque key (1–256 chars) that makes retries safe. A repeat with the
            same key and body replays the original response.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - from
                - to
                - subject
              properties:
                from:
                  type: string
                  description: 'Sender email address in format: "Name <email@domain.com>"'
                  example: John Doe <john@example.com>
                to:
                  oneOf:
                    - type: string
                      format: email
                      description: Single recipient email address
                      example: user@example.com
                    - type: array
                      items:
                        type: string
                        format: email
                      maxItems: 50
                      description: List of recipient email addresses
                  description: Recipient email address(es)
                subject:
                  type: string
                  minLength: 1
                  description: Email subject line
                html:
                  type: string
                  description: >-
                    HTML content of the email. At least one of html or text is
                    required. Can be used together with text to provide a
                    plaintext alternative
                text:
                  type: string
                  description: >-
                    Plaintext content of the email. At least one of html or text
                    is required. When used with html, serves as the plaintext
                    alternative
                cc:
                  oneOf:
                    - type: string
                      format: email
                    - type: array
                      items:
                        type: string
                        format: email
                      maxItems: 50
                  description: >-
                    CC recipient(s). Can be plain email or "Name
                    <email@domain.com>" format
                bcc:
                  oneOf:
                    - type: string
                      format: email
                    - type: array
                      items:
                        type: string
                        format: email
                      maxItems: 50
                  description: >-
                    BCC recipient(s). Can be plain email or "Name
                    <email@domain.com>" format
                reply_to:
                  oneOf:
                    - type: string
                      format: email
                    - type: array
                      items:
                        type: string
                        format: email
                      maxItems: 50
                  description: >-
                    Reply-to address(es). Can be plain email or "Name
                    <email@domain.com>" format
                headers:
                  type: object
                  additionalProperties:
                    type: string
                  description: Custom email headers
                attachments:
                  type: array
                  items:
                    type: object
                    required:
                      - filename
                      - data
                    properties:
                      filename:
                        type: string
                        description: Name of the attachment file
                      data:
                        type: string
                        format: base64
                        description: Base64 encoded file content
                  description: 'Email attachments (base64 encoded, max total size: 40MB)'
                eu:
                  type: boolean
                  description: If true, restricts email delivery to EU region only.
                  example: false
                scheduledAt:
                  oneOf:
                    - type: integer
                      description: Unix seconds (UTC).
                      example: 1762435200
                    - type: string
                      format: date-time
                      description: ISO 8601 / RFC 3339 with offset.
                      example: '2026-05-15T10:00:00Z'
                  description: >-
                    Future send time, up to 30 days out. Accepts unix seconds
                    (e.g. 1762435200) or ISO 8601 (e.g. "2026-05-15T10:00:00Z"
                    or "2026-05-15T10:00:00-04:00"). `scheduled_at` is also
                    accepted as an alias.
            examples:
              Simple Text Email:
                value:
                  from: John Doe <john@example.com>
                  to: recipient@example.com
                  subject: Test Email
                  text: Hello! This is a test email.
              HTML Email with Plaintext Alternative:
                value:
                  from: John Doe <john@example.com>
                  to: recipient@example.com
                  subject: Test Email
                  html: <h1>Hello!</h1><p>This is the HTML version.</p>
                  text: Hello! This is the plaintext version.
              Scheduled Email (ISO 8601):
                value:
                  from: John Doe <john@example.com>
                  to: recipient@example.com
                  subject: Reminder
                  text: This will arrive at the scheduled time.
                  scheduledAt: '2026-05-15T10:00:00Z'
              Scheduled Email (Unix seconds):
                value:
                  from: John Doe <john@example.com>
                  to: recipient@example.com
                  subject: Reminder
                  text: This will arrive at the scheduled time.
                  scheduledAt: 1762435200
      responses:
        '201':
          description: Email queued successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Unique message ID
                    example: 19424fd2acd0004210
                  response:
                    type: string
                    description: Queue confirmation message
                    example: Message queued as 19424fd2acd0004210
        '202':
          description: Email scheduled for future delivery.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Scheduling uuid
                    example: 0cd0f31f-1234-4abc-8def-1234567890ab
                  response:
                    type: string
                    example: Scheduled as 0cd0f31f-… for 1762435200
                  scheduled_at:
                    type: integer
                    description: Unix seconds at which the message will send
                    example: 1762435200
        '400':
          description: Bad Request - Invalid input
        '401':
          description: Unauthorized - Missing or invalid API key
        '409':
          description: >-
            Idempotency conflict — key in flight (IDEMPOTENCY_IN_FLIGHT) or
            reused with a different body (IDEMPOTENCY_BODY_MISMATCH).
      security:
        - transactionalKeyAuth: []
components:
  securitySchemes:
    apiKeyAuth:
      type: http
      scheme: bearer
      description: API key for account management endpoints. Use your api_ prefixed token.
    transactionalKeyAuth:
      type: http
      scheme: bearer
      description: >-
        Transactional key for sending emails. Use your transactional_ prefixed
        token.

````