Skip to content

Commit 7c8cc46

Browse files
committed
feat: README
1 parent ef0c5be commit 7c8cc46

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,25 @@
3434

3535
You will need to get the `token_v2` and `file_token` values from your Notion cookies. The `pages` dictionary should contain pairs of `page_name: page_id` for each page you want to export.
3636

37+
## Needed Cookies
38+
39+
To export anything from Notion, one needs to authenticate oneself with some
40+
Cookies (like a browser would). These cookies are called `token_v2` and
41+
`file_token`. They are set on all requests of a logged in user when using the
42+
Notion web-app.
43+
44+
45+
### How to retrieve the Cookies?
46+
47+
- Go to [notion.so](https://notion.so).
48+
- Log in with your account.
49+
- Open the developer tools of your browser, open Application > Storage > Cookies
50+
(Chrome); Storage tab (Firefox).
51+
- Copy the value of the Cookies called `token_v2` and `file_token` and paste
52+
them somewhere safe.
53+
- ⚠️ If you don't find `file_token`, you need to have at least had exported a file manually once.
54+
- Those cookies have a **1 year validity**, so you don't need to do this often.
55+
3756
2. **Process Exports**:
3857

3958
```python

0 commit comments

Comments
 (0)