ForbidRTCStream
https://rtc-api.zego.im/
Call this API to forbid RTC stream publishing. You can forbid the specified Stream ID from publishing to the RTC service. The forbidding operation sends a notification to publishing clients and playing clients that the stream has been forbidden.
Publishing clients receive notifications that stream publishing has been forbidden by the server using ZEGO Express SDK callback interfaces:
| Platform | ZegoExpress SDK | LiveRoom SDK | ||
|---|---|---|---|---|
| Interface | Error Code | Interface | Error Code | |
| iOS/macOS | onPublisherStateUpdate | 1003025 | onPublishStateUpdate | 12301011 |
| Android | onPublisherStateUpdate | 1003025 | onPublishStateUpdate | 12301011 |
| Windows | onPublisherStateUpdate | 1003025 | OnPublishStateUpdate | 12301011 |
Playing clients receive notifications that the played stream has been forbidden by the server using ZEGO Express SDK callback interfaces:
| Platform | ZegoExpress SDK | LiveRoom SDK | ||
|---|---|---|---|---|
| Interface | Error Code | Interface | Error Code | |
| iOS/macOS | onPlayerStateUpdate | 1004025 | onPlayStateUpdate | 12301011 |
| Android | onPlayerStateUpdate | 1004025 | onPlayStateUpdate | 12301011 |
| Windows | onPlayerStateUpdate | 1004025 | OnPlayStateUpdate | 12301011 |
In the test environment (see the IsTest common parameter description for details), the Stream ID must be prefixed with "zegotest-AppId-". For example, if the Stream ID is "test" and the AppId is "123456789" in the test environment, the Stream ID should be "zegotest-123456789-test".
Request
Query Parameters
Possible values: [ForbidRTCStream]
API prototype parameters
https://rtc-api.zego.im?Action=ForbidRTCStream
💡Public parameter. Application ID, assigned by ZEGOCLOUD. Get it from the ZEGOCLOUD Admin Console.
💡Common parameter. A 16-character hexadecimal random string (hex-encoded 8-byte random number). For the generation algorithm, refer to the signature example.
💡Common parameter. Current Unix timestamp in seconds. For the generation algorithm, refer to the signature example. A maximum deviation of 10 minutes is allowed.
💡Common parameter. Signature used to verify the legitimacy of the request. Please refer to the signature mechanism to generate it.
Possible values: [2.0]
Default value: 2.0
💡Public parameter. Signature version number.
Stream ID.
Request sequence number.
Note
For the same StreamId, within 10 consecutive seconds, the request sequence number issued for this StreamId must be strictly increasing; this avoids inconsistent operation order caused by inconsistent request timing received by the server.
If there is no concurrent scenario, using a timestamp (millisecond level) is recommended.
Responses
- 200
- application/json
