ldraney-notion-mcp 0.1.1__tar.gz → 0.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/PKG-INFO +1 -1
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/pyproject.toml +4 -1
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/PKG-INFO +1 -1
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/SOURCES.txt +1 -0
- ldraney_notion_mcp-0.1.3/src/ldraney_notion_mcp.egg-info/entry_points.txt +2 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/server.py +5 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/blocks.py +5 -1
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/comments.py +4 -2
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/databases.py +12 -2
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/pages.py +10 -4
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/search.py +4 -2
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/README.md +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/setup.cfg +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/dependency_links.txt +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/requires.txt +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/top_level.txt +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/__init__.py +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/__main__.py +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/__init__.py +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/notion_mcp/tools/users.py +0 -0
- {ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/tests/test_tools.py +0 -0
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "ldraney-notion-mcp"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.3"
|
|
8
8
|
description = "MCP server wrapping the Notion Python SDK (v2025-09-03)"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
@@ -14,6 +14,9 @@ dependencies = [
|
|
|
14
14
|
"ldraney-notion-sdk>=0.1.0",
|
|
15
15
|
]
|
|
16
16
|
|
|
17
|
+
[project.scripts]
|
|
18
|
+
ldraney-notion-mcp = "notion_mcp.server:main"
|
|
19
|
+
|
|
17
20
|
[project.optional-dependencies]
|
|
18
21
|
dev = [
|
|
19
22
|
"pytest>=7.0",
|
{ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/SOURCES.txt
RENAMED
|
@@ -3,6 +3,7 @@ pyproject.toml
|
|
|
3
3
|
src/ldraney_notion_mcp.egg-info/PKG-INFO
|
|
4
4
|
src/ldraney_notion_mcp.egg-info/SOURCES.txt
|
|
5
5
|
src/ldraney_notion_mcp.egg-info/dependency_links.txt
|
|
6
|
+
src/ldraney_notion_mcp.egg-info/entry_points.txt
|
|
6
7
|
src/ldraney_notion_mcp.egg-info/requires.txt
|
|
7
8
|
src/ldraney_notion_mcp.egg-info/top_level.txt
|
|
8
9
|
src/notion_mcp/__init__.py
|
|
@@ -50,6 +50,8 @@ def get_block_children(
|
|
|
50
50
|
def append_block_children(block_id: str, children: str) -> str:
|
|
51
51
|
"""Append child blocks to a Notion block.
|
|
52
52
|
|
|
53
|
+
IMPORTANT: The children parameter must be passed as a JSON-encoded string, NOT as an object.
|
|
54
|
+
|
|
53
55
|
Args:
|
|
54
56
|
block_id: The UUID of the parent block to append children to.
|
|
55
57
|
children: JSON string for a list of block objects to append.
|
|
@@ -71,10 +73,12 @@ def update_block(
|
|
|
71
73
|
) -> str:
|
|
72
74
|
"""Update a Notion block.
|
|
73
75
|
|
|
76
|
+
IMPORTANT: The content parameter must be passed as a JSON-encoded string, NOT as an object.
|
|
77
|
+
|
|
74
78
|
Args:
|
|
75
79
|
block_id: The UUID of the block to update.
|
|
76
80
|
content: JSON string of block properties to update. The keys depend
|
|
77
|
-
on the block type (e.g. {"paragraph": {"rich_text": [...]}}).
|
|
81
|
+
on the block type (e.g. '{"paragraph": {"rich_text": [...]}}').
|
|
78
82
|
"""
|
|
79
83
|
try:
|
|
80
84
|
kwargs: dict[str, Any] = {}
|
|
@@ -15,11 +15,13 @@ def create_comment(
|
|
|
15
15
|
) -> str:
|
|
16
16
|
"""Create a comment on a Notion page or block.
|
|
17
17
|
|
|
18
|
+
IMPORTANT: parent and rich_text must be passed as JSON-encoded strings, NOT as objects.
|
|
19
|
+
|
|
18
20
|
Args:
|
|
19
21
|
parent: JSON string for the parent object,
|
|
20
|
-
e.g. {"page_id": "..."}.
|
|
22
|
+
e.g. '{"page_id": "..."}'.
|
|
21
23
|
rich_text: JSON string for the rich-text content array,
|
|
22
|
-
e.g. [{"type": "text", "text": {"content": "Hello!"}}].
|
|
24
|
+
e.g. '[{"type": "text", "text": {"content": "Hello!"}}]'.
|
|
23
25
|
discussion_id: Optional UUID of an existing discussion thread
|
|
24
26
|
to reply to. Omit to start a new top-level comment.
|
|
25
27
|
"""
|
|
@@ -24,10 +24,12 @@ def create_database(
|
|
|
24
24
|
In Notion API v2025-09-03, database properties live on data sources.
|
|
25
25
|
Pass properties inside initial_data_source.properties.
|
|
26
26
|
|
|
27
|
+
IMPORTANT: All structured parameters must be passed as JSON-encoded strings, NOT as objects.
|
|
28
|
+
|
|
27
29
|
Args:
|
|
28
|
-
parent: JSON string for the parent object, e.g. {"type": "page_id", "page_id": "..."}.
|
|
30
|
+
parent: JSON string for the parent object, e.g. '{"type": "page_id", "page_id": "..."}'.
|
|
29
31
|
title: JSON string for the title rich-text array,
|
|
30
|
-
e.g. [{"type": "text", "text": {"content": "My DB"}}].
|
|
32
|
+
e.g. '[{"type": "text", "text": {"content": "My DB"}}]'.
|
|
31
33
|
initial_data_source: Optional JSON string for the initial data source
|
|
32
34
|
configuration including properties.
|
|
33
35
|
"""
|
|
@@ -69,6 +71,8 @@ def update_database(
|
|
|
69
71
|
) -> str:
|
|
70
72
|
"""Update a Notion database.
|
|
71
73
|
|
|
74
|
+
IMPORTANT: All structured parameters must be passed as JSON-encoded strings, NOT as objects.
|
|
75
|
+
|
|
72
76
|
Args:
|
|
73
77
|
database_id: The UUID of the database to update.
|
|
74
78
|
title: Optional JSON string for the new title rich-text array.
|
|
@@ -119,6 +123,8 @@ def query_database(
|
|
|
119
123
|
Automatically resolves the first data source and queries it.
|
|
120
124
|
If you already know the data source ID, use query_data_source instead.
|
|
121
125
|
|
|
126
|
+
IMPORTANT: filter and sorts must be passed as JSON-encoded strings, NOT as objects.
|
|
127
|
+
|
|
122
128
|
Args:
|
|
123
129
|
database_id: The UUID of the database to query.
|
|
124
130
|
filter: Optional JSON string for a filter object.
|
|
@@ -165,6 +171,8 @@ def update_data_source(
|
|
|
165
171
|
) -> str:
|
|
166
172
|
"""Update a Notion data source.
|
|
167
173
|
|
|
174
|
+
IMPORTANT: The properties parameter must be passed as a JSON-encoded string, NOT as an object.
|
|
175
|
+
|
|
168
176
|
Args:
|
|
169
177
|
data_source_id: The UUID of the data source to update.
|
|
170
178
|
properties: Optional JSON string for properties to update.
|
|
@@ -189,6 +197,8 @@ def query_data_source(
|
|
|
189
197
|
) -> str:
|
|
190
198
|
"""Query rows in a Notion data source.
|
|
191
199
|
|
|
200
|
+
IMPORTANT: filter and sorts must be passed as JSON-encoded strings, NOT as objects.
|
|
201
|
+
|
|
192
202
|
Args:
|
|
193
203
|
data_source_id: The UUID of the data source to query.
|
|
194
204
|
filter: Optional JSON string for a filter object.
|
|
@@ -17,14 +17,16 @@ def create_page(
|
|
|
17
17
|
) -> str:
|
|
18
18
|
"""Create a new Notion page.
|
|
19
19
|
|
|
20
|
+
IMPORTANT: All structured parameters must be passed as JSON-encoded strings, NOT as objects.
|
|
21
|
+
|
|
20
22
|
Args:
|
|
21
|
-
parent: JSON string for the parent object, e.g. {"type": "page_id", "page_id": "..."}.
|
|
23
|
+
parent: JSON string for the parent object, e.g. '{"type": "page_id", "page_id": "..."}'.
|
|
22
24
|
properties: JSON string for the page properties mapping.
|
|
23
25
|
children: Optional JSON string for a list of block children to append.
|
|
24
26
|
Cannot be used together with template.
|
|
25
27
|
template: Optional JSON string for a data-source template, e.g.
|
|
26
|
-
{"type": "none"}, {"type": "default"}, or
|
|
27
|
-
{"type": "template_id", "template_id": "<uuid>"}.
|
|
28
|
+
'{"type": "none"}', '{"type": "default"}', or
|
|
29
|
+
'{"type": "template_id", "template_id": "<uuid>"}'.
|
|
28
30
|
"""
|
|
29
31
|
try:
|
|
30
32
|
result = get_client().create_page(
|
|
@@ -62,6 +64,8 @@ def update_page(
|
|
|
62
64
|
) -> str:
|
|
63
65
|
"""Update a Notion page's properties, icon, or cover.
|
|
64
66
|
|
|
67
|
+
IMPORTANT: All structured parameters must be passed as JSON-encoded strings, NOT as objects.
|
|
68
|
+
|
|
65
69
|
Args:
|
|
66
70
|
page_id: The UUID of the page to update.
|
|
67
71
|
properties: Optional JSON string of properties to update.
|
|
@@ -106,10 +110,12 @@ def archive_page(page_id: str) -> str:
|
|
|
106
110
|
def move_page(page_id: str, parent: str) -> str:
|
|
107
111
|
"""Move a Notion page to a new parent.
|
|
108
112
|
|
|
113
|
+
IMPORTANT: The parent parameter must be passed as a JSON-encoded string, NOT as an object.
|
|
114
|
+
|
|
109
115
|
Args:
|
|
110
116
|
page_id: The UUID of the page to move.
|
|
111
117
|
parent: JSON string for the new parent object,
|
|
112
|
-
e.g. {"type": "page_id", "page_id": "..."}.
|
|
118
|
+
e.g. '{"type": "page_id", "page_id": "..."}'.
|
|
113
119
|
"""
|
|
114
120
|
try:
|
|
115
121
|
result = get_client().move_page(
|
|
@@ -17,12 +17,14 @@ def search(
|
|
|
17
17
|
) -> str:
|
|
18
18
|
"""Search Notion pages and databases.
|
|
19
19
|
|
|
20
|
+
IMPORTANT: filter and sort must be passed as JSON-encoded strings, NOT as objects.
|
|
21
|
+
|
|
20
22
|
Args:
|
|
21
23
|
query: Optional text query to search for.
|
|
22
24
|
filter: Optional JSON string for a filter object,
|
|
23
|
-
e.g. {"value": "page", "property": "object"}.
|
|
25
|
+
e.g. '{"value": "page", "property": "object"}'.
|
|
24
26
|
sort: Optional JSON string for a sort object,
|
|
25
|
-
e.g. {"direction": "ascending", "timestamp": "last_edited_time"}.
|
|
27
|
+
e.g. '{"direction": "ascending", "timestamp": "last_edited_time"}'.
|
|
26
28
|
start_cursor: Optional cursor for pagination.
|
|
27
29
|
page_size: Optional number of results per page.
|
|
28
30
|
"""
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/requires.txt
RENAMED
|
File without changes
|
{ldraney_notion_mcp-0.1.1 → ldraney_notion_mcp-0.1.3}/src/ldraney_notion_mcp.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|