Notion ReadOnly logo

Notion ReadOnly

Community
Taewoong1378

This project implements an optimized read-only MCP server for the Notion API, focusing on performance and efficiency for AI assistants to query and retrieve Notion content.

PublisherTaewoong1378
Repositorynotion-readonly-mcp-server
LanguageTypeScript
Forks
3
Stars
4
Available tools
8
Transport typestdio
Categories
LicenseMIT
Links
  • Connect tools to AI workflows

    Notion ReadOnly exposes MCP capabilities that can be used by compatible AI clients and agents.

  • 8 available tools

    Browse the callable actions below, including names and descriptions when provided by the server.

  • Ready-to-copy setup

    Use the installation snippets to configure this server in your preferred MCP client.

  • Open source signals

    4 stars and 3 forks from the linked repository.

Notion ReadOnly MCP Server

This project implements an optimized read-only MCP server for the Notion API, focusing on performance and efficiency for AI assistants to query and retrieve Notion content.

Key Improvements

  • Read-Only Design: Focused exclusively on data retrieval operations, ensuring safe access to Notion content.
  • Minimized Tool Set: Reduced the number of exposed Notion API tools from 15+ to only 6 essential ones for document analysis.
  • Parallel Processing: Enhanced performance by implementing asynchronous and parallel API requests for retrieving block content, significantly reducing response times.
  • Extended Database Access: Added support for database, page property, and comment retrieval operations.
  • Optimized for AI Assistants: Significantly reduced tool count addresses the "Too many tools can degrade performance" issue in AI assistants like Cursor, which limits models to approximately 40 tools.

Tool Comparison

This read-only implementation exposes far fewer tools compared to the standard Notion API integration, improving performance and compatibility with AI assistants:

Notion API Tools Comparison

The reduced tool set helps stay within the recommended tool limits for optimal AI assistant performance while still providing all essential functionality.

Installation

1. Setting up Integration in Notion:

Go to https://www.notion.so/profile/integrations and create a new internal integration or select an existing one.

Creating a Notion Integration token

While we limit the scope of Notion API's exposed to read-only operations, there is a non-zero risk to workspace data by exposing it to LLMs. Security-conscious users may want to further configure the Integration's Capabilities.

For example, you can create a read-only integration token by giving only "Read content" access from the "Configuration" tab:

Notion Integration Token Capabilities showing Read content checked

2. Adding MCP config to your client:

Using npm:

Add the following to your .cursor/mcp.json or claude_desktop_config.json (MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json)

json
{
  "mcpServers": {
    "notionApi": {
      "command": "npx",
      "args": ["-y", "notion-readonly-mcp-server"],
      "env": {
        "OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
      }
    }
  }
}

Using Docker:

Add the following to your .cursor/mcp.json or claude_desktop_config.json:

json
{
  "mcpServers": {
    "notionApi": {
      "command": "docker",
      "args": [
        "run",
        "--rm",
        "-i",
        "-e", "OPENAPI_MCP_HEADERS",
        "taewoong1378/notion-readonly-mcp-server"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "{\"Authorization\":\"Bearer ntn_****\",\"Notion-Version\":\"2022-06-28\"}"
      }
    }
  }
}

Don't forget to replace ntn_**** with your integration secret. Find it from your integration configuration tab.

3. Connecting content to integration:

Ensure relevant pages and databases are connected to your integration.

To do this, visit the page, click on the 3 dots, and select "Connect to integration".

Adding Integration Token to Notion Connections

Available Tools

This optimized server exposes only essential read-only Notion API tools:

  • API-retrieve-a-page: Get page information
  • API-get-block-children: Get page content blocks (with parallel processing)
  • API-retrieve-a-block: Get details about a specific block
  • API-retrieve-a-database: Get database information
  • API-retrieve-a-comment: Get comments on a page or block
  • API-retrieve-a-page-property: Get specific property information from a page
  • API-get-one-pager: NEW! Recursively retrieve a full Notion page with all its blocks, databases, and related content in a single call

By limiting to these 7 essential tools (compared to 15+ in the standard implementation), we ensure:

  1. Better performance in AI assistants like Cursor and Claude that have tool count limitations
  2. Reduced cognitive load for AI models when choosing appropriate tools
  3. Faster response times with fewer API options to consider
  4. Enhanced security through minimized API surface area

Automatic Content Exploration

The new API-get-one-pager tool provides a powerful way to explore Notion pages without requiring multiple API calls:

  • Recursive retrieval: Automatically traverses the entire page structure including nested blocks
  • Parallel processing: Fetches multiple blocks and their children simultaneously for maximum performance
  • Intelligent caching: Stores retrieved data to minimize redundant API calls
  • Comprehensive content: Includes pages, blocks, databases, comments, and detailed property information
  • Customizable depth: Control the level of recursion to balance between detail and performance

Using One Pager Tool

{
  "page_id": "YOUR_PAGE_ID",
  "maxDepth": 5,               // Optional: Maximum recursion depth (default: 5)
  "includeDatabases": true,    // Optional: Include linked databases (default: true)
  "includeComments": true,     // Optional: Include comments (default: true)
  "includeProperties": true    // Optional: Include detailed page properties (default: true)
}

This automatic exploration capability is especially useful for AI assistants that need to understand the entire content of a Notion page without making dozens of separate API calls, resulting in much faster and more efficient responses.

Asynchronous Processing

The server implements advanced parallel processing techniques for handling large Notion documents:

  • Multiple requests are batched and processed concurrently
  • Pagination is handled automatically for block children
  • Results are efficiently aggregated before being returned
  • Console logging provides visibility into the process without affecting response format

Examples

  1. Using the following instruction:
Get the content of page 1a6b35e6e67f802fa7e1d27686f017f2

The AI will retrieve the page details efficiently with parallel processing of block content.

  1. Using database information:
Get the structure of database 8a6b35e6e67f802fa7e1d27686f017f2

Development

Build:

pnpm build

Execute:

pnpm dev

License

MIT

AI Assistant Performance Benefits

Modern AI assistants like Cursor and Claude have limitations on the number of tools they can effectively handle:

  • Most models may not respect more than 40 tools in total
  • Too many tools can degrade overall performance and reasoning capabilities
  • Complex tool sets increase response latency and decision-making difficulty

This read-only implementation deliberately reduces the Notion API surface to address these limitations while preserving all essential functionality. The result is:

  • Faster and more reliable responses from AI assistants
  • Improved accuracy when interacting with Notion content
  • Better overall performance through focused API design

Installation

TypingMind
Prerequisites:

Node.js 18+

{
  "mcpServers": {
    "notionApi": {
      "command": "npx",
      "args": [
        "-y",
        "notion-readonly-mcp-server"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
      }
    }
  }
}

Available Tools

  • API-get-block-children

    Retrieve block children

  • API-retrieve-a-page

    Retrieve a page

  • API-retrieve-a-block

    Retrieve a block

  • API-retrieve-a-database

    Retrieve a database

  • API-retrieve-a-comment

    Retrieve comments

  • API-retrieve-a-page-property

    Retrieve a page property item

  • API-get-one-pager

    Recursively retrieve a full Notion page with all its blocks, databases, and related content

  • API-get-background-result

    Retrieve the result of a background processing request

Use Notion ReadOnly MCP with multiple AI models

TypingMind connects MCP tools at the workspace level, so once Notion ReadOnly is connected, you can use it with different AI models in TypingMind instead of setting it up separately for each model. This MCP runs locally through the TypingMind MCP connector on your device.

Setup guide to use the local connector

Use this when the MCP server needs access to local files, apps, or private resources on your computer.

1

Open the MCP settings

In TypingMind, go to Settings, Advanced Settings, then Model Context Protocol and choose Setup Connector.

  1. Open TypingMind in your browser.
  2. Click the Settings icon.
  3. Go to Advanced Settings.
  4. Open the Model Context Protocol section.
  5. Click Setup Connector and choose This Device.
TypingMind MCP connector setup screen with This Device selected
2

Run the connector command

Choose This Device, copy the command from TypingMind, and run it in Terminal. Keep the process running while you use MCP.

  1. Copy the setup command shown by TypingMind.
  2. Open Terminal on macOS or Windows Terminal on Windows.
  3. Paste and run the command.
  4. Approve the package install if Terminal asks you to proceed.
  5. Keep the Terminal window running while using MCP tools.
3

Add Notion ReadOnly as a server

When the connector status is Ready, click Edit Servers and paste the MCP server configuration.

  1. Wait until the connector status shows Ready.
  2. Click Edit Servers.
  3. Paste the Notion ReadOnly MCP server configuration.
  4. Save the server list.
  5. Refresh if you want to confirm the connector is still ready.
TypingMind MCP settings showing active server and Edit Servers button
{
  "mcpServers": {
    "notion-readonly": {
      "command": "npx",
      "args": [
        "-y",
        "notion-readonly-mcp-server"
      ]
    }
  }
}
4

Use it across models

Save the server list, open Plugins, enable the Notion ReadOnly MCP tools, then select any supported AI model in TypingMind and use the tools in chat or assign them to an AI agent.

  1. Open the Plugins page in TypingMind.
  2. Enable the Notion ReadOnly MCP tools.
  3. Start a chat and choose the AI model you want to use.
  4. Use the MCP tools in chat or assign them to an AI agent.
  5. Switch to another AI model whenever needed without reconnecting MCP.
TypingMind chat using enabled MCP tools with a selected AI model
Can you use Notion ReadOnly to help me with this task?
Notion ReadOnly
Sure. I read it.
Here is what I found using Notion ReadOnly.

Frequently asked questions

What is the Notion ReadOnly MCP server used for?

Notion ReadOnly is an MCP server that lets compatible AI clients connect to external tools and context. In TypingMind, you can add this MCP server once and make its tools available in your AI workspace.

Can I use Notion ReadOnly MCP with multiple AI models in TypingMind?

Yes. TypingMind connects MCP tools at the workspace level, so you can use Notion ReadOnly with different AI models such as Claude, ChatGPT, Gemini, or other models you have configured in TypingMind without setting up the MCP server separately for each model.

Why use Notion ReadOnly MCP with TypingMind?

TypingMind is one of the best frontends for LLM chat because it brings multiple AI models, prompts, plugins, AI agents, API keys, and MCP tools into one workspace. With Notion ReadOnly connected, you can use its MCP tools across your preferred models while keeping your chat workflow organized in TypingMind.

How do I connect Notion ReadOnly MCP to TypingMind?

Notion ReadOnly runs through the TypingMind local MCP connector. This is best when the MCP server needs access to local files, desktop apps, command-line tools, or private resources on your computer.

What tools does Notion ReadOnly MCP provide in TypingMind?

Notion ReadOnly exposes 8 MCP tools that can be enabled from the TypingMind Plugins page and used in chat or assigned to AI agents.

Do I need to share my API keys with TypingMind to use Notion ReadOnly MCP?

No. TypingMind is local-first and lets you keep your model providers, API keys, prompts, and MCP configuration under your control. If Notion ReadOnly requires authentication, add the required headers, OAuth settings, or local configuration for that MCP server when you create the connection.

Related MCP Servers

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇