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

# Get a message by ID

> Get a message by its unique identifier.



## OpenAPI

````yaml https://openphone-public-api-dev.s3.us-west-2.amazonaws.com/public/openphone-public-api-v1-dev.json get /v1/messages/{id}
openapi: 3.1.0
info:
  title: Quo Public API
  version: 1.0.0
  description: API for connecting with Quo.
  contact:
    name: Quo Support
    email: support@quo.com
    url: https://support.quo.com/
  termsOfService: https://www.quo.com/terms
servers:
  - description: Development server
    url: https://dev-public-api.openphone.dev
security:
  - apiKey: []
tags:
  - description: Operations related to the organization's A2P registration
    name: A2P Registration
  - description: Operations related to calls placed by an AI agent
    name: Agent Calls
  - description: Operations related to text conversations held by an AI agent
    name: Agent Conversations
  - description: Operations related to calls
    name: Calls
  - description: >-
      Operations related to call summaries, including AI-generated summaries and
      Sona voice assistant summaries
    name: Call Summaries
  - description: >-
      Operations related to call transcripts, including AI-generated transcripts
      and Sona voice assistant transcripts
    name: Call Transcripts
  - description: Operations related to contacts
    name: Contacts
  - description: Operations related to contact shares
    name: Contact Shares
  - description: Operations related to contact notes
    name: Contact Notes
  - description: Operations related to contact properties
    name: Contact Properties
  - description: Operations related to conversations
    name: Conversations
  - description: Operations related to workspace invitations
    name: Invites
  - description: Operations related to text messages
    name: Messages
  - description: Operations related to the organization
    name: Organization
  - description: Operations related to phone numbers
    name: Phone Numbers
  - description: Operations related to users
    name: Users
  - description: Operations related to webhooks
    name: Webhooks
  - description: >-
      Operations related to webhook events, including delivery history and test
      events
    name: Webhook Events
paths:
  /v1/messages/{id}:
    get:
      tags:
        - Messages
      summary: Get a message by ID
      description: Get a message by its unique identifier.
      operationId: getMessageById_v1
      parameters:
        - in: path
          name: id
          required: true
          schema:
            description: The unique identifier of a message
            examples:
              - AC123abc
            type: string
            pattern: ^AC(.*)$
          example: AC123abc
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    required:
                      - id
                      - to
                      - from
                      - text
                      - phoneNumberId
                      - conversationId
                      - direction
                      - userId
                      - status
                      - createdAt
                      - updatedAt
                    properties:
                      id:
                        description: The unique identifier of the message.
                        examples:
                          - AC123abc
                        example: AC123abc
                        type: string
                        pattern: ^AC(.*)$
                      to:
                        type: array
                        items:
                          type: string
                          description: >-
                            A phone number in E.164 format, including the
                            country code.
                          examples:
                            - '+15555555555'
                          pattern: ^\+[1-9]\d{1,14}$
                          example: '+15555555555'
                        description: >-
                          Array of recipient phone numbers in E.164 format.
                          Includes your Quo number for incoming messages.
                        examples:
                          - - '+15555555555'
                        example:
                          - '+15555555555'
                      from:
                        type: string
                        description: >-
                          The from identifier, typically a E.164 phone number
                          but can be a variety of formats.
                        examples:
                          - '+15555555555'
                        example: '+15555555555'
                      text:
                        type: string
                        description: The content of the message.
                        examples:
                          - Hello, world!
                        example: Hello, world!
                      phoneNumberId:
                        anyOf:
                          - description: >-
                              The unique identifier of the Quo phone number that
                              the message was sent from.
                            examples:
                              - PN123abc
                            example: PN123abc
                            type: string
                            pattern: ^PN(.*)$
                          - type: 'null'
                      conversationId:
                        description: The unique identifier of the conversation.
                        examples:
                          - CN123abc
                        example: CN123abc
                        type: string
                        pattern: ^CN(.*)$
                      direction:
                        type: string
                        enum:
                          - incoming
                          - outgoing
                        description: >-
                          The direction of the message relative to the Quo
                          number.
                        examples:
                          - incoming
                        example: incoming
                      userId:
                        anyOf:
                          - description: >-
                              The unique identifier of the user who sent the
                              message. Null for incoming messages.
                            examples:
                              - US123abc
                            example: US123abc
                            type: string
                            pattern: ^US(.*)$
                          - type: 'null'
                      status:
                        type: string
                        enum:
                          - queued
                          - sent
                          - delivered
                          - undelivered
                          - received
                        description: The status of the message.
                        examples:
                          - sent
                        example: sent
                      createdAt:
                        description: >-
                          The timestamp when the message was created at, in ISO
                          8601 format
                        examples:
                          - '2022-01-01T00:00:00Z'
                        example: '2022-01-01T00:00:00Z'
                        type: string
                        format: date-time
                      updatedAt:
                        description: >-
                          The timestamp when the message status was last
                          updated, in ISO 8601 format.
                        examples:
                          - '2022-01-01T00:00:00Z'
                        example: '2022-01-01T00:00:00Z'
                        type: string
                        format: date-time
                      media:
                        type: array
                        items:
                          type: object
                          required:
                            - url
                          properties:
                            url:
                              type: string
                              description: The URL of the attached media.
                              examples:
                                - https://example.com/image.png
                              example: https://example.com/image.png
                            type:
                              anyOf:
                                - type: string
                                - type: 'null'
                              description: The MIME type of the attached media.
                              examples:
                                - image/png
                              example: image/png
                        description: Media attached to the message.
        '400':
          description: >-
            Bad Request | User Opted Out | Invalid `to` Phone Number |
            Unreachable `to` Phone Number | Not TFN Registered | A2P
            Registration Not Approved
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/BadRequestError3'
                  - $ref: '#/components/schemas/UserOptedOutError'
                  - $ref: '#/components/schemas/InvalidToPhoneNumberError'
                  - $ref: '#/components/schemas/UnreachableToPhoneNumberError'
                  - $ref: '#/components/schemas/NotTFNRegisteredError'
                  - $ref: '#/components/schemas/A2PRegistrationNotApprovedError'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                anyOf:
                  - type: object
                    required:
                      - error
                    properties:
                      error:
                        type: object
                        required:
                          - message
                          - key
                        properties:
                          message:
                            type: string
                          key:
                            type: string
                            const: Unauthorized
                          trace:
                            type: string
                  - type: object
                    required:
                      - message
                      - code
                      - status
                      - docs
                      - title
                    properties:
                      message:
                        type: string
                      code:
                        type: string
                        const: '0200401'
                      status:
                        type: number
                        const: 401
                      docs:
                        type: string
                        const: https://quo.com/docs
                      title:
                        type: string
                        const: Unauthorized
                      trace:
                        type: string
                      errors:
                        type: array
                        items:
                          type: object
                          required:
                            - path
                            - message
                            - schema
                          properties:
                            path:
                              type: string
                            message:
                              type: string
                            value: {}
                            schema:
                              type: object
                              required:
                                - type
                              properties:
                                type:
                                  type: string
        '402':
          description: Not Enough Credits | Subscription Expired
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/NotEnoughCreditsError'
                  - $ref: '#/components/schemas/SubscriptionExpiredError'
        '403':
          description: Forbidden | A2P Daily Message Cap Reached
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/ForbiddenError5'
                  - $ref: '#/components/schemas/A2PDailyMessageCapReachedError2'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                required:
                  - message
                  - code
                  - status
                  - docs
                  - title
                properties:
                  message:
                    type: string
                  code:
                    type: string
                    const: '0200404'
                  status:
                    type: number
                    const: 404
                  docs:
                    type: string
                    const: https://quo.com/docs
                  title:
                    type: string
                    const: Not Found
                  trace:
                    type: string
                  errors:
                    type: array
                    items:
                      type: object
                      required:
                        - path
                        - message
                        - schema
                      properties:
                        path:
                          type: string
                        message:
                          type: string
                        value: {}
                        schema:
                          type: object
                          required:
                            - type
                          properties:
                            type:
                              type: string
        '500':
          description: Unexpected Error | Unknown Error
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/UnexpectedError9'
                  - $ref: '#/components/schemas/UnknownError9'
      security:
        - apiKey: []
components:
  schemas:
    BadRequestError3:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0200400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Bad Request
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Bad Request
    UserOptedOutError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0201400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: User Opted Out
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: User Opted Out
    InvalidToPhoneNumberError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0202400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Invalid `to` Phone Number
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Invalid `to` Phone Number
    UnreachableToPhoneNumberError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0203400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Unreachable `to` Phone Number
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Unreachable `to` Phone Number
    NotTFNRegisteredError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0207400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Not TFN Registered
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Not TFN Registered
    A2PRegistrationNotApprovedError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0206400'
        status:
          type: number
          const: 400
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: A2P Registration Not Approved
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: A2P Registration Not Approved
    NotEnoughCreditsError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0200402'
        status:
          type: number
          const: 402
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Not Enough Credits
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Not Enough Credits
    SubscriptionExpiredError:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
        - description
      properties:
        message:
          type: string
        code:
          type: string
          const: '0201402'
        status:
          type: number
          const: 402
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Subscription Expired
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
        description:
          type: string
          const: Your subscription has expired
      title: Subscription Expired
    ForbiddenError5:
      anyOf:
        - type: object
          required:
            - message
            - code
            - status
            - docs
            - title
          properties:
            message:
              type: string
            code:
              type: string
              const: '0200403'
            status:
              type: number
              const: 403
            docs:
              type: string
              const: https://quo.com/docs
            title:
              type: string
              const: Forbidden
            trace:
              type: string
            errors:
              type: array
              items:
                type: object
                required:
                  - path
                  - message
                  - schema
                properties:
                  path:
                    type: string
                  message:
                    type: string
                  value: {}
                  schema:
                    type: object
                    required:
                      - type
                    properties:
                      type:
                        type: string
        - type: object
          required:
            - message
            - code
            - status
            - docs
            - title
          properties:
            message:
              type: string
            code:
              type: string
              const: '0202403'
            status:
              type: number
              const: 403
            docs:
              type: string
              const: https://quo.com/docs
            title:
              type: string
              const: Not Phone Number User
            trace:
              type: string
            errors:
              type: array
              items:
                type: object
                required:
                  - path
                  - message
                  - schema
                properties:
                  path:
                    type: string
                  message:
                    type: string
                  value: {}
                  schema:
                    type: object
                    required:
                      - type
                    properties:
                      type:
                        type: string
      title: Forbidden
    A2PDailyMessageCapReachedError2:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0204403'
        status:
          type: number
          const: 403
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: A2P 10DLC Daily Message Cap Reached
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: A2P Daily Message Cap Reached
    UnexpectedError9:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0200500'
        status:
          type: number
          const: 500
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Unexpected
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Unexpected Error
    UnknownError9:
      type: object
      required:
        - message
        - code
        - status
        - docs
        - title
      properties:
        message:
          type: string
        code:
          type: string
          const: '0201500'
        status:
          type: number
          const: 500
        docs:
          type: string
          const: https://quo.com/docs
        title:
          type: string
          const: Unknown
        trace:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - path
              - message
              - schema
            properties:
              path:
                type: string
              message:
                type: string
              value: {}
              schema:
                type: object
                required:
                  - type
                properties:
                  type:
                    type: string
      title: Unknown Error
  securitySchemes:
    apiKey:
      in: header
      name: Authorization
      type: apiKey

````