This project updates the icons of all pages in a Notion database to a specified emoji using the Notion SDK. However, the database icons can be set in bulk by right-clicking without using the API, so this program is mostly unnecessary. I realized that this feature had been added after creating the program... 😂
- Create a
.env
file at the root of the repository and add:NOTION_TOKEN=[YOUR_NOTION_TOKEN]
- Edit the databaseId variable in the main function of
index.ts
to match your Notion database ID, please see How to Retrieve a Database ID. - Run the script:
npm start
This project is based on the notion-sdk-typescript-starter template.