Notion
Add a bot to Notion using the official integration.
The Notion Integration with Botpress enables seamless integration to boost productivity, allowing interactions such as commenting on discussions or pages and database manipulations right from your Botpress bot.
Setup
You will need:
- A published bot
- A Notion account and workspace
For advanced use cases, you can configure the integration manually using a Notion integration token.
You will need:
- A published bot
- A Notion account and workspace
Step 1: Install the integration in Botpress
Step 2: Create an integration in Notion
Next, create a corresponding integration in Notion:
Go to your integrations page in Notion.
Step 3: Give access to pages and databases
For your bot to interact with your Notion workspace, you need to manually specify which pages and databases it has access to:
Step 4: Configure webhook events (optional)
If you want to use the integration’s Triggers and have your bot respond to events in your Notion workspace, follow the steps below:
In the integration’s configuration menu in Botpress, copy the webhook URL (starting with https://webhook.botpress.cloud/).
In your Notion integration’s settings, go to the Webhooks tab. Then, select + Create a subscription.
Under Select the events to listen to, select the following events:
- Page created
- Page deleted
- Comment created
In Botpress, go to your bot’s most recent logs. Copy the verification token sent from Notion.
Cards
Add Comment
Add a comment to a page, block, or discussion in Notion
inputobjectoutputobjectAppend Blocks to Page
Append a markdown text to a page in Notion. The markdown text will be converted to notion blocks.
inputobjectoutputobjectCreate Page
Create a new page in Notion
inputobjectoutputobjectDelete Block
Delete a block in Notion
inputobjectoutputobjectList items in folder
List the files and folders in a folder
inputobjectoutputobjectTransfer file to Botpress
Transfer a file from an external service to Botpress
inputobjectoutputobjectGet Data Source
Get a data source from Notion
inputobjectoutputobjectGet Database
Get a database from Notion
inputobjectoutputobjectGet Page
Get a page from Notion
inputobjectoutputobjectGet Page Content
Get the content blocks of a page or block in Notion
inputobjectoutputobjectSearch by Title
Search for pages and databases in Notion. Optionally filter by title. Only returns items that have been shared with the integration.
inputobjectoutputobjectUpdate Page Properties
Update one or more properties on a Notion page using raw Notion properties JSON
inputobjectoutputobjectTo use certain Cards, you might need to identify elements by their IDs. You can get page and database IDs:
- From their URL while viewing them in your browser
- By choosing Copy Link from their options menu
Triggers
aggregateFileChanges
payloadobjectComment Created
A comment was created in Notion
payloadobjectfileCreated
payloadobjectfileDeleted
payloadobjectfileUpdated
payloadobjectfolderDeletedRecursive
payloadobject