Notion API Worker
Serverless wrapper around Notion's private API that returns page and table data as JSON, so Notion can serve as a simple CMS.
- GitHub stars
- 1.7k
- Last commit
- 11 mo ago
- Self-hosted
- Yes
- Hosted version
- Available
Notion API Worker is a small serverless service that exposes content from Notion through simple HTTP endpoints. It is meant for developers who want to use Notion as a content management system for a blog or documentation site without building their own integration. A single GET request returns the data for a page or a table.
The page endpoint returns all block data for a Notion page, which can be rendered with the react-notion library, and the table endpoint returns structured rows from tables and databases. Responses use built-in stale-while-revalidate caching and are CORS friendly, so data can be fetched directly from a browser. Public pages need no authorization; private pages require either a NOTION_TOKEN environment variable on your own instance or a bearer token in the request header.
The authors host a public version and also describe how to deploy your own on Vercel. The repository topics mention Cloudflare Workers. Because it is based on Notion's private API, the README warns that stability cannot be guaranteed, so production use needs care. The repository metadata does not list a license.
Key features
- Fetch Notion pages with a single GET request
- Structured access to tables and databases
- Built-in stale-while-revalidate caching
- CORS-friendly responses
- Private page access via token
- Deployable on Vercel or Cloudflare Workers