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

# List Payment Plans

> Retrieve all available credit subscription plans from Stripe

This endpoint returns a list of all available credit subscription plans that can be purchased. Plans are fetched directly from Stripe and include pricing, features, and credit amounts.

## Authentication

<Note>
  This endpoint is publicly accessible and does not require authentication. It
  returns the same plan information to all users.
</Note>

## Request

This endpoint does not require any request parameters.

## Response

The response is an array of subscription plan objects, sorted by credit amount in ascending order (lowest to highest).

<ResponseField name="response" type="array" required>
  The response body is a JSON array of subscription plan objects (not wrapped in an object).

  <Expandable title="Plan Object Properties">
    <ResponseField name="id" type="string" required>
      The Stripe product ID for this plan.

      **Example:** `prod_ABC123xyz`
    </ResponseField>

    <ResponseField name="productId" type="string" required>
      The Stripe product ID (same as `id`). Included for compatibility.

      **Example:** `prod_ABC123xyz`
    </ResponseField>

    <ResponseField name="label" type="string" required>
      Human-readable name of the plan, derived from the Stripe product name.

      **Example:** `Starter Plan`
    </ResponseField>

    <ResponseField name="price" type="string" required>
      Formatted price display string with currency symbol. Shows "Free" for zero-cost plans.

      **Example:** `€ 49` or `Free`
    </ResponseField>

    <ResponseField name="interval" type="string | null" required>
      Billing interval for recurring plans. Can be `month`, `year`, `day`, `week`, or `null` for one-time purchases.

      **Example:** `month`
    </ResponseField>

    <ResponseField name="amount" type="integer" required>
      Number of credits included in the plan. Extracted from the product's `credits` metadata field.

      **Example:** `1000`
    </ResponseField>

    <ResponseField name="currency" type="string" required>
      Currency symbol for the plan price.

      **Example:** `€`, `$`, `£`, or `CHF`
    </ResponseField>

    <ResponseField name="description" type="string">
      Optional description of the plan from Stripe product description.

      **Example:** `Perfect for small teams getting started with prospecting`
    </ResponseField>

    <ResponseField name="features" type="array" required>
      Array of feature strings from Stripe marketing features. Empty array if no features defined.

      **Example:** `["1000 credits per month", "Email enrichment", "Phone enrichment"]`
    </ResponseField>
  </Expandable>
</ResponseField>

## Plan Configuration

Plans are configured in Stripe with the following requirements:

| Stripe Field         | Requirement                                        |
| -------------------- | -------------------------------------------------- |
| `metadata.type`      | Must be set to `credits` to be included in results |
| `metadata.credits`   | Number of credits included in the plan             |
| `default_price`      | Active price for the product                       |
| `marketing_features` | Optional list of features to display               |

## Supported Currencies

| Currency Code | Symbol |
| ------------- | ------ |
| EUR           | €      |
| USD           | \$     |
| GBP           | £      |
| CHF           | CHF    |

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://app.lance.so/api/v1/operations/payment/plans"
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("/api/v1/operations/payment/plans", {
    method: "GET",
  });

  const plans = await response.json();
  console.log(`Found ${plans.length} available plans`);
  ```

  ```typescript TypeScript theme={null}
  interface SubscriptionPlan {
    id: string;
    productId: string;
    label: string;
    price: string;
    interval: "month" | "year" | "day" | "week" | null;
    amount: number;
    currency: string;
    description?: string;
    features: string[];
  }

  const response = await fetch("/api/v1/operations/payment/plans", {
    method: "GET",
  });

  const plans: SubscriptionPlan[] = await response.json();
  ```
</RequestExample>

<ResponseExample>
  ```json Success Response theme={null}
  [
    {
      "id": "prod_starter123",
      "productId": "prod_starter123",
      "label": "Starter",
      "price": "€ 29",
      "interval": "month",
      "amount": 500,
      "currency": "€",
      "description": "Perfect for individuals",
      "features": [
        "500 credits per month",
        "Email enrichment",
        "Basic support"
      ]
    },
    {
      "id": "prod_growth456",
      "productId": "prod_growth456",
      "label": "Growth",
      "price": "€ 79",
      "interval": "month",
      "amount": 2000,
      "currency": "€",
      "description": "For growing teams",
      "features": [
        "2000 credits per month",
        "Email & phone enrichment",
        "Priority support",
        "CRM integration"
      ]
    },
    {
      "id": "prod_enterprise789",
      "productId": "prod_enterprise789",
      "label": "Enterprise",
      "price": "€ 199",
      "interval": "month",
      "amount": 10000,
      "currency": "€",
      "description": "For large organizations",
      "features": [
        "10000 credits per month",
        "All enrichment features",
        "Dedicated support",
        "Custom integrations"
      ]
    }
  ]
  ```

  ```json Empty Response theme={null}
  []
  ```

  ```json Error Response (Server Error) theme={null}
  {
    "error": {
      "code": "INTERNAL_ERROR",
      "message": "An unexpected error occurred"
    }
  }
  ```
</ResponseExample>

## Error Codes

| Status Code | Error Code       | Description                                   |
| ----------- | ---------------- | --------------------------------------------- |
| `500`       | `INTERNAL_ERROR` | Server error while fetching plans from Stripe |

## Notes

* Plans are fetched in real-time from Stripe, ensuring pricing is always current
* Only active products with `metadata.type = "credits"` are returned
* Plans are automatically sorted by credit amount (lowest to highest)
* If a product has no active price, an error will be thrown
* The response is an empty array if no credit products are configured in Stripe
