Create channel
  • PDF

Create channel

  • PDF

The API that creates Live Station VOD channels. Channel list search API and Channel information search API are provided to search the created channels.

Request

POST https://livestation.apigw.ntruss.com/api/v2/vod/channels

Request header

Header name Requirement status Description
x-ncp-apigw-timestamp YES It indicates the time elapsed since January 1, 1970 00:00:00 UTC in milliseconds, and if the time difference compared to the API Gateway server is more than 5 minutes, then the request is considered invalid
x-ncp-apigw-timestamp:{Timestamp}
x-ncp-iam-access-key YES Access key ID value issued on the NAVER Cloud Platform portal
x-ncp-iam-access-key:{Sub Account Access Key}
x-ncp-apigw-signature-v2 YES Signature encrypted with the access key ID value and secret key
x-ncp-apigw-signature-v2:{API Gateway Signature}
Content-Type YES Specifies the request body content type as application/json
Content-Type: application/json
x-ncp-region_code YES Region code (KR)

Request body

Field name Requirement status Type Restrictions Description
channelName Yes String 3 to 20 characters can be entered
Allowed underscores (_)
The name of the channel to create.
outputProtocol Optional String HLS / HLS,DASH Set output protocols
Will be set to HLS if not entered
envType Optional String DEV, STAGE, REAL Settings for usage classification of the channel to be created
Will be set to REAL if not entered
cdn Yes Object CDN Object
cdn.createCdn Yes Boolean true, false CDN Object
cdn.cdnType Yes String CDN_PLUS, GLOBAL_CDN
cdn.cdnInstanceNo Optional Integer This must be set if cdn.createCdn is false
qualitySetId Yes Integer

Response

Field name Type Description Remarks
channelId String
channelName String
outputProtocol Optional String HLS / HLS, DASH
envType String DEV, STAGE, REAL
cdn Object
cdn.createCdn Boolean
cdn.cdnType String CDN_PLUS, GLOBAL_CDN
cdn.cdnInstanceNo Integer
qualitySetId Integer
type String

Example

Request example

POST /api/v2/vod/channels
HOST: livestation.apigw.ntruss.com
Content-Type: application/json
x-ncp-apigw-timestamp:1521787414578
x-ncp-iam-access-key:6uxz1nKkcYwUjWRG5Q1V7NsW0i5jErlu2NjBXXgy
x-ncp-apigw-signature-v2:iJFK773KH0WwQ79PasqJ+ZGixtpDQ/abS57WGQdld2M=
x-ncp-region_code:KR

Request body (if cdn.createCdn == true) 
{  
   "channelName": "myTestChannel",
   "cdn": {
       "createCdn": true,
       "cdnType": "CDN_PLUS"
   },
   "qualitySetId": 5,
   "envType": "REAL",
   "outputProtocol": "HLS"
}

Request body (if cdn.createCdn == false) 
{
    "channelName": "myTestChannel",
    "cdn": {
      "createCdn": false,
      "cdnType": "CDN_PLUS",
      "cdnInstanceNo": 1541959
    },
    "qualitySetId": 4,
    "envType": "REAL",
    "outputProtocol": "HLS"
}

Response example

HTTP/1.1 200 OK
Server: nginx
Date: Fri, 26 Feb 2021 09:53:32 GMT
Content-Type: application/json;charset=utf-8
Connection: keep-alive
Access-Control-Allow-Origin: *
x-ncp-trace-id: 36c9k60om4p3238cpmc9gm4cj4

{
  "content": {
    "channelName": "myTestChannel",
    "cdn": {
      "createCdn": false,
      "cdnType": "CDN_PLUS",
      "cdnInstanceNo": 1541959
    },
    "qualitySetId": 4,
    "envType": "REAL",
    "outputProtocol": "HLS",
    "channelId": "ls-20211122220557-mUv3r",
    "type": "VOD"
  }
}

Was this article helpful?

What's Next