In a live streaming channel, when an audience member applies to co-host, you can use a token to authenticate whether the user can publish a stream. This feature is co-host token authentication.
To enable co-host token authentication, contact email@example.com, and provide the App ID of your project. Ensure that your project has enabled the App Certificate in Console.
Once you have enabled co-host token authentication, you app user must fulfill both of the following requirements to publish a stream in a channel:
roleparameter in the
Refer to the following logic to authenticate whether an app user can publish a stream:
joinChanneland passes the token to the SDK.
renewTokenand passes the new token to the SDK.
setClientRoleto change the user role from an audience member to a host.
setClientRole. If the token is generated with the privilege of a publisher, the app client can publish a stream.