# notebooklm-py

> An unofficial Python API and CLI for Google NotebookLM, providing full programmatic access to notebooks, sources, chat, content generation, and downloads.

notebooklm-py is a comprehensive unofficial Python library and CLI that provides full programmatic access to Google NotebookLM's features, including capabilities not exposed in the web UI. It supports Python async workflows, shell scripting via CLI, and integration with AI agents like Claude Code, Codex, and OpenClaw. The library is MIT-licensed, open source, and available on PyPI.

- **Python API** — *Install via `pip install notebooklm-py` and use the async `NotebookLMClient` to create notebooks, add sources, chat, and generate content programmatically.*
- **CLI** — *Run `notebooklm login` to authenticate, then use commands like `notebooklm create`, `notebooklm ask`, and `notebooklm generate` for quick tasks and shell automation.*
- **Agent Integration** — *Install the bundled NotebookLM skill with `notebooklm skill install` or `npx skills add teng-lin/notebooklm-py` for use with Claude Code, Codex, and `.agents` skill directories.*
- **Notebook & Source Management** — *Create, list, rename, and delete notebooks; add sources from URLs, YouTube, PDFs, Google Drive, text files, audio, video, and images.*
- **Content Generation** — *Generate Audio Overviews (MP3/MP4), Video Overviews (MP4), Slide Decks (PDF/PPTX), Infographics (PNG), Quizzes, Flashcards, Reports, Data Tables (CSV), and Mind Maps (JSON).*
- **Batch Downloads & Export** — *Download all generated artifacts locally; export quizzes and flashcards as JSON, Markdown, or HTML; extract mind map JSON; download slide decks as editable PPTX — features not available in the web UI.*
- **Research Automation** — *Run web and Google Drive research queries with auto-import to build repeatable research pipelines.*
- **Programmatic Sharing** — *Manage public/private links and user permissions (viewer/editor) without the web UI.*
- **Cross-Platform** — *Tested on macOS, Linux, and Windows; supports Python 3.10–3.14.*

## Features
- Python async API
- CLI interface
- AI agent skill integration (Claude Code, Codex, OpenClaw)
- Notebook create/list/rename/delete
- Source ingestion: URLs, YouTube, PDFs, Google Drive, text, audio, video, images
- Chat with sources and conversation history
- Audio Overview generation (MP3/MP4)
- Video Overview generation (MP4)
- Slide Deck generation (PDF/PPTX)
- Infographic generation (PNG)
- Quiz generation (JSON/Markdown/HTML)
- Flashcard generation (JSON/Markdown/HTML)
- Report generation (Markdown)
- Data Table generation (CSV)
- Mind Map generation (JSON)
- Batch artifact downloads
- Web and Drive research agents with auto-import
- Programmatic sharing and permissions management
- Source fulltext access
- Save chat to notes
- Slide revision via natural language
- Export to Google Docs/Sheets

## Integrations
Google NotebookLM, Google Drive, YouTube, Claude Code, OpenAI Codex, OpenClaw, PyPI, Playwright (browser auth)

## Platforms
WINDOWS, MACOS, LINUX, API, DEVELOPER_SDK, CLI

## Pricing
Open Source

## Version
v0.3.4

## Links
- Website: https://github.com/teng-lin/notebooklm-py
- Documentation: https://github.com/teng-lin/notebooklm-py/tree/main/docs
- Repository: https://github.com/teng-lin/notebooklm-py
- EveryDev.ai: https://www.everydev.ai/tools/notebooklm-py
