Admin endpoints
Every internal endpoint the Stream panel calls — path, method, what it does, owner-only or not. Not the public API.
This is not the public API
Everything below lives under /api/admin/* (or a per-resource token path) and
authenticates with the same session cookie as the rest of the admin panel — there is
no al_live_* API key surface for Stream. See API Reference
for TEASE's actual public, key-authenticated API. This page exists so an engineer or
support person can find what a given panel screen actually calls, at a glance.
Owner-only means the router's own module docstring states the endpoint is
restricted to the workspace owner. Where a router carries no such statement, every
route in it authenticates with require_admin alone — reachable by any team member
whose access grant reaches that panel tab (see
Who needs it).
Ingest — receiving the feed
app/products/stream/api/admin/stream.py, stream_ingest.py, stream_camera.py. Not
owner-only.
| Method | Path | What it does |
|---|---|---|
| POST | /api/admin/stream/ingest | Token-gated event intake for the merged StreamEvent feed (OF chat, webcam-hub events, Fansly) — fails closed: empty config is a 503, a bad header is a 401. |
| GET | /api/admin/stream/subscribe | Live-streamed (SSE) merged chat feed for the panel. |
| GET | /api/admin/stream/feed | Paginated read of the same merged feed. |
| GET | /api/admin/stream/ingest/key | Current ingest publish key for the owner (key itself write-only — never echoed back in full). |
| POST | /api/admin/stream/ingest/key/rotate | Issues a new key; the old one stops being accepted immediately. |
| GET | /api/admin/stream/ingest/resolve | Resolves an incoming publish slug to its owner — used by the motor/receiver to route a connecting encoder. |
| GET | /api/admin/stream/ingest/verify | Verifies a slug+key pair before a publish attempt is trusted. |
| GET | /api/admin/stream/overlay-asset/{slug}/{platform} | Serves a platform-scoped overlay design asset by slug, for the receiving box to bake into a platform scene. |
| GET | /api/admin/stream/scene-asset/{slug}/{ref} | Resolves a media:<id>-style scene reference to a servable file for the receiving box. |
| POST | /api/admin/stream/camera/whip | Starts a browser-camera publish session (WHIP offer/answer). |
| DELETE | /api/admin/stream/camera/whip/{session_id} | Ends a browser-camera publish session. |
| GET | /api/admin/stream/camera/state | Current browser-camera publish state for the owner. |
Door — the always-on receiver
app/products/stream/api/admin/stream_door_admin.py (panel-facing) — not owner-only —
and app/products/stream/api/stream_door.py (receiver-facing, secret-in-path, not a
session-authenticated admin endpoint at all).
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/door/state | Live receive state, polled by the panel — separate from the GPU motor so it answers instantly regardless of whether the GPU worker is awake. |
| POST | /api/admin/stream/door/whep | Opens a low-latency WebRTC viewer session on the composed frame (team-accessible; see Who needs it). |
| DELETE | /api/admin/stream/door/whep/{session_id} | Closes a viewer session; idempotent. |
| POST | /api/stream-door/{secret}/auth | The receiving box (MediaMTX) asks whether to accept a publish, by path-segment secret — not a panel endpoint. |
| POST | /api/stream-door/{secret}/ready | Signal arrived — wakes the GPU worker. |
| POST | /api/stream-door/{secret}/notready | Signal dropped — starts the idle-shutdown countdown for the GPU worker. |
Hub — platform registry, merged chat, motor config
app/products/stream/api/admin/stream_hub.py. Not owner-only.
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/hub/status | Overall hub connection status. |
| GET | /api/admin/stream/hub/platforms | List of armed/connected platforms for the owner. |
| POST | /api/admin/stream/hub/platforms | Arms a new platform on the hub. |
| POST | /api/admin/stream/hub/platforms/{name}/toggle | Enables/disables an armed platform without removing it. |
| DELETE | /api/admin/stream/hub/platforms/{name} | Removes a platform from the hub. |
| POST | /api/admin/stream/hub/chat/send | Sends a chat reply as the creator, through the connected platform. |
| GET | /api/admin/stream/hub/chatcfg | Chat config for the motor — model nicknames, Twitch/Kick/TikTok channels, filters, translator key. |
| POST | /api/admin/stream/hub/chatcfg/{platform} | Updates that config for one platform. |
| GET | /api/admin/stream/hub/motor | Effective motor connection config (secrets never echoed — only hasUser/hasPass). |
| PUT | /api/admin/stream/hub/motor | Upserts the motor connection (hub URL, session creds, account). |
| GET | /api/admin/stream/hub/preview/{path} | Proxies the hub's HLS preview path. |
| GET | /api/admin/stream/hub/live-preview/{path} | Proxies the hub's live-preview path. |
Cockpit — go live, record, auto-live
app/products/stream/api/admin/stream_cockpit.py. Owner-only.
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/cockpit | Current cockpit state (live/record/auto-live) plus ingest and motor status for the console. |
| POST | /api/admin/stream/cockpit/live | Go live (or stop) — the action that turns "signal" into "on-air". |
| POST | /api/admin/stream/cockpit/record | Starts or stops recording the incoming signal. |
| POST | /api/admin/stream/cockpit/auto | Turns auto-live on/off — signal arriving fans out immediately, no manual "go live" click. |
| GET | /api/admin/stream/cockpit/recordings | Lists recordings held on the receiving box. |
| DELETE | /api/admin/stream/cockpit/recordings/{name} | Deletes one recording. |
Overlay — chat overlay and per-platform overlay design
app/products/stream/api/admin/stream_overlay.py (owner-only) and
app/products/stream/api/overlay_public.py (token-in-path, no session at all).
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/overlay | Current chat-overlay settings (mode, visible platforms, token status). |
| PUT | /api/admin/stream/overlay | Updates chat-overlay settings. |
| POST | /api/admin/stream/overlay/rotate | Issues a new overlay token; the old link dies instantly. |
| GET | /api/admin/stream/overlay/designs | Lists per-platform overlay design overrides. |
| GET | /api/admin/stream/overlay/design/{platform} | Reads one platform's overlay design. |
| PUT | /api/admin/stream/overlay/design/{platform} | Updates one platform's overlay design. |
| GET | /overlay/{token} | The overlay page itself, resolved by its private token — no session. |
| GET | /overlay/{token}/design/{platform} | That platform's design payload for the overlay page. |
| GET | /overlay/{token}/stream | The live SSE stream the overlay page subscribes to for merged chat. |
Scene — the on-air frame
app/products/stream/api/admin/stream_scene.py (not owner-only) and
app/products/stream/api/scene_object_public.py (token-in-path).
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/scene | Reads the shared scene (layers, frame layout) for a given frame query param. |
| PUT | /api/admin/stream/scene | Replaces the scene's layer list and applies it. |
| GET | /stream/scene-object/{token} | Public scene-object page (landing objects baked into the frame), resolved by token. |
| GET | /stream/scene-object/{token}/data | Data payload for that page. |
Studio & login — connecting a platform's chat/auto-message surface
app/products/stream/api/admin/stream_studio.py and stream_login.py. Both owner-only.
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/studio | Connection + auto-message state for every platform's studio tab. |
| POST | /api/admin/stream/studio/{platform}/connect | Connects a platform (Chaturbate token, or triggers the browser-login flow for webcam sites). |
| PUT | /api/admin/stream/studio/{platform}/settings | Updates auto-message settings (welcome, timer rotation) for a connected platform. |
| POST | /api/admin/stream/studio/{platform}/disconnect | Disconnects a platform. |
| POST | /api/admin/stream/login/{platform}/start | Starts a browser-login session for a webcam platform. |
| GET | /api/admin/stream/login/{platform}/state | Polls that session's state (waiting for captcha/2FA, succeeded, failed). |
| POST | /api/admin/stream/login/{platform}/check | Checks the session against the platform once the operator believes login is complete. |
| POST | /api/admin/stream/login/{platform}/close | Closes the login session/browser profile. |
Native — what a platform shows about the room on its own site
app/products/stream/api/admin/stream_native.py. Owner-only.
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/native/{platform} | Platform capabilities + desired title/category/tags + last-applied status. Always answers, even for a platform with no native-settings API — the panel needs to explain silence, not just hide the form. |
| PUT | /api/admin/stream/native/{platform} | Saves the desired settings + token. |
| POST | /api/admin/stream/native/{platform}/apply | Sends the saved settings to the platform. 400 on a platform with no write path — never a silent no-op. |
| DELETE | /api/admin/stream/native/{platform} | Clears the settings and the token together. |
Targets — where the video itself is sent
app/products/stream/api/admin/stream_targets.py. Owner-only. A per-owner database
row per platform (not a shared motor config file), specifically so one GPU box can
serve many creators without their target lists colliding.
| Method | Path | What it does |
|---|---|---|
| GET | /api/admin/stream/targets | All of the owner's fan-out targets, keyed by platform (stream key never echoed — only hasKey). |
| PUT | /api/admin/stream/targets/{platform} | Upserts a target's URL/key/enabled/frame-layout. Arming (enabled=true) requires a complete target — an armed toggle with no working address would lie to the owner about being live. |
| DELETE | /api/admin/stream/targets/{platform} | Removes a target. |
What's next
Troubleshooting — real, specific snags from Stream's own operation: symptom, cause, how to check.