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

# Get Subscription

> Retrieve details about a specific subscription

# Get Subscription

Retrieve information about a subscription, including its current status and next billing date.

## Authentication

```bash theme={null}
Authorization: Bearer glm_test_YOUR_API_KEY
```

## Path Parameters

| Parameter | Type   | Required | Description                             |
| --------- | ------ | -------- | --------------------------------------- |
| `id`      | string | Yes      | Subscription ID (e.g., `sub_abc123xyz`) |

## Request

```bash theme={null}
GET /api/v2/subscriptions/{id}
```

## Response

```json theme={null}
{
  "id": "sub_abc123xyz",
  "customer_id": "cus_xyz789",
  "status": "active",
  "product_id": 12345,
  "amount_cents": 9900,
  "currency": "USD",
  "interval": "monthly",
  "interval_count": 1,
  "current_period_start": "2025-10-18T14:30:00Z",
  "current_period_end": "2025-11-18T14:30:00Z",
  "next_billing_date": "2025-11-18T14:30:00Z",
  "cancel_at_period_end": false,
  "payment_method": {
    "type": "hsa_fsa_card",
    "last4": "1111",
    "brand": "visa"
  },
  "created_at": "2025-10-18T14:30:00Z",
  "updated_at": "2025-10-18T14:30:00Z"
}
```

See [Subscription Object](/api-reference/objects/subscription) for complete field descriptions.

## Examples

### Basic Retrieval

```bash theme={null}
curl https://api.withgale.com/api/v2/subscriptions/sub_abc123xyz \
  -H "Authorization: Bearer glm_test_YOUR_API_KEY"
```

### With JavaScript

```javascript theme={null}
const getSubscription = async (subscriptionId) => {
  const response = await fetch(
    `https://api.withgale.com/api/v2/subscriptions/${subscriptionId}`,
    {
      headers: {
        'Authorization': `Bearer ${process.env.GALE_API_KEY}`
      }
    }
  );

  return await response.json();
};

// Check subscription status
const sub = await getSubscription('sub_abc123xyz');
console.log(`Status: ${sub.status}`);
console.log(`Next billing: ${sub.next_billing_date}`);
```

## Related Endpoints

* [Create Subscription](/api-reference/endpoint/create-subscription)
* [List Subscriptions](/api-reference/endpoint/list-subscriptions)
* [Cancel Subscription](/api-reference/endpoint/cancel-subscription)
