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

# Send MIME email

> Send a raw MIME email. The raw message must be a valid RFC 2822 formatted email. The `envelope_from` must belong to a verified domain in your account.



## OpenAPI

````yaml POST /emails/mime
openapi: 3.1.0
info:
  title: SendKit API
  description: The SendKit API allows you to send transactional emails programmatically.
  version: 1.0.0
servers:
  - url: https://api.sendkit.dev
security:
  - bearerAuth: []
paths:
  /emails/mime:
    post:
      tags:
        - Emails
      summary: Send a raw MIME email
      description: >-
        Send a raw MIME email. The raw message must be a valid RFC 2822
        formatted email. The `envelope_from` must belong to a verified domain in
        your account.
      operationId: sendMimeEmail
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendMimeEmailRequest'
      responses:
        '202':
          description: Email accepted for delivery
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SendEmailResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '422':
          $ref: '#/components/responses/ValidationError'
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                name: rate_limit_exceeded
                message: Rate limit exceeded. Please retry after 30 seconds.
components:
  schemas:
    SendMimeEmailRequest:
      type: object
      required:
        - envelope_from
        - envelope_to
        - raw_message
      properties:
        envelope_from:
          type: string
          description: >-
            Sender email address. Must belong to a verified domain. Accepts
            plain email or with display name.
          example: Your Name <hello@yourdomain.com>
        envelope_to:
          type: string
          format: email
          description: Recipient email address.
          example: user@example.com
        raw_message:
          type: string
          minLength: 10
          maxLength: 37500000
          description: The raw RFC 2822 formatted email message.
    SendEmailResponse:
      oneOf:
        - type: object
          description: Returned when sending to a single recipient.
          properties:
            id:
              type: string
              format: uuid
              description: Unique identifier of the created email.
              example: 550e8400-e29b-41d4-a716-446655440000
        - type: object
          description: Returned when sending to multiple recipients.
          properties:
            data:
              type: array
              items:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                    description: Unique identifier of the created email.
              description: Array of created emails, one per recipient.
    ErrorResponse:
      type: object
      properties:
        name:
          type: string
          description: Error type identifier.
          example: validation_error
        message:
          type: string
          description: Human-readable error message.
          example: The from address domain is not verified.
  responses:
    Unauthorized:
      description: Unauthorized — missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            message: Invalid API key.
    ValidationError:
      description: Validation error — invalid or missing parameters
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            message: The email field is required.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key from your SendKit dashboard. Pass it as a Bearer token in the
        Authorization header.

````