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

# List conversation messages



## OpenAPI

````yaml /openapi.json get /conversations/{id}/messages
openapi: 3.0.0
info:
  title: Visito API
  version: 1.0.0
servers: []
security: []
paths:
  /conversations/{id}/messages:
    get:
      tags:
        - Conversations
      summary: List conversation messages
      parameters:
        - name: id
          in: path
          required: true
          description: Conversation/contact ID.
          schema:
            type: string
            minLength: 1
            example: 68505cb92a11ea971d9df894
        - name: limit
          in: query
          required: false
          description: Max number of messages to return (1–100).
          schema:
            type: integer
            minimum: 1
            maximum: 100
            example: 20
        - name: cursor
          in: query
          required: false
          description: Pagination cursor from previous page.
          schema:
            type: string
            example: 68505cb92a11ea971d9df894
      responses:
        '200':
          description: Conversation messages
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Message'
                  meta:
                    type: object
                    properties:
                      pagination:
                        $ref: '#/components/schemas/Pagination'
                    required:
                      - pagination
                required:
                  - data
                  - meta
        '401':
          description: Missing or invalid Authorization header
        '403':
          description: Invalid API key
        '500':
          description: Server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    Message:
      type: object
      properties:
        id:
          type: string
          example: 68505cb92a11ea971d9df894
          description: Message ID
        providerId:
          type: string
          nullable: true
          example: wamid.HBgLMTIzNDU2Nzg5FQIAERgSMzQ1Q0Y5QkE=
          description: Provider message ID (WhatsApp/Meta).
        contact:
          type: string
          nullable: true
          example: 68505cb92a11ea971d9df894
          description: Conversation/contact ID.
        content:
          type: string
          nullable: true
          example: Hello! How can I help?
          description: Message text content.
        role:
          type: string
          nullable: true
          example: assistant
          description: Message role/type.
        status:
          type: string
          nullable: true
          example: unsent
          description: Delivery status.
        error:
          type: string
          nullable: true
          example: Rate limit exceeded
          description: Provider error message when send fails.
      required:
        - id
    Pagination:
      type: object
      properties:
        limit:
          type: integer
          minimum: 1
          maximum: 100
          description: Limit used for this page.
          example: 25
        nextCursor:
          type: string
          nullable: true
          description: Cursor for the next page (null if there is no next page).
          example: 68505cb92a11ea971d9df894
        hasMore:
          type: boolean
          description: Whether more results are available.
          example: true
      required:
        - limit
        - nextCursor
        - hasMore
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          example: something_went_wrong
      required:
        - error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: 'Use `Authorization: Bearer <api_key>`.'

````