CDN Push Status Callback
RC supports real-time notifications to your server when Low-Latency Live Streaming is relayed to third-party CDNs.
Callback Method
POST: <your-receiving-server-url>
Data Format: application/json
The callback URL <your-receiving-server-url>
is the configured receiving address for your App Key and service in the Console. Ensure this address is accessible. If your network has IP restrictions, configure the IP allowlist to receive server callbacks properly.
To verify data authenticity and ensure the request originates from RC Server, each request includes a signature. For callback signature rules, see Server Callback.
Callback Parameters
The HTTP request body uses application/json
format and contains a JSON object with the following structure:
Field Name | Type | Description |
---|---|---|
timestamp | Number | Unix timestamp in milliseconds since January 1, 1970. |
type | Number | Status type: 1: CDN relay started; 2: CDN relay ended; 3: CDN relay configuration updated; 4: CDN relay failed |
appKey | String | Current AppKey in use |
sessionId | String | Current live streaming session ID |
roomId | String | Current live streaming room ID |
pushUrl | String | CDN relay URL |
userId | String | Host user ID who initiated the CDN relay |
output.videoResoulation | String | Video resolution (width × height) |
stateCode | Number | Status code |
Callback Request Example
POST /any-url-path HTTP/1.1
Host: your.app.server
Content-Type: application/json
{
"timestamp":1593483553055,
"type":2,
"stateCode":10000,
"appKey":"qf3d5gbjq962h",
"roomId":"iOS-MUJERjYwNTk5MTkyMERCMTFDQkRGODUwODIwNEM0RUI-1593483530019",
"sessionId":"AtqSLHUE_29wd2o6QKM4u7",
"userId":"A2BDE07D-5273-487A-8997-99BF25D06DFE",
"pushUrl":"rtmp://rongcloud.net/seal/AtqSLo6QKM4u7?auth_key=1593487130ace2de7f67c1111",
"output":{
"videoResoulation":"240x320"
}
}
Responding to Callbacks
Your server must return 200 OK
to acknowledge successful receipt.