---
title: "YouTube Integration"
description: "Search and access YouTube videos and channels"
---
The YouTube integration provides access to search and access YouTube videos and channels through the Integrate MCP server.

## Installation

The YouTube integration is included with the SDK:

```typescript
import { youtubeIntegration } from "integrate-sdk/server";
```

## Setup

### 1. Create a YouTube OAuth App

1. Go to [Google Cloud Console](https://console.cloud.google.com)
2. Create a new OAuth application
3. Configure your redirect URI
4. Note your Client ID and Client Secret

### 2. Configure the Integration on Your Server

Add the YouTube integration to your server configuration. The integration automatically reads `YOUTUBE_CLIENT_ID` and `YOUTUBE_CLIENT_SECRET` from your environment variables:

```typescript
import { createMCPServer, youtubeIntegration } from "integrate-sdk/server";

export const { client: serverClient } = createMCPServer({
  apiKey: process.env.INTEGRATE_API_KEY,
  integrations: [
    youtubeIntegration({
    }),
  ],
});
```

You can override the environment variables by passing explicit values:

```typescript
youtubeIntegration({
  clientId: process.env.CUSTOM_YOUTUBE_ID,
  clientSecret: process.env.CUSTOM_YOUTUBE_SECRET,
});
```

### 3. Client-Side Usage

The default client automatically includes all integrations. You can use it directly:

```typescript
import { client } from "integrate-sdk";

await client.authorize("youtube");
const result = await client.youtube.search({
  query: "value",
});

console.log(result);
```

If you're using a custom client, add the integration to the integrations array:

```typescript
import { createMCPClient, youtubeIntegration } from "integrate-sdk";

const customClient = createMCPClient({
  integrations: [youtubeIntegration()],
});
```

## Configuration Options

<AutoTypeTable
  path="../src/integrations/youtube.ts"
  name="YouTubeIntegrationConfig"
/>


## Tools

### `youtube_add_comment`

Post a new top-level comment on a video

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeAddCommentParams"
/>

### `youtube_add_to_playlist`

Add a video to a playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeAddToPlaylistParams"
/>

### `youtube_create_playlist`

Create a new playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeCreatePlaylistParams"
/>

### `youtube_delete_playlist`

Permanently delete a playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeDeletePlaylistParams"
/>

### `youtube_get_captions`

List available caption tracks for a video

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeGetCaptionsParams"
/>

### `youtube_get_channel`

Get details for any channel by ID

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeGetChannelParams"
/>

### `youtube_get_my_channel`

Get the authenticated user's own channel

_No parameters._

### `youtube_get_playlist`

Get details for a specific playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeGetPlaylistParams"
/>

### `youtube_get_video`

Get full details for a specific video

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeGetVideoParams"
/>

### `youtube_get_video_rating`

Get the authenticated user's rating for one or more videos

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeGetVideoRatingParams"
/>

### `youtube_list_comment_replies`

List replies to a specific comment thread

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListCommentRepliesParams"
/>

### `youtube_list_comments`

List top-level comment threads on a video

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListCommentsParams"
/>

### `youtube_list_my_videos`

List videos uploaded by the authenticated user

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListMyVideosParams"
/>

### `youtube_list_playlist_items`

List videos in a playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListPlaylistItemsParams"
/>

### `youtube_list_playlists`

List playlists for the authenticated user or a specific channel

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListPlaylistsParams"
/>

### `youtube_list_subscriptions`

List channels the authenticated user is subscribed to

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeListSubscriptionsParams"
/>

### `youtube_rate_video`

Like, dislike, or remove a rating from a video

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeRateVideoParams"
/>

### `youtube_remove_from_playlist`

Remove an item from a playlist

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeRemoveFromPlaylistParams"
/>

### `youtube_reply_to_comment`

Reply to an existing comment thread

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeReplyToCommentParams"
/>

### `youtube_search`

Search for videos, channels, or playlists

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeSearchParams"
/>

### `youtube_subscribe`

Subscribe to a channel

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeSubscribeParams"
/>

### `youtube_unsubscribe`

Unsubscribe from a channel

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeUnsubscribeParams"
/>

### `youtube_update_playlist`

Update a playlist's metadata

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeUpdatePlaylistParams"
/>

### `youtube_update_video`

Update a video's metadata

<AutoTypeTable
  path="generated/tool-params/youtube.ts"
  name="YoutubeUpdateVideoParams"
/>

## Notes

- Category: Entertainment
- Authentication mode: OAuth
