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

# Get campaign by ID



## OpenAPI

````yaml /en/openapi.json get /v1/campaigns/{id}
openapi: 3.0.0
info:
  title: Nuvia API - Company
  description: API documentation for companies
  version: '1.0'
  contact: {}
servers:
  - url: https://api.nuvia.ai
security: []
tags:
  - name: messages
    x-group: Mensagens
  - name: contacts
    x-group: Contatos
  - name: campaigns
    x-group: Campanhas
  - name: tables
    x-group: Tabelas e Listas
  - name: agents
    x-group: Agentes
  - name: conversations
    x-group: Conversas
  - name: inboxes
    x-group: Caixas de Entrada
  - name: knowledge
    x-group: Base de Conhecimento
  - name: Webhooks
    x-group: Webhooks
  - name: campaign-enrollments
    x-group: Inscrições em Campanha
  - name: custom-fields
    x-group: Campos Customizados
paths:
  /v1/campaigns/{id}:
    get:
      tags:
        - campaigns
      summary: Get campaign by ID
      operationId: CampaignController_findById
      parameters:
        - name: x-company-id
          in: header
          description: >-
            Target company identifier. Required only for global API keys
            (type=global). Ignored for company API keys and human users.
          required: false
          schema:
            type: string
        - name: id
          required: true
          in: path
          description: Campaign ID
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CampaignEntity'
      security:
        - JWT-auth: []
components:
  schemas:
    CampaignEntity:
      type: object
      properties:
        _id:
          $ref: '#/components/schemas/ObjectId'
        company:
          type: object
        name:
          type: string
        description:
          type: string
        channel_type:
          type: object
        trigger_type:
          type: string
          enum:
            - MANUAL
            - SCHEDULED
            - RECURRING
            - EXTERNAL_TRIGGER
        trigger_config:
          type: object
        audience_config:
          type: object
        behavior_config:
          type: object
        linkedin_config:
          type: object
        sender_config:
          type: object
        status:
          enum:
            - DRAFT
            - ACTIVE
            - PAUSED
            - COMPLETED
            - ARCHIVED
          type: string
        launched_at:
          format: date-time
          type: string
          description: >-
            First actual send of this campaign (ISSUE-6074). Exists to give

            BUSINESS idempotency to the `campaign_launched` event: once per

            campaign, forever — neither `event_id` nor Bull's retry solve this,

            because the campaign runs thousands of times over its life.


            Born ABSENT (no default) on purpose: the conditional update

            `{ launched_at: { $exists: false } }` is what guarantees
            exactly-once, and a

            default null would break that condition.
        metrics:
          type: object
        last_execution_at:
          format: date-time
          type: string
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
      required:
        - _id
        - company
        - name
        - channel_type
        - trigger_type
        - trigger_config
        - audience_config
        - status
        - metrics
    ObjectId:
      type: object
      properties: {}
  securitySchemes:
    JWT-auth:
      scheme: bearer
      bearerFormat: JWT
      type: http
      description: Token JWT de autenticação

````