Page Summary
-
The
channelBannerresource provides the URL needed to set a newly uploaded image as a channel's banner image. -
Updating a channel banner image involves a three-step process, starting with uploading the image using the
channelBanners.insertmethod. -
The uploaded banner image must have a 16:9 aspect ratio and be at least 2048x1152 pixels, with 2560x1440 recommended.
-
After uploading, the
urlproperty from the API response is extracted, and then used in thechannels.updatemethod, specifically in thebrandingSettings.image.bannerExternalUrlproperty, to set the banner image. -
The
channelBannersresource containskind,etag, andurlproperties, with theurlproperty holding the banner image's URL.
A channelBanner resource contains the URL that you would use to set a newly uploaded image as the banner image for a channel.
Methods
The API supports the following methods for channelBanners resources:
- insert
- Uploads a channel banner image to YouTube. This method represents the first two steps in a three-step process to update the banner image for a channel:
- Call the
channelBanners.insertmethod to upload the binary image data to YouTube. The image must have a 16:9 aspect ratio and be at least 2048x1152 pixels. We recommend uploading a 2560px by 1440px image. - Extract the
urlproperty's value from the response that the API returns for step 1. - Call the
channels.updatemethod to update the channel's branding settings. Set thebrandingSettings.image.bannerExternalUrlproperty's value to the URL obtained in step 2.
- Call the
Resource representation
The following JSON structure shows the format of a channelBanners resource:
{
"kind": "youtube#channelBannerResource",
"etag": etag,
"url": string
}Properties
The following table defines the properties that appear in this resource:
