Skip to content

StreamPackage Channel Configuration โ€‹

Updated

Creating a StreamPackage channel produces two inputs for receiving the stream. In this step you prepare the channel and the publishing connection; in the next step you create the endpoint for viewing.

Before You Start โ€‹

  • Confirm that you have permission to access the StreamPackage console.
  • Decide on the working region and the publishing protocol. This example uses the Seoul region and a HLS input.
  • If you plan to integrate StreamLive, you need the packager channel ID to specify in the output group. You can look it up after creating the channel.

Connecting StreamLive to the packaging input

1. Create a Channel โ€‹

  1. Select the working region in the console.
  2. Select Create Channel.
  3. Set the channel name to demo_package and the input protocol to HLS.
  4. Review the segment and playlist duration limits, then select Create.
ItemMeaningWhat to verify when configuring
Input ProtocolThe protocol of the stream entering the channelMust match the HLS or DASH configuration on the publishing side
Max Segment DurationThe maximum length of segments to acceptThe official documentation default is 15 seconds. Set it to accommodate the actual published segment length
Max Playlist DurationThe maximum total length of the playlist to acceptThe official documentation default is 600 seconds. Verify it against the total duration of the input playlist

When using primary / backup inputs, the official documentation recommends setting Max Segment Duration slightly above the actual segment length.

2. Check the Channel ID and Inputs โ€‹

Under Details in the channel details, check the name, ID, and input protocol. Input is the ingest address, Output Endpoint is the playback address, and CDN is the tab for verifying the distribution binding.

StreamPackage channel details: verifying the channel name / ID / HLS protocol

StreamPackage Input: verifying the two inputs and their authentication status

The resource names and IDs in the screenshots are examples for illustrating the screens. Use the values of the channel you are actually working on. The input addresses are redacted.

Having two inputs means two ingest paths are provided. To verify redundancy, you must also confirm whether the publishing system sends the signal to both paths, and whether timestamps and playback continue after a switchover.

3. Connect the Publishing System โ€‹

Publishing methodDestination to enterWhere to configure
The HLS_STREAM_PACKAGE output of StreamLiveThe StreamPackage channel IDThe destination of the StreamLive output group
An external HLS publishing systemThe input URL copied from the console and the required HTTP credentialsThe transport settings of that publishing system

For a StreamLive-dedicated output group, specify the StreamPackage channel ID. External publishing uses the input URL.

4. Input Authentication โ€‹

You can configure HTTP authentication under Authentication on the Input tab. If you enable authentication, you must also apply the corresponding user name and password on the publishing system.

  • Input HTTP authentication controls who may push the stream in.
  • The endpoint AuthKey is a separate authentication setting that uses the X-TENCENT-PACKAGE header.
  • CDN URL signing for viewers is a separate authentication policy of CDN.

Input authentication, endpoint authentication, and CDN authentication are applied separately on their respective legs.

Running Rotate credentials invalidates the existing credentials. During production publishing, plan the credential change on the publishing side together with the time it takes effect.

5. Verify Ingest After Creating an Endpoint โ€‹

  1. Create a HLS playback address following Endpoint configuration.
  2. Send a stream from the publishing system to this channel.
  3. Fetch the playlist at least twice and confirm that the media sequence or the segment list is advancing.
  4. Request the segments listed in the playlist and verify the video and audio in a player.

Check the input URL, protocol, HTTP authentication, and publishing state, then inspect input ingest along with playlist updates and cached responses.

Creating and Querying with API โ€‹

Run these in an environment where TCCLI authentication is configured. The create command provisions a new resource.

bash
tccli mdp CreateStreamPackageChannel --region ap-seoul --Name demo_package --Protocol HLS

Take the ID from the create response and apply it to the next command.

bash
tccli mdp DescribeStreamPackageChannel --region ap-seoul --Id REPLACE_CHANNEL_ID

Copy the input address from the API query response or from the console.

Distinguishing the Cache Settings โ€‹

The channel's segment / playlist duration limits, the cache-related settings of API, the CDN TTL, and the player buffer are all different layers.

Because a live playlist keeps changing, repeatedly receiving only cached responses can push the playback position backward. Check the CDN TTL and cache key, the cache headers in the responses, and how the playlist changes across consecutive fetches, all together. Before changing the API field, check the unit and the target it applies to in the definition of the API version you are using.

Wrapping Up and Cleaning Up โ€‹

After testing, stop publishing and clean up in the order of the CDN binding, the endpoint, and the channel. Verify the resource IDs and their usage / reference relationships before proceeding.

Reference Documents โ€‹

Built with VitePress ยท Deployed on Tencent EdgeOne Pages