# Adding SCTE-35 for Live Encoding

**URL:** <https://community.bitmovin.com/t/adding-scte-35-for-live-encoding/1053>\
**Category:** Knowledge\
**Tags:** bitmovin-encoding, code-example\
**Created:** [July 24, 2022, 7:31pm UTC](https://community.bitmovin.com/t/adding-scte-35-for-live-encoding/1053 "2022-07-24T19:31:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![seven](https://avatars.discourse-cdn.com/v4/letter/s/3d9bf3/32.png) [@seven](https://community.bitmovin.com/u/seven)\
**Post date:** [July 24, 2022, 7:31pm UTC](https://community.bitmovin.com/t/adding-scte-35-for-live-encoding/1053/1 "2022-07-24T19:31:46Z")

</div>

# How to Add SCTE 35 to your live stream.

## Step One - Basic RTMP Live

Familiarise yourself on creating a [RTMP Live Encoding](https://bitmovin.com/docs/encoding/tutorials/create-a-live-encoding-from-an-rtmp-stream)

## Step Two - Updating the Manifest Generator

Now that you know RTMP Live encoding we can update the code in [rtmp-live-encoding](https://github.com/bitmovin/bitmovin-api-sdk-examples#rtmp-live-encoding).  
Update this code snippet per the inline comments

```auto
start_live_encoding_request = StartLiveEncodingRequest(
        dash_manifests=[live_dash_manifest],
        hls_manifests=[live_hls_manifest],
        stream_key=stream_key,
        manifest_generator=ManifestGenerator.V2 , # <------- add this to use V2 ManifestGenerator
auto_shutdown_configuration=auto_shutdown_configuration
    )

```

## Step Three - Insert SCTE 35

Now you’ll have a RTMP Live stream running successfully and a `EncodeId` i.e YOUR-ENCODING-ID

Call the Bitmovin API  
`https://api.bitmovin.com/v1/encoding/encodings/YOUR-ENCODING-ID/live/scte-35-cue`  
with a sample payload of

```auto
{
  "cueDuration": 10
}

```

This adds a SCTE 35 cue tone into the live stream.

CURL command line sample; **Replace** ALL-CAPS with your own values.

```auto
curl -X 'POST' \
  'https://api.bitmovin.com/v1/encoding/encodings/YOUR-ENCODING-ID/live/scte-35-cue' \
  -H 'accept: application/json' \
  -H 'X-Api-Key: YOUR-API-KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "cueDuration": 8
}'

```

## That’s ALL !

Now you should see your SCTE markers in your HLS manifest. Similar to

```auto
0/video/720p/segment_41.m4s
#EXTINF:4.0,
0/video/720p/segment_42.m4s
#EXTINF:4.0,
0/video/720p/segment_43.m4s
#EXT-X-CUE-OUT:8.0
#EXTINF:4.0,
0/video/720p/segment_44.m4s
#EXTINF:4.0,
0/video/720p/segment_45.m4s
#EXT-X-CUE-IN
#EXTINF:4.0,
0/video/720p/segment_46.m4s

```
