productivity
Notion MCP, CLI, and Lua Integration for AI Agents
Notion integration docs for AI agents: MCP gateway setup, Notion CLI commands, Lua API reference, credentials, and function schemas.
20 functions 11 read 9 write API key auth
Notion for agents
Credentials can be configured manually in web or CLI hosts.
Use this integration from Lua code mode, the headless integrations CLI, or the KosmoKrator MCP gateway. The same package metadata powers all three surfaces.
Machine-Readable Metadata
- integration_slug
notion- route_slug
notion- package
notion- auth_strategy
api_keyAPI key- cli_setup_supported
true- cli_runtime_supported
true- mcp_gateway_supported
true- lua_supported
true- supports_multi_account
true
Quick Links
Lua APIAgent-facing namespace and function reference. Notion CLIHeadless setup and direct function calls. Notion MCPMCP gateway setup for external clients. Submit feedbackReport missing tools, auth problems, wrong docs, or runtime issues. ContributeAdd tools or improve metadata in the integrations repo.
Notion MCP Client Matrix
Use these pages when a specific agent client or framework needs copy-pasteable MCP setup for Notion.
Claude Code Notion MCP setup for Claude Code. Cursor Notion MCP setup for Cursor. Codex Notion MCP setup for Codex. OpenAI Agents Notion MCP setup for OpenAI Agents SDK. Claude Agent SDK Notion MCP setup for Claude Agent SDK. Vercel AI SDK Notion MCP setup for Vercel AI SDK. LangChain Notion MCP setup for LangChain. LangGraph Notion MCP setup for LangGraph. CrewAI Notion MCP setup for CrewAI. MCP clients Notion MCP setup for Generic MCP Clients.
Notion CLI Matrix
Use these pages for direct Notion CLI workflows in scripts, CI, cron, and agent wrappers.
CI Notion CLI for CI. Cron Jobs Notion CLI for cron jobs. Shell Scripts Notion CLI for shell scripts. Headless Automation Notion CLI for headless automation. Coding Agents Notion CLI for coding agents.
Function Catalog
| Function | Type | Parameters | Description |
|---|---|---|---|
notion.notion_search | Read read | 5 | Search pages and databases in your Notion workspace. Returns matching results with their IDs, types, and titles. Optionally filter by type (page or database) and control sort direction. |
notion.notion_create_page | Write write | 4 | Create a new page in Notion. The page can be created as a child of a database (to create a row) or as a child of another page (to create a sub-page). Provide properties as a JSON object matching the database schema when using a database parent. Provide children (block content) as a JSON array of block objects. |
notion.notion_get_page | Read read | 1 | Retrieve a Notion page by its ID. Returns the page object with properties, including title, icon, cover, parent info, and timestamps. |
notion.notion_update_page | Write write | 3 | Update properties on a Notion page. Provide properties as a JSON object matching the database/page schema. Can also archive/unarchive the page. |
notion.notion_archive_page | Write write | 1 | Archive a Notion page by setting its archived flag to true. The page can be restored by using notion_update_page with archived=false. |
notion.notion_create_database | Write write | 3 | Create a new database as a child of a page. Provide the parent page ID, a title, and a properties schema. Properties define the columns of the database. Example properties: {"Name": {"title": {}}, "Status": {"select": {"options": [{"name": "Todo"}, {"name": "Done"}]}}}. |
notion.notion_get_database | Read read | 1 | Retrieve a Notion database by its ID. Returns the full database schema including all property definitions (columns), title, and parent info. |
notion.notion_update_database | Write write | 3 | Update a Notion database's title and/or property schema. Provide a new title and/or modified properties as a JSON object. |
notion.notion_query_database | Read read | 5 | Query a Notion database to retrieve rows (pages). Supports filtering and sorting. Filter and sorts can be provided as JSON strings or arrays. Example filter: {"property": "Status", "select": {"equals": "Done"}} Example sorts: [{"property": "Name", "direction": "ascending"}] |
notion.notion_list_databases | Read read | 3 | List all databases accessible to the integration. Uses the search endpoint filtered to database objects. Optionally provide a query to filter by name. |
notion.notion_get_block_children | Read read | 3 | Get the child blocks of a Notion block or page. Returns a list of block objects. Use this to read the content of a page or to navigate nested block structures. Supports pagination. |
notion.notion_append_block_children | Write write | 2 | Append blocks to a Notion page or block. Provide children as a JSON array of block objects. Example: [{"object":"block","type":"paragraph","paragraph":{"rich_text":[{"type":"text","text":{"content":"Hello world"}}]}}] |
notion.notion_get_block | Read read | 1 | Retrieve a single Notion block by its ID. Returns the full block object including type-specific content, has_children flag, and parent info. |
notion.notion_update_block | Write write | 4 | Update the content of a Notion block. Provide the block ID and the type-specific content to update. For example, to update a paragraph block, provide: {"type": "paragraph", "paragraph": {"rich_text": [{"text": {"content": "New text"}}]}} Only the fields you include will be updated. |
notion.notion_delete_block | Write write | 1 | Delete a Notion block by its ID. This permanently removes the block (moves it to trash if it is a top-level page block). |
notion.notion_get_current_user | Read read | 0 | Get information about the current integration bot user. Returns the bot's name, avatar, and workspace info. |
notion.notion_list_users | Read read | 2 | List all users in the Notion workspace. Returns user IDs, names, types, and avatar URLs. Supports pagination. |
notion.notion_get_user | Read read | 1 | Retrieve a Notion user by their ID. Returns the user's name, type, avatar URL, and email (if available). |
notion.notion_create_comment | Write write | 4 | Create a comment on a Notion page. You can either start a new discussion (provide parent_id) or reply to an existing discussion (provide discussion_id). Provide body_text for simple text, or body_children for rich content blocks. |
notion.notion_get_comments | Read read | 3 | Retrieve comments on a Notion page or block. Returns all comment objects with their content, authors, and timestamps. Supports pagination. |