Skip to main content

Documentation Index

Fetch the complete documentation index at: https://authsome.agentr.dev/docs/llms.txt

Use this file to discover all available pages before exploring further.

Notion (DCR) is a bundled OAuth2 provider in authsome. Notion via the Model Context Protocol endpoint. For the standard OAuth flow against api.notion.com, use notion.

At a glance

Provider namenotion_dcr
Display nameNotion (DCR)
Auth typeOAuth2
Default flowdcr_pkce, Dynamic Client Registration + PKCE
PKCE supportedYes
Device code supportedNo
DCR supportedYes
Default scopes(none)
Proxy hostmcp.notion.com
Env var (access_token)NOTION_ACCESS_TOKEN
Env var (refresh_token)NOTION_REFRESH_TOKEN

Prerequisites

Notion’s MCP endpoint (mcp.notion.com) supports Dynamic Client Registration. You do not need to register an OAuth app. Authsome registers a client automatically.

Log in

uvx authsome login notion_dcr
The first time, authsome opens a local form at http://127.0.0.1:7998 to collect your client_id and client_secret. They are encrypted under your profile and reused on every subsequent login. A second browser window then opens to https://mcp.notion.com/authorize for the authorization step. Verify:
uvx authsome get notion_dcr --field status
# → connected

Multiple accounts

Pass --connection <name> on login and on every read command to keep two or more accounts on the same provider side by side. See Multiple connections per provider for the full pattern.
uvx authsome login notion_dcr --connection personal
uvx authsome login notion_dcr --connection work

Use the token

Run the agent under the proxy. The library tab is for embedding authsome inside a larger Python orchestrator.
uvx authsome run -- python my_agent.py
Under the proxy, authsome sets NOTION_ACCESS_TOKEN=authsome-proxy-managed in the child’s environment and injects the real token into outbound requests to mcp.notion.com. The child process never sees the actual value. Refresh tokens are never exported.

Override the bundled definition

uvx authsome inspect notion_dcr > ~/.authsome/providers/notion_dcr.json
# edit scopes, base_url, or anything else
uvx authsome list   # source now shows "custom" for notion_dcr
User-registered files always win over bundled definitions. See Provider schema.

What’s next

Run agents with the proxy

Inject the access token into outbound requests without exposing it.

Multiple connections per provider

Keep two or more accounts on the same provider side by side.

Provider schema

Every field in a provider definition.

OAuth providers

All bundled OAuth providers.