Documentation
Server_APIs_v2 Server APIs v2
Documentation
Demo APP
SDK Center
API Center
FAQ
Code Market
Console
Sign Up
Log In
中文站 English
  • Documentation
  • Server APIs v2
  • Streaming control
  • Forbid a stream on CDN

Forbid a stream on CDN

Last updated:2025-01-24 17:55

1 Description

Forbids a live stream to be published to CDN, applicable to scenarios where streams are published directly to CDN. If you need to apply this to scenarios where streams are published indirectly to CDN, please use the Stop forwarding a stream to CDN interface.

For the first use of this interface, you need to contact ZEGOCLOUD technical support for configuration.

2 Request method and endpoint

  • Request method: GET
  • Request endpoint: https://rtc-api.zego.im/?Action=ForbidCDNLiveStream
  • Transmission protocol: HTTPS
  • Rate limit: 20 requests/second

3 Request parameters

Listed below are the parameters specific to this request and part of the public request parameters. For the complete list of public request parameters, see Server APIs public request parameters.

Parameter Type Required Description
StreamId
String
Yes
Stream ID.
ResumeTime
String
NO
The time to resume the stream. In UTC format, for example: 2018-11-29T19:00:00Z.
Note: Only Wangsu supports this parameter, with a default push ban of 1 day and a maximum support for a 30-day push ban. For instance, if the push is banned for 30 days, then the broadcast ban duration will be set to: current time + 30 days.

4 Sample request

https://rtc-api.zego.im/?Action=ForbidCDNLiveStream
&StreamId=stream001
&<Public Request Parameters>

5 Response parameters

Parameter Type Description
Code
Number
The return code.
Message
String
Description of the operation result.
RequestId
String
The request ID.
Data
Array of Object
The response data.
CdnType
String
The CDN type.
  • ws: Wangsu CDN.
  • aliyun: Alibaba Cloud.
  • tencent: Tencent Cloud.
  • huawei: Huawei Cloud.
CdnResult
String
The CDN processing result.

6 Sample response

{
    "Code": 0,
    "Message": "success",
    "Data": [
        {
            "CdnType": "ws",
            "CdnResult": "success append purge tasks."
        }
    ],
    "RequestId": "4113829426153229963"
}

7 Return codes

Listed below are the return codes related to this API. For the complete list of return codes, see Return codes.

Return Code Description Processing Suggestions
0 Request successful. -
1 Request failed. -
2 Parameter error. -
3 Authentication failed. Please check if the authentication parameters are correct.
Page Directory
  • Free trial
  • 提交工单
    咨询集成、功能及报价等问题
    电话咨询
    400 1006 604
    Get Consulting
    Scan Wechat QR code