N8N Tools - YouTube Enhanced
Actions83
- Videos Actions
- Channels Actions
- Playlists Actions
- Search Actions
- Analytics Actions
- Get Channel Analytics
- Get Video Analytics
- Get Playlist Analytics
- Get Content Owner Analytics
- Get Audience Retention
- Get Demographics
- Get Geographic Data
- Get Device Data
- Get Traffic Source Data
- Get Revenue Data
- Get Ad Performance Data
- Get Subscriber Analytics
- Get Playback Location Data
- Get Video Performance Data
- Get Playlist Performance Data
- Get Annotation Performance Data
- Get Card Performance Data
- Get Sharing Service Data
- Get Live Streaming Data
- Get Content Type Data
- Get Time Based Data
- Comments Actions
- Subscriptions Actions
- Live Streaming Actions
- Video Upload Actions
- Community Posts Actions
- Thumbnails Actions
- Captions Actions
- Channel Memberships Actions
- Super Chat & Thanks Actions
Overview
The "Get Geographic Data" operation under the Analytics resource in this YouTube Enhanced node fetches geographic analytics data for a specified YouTube channel. It retrieves metrics such as views, estimated minutes watched, and other user-selected statistics broken down by geographic regions over a defined date range.
This node is beneficial for content creators, marketers, and analysts who want to understand where their audience is located geographically. For example, a YouTube channel owner can use this node to identify which countries or regions generate the most views or engagement, helping tailor content or marketing strategies accordingly.
Practical examples:
- A creator targeting specific countries can analyze viewership trends by region.
- Marketers can assess the effectiveness of localized campaigns by comparing geographic data before and after promotions.
- Analysts can combine geographic data with other metrics to optimize content distribution.
Properties
| Name | Meaning |
|---|---|
| Channel ID | The unique identifier of the YouTube channel for which geographic analytics data is requested. |
| Start Date | The beginning date for the analytics data range (inclusive). |
| End Date | The ending date for the analytics data range (inclusive). |
| Metrics | The list of metrics to include in the report. Options include: Views, Estimated Minutes Watched, Average View Duration, Subscribers, Likes, Comments, Shares, Estimated Revenue, CPM, Impressions, and many more. |
| Max Results | Maximum number of results to return (minimum 1, maximum 1000). |
| Start Index | The index of the first result to return (minimum 1). |
Output
The output JSON contains the geographic analytics data retrieved from the YouTube API for the specified channel and date range. This data includes the requested metrics broken down by geographic dimensions such as country or region.
The structure typically includes:
- Metric values corresponding to each geographic location.
- Metadata about the query parameters used.
- Pagination information if applicable.
No binary data is output by this operation.
Example output snippet (conceptual):
{
"kind": "youtubeAnalytics#resultTable",
"columnHeaders": [
{"name": "country", "type": "STRING"},
{"name": "views", "type": "INTEGER"},
...
],
"rows": [
["US", 12345],
["CA", 6789],
...
]
}
Dependencies
- Requires an active subscription and valid API key credential for the external N8N Tools API service.
- Requires OAuth2 credentials for accessing the YouTube Data API v3.
- The node internally uses helper classes to interact with YouTube's Analytics API endpoints.
- Proper configuration of these credentials within n8n is necessary for successful execution.
Troubleshooting
- Invalid subscription or API key error: If the node throws an error indicating invalid subscription or API key, verify that the API key credential is correctly configured and active.
- Permission errors: Ensure that the OAuth2 credentials have sufficient permissions/scopes to access YouTube Analytics data.
- Date range issues: Providing an invalid or future date range may cause errors or empty results; ensure start and end dates are valid and logical.
- Exceeded quota or rate limits: YouTube API enforces quotas; excessive requests may lead to temporary blocks. Consider reducing max results or request frequency.
- Missing required parameters: The Channel ID, Start Date, End Date, and Metrics are mandatory; missing any will cause the node to fail.