Notion-Potion is a Telegram bot that lets you quickly and easily save new notes, tasks, events etc... to your Notion workspace.
The idea behind this bot is heavily inspired by David Allen's book Getting Things Done. And, is the upgrade to the method used in this previous blog post: Implementing a GTD inbox in Notion
Notion-Potion.mp4
-
You send a message to your bot. It get's automatically saved to your Notion Inbox database
- You then can then do any of the following
- Rename the page
- Move the page to another database ex: tasks, notes, etc...
- Link the page to a specific project
- link the page to a specific Topic
- Delete the page
- You then can then do any of the following
-
Or, you can tell the bot directly where to save the page
- for example to save a page to your notes you append or prepend your message with
@note
- for example to save a page to your notes you append or prepend your message with
- Links that matches a specific website you have set up before will get saved directly to the specified database
- Ex: a URL of Youtube video gets added to the Bookmarks database while a URL of an Amazon product gets saved in the Shopping database
- Text you send with the URL gets saved inside the page as a text block.
🚧 Coming soon
- You have a telegram bot
- Use BotFather to create one and obtain your token
- Yon know your telegram user id
- use jsondumpbot to get it.
- You have a Notion API Token
- You have your Notion workspace setup [🚧 tutorial coming soon]
- Fork this repository and clone it to your local machine.
- Copy
.env.example
and rename it.env
and fill in your tokens and telegram user idTELEGRAM_BOT_TOKEN=Your telegram bot token MY_USER_ID=your telegram user id NOTION_TOKEN=your Notion token
- copy
notion.example.sqlite
and rename it tonotion.sqlite
- Replace the example databases with your databases [🚧 tutorial coming soon]
- Install all the dependencies
npm install
- Run the bot 🥳
npm run
├── docs # screenshots for readme
├── src
│ ├── bot # All the bot code like the event handlers, keyboards, state, etc...
│ ├── classes # All the Classes used by the bot
│ ├── databases # Connection to the database and all the data retrieval
│ ├── lib # Helper classes like Logger and Util
├─── __test__ # Testing code.
├─── .env.example # example env file.
├─── notion.sqlite.example # example database file.
├─── app.js # Entry point for the bot.
├─── package-lock.json
├─── package.json
└─── README.md
- 🔳 @notionhq/client
- 🤖 node-telegram-bot-api
- 📰 axios
- 🎨 chalk
- 🔐 dotenv
- 📝 node-html-parser
- 😈 nodemon
- 📑 sqlite3
- 👢 jest