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

# Get Campaign/Subcampaign

> Returns campaign/subcampaign for given ID.



## OpenAPI

````yaml https://server.stage.overflow.co/api/docs/openapi.json get /api/v3/campaigns/{campaignId}
openapi: 3.0.0
info:
  title: Overflow Open API
  description: |

    The documentation for the Overflow Open APIs.

    To access the OpenAPI spec in JSON/YAML format, navigate to:

    * `/api/docs/openapi.json`
    * `/api/docs/openapi.yaml`
  version: '3.0'
  contact: {}
servers:
  - url: https://server.stage.overflow.co
    description: API server
security: []
tags: []
paths:
  /api/v3/campaigns/{campaignId}:
    get:
      tags:
        - Campaigns
      summary: Get Campaign/Subcampaign
      description: Returns campaign/subcampaign for given ID.
      operationId: OpenApiCampaignsController_getCampaignById
      parameters:
        - name: campaignId
          required: true
          in: path
          description: The Id of the campaign/subcampaign to get.
          schema:
            example: 2ea1ae03ca521e437db76d76
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetCampaignByIdResponse'
        '404':
          description: Campaign not found.
      security:
        - ClientId: []
          ApiKey: []
components:
  schemas:
    GetCampaignByIdResponse:
      type: object
      properties:
        data:
          type: object
          properties:
            id:
              type: string
              description: Campaign Id
              example: 7710f34fd5061afeec3eab59
            archivedAt:
              type: string
              format: date-time
              nullable: true
              description: Campaign archived at
              example: '2025-01-01T00:00:00.000Z'
            createdAt:
              type: string
              format: date-time
              description: Campaign created at
              example: '2025-01-01T00:00:00.000Z'
            updatedAt:
              type: string
              format: date-time
              description: Campaign updated at
              example: '2025-01-01T00:00:00.000Z'
            name:
              type: string
              description: Campaign name
              example: Builders Fundraiser
            isSubcampaign:
              default: false
              type: boolean
              description: Whether the campaign is a subcampaign
            startDate:
              type: string
              format: date-time
              description: Campaign start date
              example: '2025-01-01T00:00:00.000Z'
            endDate:
              type: string
              format: date-time
              nullable: true
              description: Campaign end date
              example: '2025-12-01T00:00:00.000Z'
            status:
              type: string
              enum:
                - ACTIVE
                - ARCHIVED
                - EXPIRED
                - UPCOMING
              description: Campaign status
              example: ACTIVE
            displayOrder:
              type: number
              nullable: true
              description: Campaign display order
              example: 1
            hideFromDonors:
              default: false
              type: boolean
              description: Whether the campaign is hidden from donors.
            isActive:
              default: false
              type: boolean
              description: Whether the campaign is actively receiving donations.
            locationIds:
              type: array
              items:
                type: string
              description: >-
                The list of locationIds this campaign is attached to. Empty
                array means all locations.
            parentCampaigns:
              type: array
              items:
                type: object
                properties:
                  id:
                    type: string
                  name:
                    type: string
                required:
                  - id
                  - name
              description: List of parent campaigns if the campaign is a subcampaign
            subcampaigns:
              type: array
              items:
                type: object
                properties:
                  id:
                    type: string
                  name:
                    type: string
                required:
                  - id
                  - name
              description: List of subcampaigns if the campaign is a parent campaign
            applyToAllCampaigns:
              type: boolean
              description: Whether the subcampaign is applied to all campaigns
            totalContributionCount:
              default: 0
              type: number
              description: Total number of contributions towards this campaign
              example: 100
            totalContributionValue:
              default: 0
              type: number
              description: Total value of contributions towards this campaign
              example: 1000
            uniqueDonorCount:
              default: 0
              type: number
              description: Total number of unique donors who have donated to this campaign
              example: 100
          required:
            - id
            - archivedAt
            - createdAt
            - updatedAt
            - name
            - startDate
            - endDate
            - status
            - displayOrder
          description: Campaign for the given id.
      required:
        - data
  securitySchemes:
    ClientId:
      type: apiKey
      in: header
      name: x-client-id
      description: Client ID for API authentication
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: API Key for API authentication

````