nblm-mcp
nblm-mcp
一个 MCP 服务器,让 AI 代理能够访问 Google NotebookLM(2026 年 7 月更名为 Gemini Notebook):列出和创建笔记本、管理其 来源、提出基于这些来源并附带引用的问题, 以及生成 Studio 产物,如音频概览、简报文档、测验和 思维导图。
关键在于落地。NotebookLM 只根据你提供的材料作答,
因此能够调用 ask 的代理可以从你自己的文档中获得带引用的答案,
而不是凭空猜测——并且不会消耗你自己上下文的 token,因为
Gemini 在服务端完成阅读。
⚠️ 非官方——请先阅读
Google 没有为 NotebookLM 提供公开的消费者 API。 本服务器驱动的是 notebooklm.google.com 界面所调用的同一个私有 Web 端点, 通过你自己的浏览器会话 cookie 进行身份验证,基于 MIT 许可的
notebooklm-py库。
与 Google 无关联,也未获得 Google 认可。
内部 API 可能随时变更,从而导致本服务器失效。
适用你 Google 账户的速率限制和每日 Studio 配额。
请使用你愿意用于自动化的账户。最适合个人 项目、研究和原型开发。
Google 确实为 Gemini Notebook Enterprise 提供了文档化的官方 API。如果你 拥有带该功能的 Workspace/Cloud 组织,请优先使用它,而不是本服务器。
安装
尚未发布到 PyPI——直接从本仓库安装。uvx 会按需构建并运行,
因此无需手动保持更新:
uvx --from git+https://github.com/Diego-Dev-Moros/nblm-mcp nblm-mcpRelated MCP server: NotebookLM MCP Server
登录一次
登录需要 auth 附加依赖(Playwright)以及人工在键盘前操作:
uvx --from "nblm-mcp[auth] @ git+https://github.com/Diego-Dev-Moros/nblm-mcp" nblm-mcp-login浏览器窗口会打开;像平常一样登录 NotebookLM。会话
cookie 存储在 ~/.notebooklm/ 下(与
notebooklm-py 使用的配置文件布局相同,因此已有的 notebooklm login 也能复用)。MCP
服务器绝不会自行登录——它需要一个交互式浏览器,而
MCP 宿主无法提供这一点。
如果还没有浏览器,请先运行 playwright install chromium。
Cookie 会过期。过期后,工具会开始返回身份验证错误;请重新运行 登录命令。
连接到客户端
Claude Code——使用 -s user 即可在每个项目中可用:
claude mcp add notebooklm -s user -- \
uvx --from git+https://github.com/Diego-Dev-Moros/nblm-mcp nblm-mcpClaude Desktop——将其添加到 claude_desktop_config.json 并重启
应用(macOS:~/Library/Application Support/Claude/,Windows:
%APPDATA%\Claude\,Linux:~/.config/Claude/):
{
"mcpServers": {
"notebooklm": {
"command": "uvx",
"args": ["--from", "git+https://github.com/Diego-Dev-Moros/nblm-mcp", "nblm-mcp"]
}
}
}Claude Desktop 从图形界面启动,不会继承你 shell 中的
PATH。如果服务器在那里无法启动,请将 "uvx" 替换为它的绝对
路径(which uvx,通常为 ~/.local/bin/uvx)。
无论哪种方式,都可以让代理调用 auth_status 来确认是否正常工作。
工具
工具 | 功能 |
| 通过真实请求验证已存储的会话;告知你是否需要重新登录。 |
| 列出该账户可访问的所有笔记本,以及 ID 和来源数量。 |
| 获取单个笔记本及其来源;可选地包含 NotebookLM 自己的摘要。 |
| 创建一个空笔记本。 |
| 删除一个笔记本及其所有内容。需要 |
| 列出笔记本中的来源及其处理状态。 |
| 从 URL(网页、YouTube、Drive)、粘贴的文本或本地文件添加一个来源。 |
| 移除一个来源。需要 |
| 向笔记本提问;返回答案并将引用解析为来源标题。 |
| 获取笔记本的过往问答轮次。 |
| 列出已生成的 Studio 产物及其状态——这也是轮询生成进度的方法。 |
| 生成音频、视频、简报文档、学习指南、测验、抽认卡、信息图、幻灯片或思维导图。 |
| 将已完成的产物下载到运行服务器的机器上的一个文件。 |
行为说明
破坏性工具设有门禁。
delete_notebook和delete_source在没有confirm=true的情况下拒绝执行,因此误调用不会销毁 笔记本。生成速度慢且受配额限制。
generate_artifact在任务 进入队列后立即返回(默认wait=false),并告知代理轮询list_artifacts。传入wait=true则会阻塞等待;最多等待NBLM_GENERATION_TIMEOUT秒。文件路径是服务器端的。
add_source(file_path=...)和download_artifact在运行 MCP 服务器的主机上读写文件,而该主机 不一定就是用户聊天客户端所在的位置。
配置
全部可选——参见 .env.example。工作
目录中的 .env 文件会被加载(如果存在)。
变量 | 默认值 | 用途 |
| active profile | 选择使用哪个已存储的登录,用于多个 Google 账户。 |
| resolved from profile | 显式指定 |
|
|
|
|
|
|
|
| 等待新来源完成处理的秒数。 |
开发
uv venv && uv pip install -e ".[dev]"
uv run pytest
uv run ruff check src tests测试套件针对内存中的模拟客户端运行工具——它从不 接触 Google,因此在任何地方运行都安全且快速。
相关项目
notebooklm-py 完成了最困难的部分
——逆向工程并维护私有的 batchexecute 协议——并且
自带一个更庞大的 MCP 服务器。本项目是在该库之上构建的一个更小、更聚焦的工具
集合:更少的工具、对破坏性操作的确认门禁、
以及将引用解析为答案的功能。
许可证
MIT——参见 LICENSE。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseAqualityDmaintenanceEnables AI agents to query and interact with Google NotebookLM notebooks to retrieve citation-backed information. It provides tools for listing notebooks, accessing source data, and asking natural language questions.11
- Alicense-qualityDmaintenanceEnables AI agents to programmatically access Google NotebookLM through browser automation for managing notebooks, sources, and chat interactions. It supports automated content generation including audio overviews, study guides, and quizzes directly within AI workflows.329MIT
- AlicenseBqualityFmaintenanceEnables AI agents to interact with Google NotebookLM for grounded, hallucination-free answers through notebook management, source management, research, and generation tools.2932922MIT
- AlicenseBqualityAmaintenanceEnables AI assistants to programmatically interact with Google NotebookLM, allowing them to create and manage notebooks, add sources, query content, generate audio/video, and perform research tasks through natural language commands.435,890MIT
Related MCP Connectors
Google NotebookLM via natural language: create notebooks, add sources (PDF, URL, YouTube) and ask gr
AI access to your aNotepad online notes: read, search, write, and organize via 22 tools.
Your company's brain for AI agents. Cited, permission-aware knowledge across every system.
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/Diego-Dev-Moros/nblm-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server