Install
openclaw skills install notion-content-pipelineTwo-way markdown ↔ Notion sync for blog and content workflows. Use when: pushing local .md files to Notion for editing, pulling Notion edits back to local files, managing a content pipeline database with statuses (Seed → Draft → Review → Published), or tracking local file ↔ Notion page mappings. Supports batch push-all, per-file push/pull, and pipeline DB creation with Platform/Status/Hook properties.
openclaw skills install notion-content-pipelineLast used: 2026-03-24 Memory references: 2 Status: Active
Push local .md files to Notion and pull edits back. Track a content pipeline DB with
statuses (Seed → Draft → Review → Published).
| Database | ID |
|---|---|
| Content Pipeline DB (blog posts, n8n trigger) | 322eb552-581a-8111-8f6a-d042dd048ec8 |
| Tweet Pipeline DB (cron trigger) | 314c9a82-0734-81be-ac58-ddd878576cf0 |
Use the Content Pipeline DB ID when pushing blog posts via the blog-to-social pipeline (status: In Review → Approved).
Use this skill when:
.md draft to Notion for Nissan to review/edit in Notion UIDo NOT use this skill when:
curlbuffer-publisher skillBoundary with direct Notion API calls:
This skill wraps the Notion API with markdown conversion and sync-map tracking. Use it when you need the full sync workflow. For raw Notion API queries (e.g., fetching a database row, reading a page property), calling the API directly with curl or httpx is simpler and doesn't need this skill.
# CORRECT — use this 1Password item:
NOTION_API_KEY=$(op read "op://OpenClaw/bg2gpqhpta6an5n4prn2zzycya/credential")
# DO NOT use the old item (dead as of early 2026):
# op://OpenClaw/Notion API Key/credential ← this vault item is stale/deleted
API version header required: Notion-Version: 2022-06-28
scripts/notion_content_sync.py — push/pull individual files or all at oncescripts/create_pipeline_db.py — create a Notion database for content pipeline trackingscripts/pipeline_advance.py — full round-trip advance: pull → humanize → fact-check → push → status updateNOTION_API_KEY=secret_... # Notion integration token (from 1Password item above)
NOTION_PARENT_PAGE_ID=<uuid> # Parent page ID for sandbox + pipeline DB
NOTION_SYNC_MAP=~/.notion_sync_map.json # Where to store file ↔ page ID mapping
CONTENT_DIR=./content # Directory containing .md files
Or pass --sandbox-id and --sync-map as CLI flags.
# Push a single file to Notion
python3 scripts/notion_content_sync.py push content/my-post.md
# Push all .md files in content/
python3 scripts/notion_content_sync.py push-all
# Pull Notion edits back to local file
python3 scripts/notion_content_sync.py pull content/my-post.md
# List all tracked pages with Notion URLs
python3 scripts/notion_content_sync.py list
# Create the Content Pipeline database
python3 scripts/create_pipeline_db.py
Pushing content/my-post.md → Notion...
✅ Created page: "My Post Title"
Notion URL: https://www.notion.so/My-Post-Title-abc123def456...
Page ID: abc123de-f456-7890-abcd-ef1234567890
Sync map updated: content/my-post.md → abc123de-f456-7890-abcd-ef1234567890
If you see ✅ Created page with a Notion URL and the sync map updates, the push succeeded.
Overwrite (push to existing page):
Pushing content/my-post.md → Notion...
Archiving existing page abc123de-... (overwrite mode)
✅ Created page: "My Post Title" (fresh)
Notion URL: https://www.notion.so/My-Post-Title-xyz789...
Failure indicators:
401 Unauthorized → API key wrong or expired — check the 1Password item404 Not Found on parent page → NOTION_PARENT_PAGE_ID is wrong or the page was deleted400 Bad Request with block validation error → likely a markdown parsing issue (see Known Bug below)File ↔ Notion page ID mapping stored in JSON. Example:
{
"content/my-post.md": "abc123-...",
"content/other-post.md": "def456-..."
}
Default location: ./notion_sync_map.json (override with NOTION_SYNC_MAP env var).
On push, if the file is already tracked, the existing Notion page is archived and
a fresh page is created. This avoids block-count drift from repeated pushes.
Use --no-overwrite to skip if already pushed.
Bug: The markdown→Notion block converter incorrectly parsed inline annotations (bold, italic, code spans) when they appeared at the start of a paragraph. This caused a 400 Bad Request from the Notion API with an error like "annotations object is invalid".
Fix applied 2026-03-20: The annotation parser now correctly handles leading annotations by initialising the text accumulator before the first annotation span, not after.
If you see annotation-related 400 errors: Pull the latest version of scripts/notion_content_sync.py. If the error persists, check whether the markdown contains unusual Unicode or nested emphasis (**_bold italic_**) which may still trip the parser.
Created by create_pipeline_db.py:
my-openclaw-chronicles-statistical-proof). MANDATORY — n8n reads props.Slug?.rich_text and sends it to the publish API. If empty, n8n silently skips the page even when Status = Approved ✅.When pushing a blog post to the Content Pipeline DB, always set the Slug property:
"Slug": {"rich_text": [{"type": "text", "text": {"content": slug}}]}
Slug format rules:
Lesson learned 2026-03-28: The Slug property was missing from the DB schema entirely. n8n ran every 15 minutes, found the Approved page, extracted an empty slug string, and silently skipped publishing. Added Slug as a required field to the DB schema and set it on the page to unblock publishing.
# Full advance: pull → humanize → fact-check → push → status
python3 scripts/pipeline_advance.py advance content/my-post.md
# Skip steps individually
python3 scripts/pipeline_advance.py advance content/my-post.md --skip-humanize
python3 scripts/pipeline_advance.py advance content/my-post.md --skip-factcheck
# Preview without making changes
python3 scripts/pipeline_advance.py advance content/my-post.md --dry-run
.md file.humanizer.diff
alongside the file.skills/fact-checker/scripts/fact_check.py if available;
otherwise skips gracefully. Report saved as .factcheck.txt.Draft → Humanized (after humanize + fact-check)Humanized → In Review (after fact-check only)In Review — that's Nissan's decision.NOTION_PIPELINE_DB_ID=322eb552-581a-8111-8f6a-d042dd048ec8 # optional, hardcoded fallback
Using the wrong 1Password item for the API key
op://OpenClaw/Notion API Key/credential → dead item, returns empty or wrong credentialop://OpenClaw/bg2gpqhpta6an5n4prn2zzycya/credentialMissing Notion-Version header
Notion-Version: 2022-06-28 on all requestsParent page not shared with the integration
Pushing without pulling first (when round-tripping)
pull before push if the page may have been edited in NotionSync map out of date after manual Notion changes
Annotation parser 400 errors on old script versions
notion_content_sync.py is post-2026-03-20Missing Slug field → n8n silently skips Approved pages (2026-03-28)
props.Slug?.rich_text — if the field doesn't exist on the DB or the page, it gets an empty string and skips publishing without errorSlug when creating a page in the Content Pipeline DBreferences/api_notes.md — Notion API quirks and block type reference