ShawhinT/yt-mcp-agent
If you are the rightful owner of yt-mcp-agent and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
YouTube agent via a custom MCP server
yt-mcp-agent
A YouTube video agent built using a custom MCP server and OpenAI's Agent's SDK. It can extract video transcripts given link fetch specialized instructions for things like: writing blog posts, video chapters, and social posts.
Resources:
This example is a prelude to Cohort 7 of the AI Builders Bootcamp.
Requirements
- Python 3.13+
- OpenAI API key
uv
package manager (recommended)
How to run this example
uv (recommended)
-
Clone the repository
git clone <repository-url> cd yt-mcp-agent
-
Install dependencies with uv
uv sync
-
Set up your OpenAI API key
Create a
.env
file in the root directory:echo "OPENAI_API_KEY=your_api_key_here" > .env
-
Run the agent
uv run main.py
-
Interact with agent
Once running, you can ask the agent to analyze YouTube videos. Try prompts like:
- "Summarize this: https://youtu.be/N3vHJcHBS-w?si=aw8PV0acYHJGPy7R"
- "Generate chapter timestamps with links"
- "Write me a LinkedIn post about the video"
Base Python/pip
-
Clone the repository
git clone <repository-url> cd yt-mcp-agent
-
Create a virtual environment
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install dependencies
pip install -e .
-
Set up your OpenAI API key
Create a
.env
file in the root directory:echo "OPENAI_API_KEY=your_api_key_here" > .env
-
Run the agent
python main.py
-
Interact with agent