Skip to content

Commit 5b6f842

Browse files
Merge pull request #4122 from segmentio/3973-content-youtube-analytics-plugin-api-requirements
YouTube Plugin updates
2 parents 032b588 + 2618421 commit 5b6f842

File tree

1 file changed

+9
-3
lines changed
  • src/connections/sources/catalog/libraries/website/plugins/youtube

1 file changed

+9
-3
lines changed

src/connections/sources/catalog/libraries/website/plugins/youtube/index.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,16 @@ hidden: true
55

66
With the analytics.js YouTube Plugin you can collect YouTube player events into the Segment ecosystem.
77

8+
The Segment YouTube Plugin uses the following Google APIs:
9+
- [YouTube IFrame player API](https://developers.google.com/youtube/iframe_api_reference#Getting_Started){:target="_blank”}: Controls the video (play, pause, stop).
10+
- [Data API](https://developers.google.com/youtube/v3/getting-started){:target="_blank”}: Accesses metadata about the video in the iFrame.
11+
812
## Prerequisites
9-
The Segment YouTube Plugin requires the YouTube player JavaScript object as an input, so your YouTube player embed must use the [YouTube IFrame player API](https://developers.google.com/youtube/iframe_api_reference#Getting_Started).
1013

11-
To begin, generate an API Key for the Segment YouTube plugin, which it uses to access metadata about the playing video content. To do this, create a new project in the Google Developer Console, then create a new API Key in that project for the Segment YouTube plugin. You can read more about this process in the YouTube documentation on [registering an application](https://developers.google.com/youtube/registering_an_application).
14+
To begin, create a new project in the Google Developer Console, then create a new API key in that project. You can read more about this process in the YouTube documentation on [registering an application](https://developers.google.com/youtube/registering_an_application){:target="_blank”}.
15+
16+
> note "Secure your API keys"
17+
> You can [secure your API keys](https://cloud.google.com/docs/authentication/api-keys#securing){:target="_blank”} by adding API key restrictions, deleting unused API keys, and periodically rotating your keys.
1218
1319
## Getting Started
1420

@@ -38,7 +44,7 @@ var player;
3844
})}
3945
```
4046

41-
That's it! The plugin listens to the YouTube player for events, and fires the corresponding [Segment Video Spec](/docs/connections/spec/video/) events on analytics.js.
47+
The plugin listens to the YouTube player for events, and fires the corresponding [Segment Video Spec](/docs/connections/spec/video/) events on analytics.js.
4248

4349
## Supported Events
4450
The plugin tracks the following [Segment Video Spec](/docs/connections/spec/video/) events:

0 commit comments

Comments
 (0)