notion-api
Notion API for workspace automation including databases, pages, blocks, query/filter syntax, and integration patterns
Best use case
notion-api is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Notion API for workspace automation including databases, pages, blocks, query/filter syntax, and integration patterns
Teams using notion-api should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/notion-api/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How notion-api Compares
| Feature / Agent | notion-api | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Notion API for workspace automation including databases, pages, blocks, query/filter syntax, and integration patterns
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Notion Api
## When to Use This Skill
### USE Notion API when:
- Automating database entries and updates
- Building custom dashboards from Notion data
- Syncing data between Notion and external systems
- Creating pages programmatically from templates
- Querying databases with complex filters
- Building integrations with other productivity tools
- Generating reports from Notion databases
- Implementing workflow automations
### DON'T USE Notion API when:
- Need real-time sync (API has rate limits)
- Building chat/messaging features (use Slack API)
- Need file storage solution (use dedicated storage)
- Simple task management only (use Todoist API)
- Need offline-first solution (use Obsidian)
- Require sub-second response times
## Prerequisites
### Create Integration
```markdown
1. Go to https://www.notion.so/my-integrations
2. Click "New integration"
3. Name: "My Integration"
4. Select workspace
5. Set capabilities (Read/Write content, etc.)
6. Copy the "Internal Integration Token"
```
### Connect Integration to Pages
```markdown
1. Open the Notion page/database you want to access
2. Click "..." menu (top right)
3. Click "Connections" > "Connect to" > Your integration
4. Integration can now access this page and children
```
### Environment Setup
```bash
# Set environment variable
export NOTION_API_KEY="secret_xxxxxxxxxxxxxxxxxxxxx"
# Verify connection
curl -s "https://api.notion.com/v1/users/me" \
-H "Authorization: Bearer $NOTION_API_KEY" \
-H "Notion-Version: 2022-06-28" | jq
```
### Python SDK Installation
```bash
# Install official Python client
pip install notion-client
# Or with uv
uv pip install notion-client
# Additional dependencies
pip install python-dotenv requests
```
### Verify Setup
```python
from notion_client import Client
import os
notion = Client(auth=os.environ["NOTION_API_KEY"])
# Test connection
me = notion.users.me()
print(f"Connected as: {me['name']}")
# List accessible databases
databases = notion.search(filter={"property": "object", "value": "database"})
print(f"Found {len(databases['results'])} databases")
```
## Version History
| Version | Date | Changes |
|---------|------|---------|
| 1.0.0 | 2025-01-17 | Initial release with comprehensive Notion API coverage |
## Resources
- [Notion API Documentation](https://developers.notion.com/)
- [API Reference](https://developers.notion.com/reference/intro)
- [Python SDK](https://github.com/ramnes/notion-sdk-py)
- [JavaScript SDK](https://github.com/makenotion/notion-sdk-js)
- [Integration Gallery](https://www.notion.so/integrations)
- [API Changelog](https://developers.notion.com/changelog)
---
*This skill enables powerful workspace automation through Notion's comprehensive API, supporting databases, pages, blocks, queries, and integration patterns.*
## Sub-Skills
- [1. Database Operations](1-database-operations/SKILL.md)
- [2. Query Databases](2-query-databases/SKILL.md)
- [3. Filter Syntax Reference](3-filter-syntax-reference/SKILL.md)
- [4. Page Operations](4-page-operations/SKILL.md)
- [5. Block Operations](5-block-operations/SKILL.md)
- [6. Rich Text Formatting (+1)](6-rich-text-formatting/SKILL.md)
- [8. Search API](8-search-api/SKILL.md)
- [Integration with Slack (+1)](integration-with-slack/SKILL.md)
- [1. Rate Limiting (+3)](1-rate-limiting/SKILL.md)
- [Common Issues](common-issues/SKILL.md)
## Sub-Skills
- [Example 1: Task Management System (+2)](example-1-task-management-system/SKILL.md)Related Skills
notion
Notion API for creating and managing pages, databases, and blocks via curl. Search, create, update, and query Notion workspaces directly from the terminal.
activepieces-integration-with-notion-and-slack
Sub-skill of activepieces: Integration with Notion and Slack.
obsidian-integration-with-notion-export
Sub-skill of obsidian: Integration with Notion Export.
notion-api-integration-with-slack
Sub-skill of notion-api: Integration with Slack (+1).
notion-api-example-1-task-management-system
Sub-skill of notion-api: Example 1: Task Management System (+2).
notion-api-8-search-api
Sub-skill of notion-api: 8. Search API.
notion-api-6-rich-text-formatting
Sub-skill of notion-api: 6. Rich Text Formatting (+1).
notion-api-5-block-operations
Sub-skill of notion-api: 5. Block Operations.
notion-api-4-page-operations
Sub-skill of notion-api: 4. Page Operations.
notion-api-3-filter-syntax-reference
Sub-skill of notion-api: 3. Filter Syntax Reference.
notion-api-2-query-databases
Sub-skill of notion-api: 2. Query Databases.
notion-api-1-database-operations
Sub-skill of notion-api: 1. Database Operations.