# What is paying for the plan

URL: https://docs.fxapis.com/api-reference/billing/what-is-paying-for-the-plan

> What is paying for the plan. The workspace's subscription, if it has one: plan, card or crypto, status, the current paid period and whether it ends at period…

`GET https://api.fxapis.com/v1/billing/subscription`

The workspace's subscription, if it has one: plan, card or crypto, status, the current paid period and whether it ends at period end. Null when nothing is being paid for.

Authentication: `Authorization: Bearer <API key>`.

#### Responses

- `200`
- `401`

Failures return `{ "error": { "code", "message" } }`; every code is listed at https://docs.fxapis.com/errors.

#### 200 response fields

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `data` | null \| object | no |  |
| `data.id` | string (uuid) | no |  |
| `data.plan` | string | no |  |
| `data.method` | "card" \| "crypto" \| "transfer" | no |  |
| `data.interval` | "month" \| "year" | no |  |
| `data.agreement` | boolean | no | Pays for the workspace's enterprise agreement rather than a plan from the price list. |
| `data.status` | "pending" \| "active" \| "past_due" \| "ended" | no | `past_due`: a card renewal failed and is being retried; the plan is kept meanwhile. When paying stops the workspace moves to Free — opening is then refused, and closing never is. |
| `data.currentPeriodEnd` | null \| string (date-time) | no |  |
| `data.cancelAtPeriodEnd` | boolean | no |  |