Reference · Tools

YouTube

Manage YouTube channels, playlists, playlist items, videos, and video categories via the YouTube Data API v3.

Action (binary) Marketing v1 Binary data

The YouTube node manages channels, playlists, playlist items, videos and video categories through Data API v3, uploading videos with a resumable chunked upload. A typical build is publishing a rendered video with its title, description and playlist placement set automatically.

Node type
Action (binary)
Parameters
57
Outputs
Output, Error
Credentials
YouTube OAuth2

YouTube

Manage YouTube channels, playlists, and videos

Overview

The YouTube tool provides full access to the YouTube Data API v3. Supports five resources: (1) Channel — get, getAll, update, uploadBanner. (2) Playlist — create, delete, get, getAll, update. (3) Playlist Item — add, delete, get, getAll. (4) Video — delete, get, getAll (search), rate, update, upload. (5) Video Category — getAll. Binary operations include video upload (resumable upload with chunked transfer) and channel banner upload. Requires Google OAuth2 credentials with YouTube Data API scope.

Category: Marketing
Tool Name: google_youtube
Version: 1

Appearance: Icon: si-youtube | Color: #FF0000

Node Type

Action (Binary) — handles file/binary data operations

Input / Output

DirectionPort(s)
InputInput
OutputOutput, Error

Credentials

This tool requires YouTube OAuth2 credentials. See the Credentials Guide for setup instructions.

Resources

ResourceValue
Channelchannel
Playlistplaylist
Playlist ItemplaylistItem
Videovideo
Video CategoryvideoCategory

Operations

Each resource has its own Operation list, and several resources reuse the same operation values (get, getAll, delete, update). Pick the resource first, then the operation.

ResourceOperationValueDescription
ChannelGetgetRetrieve a channel
ChannelGet ManygetAllRetrieve many channels
ChannelUpdateupdateUpdate a channel
ChannelUpload BanneruploadBannerUpload a channel banner image
PlaylistCreatecreateCreate a playlist
PlaylistDeletedeleteDelete a playlist
PlaylistGetgetGet a playlist
PlaylistGet ManygetAllRetrieve many playlists
PlaylistUpdateupdateUpdate a playlist
Playlist ItemAddaddAdd a video to a playlist
Playlist ItemDeletedeleteRemove an item from a playlist
Playlist ItemGetgetGet a playlist item
Playlist ItemGet ManygetAllRetrieve many playlist items
VideoDeletedeleteDelete a video
VideoGetgetGet a video
VideoGet ManygetAllSearch for videos
VideoRaterateRate a video (like/dislike)
VideoUpdateupdateUpdate video metadata
VideoUploaduploadUpload a video (resumable upload)
Video CategoryGet ManygetAllRetrieve video categories for a region

Parameters

Every parameter accepts expressions. Where an ID field is left empty, the node also falls back to a field of the same name on the input item — an item carrying channelId, playlistId, playlistItemId, videoId or title can drive the node directly.

The Fields parameter maps to the API’s part argument and decides which blocks of the resource come back. * asks for all of them.

All Operations

ParameterTypeRequiredDefaultDescription
AuthenticationoptionsNooAuth2Authentication method to use.
Options: oAuth2 (OAuth2, recommended), serviceAccount
Google Account (credentialId)credentialNoConnect or select your Google account. (shown when Authentication is oAuth2)
Service Account EmailstringYesThe email address of the Google service account. (shown when Authentication is serviceAccount)
Private Key (serviceAccountPrivateKey)stringYesThe private key from the service account JSON key file. Paste the whole PEM block, BEGIN and END lines included. (shown when Authentication is serviceAccount)
Max ConcurrencynumberNo5Maximum number of items to process concurrently. Keep low for upload operations (1–20).

Channel: Get

ParameterTypeRequiredDefaultDescription
Channel IDstringYesThe ID of the channel to retrieve.
Fields (part)multiOptionsNo['*']Comma-separated list of resource properties to include in the response.
Options: *, brandingSettings, contentDetails, contentOwnerDetails, id, localizations, snippet, statistics, status, topicDetails

Channel: Get Many

ParameterTypeRequiredDefaultDescription
Fields (part)multiOptionsNo['*']Comma-separated list of resource properties to include in the response.
Options: *, brandingSettings, contentDetails, contentOwnerDetails, id, localizations, snippet, statistics, status, topicDetails
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo25Max number of results to return (1–50). (shown when Return All is false)
FilterscollectionNo{}Narrow the listing. With none of these set, the node returns your own channels.
— Category ID (categoryId)stringNoYouTube guide category ID to filter by.
— For Username (forUsername)stringNoYouTube username to retrieve the channel for.
— ID (id)stringNoComma-separated list of channel IDs.
— Managed By Me (managedByMe)booleanNofalseWhether to only return channels managed by the content owner.
OptionscollectionNo{}Extra request options.
— Language Code (hl)stringNoLanguage code for localized resource metadata (e.g. “en”, “de”).
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users acting on behalf of the content owner.

Channel: Update

ParameterTypeRequiredDefaultDescription
Channel IDstringYesThe ID of the channel to update.
Update FieldscollectionNo{}Branding settings to change. Only the fields you add are sent.
— Country (country)stringNoThe country with which the channel is associated.
— Description (description)stringNoChannel description (max 1000 characters).
— Default Language (defaultLanguage)stringNoDefault language for the channel.
— Default Tab (defaultTab)stringNoContent tab to display by default.
— Featured Channels Title (featuredChannelsTitle)stringNoTitle for the featured channels module (max 30 chars).
— Featured Channels URLs (featuredChannelsUrls)stringNoComma-separated list of featured channel IDs.
— Keywords (keywords)stringNoSpace-separated keywords for the channel.
— Moderate Comments (moderateComments)booleanNofalseWhether comments need approval before being visible.
— Profile Color (profileColor)stringNoProminent color for the channel.
— Show Related Channels (showRelatedChannels)booleanNofalseWhether to show related channels.
— Show Browse View (showBrowseView)booleanNofalseWhether to show browse view on the channel page.
— Tracking Analytics Account ID (trackingAnalyticsAccountId)stringNoGoogle Analytics account ID for tracking.
— Unsubscribed Trailer (unsubscribedTrailer)stringNoVideo ID for the featured video for unsubscribed viewers.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Channel: Upload Banner

ParameterTypeRequiredDefaultDescription
Channel IDstringYesThe ID of the channel to update.
Binary Property (binaryPropertyName)stringYesdataName of the binary property containing the banner image to upload. Names are case-sensitive — see the upstream node’s Binary Data panel for the exact names to use.

Playlist: Create

ParameterTypeRequiredDefaultDescription
TitlestringYesThe title of the playlist.
OptionscollectionNo{}Optional playlist properties.
— Description (description)stringNoThe playlist description.
— Privacy Status (privacyStatus)optionsNoThe playlist privacy status.
Options: private, public, unlisted
— Tags (tags)stringNoComma-separated keyword tags.
— Default Language (defaultLanguage)stringNoLanguage code (e.g. “en”).
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID.
— On Behalf Of Content Owner Channel (onBehalfOfContentOwnerChannel)stringNoChannel ID when acting on behalf of a content owner.

Playlist: Delete

ParameterTypeRequiredDefaultDescription
Playlist IDstringYesThe ID of the playlist.
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Playlist: Get

ParameterTypeRequiredDefaultDescription
Playlist IDstringYesThe ID of the playlist.
Fields (part)multiOptionsNo['*']Resource properties to include.
Options: *, contentDetails, id, localizations, player, snippet, status
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.
— On Behalf Of Content Owner Channel (onBehalfOfContentOwnerChannel)stringNoChannel ID when acting on behalf of a content owner.

Playlist: Get Many

ParameterTypeRequiredDefaultDescription
Fields (part)multiOptionsNo['*']Resource properties to include.
Options: *, contentDetails, id, localizations, player, snippet, status
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo25Max number of results to return (1–50). (shown when Return All is false)
FilterscollectionNo{}Narrow the listing. With neither set, the node returns your own playlists.
— Channel ID (channelId)stringNoOnly return playlists from this channel.
— ID (id)stringNoComma-separated playlist IDs.
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.
— On Behalf Of Content Owner Channel (onBehalfOfContentOwnerChannel)stringNoChannel ID when acting on behalf of a content owner.

Playlist: Update

ParameterTypeRequiredDefaultDescription
Playlist IDstringYesThe ID of the playlist.
TitlestringYesThe title of the playlist. It is always sent, so set it even when changing something else.
Update FieldscollectionNo{}Other playlist properties to change.
— Description (description)stringNoThe playlist description.
— Privacy Status (privacyStatus)optionsNoThe playlist privacy status.
Options: private, public, unlisted
— Tags (tags)stringNoComma-separated keyword tags.
— Default Language (defaultLanguage)stringNoLanguage code (e.g. “en”).
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Playlist Item: Add

ParameterTypeRequiredDefaultDescription
Playlist IDstringYesThe ID of the playlist to add to.
Video IDstringYesThe ID of the video to add.
OptionscollectionNo{}Optional placement and playback settings.
— Position (position)numberNoZero-based position in the playlist.
— Note (note)stringNoUser-generated note (max 280 chars).
— Start At (startAt)stringNoStart time in seconds.
— End At (endAt)stringNoEnd time in seconds.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Playlist Item: Delete

ParameterTypeRequiredDefaultDescription
Playlist Item IDstringYesThe ID of the playlist item — not the video ID.
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Playlist Item: Get

ParameterTypeRequiredDefaultDescription
Playlist Item IDstringYesThe ID of the playlist item — not the video ID.
Fields (part)multiOptionsNo['*']Resource properties to include.
Options: *, contentDetails, id, snippet, status
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Playlist Item: Get Many

ParameterTypeRequiredDefaultDescription
Playlist IDstringYesThe playlist whose items you want.
Fields (part)multiOptionsNo['*']Resource properties to include.
Options: *, contentDetails, id, snippet, status
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo25Max number of results to return (1–50). (shown when Return All is false)
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Video: Delete

ParameterTypeRequiredDefaultDescription
Video IDstringYesThe ID of the video.
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Video: Get

ParameterTypeRequiredDefaultDescription
Video IDstringYesThe ID of the video.
Fields (part)multiOptionsNo['*']Resource properties to include.
Options: *, contentDetails, id, liveStreamingDetails, localizations, player, recordingDetails, snippet, statistics, status, topicDetails
OptionscollectionNo{}Extra request options.
— On Behalf Of Content Owner (onBehalfOfContentOwner)stringNoContent owner ID for CMS users.

Video: Get Many

ParameterTypeRequiredDefaultDescription
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo25Max number of results to return (1–50). (shown when Return All is false)
FilterscollectionNo{}Search criteria. This operation is a search, so a Query or a Channel ID is usually what you want.
— Channel ID (channelId)stringNoOnly return videos from this channel.
— For Developer (forDeveloper)booleanNofalseRestrict to videos uploaded via your app.
— Published After (publishedAfter)stringNoISO 8601 datetime. Only return videos published after this time.
— Published Before (publishedBefore)stringNoISO 8601 datetime. Only return videos published before this time.
— Query (q)stringNoSearch query term.
— Region Code (regionCode)stringNoISO 3166-1 alpha-2 country code.
— Related To Video ID (relatedToVideoId)stringNoRetrieve videos related to this video.
— Video Category ID (videoCategoryId)stringNoOnly return videos in this category.
— Video Syndicated (videoSyndicated)booleanNofalseOnly videos playable outside youtube.com.
— Video Type (videoType)optionsNoRestrict results to one kind of video.
Options: any, episode, movie
OptionscollectionNo{}Result ordering and filtering.
— Order (order)optionsNorelevanceThe order results come back in.
Options: date, relevance
— Safe Search (safeSearch)optionsNoWhether to filter restricted content.
Options: moderate, none, strict

Video: Rate

ParameterTypeRequiredDefaultDescription
Video IDstringYesThe ID of the video.
RatingoptionsNolikeThe rating to apply as the authenticated account.
Options: dislike, like, none (remove any previous rating)

Video: Update

ParameterTypeRequiredDefaultDescription
Video IDstringYesThe ID of the video.
TitlestringYesThe title of the video. It is always sent, so set it even when changing something else.
Region CodestringNoISO 3166-1 alpha-2 country code (e.g. “US”, “GB”, “DE”). Used to determine video category availability.
Category ID (categoryId)stringYesNumeric video category ID. Use Video Category: Get Many to list available categories for your region.
Update FieldscollectionNo{}Other video properties to change.
— Description (description)stringNoThe video description.
— Tags (tags)stringNoComma-separated tags.
— Default Language (defaultLanguage)stringNoLanguage code (e.g. “en”).
— Privacy Status (privacyStatus)optionsNoWho can see the video.
Options: private, public, unlisted
— Embeddable (embeddable)booleanNofalseWhether the video can be embedded on other websites.
— Public Stats Viewable (publicStatsViewable)booleanNotrueWhether extended stats are publicly viewable.
— Publish At (publishAt)stringNoScheduled publish date (ISO 8601). Requires privacyStatus=private.
— Recording Date (recordingDate)stringNoDate and time when the video was recorded (ISO 8601).
— Self Declared Made For Kids (selfDeclaredMadeForKids)booleanNofalseWhether the video is designated as child-directed.
— License (license)optionsNoThe licence the video is published under.
Options: creativeCommon, youtube

Video: Upload

ParameterTypeRequiredDefaultDescription
TitlestringYesThe title of the video.
Region CodestringNoISO 3166-1 alpha-2 country code (e.g. “US”, “GB”, “DE”). Used to determine video category availability.
Category ID (categoryId)stringYesNumeric video category ID. Use Video Category: Get Many to list available categories for your region.
Binary Property (binaryPropertyName)stringYesdataName of the binary property containing the video file to upload. Names are case-sensitive — see the upstream node’s Binary Data panel for the exact names to use.
OptionscollectionNo{}Optional video properties.
— Description (description)stringNoThe video description.
— Tags (tags)stringNoComma-separated keyword tags.
— Default Language (defaultLanguage)stringNoLanguage code (e.g. “en”).
— Privacy Status (privacyStatus)optionsNoWho can see the video.
Options: private, public, unlisted
— Embeddable (embeddable)booleanNofalseWhether the video can be embedded on other websites.
— Public Stats Viewable (publicStatsViewable)booleanNotrueWhether extended stats are publicly viewable.
— Publish At (publishAt)stringNoScheduled publish date (ISO 8601). Requires privacyStatus=private.
— Recording Date (recordingDate)stringNoDate and time when the video was recorded (ISO 8601).
— Self Declared Made For Kids (selfDeclaredMadeForKids)booleanNofalseWhether the video is designated as child-directed.
— License (license)optionsNoThe licence the video is published under.
Options: creativeCommon, youtube
— Notify Subscribers (notifySubscribers)booleanNofalseWhether to send notifications to channel subscribers.

Video Category: Get Many

ParameterTypeRequiredDefaultDescription
Region CodestringYesISO 3166-1 alpha-2 country code (e.g. “US”, “GB”).
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo25Max number of results to return (1–50). (shown when Return All is false)

Output Data

Every operation merges its result onto the input item’s JSON — the fields the item already carried survive, and a result field with the same name overwrites the item’s value. Binary data on the input item is forwarded on every operation, including the two upload operations, which read the file but do not consume it.

OperationOutput
Channel Get, Channel Get Many, Playlist Get, Playlist Get Many, Playlist Item Get, Playlist Item Get Many, Video Get, Video Get Many, Video Category Get ManyOne output item per record returned. Return All keeps paging until YouTube runs out of results.
Channel Update, Playlist Create, Playlist Update, Playlist Item Add, Video UpdateOne output item carrying the returned resource.
Video UploadOne output item carrying the created video resource plus uploadId, the new video’s ID.
Channel Upload BannerOne output item carrying the API response plus bannerUploaded: true.
Playlist Delete, Playlist Item Delete, Video DeleteOne output item carrying success: true and the ID that was removed — deletedPlaylistId, deletedPlaylistItemId or deletedVideoId.
Video RateOne output item carrying success: true, videoId and rating.

An empty result never drops the item. A listing that matched nothing emits the input item with results: [] added; a Get that found nothing emits it with success: false and a message such as “Video not found”. Check for the field you expect rather than assuming an item means a hit.

Usage Examples

  • Upload a video to YouTube
  • Search for videos on a channel
  • Create a new YouTube playlist
  • Add a video to a playlist
  • Update video metadata (title, description, tags)
  • Upload a channel banner image
  • Get video categories for a region
  • Rate a video (like/dislike)

Example Configuration

Upload a video file produced by an upstream node:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "video",
    "operation": "upload",
    "title": "{{ $json.title }}",
    "regionCode": "US",
    "categoryId": "22",
    "binaryPropertyName": "data",
    "options": {
      "description": "{{ $json.description }}",
      "tags": "tutorial,howto",
      "privacyStatus": "private",
      "notifySubscribers": false,
      "selfDeclaredMadeForKids": false
    }
  }
}

Search a channel’s most recent videos:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "video",
    "operation": "getAll",
    "returnAll": false,
    "limit": 25,
    "filters": {
      "channelId": "UC_x5XG1OV2P6uZZ5FSM9Ttw",
      "q": "release notes",
      "videoType": "any"
    },
    "options": {
      "order": "date",
      "safeSearch": "moderate"
    }
  }
}

Create a public playlist:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "playlist",
    "operation": "create",
    "title": "Best of {{ $json.year }}",
    "options": {
      "description": "Our most watched uploads",
      "privacyStatus": "public",
      "tags": "highlights,annual"
    }
  }
}

Add a video to a playlist at the top:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "playlistItem",
    "operation": "add",
    "playlistId": "PLxxxxxxxxxxxxxxxx",
    "videoId": "{{ $json.uploadId }}",
    "options": {
      "position": 0,
      "note": "Added automatically"
    }
  }
}

Publish a video that was uploaded as private:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "video",
    "operation": "update",
    "videoId": "{{ $json.uploadId }}",
    "title": "{{ $json.title }}",
    "categoryId": "22",
    "updateFields": {
      "description": "Updated description",
      "tags": "tutorial,howto",
      "privacyStatus": "public",
      "license": "youtube"
    }
  }
}

Read a video’s statistics only:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "video",
    "operation": "get",
    "videoId": "{{ $json.videoId }}",
    "part": ["snippet", "statistics"]
  }
}

List the video categories available in a region:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "videoCategory",
    "operation": "getAll",
    "regionCode": "US",
    "returnAll": true
  }
}

Replace a channel banner from a binary field:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "channel",
    "operation": "uploadBanner",
    "channelId": "UC_x5XG1OV2P6uZZ5FSM9Ttw",
    "binaryPropertyName": "data"
  }
}

Like a video:

{
  "type": "google_youtube",
  "parameters": {
    "resource": "video",
    "operation": "rate",
    "videoId": "{{ $json.videoId }}",
    "rating": "like"
  }
}

Error Handling

ModeBehavior
stopHalts workflow on first error
continueSkips failed items, passes successful ones through
errorPortRoutes failed items to Error output port

Tips

Manage YouTube channels, playlists, videos (with resumable upload), and video categories via the YouTube Data API v3.

  • Uploads are resumable and chunked, so a large file is sent in pieces rather than one request. Keep Max Concurrency low when a batch of items each carries a video — several simultaneous uploads is the quickest way to exhaust the API quota.
  • Category ID is numeric. Run Video Category: Get Many for the region first if you do not already know the ID.
  • Scheduling requires privacy. Publish At only takes effect on a video whose Privacy Status is private.
  • Playlist Item ID is not the Video ID. Delete and Get on a playlist item want the item’s own ID, which comes back from Playlist Item: Add or Get Many.
  • Listings default to your own account. Channel and Playlist Get Many return the authenticated account’s resources until you set a filter such as Channel ID or ID, at which point they return those instead.
  • Fields trims the response. Asking for snippet alone instead of * makes big listings much smaller and cheaper to page through.

Frequently asked questions

How are large videos uploaded?

Resumably and in chunks rather than one request. Keep Max Concurrency low when a batch of items each carries a video — several simultaneous uploads is the quickest way to exhaust the API quota.

What form does Category ID take?

Numeric. Look it up rather than passing the category's display name, which is not accepted.

What can it manage besides videos?

Channels, playlists, playlist items and video categories, so publishing and organisation are both covered.

Which credential does it need?

A YouTube OAuth2 credential for the channel you are publishing to.

Build with the YouTube node

Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need YouTube OAuth2 credentials first.

Open BusyBot

Last updated . Spotted something wrong? Tell us.