# Get the organization's campaign standing

`GET https://evohub.io/api/v1/billing/campaign`

Part of the [Billing API](https://docs.evohub.io/billing.md) reference · operationId `getCampaignStatus`.

Where the organization stands with the credit campaigns running now.

- `campaign` is the running sign-up campaign (credit for saving a
  first card), or `null`. `status` is the organization's standing
  with it: `eligible` (it will be paid when a card is saved),
  `granted`, `pending` (under review), `ineligible`, or
  `not_applicable` (no campaign, a card is already saved, or the
  organization signed up before the campaign began). `reason` is a
  short machine-readable explanation for `pending` and `ineligible`,
  otherwise `""`.
- `integration` is the running first-integration campaign (credit
  for the first integration in a product), or `null`, and `gifts`
  the credit it — or an earlier one — paid the organization
  recently, newest first.

Requires the `billing:usage:read` scope.

## Authorization

Any one of:

- `bearerKey`
- `headerKey`

Where:

- `bearerKey`: HTTP Bearer — An EvoHub API key (`evohub_…`) as a bearer token.
- `headerKey`: API key in the header `X-API-Key` — An EvoHub API key (`evohub_…`).

## Responses

### 200 — The campaign standing.

Content type: `application/json`

Type: `object`

- `data` (OrgCampaign)
  - `campaign` (PublicCampaign | null)
    - One of:
      - PublicCampaign
        - `id` (string)
        - `kind` (string, one of `card_signup`, `first_integration`)
        - `products` (array of string): The products a first-integration campaign pays for; `[]` for a sign-up campaign.
        - `name` (string)
        - `banner_text` (string)
        - `banner_link` (string)
        - `ehu` (number): The credit paid, in EHU.
        - `ends_at` (string (date-time))
      - null
  - `status` (string, one of `eligible`, `granted`, `pending`, `ineligible`, `not_applicable`)
  - `reason` (string)
  - `integration` (PublicCampaign | null)
    - One of:
      - PublicCampaign
        - `id` (string)
        - `kind` (string, one of `card_signup`, `first_integration`)
        - `products` (array of string): The products a first-integration campaign pays for; `[]` for a sign-up campaign.
        - `name` (string)
        - `banner_text` (string)
        - `banner_link` (string)
        - `ehu` (number): The credit paid, in EHU.
        - `ends_at` (string (date-time))
      - null
  - `gifts` (array of object)
    - `id` (string)
    - `product` (string)
    - `ehu` (number)
    - `granted_at` (string (date-time) | null)
    - `expires_at` (string (date-time) | null)

### 401 — No API key was sent, or it is unknown, revoked or expired (`UNAUTHORIZED`).

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `STATEMENT_NOT_FOUND`)
  - `message` (string, required, example `No statement for that period.`)
  - `request_id` (string)

### 403 — The key lacks the scope this endpoint needs (`FORBIDDEN`).

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `STATEMENT_NOT_FOUND`)
  - `message` (string, required, example `No statement for that period.`)
  - `request_id` (string)

### 429 — Too many requests (`RATE_LIMITED`). Wait for `Retry-After` seconds.

Headers:

- `Retry-After` (integer): Seconds to wait before retrying.

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `STATEMENT_NOT_FOUND`)
  - `message` (string, required, example `No statement for that period.`)
  - `request_id` (string)

### 500 — The campaign could not be loaded (`CAMPAIGN_UNAVAILABLE`). Retry later.

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `STATEMENT_NOT_FOUND`)
  - `message` (string, required, example `No statement for that period.`)
  - `request_id` (string)

## Example request

```bash
curl -X GET 'https://evohub.io/api/v1/billing/campaign' \
  -H 'Authorization: Bearer <TOKEN>'
```
