Notion MCP Server
This server provides comprehensive CRUD operations and management functionality for Notion databases and pages through the Model Context Protocol, enabling integration with AI tools like Cursor and Claude.
Page (Record) Operations:
Create pages: Add new records to databases with customizable properties (title, rich text, status, dates, checkboxes, numbers, URLs, emails, phone numbers, people assignments, relations, etc.)
Retrieve pages: Get detailed information about specific pages including all properties, timestamps, and archive status
Update pages: Modify any property type on existing pages with support for all Notion property types
Delete pages: Archive records (soft delete that can be restored later)
Query pages: Search and filter records using complex criteria with AND/OR logic, multi-field sorting, and pagination for large datasets
Database Management:
List databases: Discover all accessible databases with their IDs, titles, and archive status
Get database: Retrieve detailed information including schema and property definitions
Update database: Modify database title and schema (add/modify/delete property columns)
Advanced Features:
Complex filtering with Notion's filter syntax (equals, contains, date ranges, checkbox states, etc.)
Multi-field sorting in ascending/descending order
Cursor-based pagination (up to 100 records per request)
Statistical information retrieval and batch processing
Enterprise-ready architecture built with DDD/TDD principles, TypeScript, and Docker deployment
Provides comprehensive CRUD operations for Notion databases and pages, including creating, updating, and deleting records, querying with filters and sorting, managing database schemas, and retrieving statistics from Notion workspaces.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Notion MCP Server find pages in my tasks database where status is 'in progress'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Notion MCP Server
Notion API連携を行うMCP(Model Context Protocol)サーバー。CursorやClaudeと連携し、NotionのデータベースへのCRUD操作を可能にします。
特徴
DDD(ドメイン駆動設計): 保守性の高いアーキテクチャ
TDD(テスト駆動開発): 高品質なコード
TypeScript: 型安全な実装
Notion API統合: Notion APIの全般的な機能をサポート
Docker対応: 環境構築不要で即座に利用可能
Related MCP server: Notion MCP Server
主な機能
ページ(レコード)操作
✅ ページ作成: データベースに新しいレコードを追加
✅ ページ取得: 指定したIDのレコードを取得
✅ ページ更新: レコードの各項目(プロパティ)を個別または一括更新
テキスト、セレクト、マルチセレクト、日付、チェックボックス、数値、URL、メールアドレス、電話番号、ユーザー、関連ページなど、全てのプロパティタイプに対応
✅ ページ削除: レコードをアーカイブ(削除)
✅ ページクエリ: フィルター・ソート条件でレコードを検索
データベース操作
✅ データベース取得: 指定したIDのデータベース情報を取得
✅ データベース一覧: アクセス可能なデータベースを一覧表示
✅ データベース更新: データベースのタイトルやスキーマを更新
高度な機能
🔄 ページネーション: 大量データの自動ページング処理
🔍 フィルタリング: 条件に基づく柔軟な検索
📊 ソート: 複数条件による並び替え
📈 統計情報: データベースの統計取得
アーキテクチャ
src/
├── domain/ # ドメイン層(ビジネスロジック)
│ ├── entities/ # エンティティ
│ ├── repositories/ # リポジトリインターフェース
│ ├── services/ # ドメインサービス
│ └── value-objects/ # 値オブジェクト
├── infrastructure/ # インフラ層(外部システム連携)
│ ├── notion/ # Notion APIクライアント
│ └── repositories/ # リポジトリ実装
├── application/ # アプリケーション層(ユースケース)
│ └── use-cases/ # ビジネスユースケース
├── presentation/ # プレゼンテーション層(入出力)
│ └── mcp/ # MCPサーバー実装
└── shared/ # 共有コードクイックスタート(Docker使用)🐳
最も簡単な方法はDockerを使用することです:
# Docker Hubから取得
docker pull kazuyaoda/notion-mcp:latest
# 実行
docker run -it \
-e NOTION_API_KEY=your_notion_api_key \
kazuyaoda/notion-mcp:latestまたは、スクリプトを使用:
export NOTION_API_KEY=your_notion_api_key
./scripts/docker-run.sh詳細は DOCKER.md を参照してください。
ローカル開発セットアップ
# 依存関係のインストール
npm install
# ビルド
npm run build
# テスト実行
npm test
# 開発モード
npm run dev設定
環境変数 NOTION_API_KEY にNotion APIキーを設定してください。
export NOTION_API_KEY=your_notion_api_keyCursor/Claudeでの使用方法
オプション1: Docker経由(推奨)
MCP設定ファイルに以下を追加:
{
"mcpServers": {
"notion": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"NOTION_API_KEY=your_notion_api_key",
"kazuyaoda/notion-mcp:latest"
]
}
}
}オプション2: ローカル実行
{
"mcpServers": {
"notion": {
"command": "node",
"args": ["/path/to/notion-mcp/dist/index.js"],
"env": {
"NOTION_API_KEY": "your_notion_api_key"
}
}
}
}機能
✅ ページの作成、取得、更新、削除
✅ データベースの取得と更新
✅ 高度なクエリ(フィルター、ソート、ページネーション)
✅ 統計情報の取得
✅ エラーハンドリング
ドキュメント
ARCHITECTURE.md - アーキテクチャの詳細
DOCKER.md - Docker使用ガイド
EXAMPLES.md - 使用例
INTEGRATION_TEST.md - 統合テストガイド
SECURITY.md - セキュリティガイド
QUICK_START.md - クイック公開ガイド
開発
テスト
# 全テスト実行
npm test
# カバレッジ付き
npm run test:coverage
# watch モード
npm run test:watchDockerビルド
# 基本ビルド
docker build -t notion-mcp:latest .
# マルチプラットフォームビルド
./scripts/docker-build.sh --multi-platform
# ビルドしてDocker Hubにプッシュ
./scripts/docker-build.sh --push --username kazuyaodaライセンス
MIT
Available Tools
8 toolscreate_pageA
Creates a new page (record) in a Notion database. Use this to add new entries such as tasks, projects, notes, etc. to any database. You can set properties like title, status, date, assignee, and more when creating the page.
Inputs: databaseId (required), properties (required).
delete_pageA
Deletes (archives) a Notion page (database record). In Notion, deletion is actually an archive operation and can be restored later. Use this to organize completed tasks, finished projects, etc.
Inputs: pageId (required).
get_databaseA
Retrieves detailed information about a specific Notion database by its ID. Returns database title, schema (property definitions), creation time, last edited time, and more. Use this to understand database structure.
Inputs: databaseId (required).
get_pageA
Retrieves detailed information about a specific Notion page (database record) by its ID. Returns all properties (fields), creation time, last edited time, archive status, and more.
Inputs: pageId (required).
list_databasesA
Lists all Notion databases accessible to the integration. Returns each database's ID, title, creation time, and archive status. Use this to discover available databases.
Inputs: no named parameters.
query_pagesB
Queries and retrieves pages (records) from a Notion database. Supports filtering and sorting. Examples: "tasks with status In Progress", "projects due this week", "tasks assigned to me". Retrieve pages matching specific conditions.
Inputs: databaseId (required), filter, sorts, startCursor, +1 more.
update_databaseA
Updates the database itself (not individual records). Can change database title or update schema (add/modify/delete properties/columns). Note: To update individual records, use update_page instead.
Inputs: databaseId (required), title, schema.
update_pageA
Updates properties (fields) of a Notion page (database record). Supports ALL property types: title, status, date, checkbox, number, select, multi-select, URL, email, phone number, people, relations, and more. You can update individual properties or multiple properties simultaneously. Examples: change status to "Completed", update progress to 80%, set deadline to next Friday, change assignee, etc.
Inputs: pageId (required), properties (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 8 tools
Each tool has a clearly distinct purpose with no overlap: create_page and delete_page handle page lifecycle, get_database and get_page retrieve specific resources, list_databases and query_pages provide listing/querying capabilities, and update_database and update_page target database vs. page updates. The descriptions explicitly differentiate tools like update_database (for schema) vs. update_page (for record properties).
All tools follow a consistent verb_noun pattern (e.g., create_page, delete_page, get_database, list_databases, query_pages, update_database, update_page). The naming is uniform throughout, using snake_case and clear action verbs aligned with the resource type, making the set predictable and easy to navigate.
With 8 tools, this server is well-scoped for managing Notion databases and pages. It covers core operations (CRUD, querying, listing) without being overly sparse or bloated. Each tool serves a distinct and necessary function in the domain, making the count appropriate for the server's purpose.
The tool set provides complete CRUD/lifecycle coverage for Notion databases and pages: create_page, get_page, update_page, and delete_page handle page operations; get_database, list_databases, and update_database manage databases; and query_pages enables filtering. There are no obvious gaps, supporting full agent workflows from discovery to modification.
Related MCP Connectors
Hosted Notion MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Query 40 databases from Claude, ChatGPT, or Cursor — on any device. Read-only, encrypted, audited.
Hosted PostgreSQL MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Hosted Airtable MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables interaction with Notion workspaces through the Notion API. Provides tools to search, read, create, and update Notion pages and databases with real-time synchronization.5,456 npmMIT
- AlicenseBqualityDmaintenanceEnables interaction with Notion workspaces through the Notion API. Supports creating, retrieving, and updating Notion pages and their properties, allowing users to manage Notion content through natural language.4MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with Notion workspaces through the Notion API. Supports searching, reading, creating pages, and querying databases with filters and sorting capabilities.5,456 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables interaction with Notion databases and pages via the Notion API. Allows searching, reading, and writing to Notion through natural language.MIT