## Create an independent livestream `realtime_kit.livestreams.create_independent_livestream(strapp_id, LivestreamCreateIndependentLivestreamParams**kwargs) -> LivestreamCreateIndependentLivestreamResponse` **post** `/accounts/{account_id}/realtime/kit/{app_id}/livestreams` Creates a livestream for the given App ID and returns ingest server, stream key, and playback URL. You can pass custom input to the ingest server and stream key, and freely distribute the content using the playback URL on any player that supports HLS/LHLS. ### Parameters - `account_id: str` The account identifier tag. - `app_id: str` The app identifier tag. - `name: Optional[str]` Name of the livestream ### Returns - `class LivestreamCreateIndependentLivestreamResponse: …` - `data: Optional[Data]` - `id: Optional[str]` The livestream ID. - `disabled: Optional[bool]` Specifies if the livestream was disabled. - `ingest_server: Optional[str]` The server URL to which the RTMP encoder should send the video and audio data. - `meeting_id: Optional[str]` - `name: Optional[str]` - `playback_url: Optional[str]` The web address that viewers can use to watch the livestream. - `status: Optional[Literal["LIVE", "IDLE", "ERRORED", "INVOKED"]]` - `"LIVE"` - `"IDLE"` - `"ERRORED"` - `"INVOKED"` - `stream_key: Optional[str]` Unique key for accessing each livestream. - `success: Optional[bool]` ### Example ```python import os from cloudflare import Cloudflare client = Cloudflare( api_token=os.environ.get("CLOUDFLARE_API_TOKEN"), # This is the default and can be omitted ) response = client.realtime_kit.livestreams.create_independent_livestream( app_id="app_id", account_id="023e105f4ecef8ad9ca31a8372d0c353", name="prdmmp-xhycsl", ) print(response.data) ``` #### Response ```json { "data": { "disabled": false, "id": "78dd0b50-4147-4bb8-88d3-2ccc2e98bff0", "ingest_server": "rtmps://live.cloudflare.com:443/live/", "meeting_id": null, "name": "Livestreaming-Demo", "playback_url": "https://customer-s8oj0c1n5ek8ah1e.cloudflarestream.com/7de6a3fec0f9c05bf1df140950d3a237/manifest/video.m3u8", "status": "INVOKED", "stream_key": "f26566285faca6fbe2e79a73a66rsrrsrrsr3cde23a2bb7dbc6c2c1761b98f4e4" }, "success": true } ```