Import markdown files to Notion
Project description
Notionfier: Import Markdown Pages to Notion.so
Fork of https://github.com/Arsenal591/notionfier
- updated dependencies
- published to PyPi
- reformatted, updated python version
Import markdown files to Notion.so using its official API.
Requirments: Python >= 3.11.
Features
- All markdown basic syntax.
- Some markdown extended syntax:
- Tables.
- Code blocks.
- Footnotes.
- Definition lists.
- Strikethrough.
- Task lists.
- Automatic URL Linking.
Usage
- Firstly, follow the instruction to create an notion integration and share a page with the integration.
CLI
notionfier import -t={{YOUR NOTION TOKEN}} -pid={{PAGE ID}} -f={{FILE PATH}}
Programmatically
from notionfier import NotionPageBuilder
token = "TOKEN"
builder = NotionPageBuilder(token)
parent_page_id = "123"
name = "Import Markdown File"
content = "##Markdown!!!"
# For sync
builder.create_page(parent_page_id, name, content)
# For async
await builder.acreate_page(parent_page_id, name, content)
TODOs
- Highlighting.
- MathJax.
- Support local image files.
- Handle deeply (> 3 levels) nested children properly.
- Deal with Notion API's request limits.
- More tests on markdown extensions.
LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
notionfier-1.0.1.tar.gz
(8.4 kB
view details)
Built Distribution
File details
Details for the file notionfier-1.0.1.tar.gz
.
File metadata
- Download URL: notionfier-1.0.1.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.6 Darwin/22.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 76b640d0cc75ad78757b013858e35cf5ba662e67332b9cbc247127f72a4fe9e8 |
|
MD5 | 63bb9d29d2175606ceaceab3dbc6e1ca |
|
BLAKE2b-256 | 5297ac646d37b4e6bd1d55791c515df9ddef6f162a3091da1f51cabdf09f4087 |
File details
Details for the file notionfier-1.0.1-py3-none-any.whl
.
File metadata
- Download URL: notionfier-1.0.1-py3-none-any.whl
- Upload date:
- Size: 10.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.6 Darwin/22.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | de5fc141233f58a638cb006810c2c18dd0f536c0f0d4267a4eb1e78d69abac99 |
|
MD5 | 56e01e61ae04f248974624f3cc44c1c8 |
|
BLAKE2b-256 | de47aefaa2cebc090b297f294c44b0bf8a4e824b79e3f3c9d15379fb7427eec6 |