Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/teng-lin/notebooklm-py/llms.txt

Use this file to discover all available pages before exploring further.

The notebooklm CLI exposes every feature of the Python library as shell commands organized into logical groups. You can run it interactively, embed it in shell scripts, or call it from CI/CD pipelines. Most commands accept a --json flag for machine-readable output and support partial notebook IDs for convenience.

Command structure

Every invocation follows this shape:
notebooklm [-p PROFILE] [--storage PATH] [--version] [-v] <command> [OPTIONS] [ARGS]

Global options

OptionDescription
-p, --profile NAMEUse a named profile (overrides NOTEBOOKLM_PROFILE)
--storage PATHOverride the default storage location
-v, --verboseEnable verbose output
--versionShow version and exit
--helpShow help message

Environment variables

VariableDescription
NOTEBOOKLM_HOMEBase directory for all config files (default: ~/.notebooklm)
NOTEBOOKLM_PROFILEActive profile name (default: default)
NOTEBOOKLM_AUTH_JSONInline authentication JSON (for CI/CD, no file writes needed)
NOTEBOOKLM_DEBUG_RPCEnable RPC debug logging—set to 1 to activate

Session commands

Session commands manage authentication and the active notebook context. You must authenticate before using any other command.
CommandDescriptionExample
loginAuthenticate via browsernotebooklm login
login --browser msedgeUse Edge for SSO-gated orgsnotebooklm login --browser msedge
use <id>Set active notebooknotebooklm use abc123
statusShow current contextnotebooklm status
status --pathsShow config file pathsnotebooklm status --paths
status --jsonJSON outputnotebooklm status --json
clearClear active notebooknotebooklm clear
auth checkDiagnose auth issuesnotebooklm auth check
auth check --testValidate with a live network testnotebooklm auth check --test
doctorCheck environment healthnotebooklm doctor
doctor --fixAuto-fix detected issuesnotebooklm doctor --fix

Partial ID matching

notebooklm use <id> and most ID-accepting commands support partial prefix matching. Providing the first six or more characters of a UUID is enough, as long as the prefix is unique.
notebooklm use abc  # Matches any notebook ID starting with "abc"

Profile commands

Named profiles let you manage multiple Google accounts. Each profile has its own session file and active notebook context.
CommandDescriptionExample
profile listList all profilesnotebooklm profile list
profile create <name>Create a profilenotebooklm profile create work
profile switch <name>Set the active profilenotebooklm profile switch work
profile delete <name>Delete a profilenotebooklm profile delete old
profile rename <old> <new>Rename a profilenotebooklm profile rename old new

Notebook commands

CommandDescriptionExample
listList all notebooksnotebooklm list
create <title>Create a notebooknotebooklm create "Research"
delete <id>Delete a notebooknotebooklm delete abc123
rename <title>Rename the current notebooknotebooklm rename "New Title"
summaryGet the AI-generated summarynotebooklm summary

Chat commands

The ask command sends a question to the active notebook and prints the answer. Use --save-as-note to persist the response as a notebook note.
CommandDescriptionExample
ask <question>Ask a questionnotebooklm ask "What is this about?"
ask -s <id>Limit to specific sourcesnotebooklm ask "Summarize" -s src1 -s src2
ask --jsonInclude source referencesnotebooklm ask "Explain X" --json
ask --save-as-noteSave response as a notenotebooklm ask "Explain X" --save-as-note
ask --save-as-note --note-title "T"Save with a custom titlenotebooklm ask "Explain X" --save-as-note --note-title "T"
configure --mode learning-guideSet the chat personanotebooklm configure --mode learning-guide
historyView conversation historynotebooklm history
history --clearClear local conversation cachenotebooklm history --clear
history --saveSave history as a notenotebooklm history --save

Source commands

source add auto-detects the content type from its argument: HTTP URLs become web sources, YouTube URLs extract transcripts, and file paths trigger uploads.
CommandArgumentsOptionsExample
source listnotebooklm source list
source add <content>URL / file path / textnotebooklm source add "https://..."
source add-drive <id> <title>Drive file ID, titlenotebooklm source add-drive abc123 "Doc"
source add-research <query>Search query--mode [fast|deep], --from [web|drive], --import-all, --no-waitnotebooklm source add-research "AI" --mode deep --no-wait
source get <id>Source IDnotebooklm source get src123
source fulltext <id>Source ID--json, -o FILEnotebooklm source fulltext src123 -o content.txt
source guide <id>Source ID--jsonnotebooklm source guide src123
source rename <id> <title>Source ID, new titlenotebooklm source rename src123 "New Name"
source refresh <id>Source IDnotebooklm source refresh src123
source delete <id>Source IDnotebooklm source delete src123
source wait <id>Source ID--timeout, --intervalnotebooklm source wait src123

Research commands

Use research commands to check on and wait for background web or Drive research started with source add-research --no-wait.
CommandOptionsExample
research status--jsonnotebooklm research status
research wait--timeout, --interval, --import-all, --jsonnotebooklm research wait --import-all

Generate commands

All generate subcommands support --source/-s (repeatable) to target specific sources, --language for multilingual output, --json for machine-readable task IDs, and --retry N for automatic exponential backoff on rate limits. Most are asynchronous by default—use --wait to block until completion.
CommandOptionsExample
generate audio [desc]--format [deep-dive|brief|critique|debate], --length [short|default|long], --waitnotebooklm generate audio "Focus on history" --wait
generate video [desc]--format [explainer|brief|cinematic], --style [auto|classic|whiteboard|kawaii|anime|watercolor|retro-print|heritage|paper-craft], --waitnotebooklm generate video --style whiteboard --wait
generate cinematic-video [desc]Alias for video --format cinematic; same optionsnotebooklm generate cinematic-video "Documentary summary" --wait
generate slide-deck [desc]--format [detailed|presenter], --length [default|short], --waitnotebooklm generate slide-deck --wait
generate revise-slide <desc>-a/--artifact <id> (required), --slide N (required), --waitnotebooklm generate revise-slide "Move title up" --artifact <id> --slide 0
generate quiz [desc]--difficulty [easy|medium|hard], --quantity [fewer|standard|more], --waitnotebooklm generate quiz --difficulty hard --wait
generate flashcards [desc]--difficulty [easy|medium|hard], --quantity [fewer|standard|more], --waitnotebooklm generate flashcards --wait
generate infographic [desc]--orientation [landscape|portrait|square], --detail [concise|standard|detailed], --waitnotebooklm generate infographic --orientation portrait --wait
generate report [desc]--format [briefing-doc|study-guide|blog-post|custom], --append "...", --waitnotebooklm generate report --format study-guide --wait
generate data-table <desc>--waitnotebooklm generate data-table "compare key concepts" --wait
generate mind-map(synchronous, no --wait option)notebooklm generate mind-map

Artifact commands

CommandArgumentsOptionsExample
artifact list--typenotebooklm artifact list --type audio
artifact get <id>Artifact IDnotebooklm artifact get art123
artifact rename <id> <title>Artifact ID, titlenotebooklm artifact rename art123 "Title"
artifact delete <id>Artifact IDnotebooklm artifact delete art123
artifact export <id>Artifact ID--type [docs|sheets], --titlenotebooklm artifact export art123 --type sheets
artifact poll <task_id>Task IDnotebooklm artifact poll task123
artifact wait <id>Artifact ID--timeout, --intervalnotebooklm artifact wait art123

Download commands

Download commands write files to your local machine. Use --all for batch downloads, --latest for the most recent artifact, or -a/--artifact to target a specific ID.
CommandOptionsDefault formatExample
download audio [path]--all, --latest, -a, --force.mp4notebooklm download audio ./podcast.mp3
download video [path]--all, --latest, -a, --force.mp4notebooklm download video ./overview.mp4
download cinematic-video [path]Same as video.mp4notebooklm download cinematic-video ./documentary.mp4
download slide-deck [path]--format [pdf|pptx], --all, --latest.pdfnotebooklm download slide-deck --format pptx
download infographic [path]--all, --latest, -a.pngnotebooklm download infographic ./info.png
download report [path]--all, --latest, -a.mdnotebooklm download report ./study-guide.md
download mind-map [path]--all, --latest, -a.jsonnotebooklm download mind-map ./map.json
download data-table [path]--all, --latest, -a.csvnotebooklm download data-table ./data.csv
download quiz [path]--format [json|markdown|html], -a.jsonnotebooklm download quiz --format markdown quiz.md
download flashcards [path]--format [json|markdown|html], -a.jsonnotebooklm download flashcards cards.json

Language commands

Language is a global setting that applies to all artifact generation in your account.
CommandDescriptionExample
language listList all 80+ supported languagesnotebooklm language list
language getShow current language settingnotebooklm language get
language get --localSkip server syncnotebooklm language get --local
language set <code>Set the output languagenotebooklm language set zh_Hans
language set <code> --localSave locally onlynotebooklm language set ja --local

Sharing commands

CommandDescriptionExample
share statusShow sharing configurationnotebooklm share status
share public --enableEnable public link sharingnotebooklm share public --enable
share public --disableDisable public sharingnotebooklm share public --disable
share view-level fullSet viewers to see full notebooknotebooklm share view-level full
share view-level chatRestrict viewers to chat onlynotebooklm share view-level chat
share add <email>Share with a user (viewer by default)notebooklm share add user@example.com
share update <email>Change a user’s permissionnotebooklm share update user@example.com --permission editor
share remove <email>Remove user accessnotebooklm share remove user@example.com

Note commands

CommandArgumentsExample
note listnotebooklm note list
note create <content>Note textnotebooklm note create "My notes..."
note get <id>Note IDnotebooklm note get note123
note save <id>Note ID + --title, --contentnotebooklm note save note123 --title "Updated title"
note rename <id> <title>Note ID, titlenotebooklm note rename note123 "Title"
note delete <id>Note IDnotebooklm note delete note123

Skill commands

Skill commands install the NotebookLM skill into local agent directories so tools like Claude Code can pick it up automatically.
CommandDescriptionExample
skill installInstall to ~/.claude/skills/ and ~/.agents/skills/notebooklm skill install
skill statusCheck installed targets and versionnotebooklm skill status
skill uninstallRemove installed targetsnotebooklm skill uninstall
skill showDisplay the packaged skill filenotebooklm skill show

Common workflows

These end-to-end examples show how to combine CLI commands into useful pipelines.

Research → podcast

notebooklm create "Climate Change Research"
notebooklm use <notebook_id>
notebooklm source add "https://en.wikipedia.org/wiki/Climate_change"
notebooklm source add-research "climate change policy 2024" --mode deep --import-all
notebooklm generate audio "Focus on policy solutions" --format debate --wait
notebooklm download audio ./climate-podcast.mp3

Document analysis → study materials

notebooklm create "Exam Prep"
notebooklm use <id>
notebooklm source add "./textbook-chapter.pdf"
notebooklm source add "./lecture-notes.pdf"
notebooklm summary
notebooklm generate quiz --difficulty hard --wait
notebooklm generate flashcards --wait
notebooklm generate report --format study-guide --wait
notebooklm download quiz --format markdown quiz.md
notebooklm download flashcards cards.json
notebooklm download report ./study-guide.md

YouTube → quick summary

notebooklm create "Video Notes"
notebooklm use <id>
notebooklm source add "https://www.youtube.com/watch?v=VIDEO_ID"
notebooklm summary
notebooklm ask "What are the main points?"
notebooklm generate report --format briefing-doc --wait
notebooklm download report ./briefing.md

Bulk import

notebooklm use <id>
notebooklm source add "https://example.com/article1"
notebooklm source add "https://example.com/article2"

# Loop over local files
for f in ./papers/*.pdf; do
  notebooklm source add "$f"
done
Use --wait when you need a file on disk immediately. For long-running generation (audio, video, slide decks), omit --wait and check back with notebooklm artifact list, or use artifact wait <id> in a background task.Nearly every command supports --json for structured output, making it easy to parse results with jq or pass IDs between steps in a script.

Tips for LLM agents

When this CLI is called programmatically by an AI agent, keep the following in mind.
  • Use notebooklm use <id> to set context for a single-agent session, or pass -n <id> directly to commands in parallel workflows to avoid context collisions.
  • Generation commands are async by default except mind-map, which is synchronous. Use --no-wait for long operations and poll with artifact wait in a subagent.
  • Partial IDs work for most commands—six or more characters is usually enough.
  • Use --json on every command to get machine-readable output instead of styled tables.
  • source add auto-detects the content type from the argument, so you do not need separate commands for URLs, files, or YouTube links.
  • For non-blocking deep research, run source add-research --mode deep --no-wait and then research wait --import-all in a subagent.

Build docs developers (and LLMs) love