# YouTube

## Enabling the YouTube module?

This module must be enabled to be used. To enable, click the **Enable** button in the top right hand side of the page.

## Adding a new channel?

Adding a new channel will cause BotGhost to track that channel for new videos. Whenever that channel posts a new YouTube video, your bot will send a notification to your server.

To get started, click the '**Add'** button next to add Channel. This will bring up a new window to add a channel to the tracking list.&#x20;

![GIF: setting up the YouTube module, speedrun!](https://1937909199-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Lm_hW5MApY3J0lRhi0M%2Fuploads%2FEfEj7bg8fiKFyTFrZgYl%2FYoutube_1.gif?alt=media\&token=f2fdcd5d-0d16-4d4e-b8d2-056764bbedd5)

#### Fields

| Field              | Description                                                                                                                                         |
| ------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| Channel ID         | The channel id of the YouTube channel you are trying to track. To get this ID refer to *Getting an ID* belo&#x77;*.*                                |
| Channel to Post in | This is the text-channel in discord to post new video notifications in. If this channel does not exist then your bot will automatically create one. |
| Channel Name       | The name of the YouTube channel.                                                                                                                    |

## Getting a YouTube channel ID?

The ID of a YouTube channel can be found by looking at the URL of the YouTube channel.

1. Go to the YouTube channel you wish to track
2. Take a look at the URL of the page
3. If the  URL looks like youtube.co&#x6D;**/user/**&#x63;hannelname you will need to paste the channel name of the channel into a tool such as [<mark style="color:blue;">**this**</mark>](https://commentpicker.com/youtube-channel-id.php) to get the channel ID.
4. If the URL looks like youtube.com/channel/**id** or youtube.com/c/**id**, what comes after the **/channel/** or **/c/** is the ID of the YouTube channel.

{% hint style="info" %}
Please note that there is a slight delay associated with the YouTube API, it will take up to a maximum of 15 minutes for the video to be posted in the channel you've selected!
{% endhint %}
