npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@agentx-ai/notion-mcp-server

v1.1.0

Published

AgentX MCP server for Notion API with user-friendly environment variables

Readme

AgentX Notion MCP Server

(Folk from https://github.com/makenotion/notion-mcp-server)

Website

This project implements an MCP server for the Notion API with user-friendly environment variables.

mcp-demo

✨ Features

  • 🔧 User-friendly configuration - Simple environment variables instead of complex JSON
  • 🔄 Backward compatibility - Still supports legacy OPENAPI_MCP_HEADERS
  • 🚀 Easy setup - Just set NOTION_API_TOKEN and optionally NOTION_VERSION
  • 📚 Full Notion API support - All Notion API endpoints available
  • 🛡️ Secure - Proper authentication and error handling

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 (for example, you will not be able to delete databases via MCP), 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. Connecting content to integration:

Ensure relevant pages and databases are connected to your integration.

To do this, visit the Access tab in your internal integration settings. Edit access and select the pages you'd like to use. Integration Access tab

Edit integration access

Alternatively, you can grant page access individually. You'll need to visit the target page, and click on the 3 dots, and select "Connect to integration".

Adding Integration Token to Notion Connections

3. 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)

{
  "mcpServers": {
    "notionApi": {
      "command": "npx",
      "args": ["-y", "@agentx-ai/notion-mcp-server"],
      "env": {
        "NOTION_API_TOKEN": "ntn_****",
        "NOTION_VERSION": "2022-06-28"
      }
    }
  }
}

Note: NOTION_VERSION is optional and defaults to "2022-06-28" if not provided.

Using Docker:

There are two options for running the MCP server with Docker:

Option 1: Using the official Docker Hub image:

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

{
  "mcpServers": {
    "notionApi": {
      "command": "docker",
      "args": [
        "run",
        "--rm",
        "-i",
        "-e", "NOTION_API_TOKEN",
        "-e", "NOTION_VERSION",
        "mcp/notion"
      ],
      "env": {
        "NOTION_API_TOKEN": "ntn_****",
        "NOTION_VERSION": "2022-06-28"
      }
    }
  }
}

This approach:

  • Uses the official Docker Hub image
  • Uses simple environment variables instead of complex JSON
  • Provides a more user-friendly configuration method
Option 2: Building the Docker image locally:

You can also build and run the Docker image locally. First, build the Docker image:

docker-compose build

Then, add the following to your .cursor/mcp.json or claude_desktop_config.json:

{
  "mcpServers": {
    "notionApi": {
      "command": "docker",
      "args": [
        "run",
        "--rm",
        "-i",
        "-e",
        "NOTION_API_TOKEN=ntn_****",
        "-e",
        "NOTION_VERSION=2022-06-28",
        "notion-mcp-server"
      ]
    }
  }
}

Legacy Support: The old OPENAPI_MCP_HEADERS environment variable is still supported for backward compatibility, but the new approach is recommended for better user experience.

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

Copying your Integration token from the Configuration tab in the developer portal

Installing via Smithery

smithery badge

To install Notion API Server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @agentx-ai/notion-mcp-server --client claude

Examples

  1. Using the following instruction
Comment "Hello MCP" on page "Getting started"

AI will correctly plan two API calls, v1/search and v1/comments, to achieve the task

  1. Similarly, the following instruction will result in a new page named "Notion MCP" added to parent page "Development"
Add a page titled "Notion MCP" to page "Development"
  1. You may also reference content ID directly
Get the content of page 1a6b35e6e67f802fa7e1d27686f017f2

Development (test locally)

Build

npm run build

Install

npm install -g .

Test with modelcontextprotocol/inspector

npx @modelcontextprotocol/inspector notion-mcp-server

Click:

http://localhost:6274/?MCP_PROXY_AUTH_TOKEN=xxxxxxxxxx