jacob-bd/gemini-notebook-mcp-cli

Programmatic access to Gemini Notebook - via command-line interface (CLI), Model Context Protocol (MCP) server, and AI agent skills.

What it solves

Gemini Notebook (formerly NotebookLM) doesn't have a public API, so you can't easily automate tasks or connect it to other tools. This project bridges that gap by using internal, undocumented endpoints to give you programmatic control. It lets you create and manage notebooks, add sources, generate audio or video, run queries, and download results — all from your terminal or through an AI assistant.

How it works

You install a single package that provides two things: a command-line tool called nlm and an MCP server that AI assistants can connect to. After signing in with your Google account (the tool extracts cookies from your browser), you can run commands like nlm notebook list or nlm source add, or ask a connected AI to perform those actions in natural language. A setup wizard (nlm setup) automatically detects AI tools installed on your machine and links them to Gemini Notebook with just a few keystrokes. The tool also handles multiple Google profiles, encrypted credential storage (optionally using your OS keychain), and background session refreshing so you don't have to log in repeatedly.

Who it’s for

This is for anyone who uses Gemini Notebook and wants to automate their workflow. It's particularly useful for developers, researchers, and content creators who want to script actions, integrate with other software, or connect NotebookLM to AI coding assistants like Claude Code, Cursor, or Gemini CLI. It also works well in CI/CD pipelines and unattended environments thanks to its headless authentication refresh.

Highlights

  • Bridges a missing API – Uses internal endpoints to expose a full command-line and MCP interface to Gemini Notebook.
  • Two-in-one delivery – Both a CLI (nlm) and an MCP server (notebooklm-mcp) come from one installation.
  • Extensive feature set – Notebook CRUD, source adding (URL, text, Drive, file), querying, studio content generation (audio, video, slides), artifact downloading, sharing, research, batch operations, cross-notebook queries, pipelines, tags, collections, and usage tracking.
  • One-command setup – nlm setup auto-detects and configures many AI tools (Claude, Codex, Cursor, Windsurf, Cline, GitHub Copilot, etc.), plus offers a skill installer to teach your AI how to use NotebookLM well.
  • Flexible authentication – Supports multiple Google profiles, encrypted login storage, and scheduled background refresh for long-running sessions.
  • Diagnostics and support – Includes nlm doctor to troubleshoot issues and comprehensive documentation.

Related

  • Project
  • Project
  • Project
  • Project
  • Project