Notion Integration
Manage Notion pages and databases
The Notion integration provides access to manage Notion pages and databases through the Integrate MCP server.
Installation
The Notion integration is included with the SDK:
import { notionIntegration } from "integrate-sdk/server";Setup
1. Create a Notion OAuth App
- Go to Notion Integrations
- Create a new OAuth application
- Configure your redirect URI
- Note your Client ID and Client Secret
2. Configure the Integration on Your Server
Add the Notion integration to your server configuration. The integration automatically reads NOTION_CLIENT_ID and NOTION_CLIENT_SECRET from your environment variables:
import { createMCPServer, notionIntegration } from "integrate-sdk/server";
export const { client: serverClient } = createMCPServer({
apiKey: process.env.INTEGRATE_API_KEY,
integrations: [
notionIntegration({
}),
],
});You can override the environment variables by passing explicit values:
notionIntegration({
clientId: process.env.CUSTOM_NOTION_ID,
clientSecret: process.env.CUSTOM_NOTION_SECRET,
});3. Client-Side Usage
The default client automatically includes all integrations. You can use it directly:
import { client } from "integrate-sdk";
await client.authorize("notion");
const result = await client.notion.search({});
console.log(result);If you're using a custom client, add the integration to the integrations array:
import { createMCPClient, notionIntegration } from "integrate-sdk";
const customClient = createMCPClient({
integrations: [notionIntegration()],
});Configuration Options
export interface NotionIntegrationConfig {
/** Notion OAuth client ID (defaults to NOTION_CLIENT_ID env var) */
clientId?: string;
Tools
notion_search
Search for pages and databases in Notion
export interface NotionSearchParams {
/** Text query to search for */
query?: string;
notion_get_page
Retrieve a Notion page by ID
export interface NotionGetPageParams {
/** The ID of the page to retrieve */
page_id: string;
notion_create_page
Create a new page under a page or database parent
export interface NotionCreatePageParams {
/** Parent page or database */
parent: { page_id: string } | { database_id: string };
notion_update_page
Update a page's properties, icon, cover, or archive status
export interface NotionUpdatePageParams {
/** The ID of the page to update */
page_id: string;
notion_get_page_property
Get a specific property value from a page with pagination support
export interface NotionGetPagePropertyParams {
/** The ID of the page */
page_id: string;
notion_get_database
Get a database by ID including its schema
export interface NotionGetDatabaseParams {
/** The ID of the database to retrieve */
database_id: string;
notion_query_database
Query a database with filters, sorts, and pagination
export interface NotionQueryDatabaseParams {
/** The ID of the database to query */
database_id: string;
notion_create_database
Create a new database under a parent page
export interface NotionCreateDatabaseParams {
/** Parent page for the database */
parent: { page_id: string };
notion_update_database
Update a database's title, description, properties, or archive status
export interface NotionUpdateDatabaseParams {
/** The ID of the database to update */
database_id: string;
notion_get_block
Get a block by ID
export interface NotionGetBlockParams {
/** The ID of the block to retrieve */
block_id: string;
notion_get_block_children
Get child blocks of a block with pagination
export interface NotionGetBlockChildrenParams {
/** The ID of the parent block */
block_id: string;
notion_append_blocks
Append child blocks to a parent block
export interface NotionAppendBlocksParams {
/** The ID of the parent block */
block_id: string;
notion_update_block
Update a block's content
export interface NotionUpdateBlockParams {
/** The ID of the block to update */
block_id: string;
notion_delete_block
Delete (archive) a block
export interface NotionDeleteBlockParams {
/** The ID of the block to delete */
block_id: string;
notion_get_user
Get a user by ID
export interface NotionGetUserParams {
/** The ID of the user to retrieve */
user_id: string;
notion_get_current_user
Get the bot user associated with the current token
No parameters.
notion_list_users
List workspace users with pagination
export interface NotionListUsersParams {
/** Start cursor for pagination */
start_cursor?: string;
notion_create_comment
Create a comment on a page or reply to a discussion
export interface NotionCreateCommentParams {
/** Parent page to comment on (use this or discussion_id) */
parent?: { page_id: string };
notion_list_comments
List comments on a block or page
export interface NotionListCommentsParams {
/** The ID of the block or page */
block_id: string;
notion_move_page
Move a page to a new parent page or data source
export interface NotionMovePageParams {
/** Notion page ID to move */
page_id: string;
notion_create_file_upload
Create a Notion file upload. Use mode "external_url" to import from a URL,
export interface NotionCreateFileUploadParams {
/** Upload mode: "external_url" to import from URL, "single_part" to upload content */
mode: "external_url" | "single_part";
notion_send_file_upload
Send file content for a Notion file upload (single_part mode).
export interface NotionSendFileUploadParams {
/** File upload ID (from createFileUpload response) */
upload_id: string;
notion_complete_file_upload
Complete a Notion file upload after sending content
export interface NotionCompleteFileUploadParams {
/** File upload ID */
upload_id: string;
notion_get_file_upload
Get the status of a Notion file upload
export interface NotionGetFileUploadParams {
/** File upload ID */
upload_id: string;
notion_create_data_source
Create a new Notion data source under a parent page
export interface NotionCreateDataSourceParams {
/** ID of the parent page */
parent_id: string;
notion_get_data_source
Get a Notion data source by its ID
export interface NotionGetDataSourceParams {
/** Notion data source ID */
data_source_id: string;
notion_update_data_source
Update a Notion data source's title, description, properties, or status
export interface NotionUpdateDataSourceParams {
/** Notion data source ID */
data_source_id: string;
notion_query_data_source
Query a Notion data source with optional filters, sorts, and pagination
export interface NotionQueryDataSourceParams {
/** Notion data source ID */
data_source_id: string;
Notes
- Category: Productivity
- Authentication mode: OAuth