Skip to content

szktkfm/notionctl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

notionctl

A toy notion cli

Go Report Card CI

Installation

go install github.com/szktkfm/notionctl...

Usage

Create a Notion Integration. Refer https://developers.notion.com/docs.

Set the API key and the ID of the Database to be integrated into an environment variable.

export NOTION_API_KEY=<your notion api key>
export NOTION_DATABASE=<integrated db id>

You can display the values from the Database in a table-like format as follows

$ notionctl get
NAME               AGE     FOOD GROUP    TAGS     DESCRIPTION
Mandarin orange    5d4h    Fruit         -        small citrus tree fruit
Tuscan Kale        32d     Vegetable     salad    A dark green leafy veget

You can create pages in the database from markdown files or raw text.

$ notionctl push --title readme --file readme.md

$ notionctl push --title todo --description "Buy toothpaste."

$ cat <<EOF | notionctl --title todo --file -
Buy toothpaste.
EOF

About

A toy notion cli

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published