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

# List campaigns

> Retrieve a paginated list of campaigns for the current user.



## OpenAPI

````yaml /api-reference/campaigns-contacts.openapi.yaml get /api/v1/campaigns
openapi: 3.1.0
info:
  title: Campaigns & Contacts API
  description: >
    REST endpoints for managing calling campaigns (batches) and contact
    directories (People Groups, columns, and rows).


    **Production base URL:** `https://api.kupe.in` — prepend this to each path
    below.


    ## Recommended workflow: Excel → People → Campaign → Launch


    1. `POST /api/v1/people-groups` — create a people list

    2. `POST /api/v1/people-groups/{id}/upload/preview` — (optional) validate
    Excel/CSV mapping

    3. `POST /api/v1/people-groups/{id}/upload` — import contacts from `.csv`,
    `.xlsx`, or `.xls`

    4. `POST /api/v1/campaigns` — create a campaign (agent/workflow + caller
    phone)

    5. `POST /api/v1/campaigns/{id}/groups` — attach the people list to the
    campaign

    6. `GET /api/v1/campaigns/{id}/readiness` — verify the campaign can be
    launched

    7. `POST /api/v1/campaigns/{id}/start` — start dialing
  version: 1.0.0
servers:
  - url: https://api.kupe.in
    description: Production
security:
  - KupeApiKey: []
  - BearerAuth: []
tags:
  - name: Campaigns
    description: Create, update, control, list, and monitor outbound campaigns (batches).
  - name: People Groups
    description: >-
      Define schemas (columns), list records (rows), and upload contact files
      (CSV, Excel).
paths:
  /api/v1/campaigns:
    get:
      tags:
        - Campaigns
      summary: List campaigns
      description: Retrieve a paginated list of campaigns for the current user.
      operationId: listCampaigns
      parameters:
        - name: page
          in: query
          schema:
            type: integer
            minimum: 1
            default: 1
        - name: page_size
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
        - name: start_date
          in: query
          schema:
            type: string
            format: date-time
          description: Start date filter.
        - name: end_date
          in: query
          schema:
            type: string
            format: date-time
          description: End date filter.
      responses:
        '200':
          description: A list of campaigns and total count.
          content:
            application/json:
              schema:
                type: object
                properties:
                  campaigns:
                    type: array
                    items:
                      $ref: '#/components/schemas/CampaignResponse'
                  total:
                    type: integer
components:
  schemas:
    CampaignResponse:
      type: object
      properties:
        id:
          type: string
          format: uuid
        user_id:
          type: string
          format: uuid
        agent_id:
          type: string
          format: uuid
        workflow_id:
          type: string
          format: uuid
          nullable: true
        call_flow_id:
          type: string
          format: uuid
          nullable: true
        caller_phone_id:
          type: string
          format: uuid
        batch_name:
          type: string
        description:
          type: string
          nullable: true
        status:
          type: string
        variable_names:
          type: array
          items:
            type: string
        batch_size:
          type: integer
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
  securitySchemes:
    KupeApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: Kupe dashboard API key.
      x-default: YOUR_KUPE_API_KEY
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Supabase session JWT.

````