YouTube에서 Shorts 동영상의 조회수를 집계하는 방식에 맞게 Data API를 업데이트하고 있습니다.
자세히 알아보기
Watermarks: set
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
YouTube에 워터마크 이미지를 업로드하고 채널에 설정합니다.
이 메서드는 미디어 업로드를 지원합니다. 업로드한 파일은 다음 제한사항을 따라야 합니다.
- 최대 파일 크기: 10MB
- 허용되는 미디어 MIME 유형:
image/jpeg
, image/png
, application/octet-stream
할당량 영향: 이 메서드를 호출하면 할당량 비용이 50단위가 됩니다.
요청
HTTP 요청
POST https://www.googleapis.com/upload/youtube/v3/watermarks/set
승인
이 요청에는 다음 범위 중 하나 이상에 대한 승인이 필요합니다. 인증 및 승인에 대해 자세히 알아보려면 OAuth 2.0 승인 구현을 참고하세요.
범위 |
https://www.googleapis.com/auth/youtubepartner |
https://www.googleapis.com/auth/youtube.upload |
https://www.googleapis.com/auth/youtube |
https://www.googleapis.com/auth/youtube.force-ssl |
매개변수
다음 표에는 이 쿼리가 지원하는 매개변수가 나와 있습니다. 나열된 모든 매개변수는 쿼리 매개변수입니다.
매개변수 |
필수 매개변수 |
channelId |
string
channelId 매개변수는 워터마크가 제공되는 YouTube 채널 ID를 지정합니다. |
선택적 매개변수 |
onBehalfOfContentOwner |
string
참고: 이 매개변수는 YouTube 콘텐츠 파트너 전용입니다.
onBehalfOfContentOwner 매개변수는 요청의 승인 사용자 인증 정보가 매개변수 값에 지정된 콘텐츠 소유자를 대신하는 YouTube CMS 사용자를 식별함을 나타냅니다. 이 매개변수는 여러 YouTube 채널을 소유하고 관리하는 YouTube 콘텐츠 파트너를 위해 마련되었습니다. 콘텐츠 소유자는 한 번 인증하면 개별 채널에 대한 인증 사용자 인증 정보를 제공하지 않고도 모든 동영상 및 채널 데이터에 액세스할 수 있습니다. 사용자가 인증할 CMS 계정은 지정된 YouTube 콘텐츠 소유자에게 연결되어야 합니다. |
요청 본문
요청 본문에 watermark
리소스를 제공합니다.
응답
이 메서드는 요청에 성공하면 HTTP 204 No Content
상태 코드를 반환합니다.
오류
다음 표에는 이 메서드 호출에 대한 응답으로 API에서 반환할 수 있는 오류 메시지가 나와 있습니다. 자세한 내용은 YouTube Data API - 오류를 참고하세요.
오류 유형 |
오류 세부정보 |
설명 |
badRequest (400) |
imageFormatUnsupported |
제공한 이미지가 지원되지 않는 형식입니다. |
badRequest (400) |
imageTooTall |
제공한 이미지 높이가 너무 깁니다. |
badRequest (400) |
imageTooWide |
제공한 이미지 너비가 너무 넓습니다. |
badRequest (400) |
mediaBodyRequired |
요청에 이미지 콘텐츠가 포함되어 있지 않습니다. |
forbidden (403) |
forbidden |
지정된 채널에 워터마크를 설정할 수 없습니다. 요청이 올바르게 승인되지 않았거나 channelId 매개변수가 잘못된 값으로 설정되었을 수 있습니다. |
사용해 보기
APIs Explorer를 사용하여 이 API를 호출하고 API 요청 및 응답을 확인합니다.
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2024-11-23(UTC)
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2024-11-23(UTC)"],[[["This method enables uploading a watermark image to YouTube and applying it to a specific channel, supporting file sizes up to 10MB."],["Accepted image formats for the watermark include JPEG and PNG, and the method uses `application/octet-stream` as an accepted MIME type."],["Setting a watermark using this method consumes 50 quota units, and requires proper authorization using at least one of the specified scopes."],["The `channelId` is a required parameter, while `onBehalfOfContentOwner` is an optional parameter meant only for YouTube content partners."],["A successful request returns a `204 No Content` status, and common errors include unsupported image format, incorrect image dimensions, and missing image content."]]],["The content describes uploading a watermark image to a YouTube channel using the `watermarks/set` method. This process involves a POST request to the API endpoint, requiring a `channelId` parameter and authorization with specific scopes. The image file must be under 10MB and of `image/jpeg`, `image/png`, or `application/octet-stream` MIME type. This operation costs 50 quota units. A successful request returns a `204` status; errors can include invalid format, size issues, or authorization problems.\n"]]