Begin Notion OAuth
Auth
Begin Notion OAuth
Generates a Notion authorize URL bound to the current
(user, organization) via a state nonce. Frontend redirects the
browser to the returned url.
Org admin only. The state nonce is stored server-side with a 10-minute TTL and consumed on callback.
POST
Begin Notion OAuth
Documentation Index
Fetch the complete documentation index at: https://docs.archyon.app/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Both Clerk session JWTs (browser) and Archyon Personal Access
Tokens (an_pat_…, server / CLI / MCP) use the same Bearer
header. The server distinguishes them by token shape.
- Clerk JWTs carry org context in the token claims
(
org_id,org_role,org_slug) — required for org-scoped endpoints. Configure your Clerk session template to include these claims; see DEPLOYMENT.md. - PATs are minted at
/account→ Tokens. Each PAT is bound to whichever org was active at mint time. Switch orgs and re-mint to address a different org.
Response
Authorize URL ready.
Example:
"https://api.notion.com/v1/oauth/authorize?owner=user&client_id=abc123&state=xyz"