Delivery API

Everything is plain HTTPS. Authenticate with a bearer key, play back with a short-lived session token.

Base URL

https://vod.nightsec.pro

1 · Request a manifest

GET /v1/assets/{asset_id}/manifest.m3u8
Authorization: Bearer <api_key>

The response returns the bitrate ladder and a per-session media path. Manifests are short-lived and must not be cached by intermediaries.

2 · Pull media segments

The manifest points the player at a session-scoped media path. The player streams segments from that path, presenting the session token it was issued:

GET /media/hls/{session}/seg
X-Media-Token: <session_token>

Segment responses are streamed without intermediate buffering so playback can begin before the full segment has landed. Requests that omit a valid X-Media-Token are served the public site instead of media data.

3 · Rotate a session

POST /v1/sessions/refresh
Authorization: Bearer <api_key>

Status codes

200Manifest or segment returned
401Missing or expired session token
404Unknown asset or session
429Rate limited

Rate limits

Manifest requests are limited to 60 per minute per key. Segment requests are unmetered within your plan's delivery allowance.