Member-only story
How to Automate Notion with Python

I love Notion.
Before I discovered Notion, all my notes, projects, progress trackers and ideas were scattered across multiple places. It was a mess.
Notion brought everything into one place. Every project, every idea, all my notes are now in one place. I can see them all — I don’t need to switch between multiple apps. I can link and refer to each other. Notion streamlined my workflow and improved it in a way I did not know it can.
I also like to automate things. I’m one of those people who would rather spend an evening or two writing scripts to automate boring repetitive tasks than to do them over and over again.
With this kind of mindset, I looked at the workflows I created in Notion and tried to find a way to automate them.
As of the end of November 2020, Notion does not have any public API available. The billing page says the Content API is on the roadmap and it will be only available for paid accounts. What Notion’s team did not say is when we can expect the official API to be released.
Luckily, we can use notion-py package for now.
notion-py is an unofficial Python client for Notion. Under the hood, it uses requests package to open Notion as a webpage in headless mode and get data that way. It also works for both free and paid…