Create channel
- Print
- PDF
Create channel
- Print
- PDF
Article Summary
Share feedback
Thanks for sharing your feedback!
VOD Station provides an API for creating channels, and provides the channel list view API and the channel information view API to view created channels.
Note
The following are cautions for using the content authentication (Signed URL/JWT) control of Global Edge integrated with VOD Station.
- You must set Edge Auth from Global Edge's cache settings as follows. To change the Edge Auth of Global Edge, see API guide.
- Authentication exclusion extensions
- .ts, .mp4, .m4s, .vtt
- Extensions that forward authentication token to origin
- .m3u8, .mpd
- Authentication exclusion extensions
- At the time of issuing the authentication token, you must enter the wildcard path in acl and path for both Signed URL and JWT. For details on issuing the authentication token, see the User guide.
- Single bitrate playback: '/[protocol]/[encryptedBucketName]/[path]/[video filename]/*'
- Example:
- HLS : https://example.cdn.ntruss.com/hls/guide/vod-5100k.mp4/index.m3u8
- wildcard path : '/hls/guide/vod-5100k.mp4/*'
- DASH : https://example.cdn.ntruss.com/dash/guide/vod-5100k.mp4/index.m3u8
- wildcard path : '/dash/guide/vod-5100k.mp4/*'
- HLS : https://example.cdn.ntruss.com/hls/guide/vod-5100k.mp4/index.m3u8
- Example:
- Adaptive bitrate playback: '/[protocol]/[encryptedBucketName]/[path]/[prefix],[video filenames],[suffix].smil/*'
- Example:
- HLS playback address: https://example.edge.navercorp.com/hls/guide/abr/vod-,5400,2400,1200,0900,0600,0300,k.mp4.smil/master.m3u8
- wildcard path: '/hls/guide/abr/vod-,5400,2400,1200,0900,0600,0300,k.mp4.smil/*'
- DASH playback address: https://example.cdn.ntruss.com/dash/guide/abr/vod-,5400,2400,1200,0900,0600,0300,k.mp4.smil/manifest.mpd
- wildcard path : '/dash/guide/abr/vod-,5400,2400,1200,0900,0600,0300,k.mp4.smil/*'
- HLS playback address: https://example.edge.navercorp.com/hls/guide/abr/vod-,5400,2400,1200,0900,0600,0300,k.mp4.smil/master.m3u8
- Example:
- Single bitrate playback: '/[protocol]/[encryptedBucketName]/[path]/[video filename]/*'
Requests
POST https://vodstation.apigw.ntruss.com/api/v2/channels
Request headers
Header name | Description |
---|---|
x-ncp-region_code | NAVER Cloud Platform's Region code x-ncp_region_code:{Region Code} |
x-ncp-apigw-timestamp | Time elapsed since January 1, 1970 00:00:00 UTC in milliseconds. The request is considered invalid if the time difference compared to the API Gateway server is 5 minutes or longerx-ncp-apigw-timestamp:{Timestamp} |
x-ncp-iam-access-key | Access key ID value issued from NAVER Cloud Platform portalx-ncp-iam-access-key:{Sub Account Access Key} |
x-ncp-apigw-signature-v2 | Signature encrypted with the access key ID value and secret keyx-ncp-apigw-signature-v2:{API Gateway Signature} |
Content-Type | Specifies the request body content type as application/jsonContent-Type: application/json |
Request bodies
API field names in the request body are case sensitive.
Field name | Required | Type | Service limits | Default value | Description |
---|---|---|---|---|---|
name | Yes | String | Name of the channel to be created | ||
storageBucketName | Yes | String | Name of NAVER Cloud Platform Object Storage bucket to be integrated with the channel | ||
accessPrivateFiles | No | Boolean | Set access restrictions for private files in the Object Storage bucket to be integrated If allowed, streaming is available, even if the file remains private | ||
protocolList[] | Yes | Array(String) | HLS, DASH | Streaming protocol of the channel HLS and DASH are supported, and both can be selected at the same time | |
encryptionList[] | No | Array | Media protection settings of the channel Provides media encryption feature and DRM (FairPlay, Widevine/PlayReady) connection interface | ||
encryptionList[].drmContentId | Optional | String | 1 to 200 characters of numbers and English letters Unnecessary when media encryption is set | DRM Content ID The value is included for DRM key requests and needed for issuing licenses | |
encryptionList[].drmKeyUrl | Optional | String | URL including http(s):// Unnecessary when media encryption is set | CPIX API URL of the DRM provider VOD Station officially supports integration with Inka Pallyacon DRM's CPIX v1 API For DRM packaging, VOD Station requests POST including xml body | |
encryptionList[].systemIdList | Optional | Array(String) | Spaces not allowed, hyphens allowed, 256 or fewer characters Unnecessary when media encryption is set | SystemID per DRM type Enter appropriate values for the type to set | |
encryptionList[].drmTypeCode | Optional | Integer | FairPlay: 21 Widevine/PlayReady: 22 Unnecessary when media encryption is set | DRM type settings required | |
encryptionList[].mediaEncryptionTypeCode | Optional | Integer | AES-128: 1 Unnecessary when DRM is set | Sets HLS AES-128 Unable to set up with FairPlay | |
encryptionList[].protocol | Yes | String | HLS, DASH | Sets DRM or a protocol that suits media encryption Widevine/PlayReady: DASH FairPlay: HLS MediaEncryption: HLS | |
segmentDuration | Yes | Integer | An integer between 5 and 20 | Playback time per segment The longer the playback time is, the larger the segment gets. The loading time may be prolonged depending on the client's network condition On the other hand, the shorter the segment's playback time is, the smaller the segment gets. If it's set to be too short, buffering may occur depending on the client's network condition (unit: second) | |
segmentDurationOption | No | String | BASIC, VARIABLE | BASIC | Creates segments so that all segments start with a keyframe When selecting the VARIABLE option, a difference may occur between configured segmentDuration value and segment duration actually created, and the segment duration may not be fixed |
createCdn | Yes | Boolean | true, false | VOD Station requires CDN connection Can be created with channel creation or created separately before use | |
cdnTypeList[] | Optional | String | Supported value: CDN+ | Use it when using the automatically created CDN through the CDN+. Global Edge automatic creation CDN uses the cdn object. For separate CND creation, see VOD Station CDN manual integration guide | |
cdn | Optional | Object | When automatically creating Global Edge, it is requested mandatorily. | When automatically creating through the CDN+, it is not used | |
cdn.profileId | Optional | Integer | Global Edge Profile ID to be newly created | Profile ID for creating Global Edge | |
cdn.regionType | Optional | String | It is used when integrating Global Edge. | KOREA, JAPAN, GLOBAL | Global Edge service region |
cdn.type | Optional | String | It is used when integrating Global Edge. | GLOBAL_EDGE | Type for newly creating Global Edge |
drm | No | Object | Must enter when selecting One Click Multi DRM | ||
drm.siteId | No | String | Must enter when selecting One Click Multi DRM | ||
drm.contentId | No | String | Must enter when selecting One Click Multi DRM | ContentId is a unique ID for the content you want to playback and is used for DRM packaging. You can enter 3 to 100 characters using English letters, numbers, hyphens (-), and underscores (_) |
Responses
Field name | Type | Description | Note |
---|---|---|---|
content | Object | VOD Station OPEN API response object | |
content.id | String | ID of the created channel | |
content.name | Object | Channel name | |
content.channelStatus | Integer | Channel's current status | CREATING, READY, STOPPING, STOPPED, TERMINATING, TERMINATED, FORCE_STOPPING, FORCE_STOPPED, FORCETERMINATING, FORCETERMINATED |
content.storageBucketName | String | The name of the Object Storage bucket integrated with the channel | |
content.encryptedBucketName | String | Encrypted name of the Object Storage bucket integrated with the channel, used when creating the playback URL | |
content.accessPrivateFiles | Boolean | Set access restrictions on VOD Station for private files in the bucket | |
content.segmentDuration | Integer | Channel's segment duration (unit: second) | |
content.segmentDurationOption | String | Channel's segment keyframe alignment options | |
content.protocolList[] | Array(String) | List of streaming protocols of the channel | |
content.createTime | Integer | The time channel creation started | |
content.readyTime | Integer | The time channel creation was completed | |
content.cdnCreatedTime | Integer | The time when the CDN is automatically created with a channel | |
content.playUrl | String | CDN-based playback URL template | |
content.cdnStatus | String | Status of the CDN integrated with the channel If not auto-generated, displayed as NOT_FOUND | |
content.cdnDomain | String | Automatically created CDN+ Domain | |
content.cdnServiceName | String | Automatically created CDN+ Service name | |
content.cdn | Object | Automatically created Global Edge information | |
content.cdn.cdnType | String | Automatically created CDN Type | |
content.cdn.cdnDomain | String | Automatically created Global Edge Domain | |
content.cdn.cdnServiceName | String | Automatically created Global Edge Service name | |
content.cdn.profileId | String | Automatically created Global Profile ID | |
content.cdn.regionType | String | Automatically created Global Edge Service Region | |
content.cdn.cdnInstanceNo | Integer | Automatically created Global Edge instance information | |
content.storageBucketStatus | String | Status of the Object Storage bucket integrated with the channel | |
content.originPath | String | This is referred to when an independent CDN is created using the original path of the created channel | |
content.encryptionList[] | Array | Media security settings of the channel | |
content.encryptionList[].protocol | String | Media security target protocol | |
content.encryptionList[].mediaEncryptionTypeCode | Integer | Media security setting's encryption type 1: AES-128 2: Sample-AES 3: CENC | |
content.encryptionList[].drmTypeCode | Intenger | Media security setting's DRM type 21: FairPlay 22: Widevine/PlayReady | |
content.encryptionList[].drmTypeName | String | Name of the media security setting's DRM type | |
content.encryptionList[].drmContentId | String | Content ID to be requested when packaging from VOD Station | |
content.encryptionList[].systemIdList | Array(String) | DRM System ID to be requested when packaging from VOD Station | |
content.encryptionList[].drmKeyUrl | String | DRM CPIX API URL to be requested when packaging from VOD Station | |
content.drm | Object | DRM Encryption settings using VOD Station | |
content.drm.siteId | String | Site id created through One Click Multi DRM product | |
content.drm.contentId | String | Unique ID of content where DRM Encryption is applied Used for DRM packaging. You can enter 3 to 100 characters using English letters, numbers, hyphens (-), and underscores (_). | |
error | Object | Error response code and message | |
error.errorCode | String | Error response code | |
error.message | String | Error response message | |
error.details | String | Detailed description of the error message Responds when an API Gateway error occurs |
Examples
Request examples
POST https://vodstation.apigw.ntruss.com/api/v2/channels
POST /api/v2/channels
HOST: vodstation.apigw.ntruss.com
Content-Type: application/json
x-ncp-region_code:KR
x-ncp-apigw-timestamp:1521787414578
x-ncp-iam-access-key:6uxz1nKkcYwUjWRG5Q1V7NsW0i5jErlu2NjBXXgy
x-ncp-apigw-signature-v2:iJFK773KH0WwQ79PasqJ+ZGixtpDQ/abS57WGQdld2M=
Request body (Global Edge)
{
"accessPrivateFiles": false,
"cdn": {
"profileId": 681,
"regionType": "KOREA",
"type": "GLOBAL_EDGE"
},
"createCdn": true,
"name": "ey-api-gedge-0628",
"protocolList": [
"HLS","DASH"
],
"segmentDuration": 5,
"segmentDurationOption": "BASIC",
"storageBucketName": "eytestbucket"
}
Reqeust body (non DRM)
{
"cdnTypeList": [
"CDN+"
],
"name": "api-guide",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"storageBucketName": "vodstation-bucket"
}
Request body (One Click Multi DRM using MediaEncryption and Widevine/PlayReady)
{
"createCdn": true,
"name": "api-guide-drm",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"segmentDurationOption": "BASIC",
"accessPrivateFiles": true,
"storageBucketName": "vodstaton-test",
"drm" : {
"siteId" : "ABCD",
"contentId" : "abc-2344-dfd"
}
}
Request body (DRM using MediaEncryption and Widevine/PlayReady)
{
"cdn": {
"profileId": 681,
"regionType": "KOREA",
"type": "GLOBAL_EDGE"
},
"createCdn": true,
"encryptionList": [
{
"drmContentId": "openapi",
"drmKeyUrl": "https://kms.example.com/cpix/token",
"systemIdList": [
"9A04F079-9840-4286-AB92-E65BE0885F95",
"EDEF8BA9-79D6-4ACE-A3C8-27DCD51D21ED"
],
"drmTypeCode": 22,
"protocol": "DASH"
},
{
"mediaEncryptTypeCode": 1,
"protocol":"HLS"
}
],
"name": "api-guide-drm",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"segmentDurationOption": "BASIC",
"accessPrivateFiles": true,
"storageBucketName": "vodstaton-test"
}
Request body (DRM using FairPlay and Widevine/PlayReady)
{
"cdn": {
"profileId": 681,
"regionType": "KOREA",
"type": "GLOBAL_EDGE"
},
"createCdn": true,
"encryptionList": [
{
"drmContentId": "openapi",
"drmKeyUrl": "https://kms.example.com/cpix/token",
"systemIdList": [
"9A04F079-9840-4286-AB92-E65BE0885F95",
"EDEF8BA9-79D6-4ACE-A3C8-27DCD51D21ED"
],
"drmTypeCode": 22,
"protocol": "DASH"
},
{
"drmContentId": "openapi",
"drmKeyUrl": "https://kms.example.com/cpix/token",
"systemIdList": [
"94CE86FB-07FF-4F43-ADB8-93D2FA968CA2"
],
"drmTypeCode": 21,
"protocol": "HLS"
},
],
"name": "api-guide-drm",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"accessPrivateFiles": true,
"storageBucketName": "vodstaton-test"
}
Request body (DRM using Widevine)
{
"cdn": {
"profileId": 681,
"regionType": "KOREA",
"type": "GLOBAL_EDGE"
},
"createCdn": true,
"encryptionList": [
{
"drmContentId": "openapi",
"drmKeyUrl": "https://kms.example.com/cpix/token",
"systemIdList": [
"EDEF8BA9-79D6-4ACE-A3C8-27DCD51D21ED"
],
"drmTypeCode": 22,
"protocol": "DASH"
},
],
"name": "api-guide-drm",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"accessPrivateFiles": true,
"storageBucketName": "vodstaton-test"
}
Request body (using MediaEncryption Only)
{
"cdn": {
"profileId": 681,
"regionType": "KOREA",
"type": "GLOBAL_EDGE"
},
"createCdn": true,
"encryptionList": [
{
"mediaEncryptTypeCode": 1,
"protocol":"HLS"
}
],
"name": "api-guide-drm",
"protocolList": [
"HLS", "DASH"
],
"segmentDuration": 5,
"accessPrivateFiles": true,
"storageBucketName": "vodstaton-test"
}
Response examples
HTTP/1.1 200 OK
Server: nginx
Date: Wed, 12 Sep 2018 09:53:32 GMT
Content-Type: application/json;charset=utf-8
Connection: keep-alive
Access-Control-Allow-Origin: *
x-ncp-trace-id: 36c9k60om4p3238cpmc9gm4cj4
{
"content": {
"disabled": false,
"id": "vs-20230628104743-IhwvCgd",
"name": "ey-api-gedge-0628",
"channelStatus": "CREATING",
"storageBucketName": "gjtest",
"segmentDuration": 5,
"protocolList": [
"HLS",
"DASH"
],
"createTime": 1687916863,
"cdnCreatedTime": 1687916864,
"playUrl": "https://kphmlswg1388.beta-edge.naverncp.com/[protocol]/[Object Storage Bucket(encryption name)]/[path]/[video filename]/[manifest]",
"cdnStatus": "CREATING",
"cdnDomain": "kphmlswg1388.beta-edge.naverncp.com",
"cdnServiceName": "edge-vs-20230628104743-IhwvCgd",
"storageBucketStatus": "RUNNING",
"originPath": "beta-vs2-k1.video.media.ntruss.com/86/vs-20230628104743-IhwvCgd",
"encryptList": [
],
"accessPrivateFiles": false,
"encryptedBucketName": "sk3DDQr8sR~23I9msiHAPg__",
"segmentDurationOption": "BASIC",
"cdn": {
"cdnType": "GLOBAL_EDGE",
"cdnDomain": "kphmlswg1388.beta-edge.naverncp.com",
"cdnServiceName": "edge-vs-20230628104743-IhwvCgd",
"profileId": 681,
"regionType": "KOREA",
"cdnInstanceNo": 1388
},
"drm": {
"siteId": "ABCD",
"contentId": "abc-2344-dfd"
}
}
}
Was this article helpful?