Classic/VPC 환경에서 이용 가능합니다.
원하는 화질을 그룹핑하여 Custom 화질 설정을 생성합니다.
요청
요청 형식을 설명합니다. 요청 형식은 다음과 같습니다.
메서드 | URI |
---|---|
POST | /api/v2/qualitySets |
요청 헤더
Live Station API에서 공통으로 사용하는 헤더에 대한 정보는 Live Station 요청 헤더를 참조해 주십시오.
요청 바디
요청 바디에 대한 설명은 다음과 같습니다.
필드 | 타입 | 필수 여부 | 설명 |
---|---|---|---|
name |
String | Required | 화질 설정 이름
|
qualityIds |
Array | Required | 화질 아이디 목록
|
isEnabledUll |
Boolean | Required | Low Latency 설정 여부
|
segmentDuration |
Integer | Conditional | 세그먼트당 재생 시간(밀리초)
|
segmentCount |
Integer | Conditional | 세그먼트 수
|
enableHlsTimedMetadata |
Boolean | Required | 시간 기반 메타데이터 설정 여부
|
timedMetadata |
Object | Conditional | 시간 기반 메타데이터 설정
|
timedMetadata.header |
String | Conditional | 헤더(식별 값)
|
timedMetadata.interval |
Integer | Conditional | 삽입 주기(밀리초)
|
timedMetadata.key |
String | Conditional | 키
|
요청 예시
요청 예시는 다음과 같습니다.
curl --location --request POST 'https://livestation.apigw.ntruss.com/api/v2/qualitySets' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
--header 'Content-Type: application/json' \
--header 'x-ncp-region_code: KR' \
--data '{
"name": "setting000",
"qualityIds": [
****, 5
],
"isEnabledUll": false,
"segmentDuration": 1000,
"segmentCount": 2,
"enableHlsTimedMetadata": true,
"timedMetadata": {
"header": "ncloud.livestation.metadata",
"interval": 1000,
"key": "utc"
}
}'
응답
응답 형식을 설명합니다.
응답 바디
응답 바디에 대한 설명은 다음과 같습니다.
필드 | 타입 | 필수 여부 | 설명 |
---|---|---|---|
content |
Object | - | 응답 결과 |
content.disabled |
Boolean | - | 화질 비활성화 여부
|
content.id |
Integer | - | 화질 설정 아이디 |
content.status |
String | - | 화질 설정 상태
|
content.createdTime |
Integer | - | 화질 설정 생성 일시(밀리초)
|
content.genType |
String | - | 설정 분류
|
content.name |
String | - | 화질 설정 이름 |
content.segmentDuration |
Integer | - | 세그먼트당 재생 시간(밀리초)
|
content.segmentCount |
Integer | - | 세그먼트 수
|
content.qualityIds |
Array | - | 화질 아이디 목록 |
content.qualities |
Array | - | 화질 목록: qualities |
content.enableHlsTimedMetadata |
Boolean | - | 시간 기반 메타데이터 설정 여부
|
content.isEnabledUll |
Boolean | - | Low Latency 설정 여부
|
content.targetLatency |
Integer | - | Low Latency 목표 지연 시간(초)
|
content.timedMetadata |
Object | - | 시간 기반 메타데이터 설정
|
content.timedMetadata.key |
String | - | 키
|
content.timedMetadata.header |
String | - | 헤더(식별 값) |
content.timedMetadata.interval |
Integer | - | 삽입 주기(밀리초)
|
qualities
qualities
에 대한 설명은 다음과 같습니다.
필드 | 타입 | 필수 여부 | 설명 |
---|---|---|---|
disabled |
Boolean | - | 화질 비활성화 여부
|
id |
Integer | - | 화질 아이디 |
status |
String | - | 화질 상태
|
createdTime |
Integer | - | 화질 생성 일시(밀리초)
|
genType |
String | - | 설정 분류
|
name |
String | - | 화질 이름 |
type |
String | - | 화질 타입
|
video |
Object | - | 비디오 설정 정보
|
video.fps |
Float | - | 초당 프레임 수(fps) |
video.bitrate |
Integer | - | 비디오 스트림의 비트레이트(bps) |
video.bframes |
Integer | - | B-프레임(양방향 예측 프레임) 수 |
video.level |
Integer | - | 비디오 코덱 레벨
|
video.width |
Integer | - | 출력 비디오의 너비(픽셀) |
video.height |
Integer | - | 출력 비디오의 높이(픽셀) |
video.bypass |
Boolean | - | 비디오 스트림 바이패스 여부
|
video.codec |
String | - | 비디오 코덱 포맷
|
video.orientation |
String | - | 비디오 방향 전환 설정
|
video.profile |
String | - | 비디오 코덱 프로필
|
video.rateControl |
String | - | 비트레이트 배분 방식
|
video.videoH264ParamRefFrames |
Integer | - | H.264 참조 프레임 수
|
audio |
Object | - | 오디오 설정 정보 |
audio.codec |
String | - | 오디오 코덱 포맷
|
audio.profile |
String | - | 오디오 코덱 프로필
|
audio.samplerate |
Integer | - | 오디오 샘플링 레이트(Hz)
|
audio.channels |
Integer | - | 오디오 채널 수 |
audio.bitrate |
Integer | - | 오디오 스트림의 비트레이트(Kbps) |
audio.bypass |
Boolean | - | 오디오 스트림 바이패스 여부
|
응답 상태 코드
Live Station API에서 공통으로 사용하는 응답 상태 코드에 대한 정보는 Live Station 응답 상태 코드를 참조해 주십시오.
응답 예시
응답 예시는 다음과 같습니다.
{
"content": {
"disabled": false,
"id": ****,
"status": "CREATED",
"createdTime": 1755138264367,
"genType": "CUSTOM",
"name": "setting000",
"segmentDuration": 1000,
"segmentCount": 2,
"qualityIds": [
5,
****
],
"qualities": [
{
"disabled": false,
"id": 5,
"status": "CREATED",
"createdTime": 1546300800000,
"genType": "SYSTEM",
"name": "720p-9-16",
"type": "NORMAL",
"video": {
"fps": 30.0,
"bitrate": 2500000,
"bframes": 0,
"level": -1,
"width": 720,
"height": 1280,
"bypass": false,
"codec": "H264",
"profile": "MAIN",
"rateControl": "VBR",
"videoH264ParamRefFrames": 1
},
"audio": {
"codec": "AAC",
"profile": "LC",
"samplerate": 48000,
"channels": 0,
"bitrate": 128,
"bypass": false
}
},
{
"disabled": false,
"id": ****,
"status": "CREATED",
"createdTime": 1755134604000,
"genType": "CUSTOM",
"name": "quality000",
"type": "NORMAL",
"video": {
"fps": 60.0,
"bitrate": 204800000,
"bframes": 4,
"level": -1,
"width": 1920,
"height": 1080,
"bypass": true,
"codec": "H264",
"profile": "HIGH",
"rateControl": "VBR",
"videoH264ParamRefFrames": 1
},
"audio": {
"codec": "AAC",
"profile": "LC",
"samplerate": 44100,
"channels": 2,
"bitrate": 320,
"bypass": true
}
}
],
"enableHlsTimedMetadata": true,
"isEnabledUll": false,
"timedMetadata": {
"key": "utc",
"header": "ncloud.livestation.metadata",
"interval": 1000
}
}
}