Skip to content

Notion

PerSQL mirrors your Notion databases into SQL tables you can query, join, and aggregate — the things Notion’s own views can’t express.

  1. Go to notion.persql.com/install/start, authorize the workspace, and connect it to your PerSQL workspace.

  2. Pick which Notion databases to mirror. Each becomes a SQL table in a workspace database in your workspace, kept current as pages change.

import { PerSQL } from "@persql/sdk";
const db = new PerSQL({ token: process.env.PERSQL_TOKEN })
.database(process.env.PERSQL_DATABASE);
const { data } = await db.query(`
SELECT status, count(*) AS n
FROM tasks
GROUP BY status
`);

Point an agent at the Notion MCP to manage the mirror:

https://notion.persql.com/mcp

Authenticate with a PerSQL bearer token. notion_discover_databases and notion_register_database pick what to mirror; workspace_recipe returns the sync snippet and workspace_list shows connected workspaces.