Skip to content

Latest commit

 

History

9 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

notion-scripts

Notion scripts for setting up a database calendar for my courses.

  • index.js : creates pages from a json-like object
  • copy.js : duplicates pages from one database to another
    • DATABASE_ID source database
    • DATABASE_ID_COPY destination database
    • filters for page.date > now

.env file (see .env.example):

  • NOTION_TOKEN notion api token (docs)
  • DATABASE_ID the id of the database being worked with
    • go to a database, copy link; https://www.notion.so/<username>/<database_id>?v=<view_id..?>
  • DATABASE_ID_COPY

Setup

Create an "internal" Notion integration. steps

Add the api token to your .env file.

Then, for each database that the script will run for, enable the automation workflow's access to the it via the "Connections" / "Connect to" menu option. steps

Script usage: node index.js, node copy.js.

About

No description or website provided.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages