put /api/v1/projects/{project_name}/media/streamingPolicies/{policy_name} cURL JavaScript Python Go Java C# curl -X PUT "https://app.mk.io/api/v1/projects/{project_name}/media/streamingPolicies/{policy_name}" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"properties": {
"catalog": {
"key": null
},
"commonEncryptionCbcs": {
"clearKeyEncryptionConfiguration": {
"customKeysAcquisitionUrlTemplate": "string"
},
"clearTracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
],
"contentKeys": {
"defaultKey": {
"label": "string",
"policyName": "string"
},
"keyToTrackMappings": [
{
"label": "string",
"policyName": "string",
"tracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
]
}
]
},
"drm": {
"fairPlay": {
"allowPersistentLicense": true,
"customLicenseAcquisitionUrlTemplate": "string"
},
"playReady": {
"customLicenseAcquisitionUrlTemplate": "string",
"playReadyCustomAttributes": "string"
},
"widevine": {
"customLicenseAcquisitionUrlTemplate": "string"
}
},
"enabledProtocols": {
"dash": true,
"download": true,
"hls": true,
"smoothStreaming": true
}
},
"commonEncryptionCenc": {
"clearKeyEncryptionConfiguration": {
"customKeysAcquisitionUrlTemplate": "string"
},
"clearTracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
],
"contentKeys": {
"defaultKey": {
"label": "string",
"policyName": "string"
},
"keyToTrackMappings": [
{
"label": "string",
"policyName": "string",
"tracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
]
}
]
},
"drm": {
"playReady": {
"customLicenseAcquisitionUrlTemplate": "string",
"playReadyCustomAttributes": "string"
},
"widevine": {
"customLicenseAcquisitionUrlTemplate": "string"
}
},
"enabledProtocols": {
"dash": true,
"download": true,
"hls": true,
"smoothStreaming": true
}
},
"defaultContentKeyPolicyName": "string",
"envelopeEncryption": {
"clearTracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
],
"contentKeys": {
"defaultKey": {
"label": "string",
"policyName": "string"
},
"keyToTrackMappings": [
{
"label": "string",
"policyName": "string",
"tracks": [
{
"trackSelections": [
{
"operation": "Unknown",
"property": "Unknown",
"value": "string"
}
]
}
]
}
]
},
"customKeyAcquisitionUrlTemplate": "string",
"enabledProtocols": {
"dash": true,
"download": true,
"hls": true,
"smoothStreaming": true
}
},
"noEncryption": {
"enabledProtocols": {
"dash": true,
"download": true,
"hls": true,
"smoothStreaming": true
}
}
}
}' 200 Streaming Policy updated Example Schema
200 · Streaming Policy updated 201 · Streaming Policy created 400 · Bad Request 401 · Unauthorized 403 · Forbidden 404 · Not Found 429 · Too Many Requests 500 · Internal Server Error {
"id" : "string" ,
"name" : "name" ,
"properties" : {
"catalog" : {
"key" : null
},
"commonEncryptionCbcs" : {
"clearKeyEncryptionConfiguration" : {
"customKeysAcquisitionUrlTemplate" : "string"
},
"clearTracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
],
"contentKeys" : {
"defaultKey" : {
"label" : "string" ,
"policyName" : "string"
},
"keyToTrackMappings" : [
{
"label" : "string" ,
"policyName" : "string" ,
"tracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
]
}
]
},
"drm" : {
"fairPlay" : {
"allowPersistentLicense" : true ,
"customLicenseAcquisitionUrlTemplate" : "string"
},
"playReady" : {
"customLicenseAcquisitionUrlTemplate" : "string" ,
"playReadyCustomAttributes" : "string"
},
"widevine" : {
"customLicenseAcquisitionUrlTemplate" : "string"
}
},
"enabledProtocols" : {
"dash" : true ,
"download" : true ,
"hls" : true ,
"smoothStreaming" : true
}
},
"commonEncryptionCenc" : {
"clearKeyEncryptionConfiguration" : {
"customKeysAcquisitionUrlTemplate" : "string"
},
"clearTracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
],
"contentKeys" : {
"defaultKey" : {
"label" : "string" ,
"policyName" : "string"
},
"keyToTrackMappings" : [
{
"label" : "string" ,
"policyName" : "string" ,
"tracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
]
}
]
},
"drm" : {
"playReady" : {
"customLicenseAcquisitionUrlTemplate" : "string" ,
"playReadyCustomAttributes" : "string"
},
"widevine" : {
"customLicenseAcquisitionUrlTemplate" : "string"
}
},
"enabledProtocols" : {
"dash" : true ,
"download" : true ,
"hls" : true ,
"smoothStreaming" : true
}
},
"defaultContentKeyPolicyName" : "string" ,
"envelopeEncryption" : {
"clearTracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
],
"contentKeys" : {
"defaultKey" : {
"label" : "string" ,
"policyName" : "string"
},
"keyToTrackMappings" : [
{
"label" : "string" ,
"policyName" : "string" ,
"tracks" : [
{
"trackSelections" : [
{
"operation" : "Unknown" ,
"property" : "Unknown" ,
"value" : "string"
}
]
}
]
}
]
},
"customKeyAcquisitionUrlTemplate" : "string" ,
"enabledProtocols" : {
"dash" : true ,
"download" : true ,
"hls" : true ,
"smoothStreaming" : true
}
},
"noEncryption" : {
"enabledProtocols" : {
"dash" : true ,
"download" : true ,
"hls" : true ,
"smoothStreaming" : true
}
}
},
"systemData" : {
"createdAt" : "2024-01-01T00:00:00Z" ,
"createdBy" : "string" ,
"createdByType" : "User" ,
"internalId" : "00000000-0000-0000-0000-000000000000" ,
"lastModifiedAt" : "2024-01-01T00:00:00Z" ,
"lastModifiedBy" : "string" ,
"lastModifiedByType" : "User"
},
"type" : "string"
}