Skip to content

Feature Request: Selective Tool Loading for Notion MCP #111

@antonlvovych

Description

@antonlvovych

Summary

Add environment variables to enable/disable specific Notion MCP tools at runtime for better security, performance, and reduced context size.

Motivation

Currently all tools load by default. Teams often need only a subset - e.g., read-only agents only need search and fetch. Selective loading reduces token usage, improves security via least-privilege, and simplifies debugging.

Implementation

Environment Variables:

# Allow-list (only these tools load)
ENABLED_TOOLS=search,fetch,create-pages

# or

# Deny-list (everything except these)  
DISABLED_TOOLS=move-pages,duplicate-page,create-comment

Example Usage

Claude Desktop:

{
  "mcpServers": {
    "notion": {
      "command": "npx",
      "args": ["-y", "@notionhq/notion-mcp-server"],
      "env": {
        "NOTION_TOKEN": "ntn_****",
        "ENABLED_TOOLS": "search,fetch,create-pages"
      }
    }
  }
}

Docker:

docker run -e NOTION_TOKEN=ntn_**** \
  -e DISABLED_TOOLS=move-pages,duplicate-page \
  mcp/notion

Benefits

  • Smaller schemas = faster discovery + lower token costs
  • Least-privilege security for specific workflows
  • Easier debugging with minimal tool surface

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions