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

# Get Campaign Messages

> Returns all messages associated with a campaign, including contact details and step information



## OpenAPI

````yaml GET /public-api/campaigns/{id}/get-messages
openapi: 3.0.0
info:
  title: Agents Public API
  version: '1.0'
  description: REST API for managing contacts, campaigns, and conversations
  termsOfService: https://agents.nineteen58.co.za/terms
  contact:
    name: API Support
    url: https://agents.nineteen58.co.za/support
    email: support@nineteen58.co.za
servers:
  - url: https://agents.nineteen58.co.za
    description: Production server
security:
  - apiKeyAuth: []
tags: []
paths:
  /public-api/campaigns/{id}/get-messages:
    get:
      tags:
        - Campaign Messages
      summary: Retrieve messages for a specific campaign
      description: >-
        Returns all messages associated with a campaign, including contact
        details and step information
      operationId: getpublicapicampaignsidgetmessages
      parameters:
        - in: header
          name: x-api-key
          schema:
            type: string
          required: true
          description: API key for authentication
        - in: path
          name: id
          schema:
            type: string
            format: uuid
          required: true
          description: Campaign ID
        - in: query
          name: page
          schema:
            type: integer
            minimum: 1
            default: 1
          description: Page number for pagination
        - in: query
          name: pageSize
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
          description: Number of items per page
      responses:
        '200':
          description: Successfully retrieved campaign messages
          content:
            application/json:
              schema:
                type: object
                properties:
                  messages:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: uuid
                        created_at:
                          type: string
                          format: date-time
                        earliest_at:
                          type: string
                          format: date-time
                        sent_at:
                          type: string
                          format: date-time
                        contact:
                          type: object
                          properties:
                            id:
                              type: string
                              format: uuid
                            name:
                              type: string
                            identifier:
                              type: string
                        step_name:
                          type: string
                  totalCount:
                    type: integer
                  currentPage:
                    type: integer
                  pageSize:
                    type: integer
                  totalPages:
                    type: integer
        '401':
          description: Unauthorized - Invalid or missing authentication token
        '404':
          description: Campaign not found
        '500':
          description: Internal server error
      security:
        - apiKeyAuth: []
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````