> ## 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.

# API Reference

> Buyer overview of Streamly HTTP APIs — OpenAPI docs, /api/v1 tenant APIs, operator routes, and auth scopes.

Streamly exposes HTTP APIs used by the storefront, tenant dashboard, operator console, and optional external clients.

## OpenAPI

On any running deploy, open:

| URL                 | Purpose                           |
| ------------------- | --------------------------------- |
| `/api/docs`         | Interactive OpenAPI reference     |
| `/api/openapi.json` | Machine-readable OpenAPI document |

## API groups

\| Prefix | Audience | Notes |
\| --- | --- |
\| `/api/v1/*` | Viewers / tenant clients | Tenant resolved from **Host** + session; catalog, playback, billing checkout, domains, profiles, … |
\| `/api/operator/*` | Operator | Themes, branding, plans, settings |
\| `/api/admin/*` | Operator activation / onboarding / health | License connect flows |
\| `/api/webhooks/stripe` | Stripe | Configure in Stripe Dashboard |
\| `/api/internal/jobs/run` | Scheduler | Header `X-Streamly-Cron-Secret` |
\| `/api/auth/refresh` | Sessions | Keep middleware lean on Workers |

## Client rules

* Always call **your** Streamly host (`NEXT_PUBLIC_STREAMLY_API_BASE`) — do not call TMDB from Flutter/browsers; use server `TMDB_API_TOKEN` + Streamly APIs.
* Viewer vs operator cookies are separate — see [Authentication Flow](/authentication/authentication-flow).
* Custom domains must preserve `Host` for correct tenant scoping — see [Domain](/configuration/domain).

## Related

* [Platform Architecture](/introduction/platform-architecture)
* [Environment Variables](/technical/environment-variables)
* [Security](/technical/security)
* [Helpful Resources](/support/helpful-resources)
