Docs / Notion Integration

Notion OAuth Integration

Included in Pro

Index your Notion workspace alongside your codebase. Search runbooks, architecture decisions, and design docs from the same MCP tool.

Prerequisites

  • Active Pyckle Pro subscription
  • A Notion account with access to the workspace you want to index
  • Notion integration created at notion.so/my-integrations

Setup

1

Create a Notion integration

Go to notion.so/my-integrations → New integration:

  • • Name: "Pyckle" (or any name)
  • • Type: Public integration (required for OAuth)
  • • Redirect URIs: https://pyckle.co/auth/notion/callback
  • • Capabilities: Read content, Read user information

Save your Client ID and Client Secret.

2

Set credentials on Fly

fly secrets set -a pyckle \ NOTION_CLIENT_ID= \ NOTION_CLIENT_SECRET= \ NOTION_REDIRECT_URI="https://pyckle.co/auth/notion/callback"
3

Connect your workspace

Open the OAuth flow in your browser. Replace your_state with any string you want to track:

https://pyckle.co/auth/notion?state=your_state

You'll be redirected to Notion's authorization page. Click Allow. On success, you'll see your access_token and workspace name.

4

Index your workspace

Use the token from step 3 with the index_notion MCP tool:

index_notion( token="ntn_xxxxx", database_id="your_database_id" # optional: specific DB )
5

Search your Notion content

Notion pages are now searchable via the standard search_code tool:

search_code("auth architecture decision ADR")

Results from Notion pages appear alongside code results, tagged with source: "notion".

Multi-User Setup

Each team member can connect their own Notion workspace independently. The OAuth flow is per-user — each user gets their own access token which scopes to the databases they share with the integration. No shared tokens required.

Troubleshooting

redirect_uri_mismatch error from Notion

The redirect URI in your Notion integration settings must exactly match https://pyckle.co/auth/notion/callback — no trailing slash.

index_notion returns empty results

Share the target database with your Notion integration. In Notion: open the database → ··· menu → Add connections → select your integration.