Helper to build Notion API params, parse markdown text into Notion API blocks
Project description
notion-params
Helper to build Notion API params, parse markdown text into Notion API blocks
import notion_client
from notion_params import NotionParams as NP
def demo():
notion = notion_client.client.Client(auth=os.environ['NOTION_TOKEN'])
page_id = '7458781ba20644e0b850452095000000'
sub_page = notion.pages.create(**NP.create_page(
page_id,
title='title text',
emoji='😀',
text="""# H1 title
Text text text
> quote
>
>> sub quote
>> more text
!!callout
custom markdown syntax to write callout
- list item abc
- another list item
1. ordered list sample
1. second item
...
"""))
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
notion-params-0.0.1.tar.gz
(8.7 kB
view hashes)
Built Distribution
Close
Hashes for notion_params-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f59bdedd2a106c0a6fe82a128a1e9f7e131f6e85e5af23b765e9268dae39785 |
|
MD5 | d12fad4184053017fc6d5b3c8d6c357a |
|
BLAKE2b-256 | 6ed757993f35e5e24e20f24ec7bcec858e0f48e5b7dd91f0d0e0c0619e654f58 |