OneCLI connects AI agents to Notion through Notion’s OAuth flow. Agents can search your workspace, read page content, create and update pages, and query databases. The gateway injects OAuth credentials into requests to the Notion API automatically.This is useful for agents that need to look up internal documentation, create tasks or notes, or sync data with Notion databases.
Open the OneCLI dashboard and navigate to Connections > Notion.
2
Authorize
Click Connect Notion. You’ll be redirected to Notion to authorize OneCLI. Select which pages and databases the integration can access, then click Allow access.
Skip this section on OneCLI Cloud. It’s only for self-hosted OneCLI without NOTION_CLIENT_ID and NOTION_CLIENT_SECRET set, or if you want your own company name on Notion’s consent screen.
1. Create the Notion integration
Go to notion.so/profile/integrations and select New integration. Name it OneCLI, pick your workspace, set Type to Public, and save.
2. Set the capabilities
Open Capabilities and turn on the ones your agents need:
Capability
Why
Read content
Search and read pages and databases
Update content and Insert content
Create and edit pages
Read comments
Read page comments
Read user information without email addresses
Show who wrote what
3. Add the redirect URI
In OneCLI, open Connections > Notion > Custom credentials and copy the Redirect URI. In Notion, open Configuration > OAuth Domain & URIs, paste it into Redirect URIs, and save.
Copy the Redirect URI from Custom credentials in OneCLI.
Notion's OAuth domains & URIs section with the OneCLI Redirect URI.
4. Connect with your integration
In Notion, open Configuration and copy the OAuth Client ID and OAuth Client Secret. Paste both into Connections > Notion > Custom credentials, select Save & Connect, and allow access in Notion.
Your integration's Configuration tab in Notion: the OAuth Client ID and Client Secret.
Access is per agent: grant the connection to each agent that needs it, choosing per tool what runs freely, what needs human approval, and what stays blocked — a read-only agent is a single grant. Organization rules add guardrails on top, like rate limits and blanket blocks. Everything is checked before credential injection, so a blocked request never reaches Notion.