AVA MCP Server
模型上下文协议(MCP)
所有版权归于: https://github.com/ShawhinT/YouTube-Blog/
这是 AI 代理系列的第四个示例。在这里,我构建了一个客户端 MCP 服务器,以便任何 AI 应用都可以访问人工智能虚拟助手 (AVA) 的工具集。
链接
如何运行此示例
克隆此 repo
如果还没有安装uv,请先安装
# Mac/Linux
curl -LsSf https://astral.sh/uv/install.sh | sh
# Windows
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"在开发模式下测试服务器
uv run mcp dev mcp-server-example.py将服务器配置添加到 AI 应用程序(例如 Claude Desktop 或 Cursor)。
{
"mcpServers": {
"AVA": {
"command": "/Users/shawhin/.local/bin/uv", # replace with global path to your uv installation
"args": [
"--directory",
"/Users/shawhin/Documents/_code/_stv/sandbox/ava-mcp/", # replace with global path to repo
"run",
"mcp-server-example.py"
]
}
}
}Related MCP server: Gmail AutoAuth MCP Server
自定义 AVA 的行为
更新个人信息和偏好
在项目目录中找到
prompts/ava.md文件使用以下方式自定义文件:
沟通偏好
处理任务的具体说明
AVA 的任何其他相关指南
环境设置(.env)
在项目根目录中创建一个
.env文件,其中包含以下变量:
USER_EMAIL=your_email_address
# Google OAuth Credentials
GOOGLE_CREDENTIALS_PATH=.config/ava-agent/credentials.json
GOOGLE_TOKEN_PATH=.config/ava-agent/token.json所需的环境变量:
USER_EMAIL:您要用于此应用程序的 Gmail 地址GOOGLE_CREDENTIALS_PATH:您的 Google OAuth 凭据文件的路径GOOGLE_TOKEN_PATH:存储 Google OAuth 令牌的路径
Google OAuth 设置
1.创建项目目录结构
首先,创建所需的目录结构:
mkdir -p .config/ava-agent2. 设置 Google Cloud 项目
创建新项目或选择现有项目
启用 Gmail API:
在导航菜单中,转到“API 和服务”>“库”
搜索“Gmail API”
点击“启用”
3.创建OAuth凭证
在 Google Cloud Console 中:
前往“API 和服务”>“凭证”
点击“创建凭证”>“OAuth 客户端 ID”
选择“桌面应用程序”作为应用程序类型
给它起一个名字(例如,“AVA Gmail 客户端”)
点击“创建”
下载凭证:
创建完成后,点击“下载JSON”
将下载的文件保存为
.config/ava-agent/中的credentials.json该文件应包含您的客户端 ID 和客户端密钥
4. 配置 OAuth 同意屏幕
在 Google Cloud Console 中:
前往“API 和服务”>“OAuth 同意屏幕”
选择“外部”用户类型
填写所需信息:
应用程序名称
用户支持电子邮件
开发者联系信息
添加 Gmail API 范围:
https://www.googleapis.com/auth/gmail.modify将您的电子邮件添加为测试用户
完成配置
登录 Google
在服务器访问你的 Gmail 账户之前,你需要先授权。你可以运行uv run oauth.py来执行此操作,它会执行以下操作。
检查
token.json是否存在如果未找到,它将启动 Google OAuth 身份验证流程
指导您完成浏览器中的身份验证过程:
系统会要求您登录 Google 帐户
授予请求的权限
应用程序将自动保存令牌
自动生成并存储令牌
安全说明
文件保护
切勿将
.env文件或token.json提交到版本控制确保您的 Google 凭据安全
将以下内容添加到您的
.gitignore中:.env .config/ava-agent/token.json .config/ava-agent/credentials.json
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn MCP server that provides AI applications with a toolset for an Artificial Virtual Assistant (AVA) integrated with the Gmail API. It enables users to automate email management and personal tasks through secure Google OAuth authentication.1Apache 2.0
- AlicenseNot gradedqualityDmaintenanceAn MCP server enabling AI assistants to manage Gmail through natural language, including sending, reading, searching, labeling, and handling attachments with auto authentication.1MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that enables AI assistants to interact with Google Calendar and Gmail, allowing users to manage events, send emails, and organize their inbox through natural language.MIT
- AlicenseAqualityBmaintenanceAn MCP-compliant server that exposes Gmail and Google Docs as tools, enabling AI agents to draft, send, and manage emails, as well as create, read, and append to documents through natural language.9MIT
Related MCP Connectors
Personal assistant MCP server with search, execute, packages, jobs, secrets, and integrations.
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
An MCP server that integrates with Discord to provide AI-powered features.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/ramaiyaKushal/mcp-learning'
If you have feedback or need assistance with the MCP directory API, please join our Discord server