방송 송출을 위한 라이브 채널을 생성합니다.
요청
요청 형식을 설명합니다. 요청 형식은 다음과 같습니다.
| 메서드 | URI |
|---|---|
| POST | /api/fin-v2/channels |
요청 헤더
Live Station API에서 공통으로 사용하는 헤더에 대한 정보는 Live Station 요청 헤더를 참조해 주십시오.
요청 바디
요청 바디에 대한 설명은 다음과 같습니다.
| 필드 | 타입 | 필수 여부 | 설명 |
|---|---|---|---|
channelName |
String | Required | 채널 이름
|
envType |
String | Optional | 채널 타입
|
outputProtocol |
String | Optional | Output Protocol 설정
|
cdn |
Object | Required | CDN 설정 |
cdn.createCdn |
Boolean | Required | CDN 신규 생성 여부
|
cdn.cdnType |
String | Required | CDN 유형
|
cdn.cdnInstanceNo |
Integer | Conditional | CDN 인스턴스 아이디
|
qualitySetId |
Integer | Required | 화질 설정 아이디
|
useDvr |
Boolean | Required | 타임머신 설정 여부
|
immediateOnAir |
Boolean | Optional | 송출 즉시 자동 녹화 설정 여부
|
timemachineMin |
Integer | Conditional | 타임머신 허용 범위(분)
|
record |
Object | Required | 녹화 저장 정보 |
record.format |
String | Conditional | 자동 저장 녹화 타입
|
record.type |
String | Required | 녹화 저장 설정
|
record.bucketName |
String | Conditional | 녹화 파일 저장 버킷 이름
|
record.filePath |
String | Conditional | 저장 상세 경로
|
record.accessControl |
String | Conditional | 녹화 파일 저장 버킷 공개 범위
|
isStreamFailOver |
Boolean | Optional | 송출 이중화 설정 여부
|
참고
요청 예시
요청 예시는 다음과 같습니다.
curl --location --request POST 'https://livestation.apigw.ntruss.com/api/fin-v2/channels' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
--header 'x-ncp-region_code: FKR' \
--header 'Content-Type: application/json' \
--data '{
"channelName": "testchannel",
"envType": "DEV",
"outputProtocol": "LL_HLS",
"cdn": {
"createCdn": true,
"cdnType": "CDN_PLUS",
"profileId": 4207,
"regionType": "KOREA"
},
"qualitySetId": 2585,
"useDvr": true,
"immediateOnAir": true,
"timemachineMin": 360,
"record": {
"format": "MP4",
"type": "AUTO_UPLOAD",
"bucketName": "mybucket",
"filePath": "/livestation",
"accessControl": "PRIVATE"
},
"isStreamFailOver": true
}'
응답
응답 형식을 설명합니다.
응답 바디
응답 바디에 대한 설명은 다음과 같습니다.
| 필드 | 타입 | 필수 여부 | 설명 |
|---|---|---|---|
content |
Object | - | 응답 결과 |
content.channelName |
String | - | 채널 이름 |
content.cdn |
Object | - | CDN 설정 |
content.cdn.createCdn |
Boolean | - | CDN 신규 생성 여부
|
content.cdn.cdnType |
String | - | CDN 유형
|
content.qualitySetId |
Integer | - | 화질 설정 아이디 |
content.useDvr |
Boolean | - | 타임머신 설정 여부
|
content.immediateOnAir |
Boolean | - | 송출 즉시 자동 녹화 설정 여부
|
content.timemachineMin |
Integer | - | 타임머신 허용 범위(분) |
content.channelId |
String | - | 채널 아이디 |
content.uploadPath |
String | - | 녹화 파일 업로드 경로 |
content.envType |
String | - | 채널 타입
|
content.record |
Object | - | 녹화 저장 정보 |
content.record.type |
String | - | 녹화 저장 설정
|
content.record.bucketName |
String | - | 녹화 파일 저장 버킷 이름 |
content.record.filePath |
String | - | 저장 상세 경로 |
content.record.format |
String | - | 자동 저장 녹화 타입
|
content.record.accessControl |
String | - | 녹화 파일 저장 버킷 공개 범위
|
content.outputProtocol |
String | - | Output Protocol |
content.origin |
Object | - | 원본 정보 |
content.origin.originDomain |
String | - | 원본 도메인 |
content.origin.originPath |
String | - | 원본 경로 |
content.isStreamFailOver |
Boolean | - | 송출 이중화 설정 여부
|
응답 상태 코드
Live Station API에서 공통으로 사용하는 응답 상태 코드에 대한 정보는 Live Station 응답 상태 코드를 참조해 주십시오.
응답 예시
응답 예시는 다음과 같습니다.
{
"content": {
"channelName": "testchannel",
"cdn": {
"createCdn": true,
"cdnType": "CDN_PLUS",
"cdnInstanceNo": 1***2,
},
"qualitySetId": 2585,
"useDvr": true,
"immediateOnAir": true,
"timemachineMin": 360,
"channelId": "ls-20250818******-UbUBe",
"uploadPath": "/mybucket/livestation",
"envType": "DEV",
"record": {
"type": "AUTO_UPLOAD",
"bucketName": "mybucket",
"filePath": "/livestation",
"format": "MP4",
"accessControl": "PRIVATE"
},
"outputProtocol": "LL_HLS",
"origin": {
"originDomain": "*****.video.media.ntruss.com",
"originPath": "27***85"
},
"isStreamFailOver": true
}
}