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

# List campaign targets

> Returns the people in a campaign and where each one stands.



## OpenAPI

````yaml /openapi.json get /campaigns/{campaignId}/targets
openapi: 3.1.0
info:
  title: ReachHunt API
  version: 1.0.0
  description: >-
    The ReachHunt API gives your own apps and scripts programmatic access to
    your workspace: accounts, campaigns, lead lists, conversations, messages,
    tags and statuses.


    Send your API key in the `Authorization` header: `Authorization: Bearer
    YOUR_API_KEY`. The key decides the workspace, so no path or parameter names
    one.


    Every response has the same envelope: `{ "status": true, "data": ...,
    "error": null }`.
servers:
  - url: https://api.reachhunt.ai/api/v1
    description: Production
security: []
tags:
  - name: Workspaces
    description: Your workspace and the people in it.
  - name: Accounts
    description: The X and LinkedIn accounts you connected.
  - name: Analytics
    description: Activity over time.
  - name: Credits
    description: AI credits and how they were used.
  - name: Campaigns
    description: Outreach that messages your leads step by step.
  - name: Agents
    description: AI agents that reply to your leads.
  - name: Tags
    description: Labels you put on conversations.
  - name: Statuses
    description: Pipeline stages you put conversations in.
  - name: Leads
    description: The people in your lead lists.
  - name: Lead lists
    description: Lists of people you collect to message.
  - name: Conversations
    description: The conversations in your inbox.
  - name: Messages
    description: The messages in a conversation.
  - name: Conversation details
    description: Your team's record of the person in a conversation.
  - name: Internal notes
    description: Notes only your team sees.
  - name: Scheduled messages
    description: Messages set to send later.
  - name: Templates
    description: Saved messages you can reuse.
  - name: Webhook events
    description: What each event sends.
paths:
  /campaigns/{campaignId}/targets:
    get:
      tags:
        - Campaigns
      summary: List campaign targets
      description: Returns the people in a campaign and where each one stands.
      operationId: campaigns.listTargets
      parameters:
        - name: campaignId
          in: path
          required: true
          description: The campaign ID.
          schema:
            type: string
        - name: status
          in: query
          required: false
          description: Only targets in this state.
          schema:
            type: string
        - name: search
          in: query
          required: false
          description: Text to look for in the name or handle.
          schema:
            type: string
        - name: page
          in: query
          required: false
          description: The page to return, starting at 1.
          schema:
            type: integer
            minimum: 1
        - name: limit
          in: query
          required: false
          description: How many items to return, from 1 to 100. Defaults to 50.
          schema:
            type: integer
            minimum: 1
            maximum: 100
      responses:
        '200':
          description: 'OK. Check `status`: errors the API handles itself also return 200.'
          content:
            application/json:
              schema:
                type: object
                required:
                  - status
                  - data
                  - error
                properties:
                  status:
                    type: boolean
                    description: '`true` when the request succeeded.'
                  data:
                    type: object
                    properties:
                      items:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                              description: The ID.
                            prospectId:
                              type: string
                              description: The lead ID.
                            platform:
                              type: string
                              description: 'The network: `x` or `linkedin`.'
                            handle:
                              type: string
                              description: The username, without a prefix.
                            name:
                              type: string
                              description: The name.
                            avatarUrl:
                              type:
                                - string
                                - 'null'
                              description: Link to the photo.
                            status:
                              type: string
                              description: The current state.
                            stepIndex:
                              type: integer
                              description: The sequence step the person is on.
                            messagesSent:
                              type: integer
                              description: Messages sent from ReachHunt.
                            inviteState:
                              type: string
                              description: Where the connection request stands.
                            invitedAt:
                              type:
                                - string
                                - 'null'
                              format: date-time
                              description: When the connection request was sent.
                            accountId:
                              type: string
                              description: The connected account.
                            conversationId:
                              type: string
                              description: >-
                                The conversation ID. URL-encode it in paths: X
                                IDs contain `:`.
                            lastSentAt:
                              type: string
                              format: date-time
                              description: When the last message went out.
                            nextActionAt:
                              type:
                                - string
                                - 'null'
                              format: date-time
                              description: When the next step is due.
                            failedAt:
                              type:
                                - string
                                - 'null'
                              format: date-time
                              description: When it failed.
                            replied:
                              type: boolean
                              description: Whether the person replied.
                            repliedAt:
                              type: string
                              format: date-time
                              description: When the person replied.
                            error:
                              type:
                                - string
                                - 'null'
                              description: Why it failed. `null` when it did not.
                          required:
                            - id
                            - prospectId
                            - platform
                            - handle
                            - name
                            - avatarUrl
                            - status
                            - stepIndex
                            - messagesSent
                            - inviteState
                            - invitedAt
                            - accountId
                            - conversationId
                            - lastSentAt
                            - nextActionAt
                            - failedAt
                            - replied
                            - repliedAt
                            - error
                      page:
                        type: integer
                        description: The page returned.
                      limit:
                        type: integer
                        description: The page size used.
                      total:
                        type: integer
                        description: How many match, across all pages.
                      totalPages:
                        type: integer
                        description: How many pages there are.
                    required:
                      - items
                      - page
                      - limit
                      - total
                      - totalPages
                  error:
                    type: 'null'
                    description: Always `null` on success.
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/PlanRequired'
        '500':
          $ref: '#/components/responses/ServerError'
      security:
        - bearerAuth: []
components:
  responses:
    Unauthorized:
      description: The API key is missing or not valid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Failure'
          example:
            status: false
            data: null
            error: Not authenticated
    PlanRequired:
      description: The workspace has no active plan, or its trial has ended.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Failure'
          example:
            status: false
            data: null
            error: Your free trial has ended. Pick a plan to continue.
    ServerError:
      description: Something failed on our side. Try again.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Failure'
          example:
            status: false
            data: null
            error: Something went wrong. Please try again.
  schemas:
    Failure:
      type: object
      required:
        - status
        - data
        - error
      properties:
        status:
          type: boolean
          description: Always `false` for an error.
        data:
          type: 'null'
          description: Always `null` for an error.
        error:
          type: string
          description: What went wrong, in plain words.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: Bearer
      description: >-
        Your API key, sent as `Authorization: Bearer YOUR_API_KEY`. Create one
        in **Settings → API**.
      x-default: Bearer YOUR_API_KEY

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.