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

# List all Campaigns

> Retrieves all campaigns in this user account. If `workspace_id` query parameter is provided, only fetches campaigns from that workspace.



## OpenAPI

````yaml /openapi.yml get /api/v1/campaigns/
openapi: 3.1.1
info:
  title: DeliverymanAI API
  version: 1.0.0
  description: >-
    API documentation for DeliverymanAI, a Cold Email Management and Automation
    platform. This API provides endpoints for managing campaigns, contacts,
    email sequences, and related services.
servers:
  - url: https://api.deliveryman.ai
    description: Deliveryman API Server
security: []
paths:
  /api/v1/campaigns/:
    get:
      tags:
        - Campaign
      summary: List all Campaigns
      description: >-
        Retrieves all campaigns in this user account. If `workspace_id` query
        parameter is provided, only fetches campaigns from that workspace.
      operationId: campaigns_retrieve
      parameters:
        - in: query
          name: limit
          schema:
            maximum: 100
            minimum: 1
            title: Limit
            type: integer
          description: >-
            Maximum number of records to fetch in the current page. Must be
            between 1 and 100.
          required: true
        - in: query
          name: offset
          schema:
            minimum: 0
            title: Offset
            type: integer
          description: >-
            Number of records to skip before fetching the results.For example,
            an offset of 0 starts at the beginning, while an offset of 50
            fetches records starting from the 51st. If offset is greater than
            number of records available, results will be empty.
          required: true
        - in: query
          name: workspace_id
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            title: Workspace Id
          description: Fetch campaigns from this workspace only.
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAllCampaignApiResponse'
          description: Success
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SimpleMessageResponse'
          description: Bad Request
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SimpleMessageResponse'
          description: Not Found
        '500':
          description: Internal Server Error
      security:
        - ApiKeyAuth: []
components:
  schemas:
    GetAllCampaignApiResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/GetAllCampaignsAPI'
          description: List of campaign data.
        total:
          type: integer
          minimum: 0
          description: >-
            Total number of campaigns available in this workspace if
            `workspace_id` was provided. Otherwise across all workspaces.
      required:
        - data
        - total
    SimpleMessageResponse:
      type: object
      properties:
        message:
          type: string
      required:
        - message
    GetAllCampaignsAPI:
      type: object
      properties:
        uid:
          type: string
          maxLength: 255
        name:
          type: string
          maxLength: 300
        workspace_id:
          type:
            - integer
            - 'null'
          readOnly: true
        status:
          $ref: '#/components/schemas/StatusF69Enum'
        created_on:
          type: string
          format: date-time
          readOnly: true
      required:
        - created_on
        - name
        - uid
        - workspace_id
    StatusF69Enum:
      enum:
        - creating
        - created
        - scheduled
        - running
        - paused
        - complete
        - cancelled
        - failed
      type: string
      description: |-
        * `creating` - Creating
        * `created` - Created
        * `scheduled` - Scheduled
        * `running` - Running
        * `paused` - Paused
        * `complete` - Complete
        * `cancelled` - Cancelled
        * `failed` - Failed
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: 'Enter your API key in the format: X-Api-Key <your_key>'

````