Given a Notion.so URL fetches it as zipped markdown.
First of all you need to obtain a token. Currently the only known way of doing
this is to grab it from your browser’s cookies (it is called token_v2
there).
- Install Python 3 and
requests
- Set the
NOTION_TOKEN
environment variable to your token - Execute
./notion.py "<url>"
nix-build default.nix --argstr token "<token>" --argstr url "<url>" -A notionToPdf
Keep in mind that the derivation is impure and non-deterministic, so, um, it is not entirely clear how to force a rebuild of the same URL...