Update Pull Stream
Update information of a restream
curl -X POST "https://api.5centscdn.com/v2/streams/restream/1001" \
-H "Content-Type: application/json" \
-H "X-API-Key: YOUR_API_KEY" \
-d '{
"restreamtype": "mediaserver",
"codec": "h265",
"server[mediaserver]": "11,211",
"protocols": [
"RTSP",
"HLS"
],
"url[mediaserver][]": "rtmp://fms-01-01.5centscdn.com",
"mode[mediaserver]": "rtmp",
"audiofix": "Y",
"draft": "0",
"platformtype": ""
}'
import requests
import json
url = "https://api.5centscdn.com/v2/streams/restream/1001"
headers = {
"Content-Type": "application/json",
"X-API-Key": "YOUR_API_KEY"
}
data = {
"restreamtype": "mediaserver",
"codec": "h265",
"server[mediaserver]": "11,211",
"protocols": [
"RTSP",
"HLS"
],
"url[mediaserver][]": "rtmp://fms-01-01.5centscdn.com",
"mode[mediaserver]": "rtmp",
"audiofix": "Y",
"draft": "0",
"platformtype": ""
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const response = await fetch("https://api.5centscdn.com/v2/streams/restream/1001", {
method: "POST",
headers: {
"Content-Type": "application/json",
"X-API-Key": "YOUR_API_KEY"
},
body: JSON.stringify({
"restreamtype": "mediaserver",
"codec": "h265",
"server[mediaserver]": "11,211",
"protocols": [
"RTSP",
"HLS"
],
"url[mediaserver][]": "rtmp://fms-01-01.5centscdn.com",
"mode[mediaserver]": "rtmp",
"audiofix": "Y",
"draft": "0",
"platformtype": ""
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"restreamtype": "mediaserver",
"codec": "h265",
"server[mediaserver]": "11,211",
"protocols": [
"RTSP",
"HLS"
],
"url[mediaserver][]": "rtmp://fms-01-01.5centscdn.com",
"mode[mediaserver]": "rtmp",
"audiofix": "Y",
"draft": "0",
"platformtype": ""
}`)
req, err := http.NewRequest("POST", "https://api.5centscdn.com/v2/streams/restream/1001", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://api.5centscdn.com/v2/streams/restream/1001')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['X-API-Key'] = 'YOUR_API_KEY'
request.body = '{
"restreamtype": "mediaserver",
"codec": "h265",
"server[mediaserver]": "11,211",
"protocols": [
"RTSP",
"HLS"
],
"url[mediaserver][]": "rtmp://fms-01-01.5centscdn.com",
"mode[mediaserver]": "rtmp",
"audiofix": "Y",
"draft": "0",
"platformtype": ""
}'
response = http.request(request)
puts response.body
{
"result": "success",
"message": "Stream Updated",
"stream": {
"monitoring_id": null,
"type": "restream",
"id": 69971,
"serviceid": 103,
"name": "logotest/james",
"codec": "h265",
"ingests": [
[],
null
],
"protocols": [
[
"HLS",
"RTSP"
],
[
"HLS",
"RTSP"
]
],
"parentid": null,
"server": "201",
"backup": "",
"dedicatedLTC": "1",
"hasAdvancedFeatures": "1",
"monitoring_triggers": null,
"draft": "0",
"disabled": "0",
"created_at": "2026-03-11 13:05:31",
"updated_at": "2026-04-30 13:29:14",
"lastseen_at": "2026-04-30 13:29:11",
"deleted": null,
"ingestsLock": 0,
"protocolsLock": 0,
"status": "Deploying",
"has": {
"rtmp": 0,
"rtsp": 1,
"hls": 1,
"dash": 0,
"rtmpauth": false
},
"parts": {
"pp": "logotest",
"sn": "james",
"full": "logotestjames"
},
"restream": {
"type": "mediaserver",
"mode": "rtmp",
"urls": [
"rtmp://fms-01-01.5centscdn.com"
],
"staticip": "N",
"audiofix": "Y",
"server": {
"country": "North America"
}
},
"playbackurls": {
"scheme": "https",
"url_prefix": "https://stream-abc12-hls-live.stream.example.com",
"rtmp": "rtmp://rtmp.5centscdn.com:1935/",
"rtsp": "rtsp://rtsp.5centscdn.com:554/",
"hlsManifest": "playlist.m3u8",
"dashManifest": "manifest.mpd",
"hls": "https://hash-hls-live.5centscdn.com",
"dash": "https://hash-hls-live.5centscdn.com",
"players": {
"flowplayer": {
"baseQ": "",
"base": "https://cdn.example.com/flowplayer/hls/",
"hls": "https://cdn.example.com/flowplayer/hls/aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4"
},
"videojs": {
"baseQ": "",
"base": "https://cdn.example.com/videojs/hls/",
"hls": "https://cdn.example.com/videojs/hls/aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4"
},
"own": {
"hashes": {
"stream-abc12-hls-live.stream.example.com": {
"hash": "48nujrim2v7hzm6y",
"hls": "https://hash-hls-live.5centscdn.com",
"base64": "aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4",
"dash": "https://hash-hls-live.5centscdn.com",
"base64dash": "aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4"
}
},
"baseQ": "?showcv=true&title=logotest/james",
"base": "https://cdn.example.com/player/hls/skin1/48nujrim2v7hzm6y/",
"hls": "https://cdn.example.com/player/hls/skin1/48nujrim2v7hzm6y/aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4?showcv=true&title=logotest/james",
"dash": "https://cdn.example.com/player/dash/skin1/48nujrim2v7hzm6y/aHR0cHM6Ly9zdHJlYW0uZXhhbXBsZS5jb20vc2FtcGxlL3N0cmVhbS9wbGF5bGlzdC5tM3U4?showcv=true&title=logotest/james"
}
},
"tokenized": null
},
"platformsCount": 1,
"ssl_enabled": true,
"hash": "james.stream",
"ndvr": {
"enabled": "N",
"retention": "18"
},
"securetoken": {
"enabled": "N",
"policy": "D",
"keyip": "Y",
"list": "e4c2c4ed2d921dbe",
"timeout": 7113,
"session": "0",
"ips": "",
"dirs": null,
"active": "N"
},
"record": null,
"domainlock": {
"enabled": "N",
"policy": "N",
"list": "example.com,docs.example.com",
"ips": "",
"noreferer": "Y",
"active": "N"
},
"geoblock": {
"enabled": "N",
"policy": "N",
"list": [
"AF"
],
"ips": "",
"active": "N"
},
"ipaccess": {
"enabled": "N",
"policy": "N",
"list": "",
"ips": "",
"active": "N"
},
"useragent": {
"enabled": "N",
"policy": "Y",
"list": "",
"ips": "",
"casesensitive": "N",
"active": "N",
"listArr": [
""
]
},
"rtmpauth": {
"password": "",
"active": "N"
},
"transcode": {
"ltc": 0,
"type": "mixed",
"enabled": false,
"isEditable": true
},
"platforms": [
{
"id": 46770,
"rtmp": "rtmp://live.us.picarto.tv/golive",
"auth": "N",
"username": "",
"password": "",
"isSRT": false,
"key": "lll",
"schedule": "instant",
"scheduletime": null,
"codec": null,
"length": "00:00",
"relid": 69971,
"dedicatedLTC": "0",
"transcode": {
"ltc": 0,
"type": "mixed",
"enabled": false,
"isEditable": true
},
"disabled": "0",
"name": "h",
"platform_id": 1,
"provider_id": 0,
"video_id": ""
}
],
"messages": {},
"adInsertion": {
"id": 9,
"relid": 69971,
"type": "stream",
"enabled": "Y",
"policy": "1",
"provider": "FreeWheel",
"meta": {
"adpreroll": {
"maxDuration": 30,
"offset": 0
},
"adreplacement": {
"scte35": {
"adBreakTriggers": [
"0x22",
"0x30",
"0x32",
"0x34",
"0x36",
"splice_insert"
],
"markersToRemove": [
"ALL"
]
},
"onStartWithinAdBreak": "replace"
}
},
"defaultDuration": 30,
"created_at": "2026-04-01 14:04:46",
"schedules": [],
"active": "N"
}
},
"warnings": null,
"errors": null
}
/streams/restream/{streamid}Target server for requests. Edit to use your own host.
API key (sent in header)
Stream ID
The media type of the request body
The type of restream being used. mediaserver indicates the stream is relayed through a media server.
Video codec for the stream. Use h264 or h265.
The unique identifier for the media server. Examples include 209 for Oceania or 11,211 for North America.
List of output protocols. Values include HLS, RTMP, DASH, RTSP.
A URL pointing to the media server endpoint for accessing the stream.
The streaming mode used by the media server. Examples include rtmp, hls, http.
Fix audio sync issues in pull streams. Y means enabled, N means disabled.
Set to 0 to publish the stream, or 1 to save it as a draft.
Specifies the platform type for the stream. Examples include rtmp or hls.
Request Preview
Response
Response will appear here after sending the request
Authentication
API Key for authentication. Provide your API key in the header.
Path Parameters
Body
The type of restream being used. mediaserver indicates the stream is relayed through a media server.
mediaserverThe unique identifier for the media server. Examples include 209 for Oceania or 11,211 for North America.
11,211A URL pointing to the media server endpoint for accessing the stream.
rtmp://fms-01-01.5centscdn.comThe streaming mode used by the media server. Examples include rtmp, hls, http.
rtmpResponses
Status of the API response.
Human-readable message describing the result.
Stream object containing configuration and status details.
Unique monitoring identifier for the stream.
Type identifier for this stream or object.
Unique numeric identifier.
Unique identifier of the service this stream belongs to.
Name of the stream.
Video codec used for the stream.
List of active ingest connection details for each server.
Supported streaming protocols for each server.
Identifier of the parent stream, if this is a child stream.
Server ID or identifier assigned to the stream.
Backup server ID for failover.
Whether a dedicated live transcoding server is allocated for this stream.
Whether advanced features are enabled for this stream.
Monitoring alert trigger configuration for the stream.
Draft status flag. 0 means published; 1 means unpublished draft.
Disabled flag. 0 means active; 1 means disabled.
Timestamp when the stream was created.
Timestamp when the stream was last updated.
Timestamp when the stream was last detected as active.
Deletion timestamp, or null if the stream is not deleted.
Whether the ingest endpoint list is locked from editing.
Whether the supported protocol list is locked from editing.
Current deployment or operational status of the stream.
Flags indicating which streaming protocols are active.
Whether RTMP streaming is enabled. 1 = enabled, 0 = disabled.
Whether RTSP streaming is enabled. 1 = enabled, 0 = disabled.
Whether HLS streaming is enabled. 1 = enabled, 0 = disabled.
Whether DASH streaming is enabled. 1 = enabled, 0 = disabled.
Whether RTMP publish authentication is required.
Stream name components.
Stream name prefix (part 1, before the slash).
Stream name suffix (part 2, after the slash).
Combined full stream name without the slash separator.
Restream platform configuration object.
Type identifier for this stream or object.
Operating mode for the configuration.
Static IP address associated with this server.
Server ID or identifier assigned to the stream.
Geographic region of the ingest server.
Playback URL set for all supported protocols and player types.
URL scheme used for playback.
Base CDN hostname URL used as a prefix for playback URLs.
RTMP playback or destination URL.
RTSP playback URL.
HLS manifest filename.
DASH manifest filename.
HLS playback or player iframe URL.
DASH playback or player iframe URL.
Embedded player iframe URL set for supported player types.
Flowplayer iframe URL information.
Query string appended to the player iframe URL.
Base player iframe URL without the stream path.
HLS playback or player iframe URL.
Video.js player iframe URL information.
Query string appended to the player iframe URL.
Base player iframe URL without the stream path.
HLS playback or player iframe URL.
Native stream player iframe URL information.
Map of CDN hostname to stream hashes and playback URLs.
Short hash or slug used in stream URLs.
HLS playback or player iframe URL.
Base64-encoded HLS playback URL for use with iframe players.
DASH playback or player iframe URL.
Base64-encoded DASH playback URL for use with iframe players.
Query string appended to the player iframe URL.
Base player iframe URL without the stream path.
HLS playback or player iframe URL.
DASH playback or player iframe URL.
Tokenized playback URL configuration, or null if disabled.
Number of external restreaming platforms configured.
Whether HTTPS/SSL is enabled for playback.
Short hash or slug used in stream URLs.
Network DVR (nDVR) rewind configuration for the stream.
Enable or disable this feature.
Retention period in days (record) or minutes (nDVR).
Secure token URL signing configuration.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Whether the token is bound to the viewer IP address.
Comma-separated list of allowed or blocked values.
Token expiry time in seconds.
Session-based token mode flag.
IP addresses associated with the access control policy.
URL directory paths restricted by this policy.
Whether this policy is currently enforced.
Recording (DVR) configuration for the stream.
Domain lock (hotlink protection) configuration.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Comma-separated list of allowed or blocked values.
IP addresses associated with the access control policy.
Whether to allow playback requests with no Referer header.
Whether this policy is currently enforced.
Geoblocking access control configuration.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Comma-separated list of allowed or blocked values.
IP addresses associated with the access control policy.
Whether this policy is currently enforced.
IP address access control configuration.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Comma-separated list of allowed or blocked values.
IP addresses associated with the access control policy.
Whether this policy is currently enforced.
User-agent based access control configuration.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Comma-separated list of allowed or blocked values.
IP addresses associated with the access control policy.
Whether user-agent pattern matching is case-sensitive.
Whether this policy is currently enforced.
User-agent filter list as a parsed array.
Whether RTMP publish authentication is required.
Password for RTMP publish authentication.
Whether this policy is currently enforced.
Live transcoding configuration for the stream.
Live transcoding server ID assigned to this stream.
Type identifier for this stream or object.
Enable or disable this feature.
Whether the transcoding configuration can be edited.
List of configured external restreaming platform entries.
Unique numeric identifier.
RTMP playback or destination URL.
Whether RTMP publish authentication is enabled.
Username for RTMP authentication.
Password for RTMP publish authentication.
RTMP stream key for the restream platform.
Publishing schedule type.
Video codec used for the stream.
Maximum stream length in hh:mm:ss format.
Whether a dedicated live transcoding server is allocated for this stream.
Live transcoding configuration for the stream.
Live transcoding server ID assigned to this stream.
Type identifier for this stream or object.
Enable or disable this feature.
Whether the transcoding configuration can be edited.
Disabled flag. 0 means active; 1 means disabled.
Name of the stream.
Unique identifier of the ad insertion provider record.
Informational messages related to the stream state.
Ad insertion configuration for the stream, or null if not configured.
Unique numeric identifier.
Type identifier for this stream or object.
Enable or disable this feature.
Policy mode controlling allow/deny behavior.
Metadata object for the server.
Pre-roll ad configuration object.
Maximum duration in seconds.
Ad replacement configuration object.
SCTE-35 signalling configuration.
SCTE-35 splice command types that trigger an ad break.
SCTE-35 marker types to strip from the outgoing manifest.
Behaviour when a viewer joins during an active ad break.
Timestamp when the stream was created.
Whether this policy is currently enforced.
Non-fatal warnings returned with the response.
Errors returned with the response.