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

# Get email by ID

> Returns a single email send record by ID (only if sent by this application).



## OpenAPI

````yaml /openapi-v3.json get /emails/{id}
openapi: 3.0.0
info:
  title: Max AI Public API
  description: API for third-party marketplace apps
  version: '3.0'
  contact: {}
servers:
  - url: https://api.maxcare.ai/v3
security: []
tags: []
paths:
  /emails/{id}:
    get:
      tags:
        - Emails
      summary: Get email by ID
      description: >-
        Returns a single email send record by ID (only if sent by this
        application).
      operationId: EmailsPublicController_getEmail
      parameters:
        - name: id
          required: true
          in: path
          description: Email send record ID
          schema:
            type: string
        - name: X-Organization-Id
          in: header
          required: true
          schema:
            type: string
          description: Target clinic organization ID
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetEmailSuccessResponseV3'
        '400':
          description: Missing or invalid request parameter
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiBadRequestResponse'
        '401':
          description: Invalid or missing API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiUnauthorizedResponse'
        '403':
          description: Insufficient scope
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiForbiddenResponse'
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiNotFoundResponse'
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiRateLimitResponse'
      security:
        - api-key: []
components:
  schemas:
    GetEmailSuccessResponseV3:
      type: object
      properties:
        code:
          type: string
          description: Response code
          example: success
        data:
          $ref: '#/components/schemas/ExternalEmailResponseV3'
      required:
        - code
        - data
    PublicApiBadRequestResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: bad_request
        message:
          type: string
          description: Human-readable error message
          example: '''id'' must be a valid UUID'
        trace_id:
          type: string
          description: Trace ID for debugging
          example: 550e8400-e29b-41d4-a716-446655440000
      required:
        - code
        - message
        - trace_id
    PublicApiUnauthorizedResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: unauthorized
        message:
          type: string
          description: Human-readable error message
          example: Invalid or missing API key
        trace_id:
          type: string
          description: Trace ID for debugging
          example: 550e8400-e29b-41d4-a716-446655440000
      required:
        - code
        - message
        - trace_id
    PublicApiForbiddenResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: forbidden
        message:
          type: string
          description: Human-readable error message
          example: Insufficient scope
        trace_id:
          type: string
          description: Trace ID for debugging
          example: 550e8400-e29b-41d4-a716-446655440000
      required:
        - code
        - message
        - trace_id
    PublicApiNotFoundResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: not_found
        message:
          type: string
          description: Human-readable error message
          example: Resource not found
        trace_id:
          type: string
          description: Trace ID for debugging
          example: 550e8400-e29b-41d4-a716-446655440000
      required:
        - code
        - message
        - trace_id
    PublicApiRateLimitResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: rate_limit_exceeded
        message:
          type: string
          description: Human-readable error message
          example: Rate limit exceeded. Maximum 1000 requests per 60 seconds.
        trace_id:
          type: string
          description: Trace ID for debugging
          example: 550e8400-e29b-41d4-a716-446655440000
      required:
        - code
        - message
        - trace_id
    ExternalEmailResponseV3:
      type: object
      properties:
        id:
          type: string
          description: Email send record ID
          example: eml_a7c3f1e28b4d4a9eb5c6d7e8f9012345
        recipientEmail:
          type: string
          description: Recipient email address
          example: jane.doe@example.com
        recipientType:
          type: string
          description: Recipient entity type
          enum:
            - patient
            - user
          nullable: true
          example: patient
        recipientId:
          type: string
          description: Recipient entity ID (patient or user)
          nullable: true
          example: pat_8de030393a9e417ab2b3a8b8df183631
        emailType:
          type: string
          description: Email type
          example: appointment_reminder
        subject:
          type: string
          description: Email subject line
          example: Your upcoming appointment on March 25
        fromAddress:
          type: string
          description: Sender address
          example: notifications@accounts.maxcare.ai
        status:
          type: string
          description: Delivery status
          example: sent
          enum:
            - sent
            - scheduled
        scheduledAt:
          type: string
          description: Scheduled send time (ISO 8601)
          nullable: true
          example: null
        sentAt:
          type: string
          description: When the email was sent
          example: '2026-03-25 10:00:01.234+00'
        deliveredAt:
          type: string
          description: When delivery was confirmed
          nullable: true
          example: '2026-03-25 10:00:03.567+00'
        openedAt:
          type: string
          description: When the email was opened
          nullable: true
          example: null
        bouncedAt:
          type: string
          description: When the email bounced
          nullable: true
          example: null
        createdAt:
          type: string
          description: Created timestamp
          example: '2026-03-25 09:59:58.891+00'
      required:
        - id
        - recipientEmail
        - recipientType
        - recipientId
        - emailType
        - subject
        - fromAddress
        - status
        - scheduledAt
        - sentAt
        - deliveredAt
        - openedAt
        - bouncedAt
        - createdAt
  securitySchemes:
    api-key:
      scheme: bearer
      bearerFormat: JWT
      type: http
      description: Marketplace API key

````