항목의 type을 먼저 보고 필드를 읽으세요. 영상·쇼츠는 duration·view_count·channel, 채널은 handle·follower_count·is_verified, 재생목록은 video_count·channel입니다. 정확한 업로드일·좋아요 수는 유튜브 영상 정보 조회로 확인하세요.
{
"data": {
"query": "파이썬 기초 강좌",
"count": 2,
"results": [
{
"type": "video", "id": "Xy12AbCdEfG", "url": "https://www.youtube.com/watch?v=Xy12AbCdEfG",
"title": "파이썬 기초 강좌 1강", "description": null, "duration": 1532, "view_count": 1200000,
"live_status": null, "published_at": null,
"channel": { "id": "UCxxxxxxxxxxxxxxxxxxxxxx", "name": "예시 채널", "url": "https://www.youtube.com/channel/UCxxxxxxxxxxxxxxxxxxxxxx", "handle": "@example" },
"thumbnail": "https://i.ytimg.com/vi/Xy12AbCdEfG/hqdefault.jpg"
},
{
"type": "short", "id": "aBcDeFgHiJk", "url": "https://www.youtube.com/shorts/aBcDeFgHiJk",
"title": "파이썬 1분 팁", "description": null, "duration": 45, "view_count": 35000,
"live_status": null, "published_at": null, "channel": null,
"thumbnail": "https://i.ytimg.com/vi/aBcDeFgHiJk/hqdefault.jpg"
}
],
"success": 1
},
"api": { "success": true, "cost": 20, "ms": 4100, "pl_id": 1595635 }
}
예시의 ID·채널·수치는 설명을 위한 값입니다.