This guide walks you through using the Visionular API to insert SCTE-35 Splice Insert signals into a live stream. By following this guide, you will learn how to create a SCTE-35 enabled live stream, and insert splice signals to mark ad breaks or program switch points during a live broadcast.
To use the SCTE-35 Splice Insert feature, you must enable it when creating the live stream by setting scte35_support to true.
API Reference: Create a live stream
Method: POSTURL: /live/v1/live-streams
Request Body:
| Field | Type | Required | Description |
|---|---|---|---|
scte35_support | boolean | No | Set to true to enable SCTE-35 Splice Insert support. Default: false. |
You can combine scte35_support with other stream creation parameters (e.g., latency_mode, record, policy).
Example Request:
POST /live/v1/live-streamsHost: api.visionular.comContent-Type: application/jsonAuthorization: Visionular AccessKeyId={AK}, Signature={SIGN}{"scte35_support": true,"latency_mode": "low","policy": ["public"]}
Example Response:
{"code": 0,"data": {"stream_key": "202501-497b23b4-abcd-xxxx-xxxx-4c65fd3f6edc","status": "idle","reconnect_window": 60,"playback_ids": [{"policy": "public","id": "202501-N2E4ZDlmYzk3YTJhNzM4NTI4ZWFjYTdjODMxODA0ZDc"}],"type": "normal","max_continuous_duration": 43200,"latency_mode": "low","scte35_support": true,"id": "202501-NGJmZWM0NTk4NTczMWZkZjhkNmUwNzE1NzVlMWU1OGM","dvr_duration": 1800,"created_at": 1735889158},"message": "success","request_id": "d254a7df-d3dd-4979-a003-02b30637936a"}
Note the id field — this is your live_stream_id for subsequent steps.
Push your live stream via RTMP/RTMPS to the Visionular ingest server using the stream_key from Step 1. The stream must be in active status before you can insert SCTE-35 signals.
| Server Address | Description |
|---|---|
rtmp://global-ingest-live.visionular.com/live | Standard RTMP ingest |
rtmps://global-ingest-live.visionular.com:443/live | Secure RTMPS ingest |
You can verify the stream is active by calling the Query a live stream API and checking that status is active.
Once the stream is active, you can insert a SCTE-35 Splice Insert signal to mark an ad break or program switch point.
API Reference: Insert a SCTE35 Splice Insert signal
Method: PUTURL: /live/v1/live-streams/{live_stream_id}/scte35-splice-insert
Path Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
live_stream_id | string | Yes | The ID of the live stream (44 characters). |
Request Body Fields:
| Field | Type | Required | Description |
|---|---|---|---|
scte35_splice_insert | object | Yes | SCTE-35 Splice Insert configuration object. |
scte35_splice_insert.start_type | string | No | Insertion type. Currently only immediate is supported. Default: immediate. |
scte35_splice_insert.duration | integer | Yes | Ad break duration in seconds. Range: 0–57600 (max 16 hours). |
scte35_splice_insert.ad_format | string | No | Ad format. Options: interstitial, pip, overlay, squeezeBack. Default: interstitial. |
Example Request:
PUT /live/v1/live-streams/202501-NGJmZWM0NTk4NTczMWZkZjhkNmUwNzE1NzVlMWU1OGM/scte35-splice-insertHost: api.visionular.comContent-Type: application/jsonAuthorization: Visionular AccessKeyId={AK}, Signature={SIGN}{"scte35_splice_insert": {"start_type": "immediate","duration": 30,"ad_format": "pip"}}
Example cURL:
curl -X PUT \'https://api.visionular.com/live/v1/live-streams/202501-NGJmZWM0NTk4NTczMWZkZjhkNmUwNzE1NzVlMWU1OGM/scte35-splice-insert' \-H 'Authorization: Visionular AccessKeyId={AK}, Signature={SIGN}' \-H 'Content-Type: application/json' \-d '{"scte35_splice_insert": {"start_type": "immediate","duration": 30,"ad_format": "pip"}}'
Success Response (201 Created):
{"request_id": "550e8400-e29b-41d4-a716-446655440000","code": 0,"message": "success","data": {}}
After a successful insertion, the SCTE-35 markers will appear in the HLS playlist as EXT-X-CUE-OUT / EXT-X-CUE-OUT-CONT / EXT-X-CUE-IN tags. Your SSAI system or player can then react to these markers to insert or replace ad content.
For details on HLS playlist marker format, see SCTE-35 & SSAI.
| Format | Description |
|---|---|
interstitial | Full content replacement — the ad takes over the entire video frame during the break. This is the default format. |
pip | Picture-in-Picture — the main stream is scaled down to a corner while the ad plays in the remaining area. |
overlay | The ad is overlaid on top of the live stream content. |
squeezeBack | The main stream is squeezed to one side of the frame, with the ad content filling the other side. |
| HTTP Status | Error Code | Message | Cause |
|---|---|---|---|
| 400 | 100100 | Bad Request: you need to enable scte35 support first | The stream was not created with scte35_support: true. |
| 400 | 100100 | Bad Request: Invalid Parameters: ... | Request body validation failed (e.g., missing duration). |
| 400 | 100110 | Bad Request: The stream is not active | The stream is not currently in active status. Start pushing before inserting. |
| 404 | 100600 | Not Found: live stream id xxx | The specified live_stream_id does not exist. |
| 500 | 100700 | Internal error | Server-side error. Retry or contact support. |
immediate is supported. PTS-based delayed insertion is not yet available.active. Idle or disabled streams will return an error.splice_information_table list, keeping only the latest entry.