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

# Stripe / Billing

> Configure Stripe checkout and Connect for Streamly via the payments.stripe plugin — required fields, webhooks, and plans.

Streamly billing is **plugin-based**. Stripe keys are **not** in `.env.example`; install and configure Stripe from `/admin/plugins`.

## Wired today

| Piece                      | Status                                                                 |
| -------------------------- | ---------------------------------------------------------------------- |
| `payments.stripe` plugin   | **Wired** — primary checkout                                           |
| Viewer / platform checkout | `/api/v1/billing/platform/checkout`, `/api/v1/billing/viewer/checkout` |
| Stripe Connect helpers     | `/api/v1/billing/connect`                                              |
| Stripe webhook             | `/api/webhooks/stripe`                                                 |
| Plans UI                   | `/admin/plans`                                                         |

## Not wired (roadmap)

| Piece         | Status                                  |
| ------------- | --------------------------------------- |
| PayPal        | Wire next — **no** PayPal webhook route |
| Bank transfer | Wire next                               |

## Plugin configuration fields

In `/admin/plugins` → Stripe:

| Field                   | Required | Purpose                                              |
| ----------------------- | -------- | ---------------------------------------------------- |
| `publishableKey`        | Yes      | Stripe publishable key                               |
| `secretKey`             | Yes      | Stripe secret key                                    |
| `webhookSecret`         | Yes      | Signing secret for `/api/webhooks/stripe`            |
| `connectWebhookSecret`  | Optional | Signing secret for Connect webhook events            |
| `applicationFeePercent` | Optional | Platform fee % on viewer charges (multi-tenant SaaS) |

## Setup steps

1. Open `/admin/plugins` → install/enable **Stripe** (`payments.stripe`).
2. Enter the required keys above.
3. In Stripe Dashboard → Webhooks, add endpoint:
   * URL: `https://YOUR_HOST/api/webhooks/stripe`
   * Copy the signing secret into `webhookSecret`.
4. If you use **Stripe Connect** for tenant payouts, configure Connect webhooks and paste into `connectWebhookSecret`.
5. Create viewer plans in `/admin/plans`.
6. Tenant Connect return/refresh lands on `/dashboard/settings?stripe=return|refresh`.

<CardGroup cols={2}>
  <Card title="Plans" icon="layout-grid" href="/admin-dashboard/plans">
    Define pricing tiers viewers subscribe to.
  </Card>

  <Card title="Plugins" icon="puzzle-piece" href="/admin-dashboard/plugins">
    Install Stripe and other trusted integrations.
  </Card>
</CardGroup>

## Related

* [Billing FAQ](/faq/billing-faq)
* [Subscriptions](/admin-dashboard/subscriptions)
* [Transactions](/admin-dashboard/transactions)
