Token导航 LogoToken导航TokenDH.com
研究检索需要联网clawhub未标认证来源可访问clear审计通过

openclaw-notion-skillOpenClaw Notion 技能

Agent Skill

用于处理 Notion 页面、数据库、工作区内容和结构化记录。它适合让 Agent 查询知识库、整理页面内容、创建记录或把外部信息同步到 Notion。使用时需要确认集成是否已被授权到目标页面或数据库,并区分读取、追加和覆盖更新;涉及批量写入或修改数据库属性时,应先核对字段名称、属性类型和目标页面。

总安装

87,222

周安装

3,563

GitHub Stars

4

下载量

28,219
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:openclaw-notion-skill(OpenClaw Notion 技能)
来源仓库:https://github.com/moikapy/openclaw-notion-skill
安装命令:
openclaw skills install openclaw-notion-skill
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install openclaw-notion-skill

简介

与 Notion 工作区集成以读取页面、查询数据库、创建条目和管理内容。非常适合知识库、项目跟踪、内容日历、CRM 和协作文档。适用于您与集成明确共享的任何概念页面或数据库。

SKILL.md

name
notion
version
0.1.0
description
Integrate with Notion workspaces to read pages, query databases, create entries, and manage content. Perfect for knowledge bases, project tracking, content calendars, CRMs, and collaborative documentation. Works with any Notion page or database you explicitly share with the integration.

Notion Integration

Connect your Notion workspace to OpenClaw for seamless knowledge management and project tracking.

When to Use This Skill

Use Notion when the user wants to:

  • Add items to a database (backlog, todos, tracking)
  • Create new pages in a database or as children of existing pages
  • Query/search their Notion workspace for information
  • Update existing pages (status, notes, properties)
  • Read page content or database entries

Setup

1. Create Notion Integration

  1. Go to notion.so/my-integrations
  2. Click New integration
  3. Name it (e.g., "OpenClaw")
  4. Select your workspace
  5. Copy the Internal Integration Token (starts with secret_)
  6. Save this token securely in OpenClaw config or environment: NOTION_TOKEN=secret_...

2. Share Pages with Integration

Important: Notion integrations have NO access by default. You must explicitly share:

  1. Go to any page or database in Notion
  2. Click ShareAdd connections
  3. Select your "OpenClaw" integration
  4. The skill can now read/write to that specific page/database

3. Get Database/Page IDs

From URL:

  • Database: https://www.notion.so/workspace/XXXXXXXX?v=... → ID is XXXXXXXX (32 chars)
  • Page: https://www.notion.so/workspace/XXXXXXXX → ID is XXXXXXXX

Note: Remove hyphens when using IDs. Use the 32-character string.

Core Operations

Query Database

Retrieve entries from any database you've shared.

// Using the Notion skill via exec
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js query-database ${databaseId}`
});

// With filters (example: status = "In Progress")
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js query-database ${databaseId} --filter '{"property":"Status","select":{"equals":"In Progress"}}'`
});

Returns: Array of pages with properties as configured in your database.

Add Database Entry

Create a new row in a database.

// Add entry with multiple properties
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js add-entry ${databaseId} \
    --title "My New Content Idea" \
    --properties '${JSON.stringify({
      "Status": { "select": { "name": "Idea" } },
      "Platform": { "multi_select": [{ "name": "X/Twitter" }] },
      "Tags": { "multi_select": [{ "name": "3D Printing" }, { "name": "AI" }] },
      "Priority": { "select": { "name": "High" } }
    })}'`
});

Get Page Content

Read the content of any page (including database entries).

await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js get-page ${pageId}`
});

Returns: Page title, properties, and block content (text, headings, lists, etc.).

Update Page

Modify properties or append content to an existing page.

// Update properties
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js update-page ${pageId} \
    --properties '${JSON.stringify({
      "Status": { "select": { "name": "In Progress" } }
    })}'`
});

// Append content blocks
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js append-body ${pageId} \
    --text "Research Notes" --type h2`
});

Search Notion

Find pages across your shared workspace.

await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js search "content ideas"`
});

Common Use Cases

Content Pipeline (Content Creator Workflow)

Database Structure:

  • Title (title)
  • Status (select: Idea → Draft → Scheduled → Posted)
  • Platform (multi_select: X/Twitter, YouTube, MakerWorld, Blog)
  • Publish Date (date)
  • Tags (multi_select)
  • Draft Content (rich_text)

OpenClaw Integration:

// Research scout adds findings to Notion
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js add-entry ${contentDbId} \
    --title "New 3D Print Technique" \
    --properties '${JSON.stringify({
      "Status": { "select": { "name": "Idea" } },
      "Platform": { "multi_select": [{ "name": "YouTube" }] },
      "Tags": { "multi_select": [{ "name": "3D Printing" }] }
    })}'`
});

// Later: Update when drafting
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js update-page ${entryId} \
    --properties '${JSON.stringify({
      "Status": { "select": { "name": "Draft" } },
      "Draft Content": { "rich_text": [{ "text": { "content": "Draft text here..." } }] }
    })}'`
});

Project Management (Solo Entrepreneur)

Database Structure:

  • Name (title)
  • Status (select: Not Started → In Progress → Blocked → Done)
  • Priority (select: Low → Medium → High → Critical)
  • Due Date (date)
  • Estimated Hours (number)
  • Actual Hours (number)
  • Links (url)
  • Notes (rich_text)

Weekly Review Integration:

// Query all "In Progress" projects
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js query-database ${projectsDbId} --filter '{"property":"Status","select":{"equals":"In Progress"}}'`
});

Customer/Quote CRM (3D Printing Business)

Database Structure:

  • Customer Name (title)
  • Status (select: Lead → Quote Sent → Ordered → Printing → Shipped)
  • Email (email)
  • Quote Value (number)
  • Filament Type (select)
  • Due Date (date)
  • Shopify Order ID (rich_text)

Shopify Integration:

// New order → create CRM entry
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js add-entry ${crmDbId} \
    --title "${customerName}" \
    --properties '${JSON.stringify({
      "Status": { "select": { "name": "Ordered" } },
      "Email": { "email": customerEmail },
      "Shopify Order ID": { "rich_text": [{ "text": { "content": orderId } }] }
    })}'`
});

Knowledge Base (Wiki Replacement for MEMORY.md)

Structure: Hub page with nested pages:

  • 🏠 Home (shared with integration)

- SOPs - Troubleshooting - Design Patterns - Resource Links

Query for quick reference:

// Search for "stringing" to find 3D print troubleshooting
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js search "stringing"`
});

Property Types Reference

When creating/updating database entries, use these property value formats:

// Title (always required for new pages)
{ "title": [{ "text": { "content": "Page Title" } }] }

// Select (single choice)
{ "select": { "name": "Option Name" } }

// Multi-select (multiple choices)
{ "multi_select": [{ "name": "Tag 1" }, { "name": "Tag 2" }] }

// Status (for new Status property type)
{ "status": { "name": "In progress" } }

// Text / Rich text
{ "rich_text": [{ "text": { "content": "Your text here" } }] }

// Number
{ "number": 42 }

// Date
{ "date": { "start": "2026-02-15" } }
{ "date": { "start": "2026-02-15T10:00:00", "end": "2026-02-15T12:00:00" } }

// Checkbox
{ "checkbox": true }

// Email
{ "email": "user@example.com" }

// URL
{ "url": "https://example.com" }

// Phone
{ "phone_number": "+1-555-123-4567" }

// Relation (link to another database entry)
{ "relation": [{ "id": "related-page-id-32chars" }] }

Security & Permissions

Critical Security Model:

  • ✅ Integration ONLY sees pages you explicitly share
  • ✅ You control access per page/database
  • ✅ Token stored securely in ~/.openclaw/.env (never in code)
  • ❌ Never commit NOTION_TOKEN to git
  • ❌ Integration cannot access private teamspaces or other users' private pages

Best Practices:

  1. Use a dedicated integration (don't reuse personal integrations)
  2. Share minimum necessary pages (granular > broad)
  3. Rotate token if compromised via Notion integration settings
  4. Review shared connections periodically

Environment Setup

Add to ~/.openclaw/.env:

NOTION_TOKEN=secret_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Or set per-command:

NOTION_TOKEN=secret_xxx node notion-cli.js ...

Error Handling

Common errors and fixes:

ErrorCauseFix
"API token is invalid"Wrong token or integration deletedCheck token at notion.so/my-integrations
"object_not_found"Page not shared with integrationShare page: Share → Add connections
"validation_error"Property format incorrectCheck property type in database
"rate_limited"Too many requestsAdd delay between requests

Quick Install (One Command)

cd ~/.agents/skills/notion
./install.sh

Manual install (if above fails):

cd ~/.agents/skills/notion
npm install

That's it! No build step required for the standalone version.

Quick Test

# After setting NOTION_TOKEN in ~/.openclaw/.env
node notion-cli.js test

Smart ID Resolution

Reference entries by Notion auto-ID (e.g., #3) or direct UUID.

By Notion ID (Recommended for Manual Use)

Use the number you see in your database's ID column:

# Get entry #3
node notion-cli.js get-page '#3' DATABASE_ID

# Add content to entry #3
node notion-cli.js append-body '#3' --database DATABASE_ID \
  --text "Research notes" --type h2

# Add bullet to entry #3
node notion-cli.js append-body '#3' --database DATABASE_ID \
  --text "Key finding" --type bullet

By Direct UUID (For Automation)

# Using full UUID from Notion URL
node notion-cli.js get-page 2fb3e4ac...
node notion-cli.js append-body 2fb3e4ac... \
  --text "Content" --type paragraph

Auto-detection: Starts with # = Notion ID lookup. 32-char hex = Direct UUID.

Pro Tip: Add an ID property (type: unique ID) to auto-number entries as #1, #2, #3...

Page Body Editing

Add rich content to page bodies, not just properties.

Append Content Blocks

# Add heading
node notion-cli.js append-body PAGE_ID --text "Research Summary" --type h2

# Add paragraph (default)
node notion-cli.js append-body PAGE_ID --text "Detailed findings go here..."

# Add bullet list item
node notion-cli.js append-body PAGE_ID --text "First key finding" --type bullet

# Add numbered list item
node notion-cli.js append-body PAGE_ID --text "Step one description" --type numbered

# Add TODO checkbox
node notion-cli.js append-body PAGE_ID --text "Create video script" --type todo

# Add quote
node notion-cli.js append-body PAGE_ID --text "Important quote from source" --type quote

# Add code block
node notion-cli.js append-body PAGE_ID --text "const result = optimizeSupports();" --type code --lang javascript

Supported Block Types

TypeDescriptionExample Use
paragraphRegular text (default)Descriptions, explanations
h1, h2, h3HeadingsSection organization
bulletBulleted listKey findings, features
numberedNumbered listStep-by-step instructions
todoCheckbox itemAction items, tasks
quoteBlockquoteSource citations
codeCode blockSnippets, commands
dividerHorizontal lineSection separation

Get Page with Body Content

# Get full page including formatted body
node notion-cli.js get-page PAGE_ID

Returns:

  • Page properties
  • Formatted body blocks (type + content preview)
  • Block count

Advanced: Raw JSON Blocks

For complex layouts, use raw Notion block JSON:

node notion-cli.js append-body PAGE_ID --blocks '[
  {"object":"block","type":"heading_2","heading_2":{"rich_text":[{"text":{"content":"Research Notes"}}]}},
  {"object":"block","type":"bulleted_list_item","bulleted_list_item":{"rich_text":[{"text":{"content":"Finding 1"}}]}},
  {"object":"block","type":"code","code":{"rich_text":[{"text":{"content":"console.log(1)"}}],"language":"javascript"}}
]'

Advanced: Webhook Sync

For bidirectional sync (Notion changes → OpenClaw):

  1. Set up Notion webhook integration (requires Notion partner account)
  2. Configure webhook endpoint to your OpenClaw Gateway
  3. Skill processes incoming webhooks and updates memory files

See references/webhooks.md for implementation details.


Need help? Check your Notion integration settings at https://www.notion.so/my-integrations

Using in OpenClaw

Quick Setup

# 1. Install
cd ~/.agents/skills/notion
npm install

# 2. Configure token
echo "NOTION_TOKEN=secret_xxxxxxxxxx" >> ~/.openclaw/.env

# 3. Test connection
node notion-cli.js test

From OpenClaw Agent

// Query database
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js query-database YOUR_DB_ID`
});

// Add entry
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js add-entry YOUR_DB_ID \\
    --title "New Content Idea" \\
    --properties '{"Status":{"select":{"name":"Idea"}}}'`
});

// Search
await exec({
  command: `node ~/.agents/skills/notion/notion-cli.js search "tree support"`
});

Cron Job Usage

Update your Research Topic Scout to push to Notion:

"message": "Research trends and add to Notion: 
  node ~/.agents/skills/notion/notion-cli.js add-entry DB_ID 
    --title '<title>' 
    --properties '{...,\"Platform\":{\"multi_select\":[{\"name\":\"X\"}]}}'"

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

82.74%
按下载量换算23,348

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

未展示

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills