---
title: "listPlans"
description: "List available plans"
canonical: "https://pgbeam.com/docs/ts-sdk/analytics/listPlans"
last-updated: "2026-10-30T03:14:55.000Z"
---

# listPlans

> List available plans

URL: https://pgbeam.com/docs/ts-sdk/analytics/listPlans

{/* Auto-generated from OpenAPI. Do not edit. Run `pnpm generate:sdk-docs` to regenerate. */}

Returns all available plan tiers with their limits and pricing.

## Usage

```typescript
const result = await api.analytics.listPlans();
```

## Parameters

None.

## Response

`Promise<ListPlansResponse>`: list of available plans.

## Example

```typescript
import { PgBeamClient } from "pgbeam";

const client = new PgBeamClient({
  token: "pbu_...",
  baseUrl: "https://api.pgbeam.com",
});

const result = await client.api.analytics.listPlans();
```

## Errors

| Status | Description                                                                                                                         |
| ------ | ----------------------------------------------------------------------------------------------------------------------------------- |
| 400    | The request was rejected. `code` is `INVALID_INPUT`, and `errors` names the offending fields when the failure was a validation one. |
| 401    | Missing or invalid authentication. `code` is `UNAUTHORIZED`.                                                                        |
| 429    | Rate limited. `code` is `RATE_LIMITED`.                                                                                             |
| 500    | The request failed for a reason on our side. `code` is `INTERNAL_ERROR`. Quote `request_id` when reporting it.                      |