Skip to content

yamanoku-playground/2021-05-15-notion-sdk-js-playground

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

2021-05-15-notion-sdk-js-playground

Get https://www.notion.so/yamanoku/d23d73e2e3bc415082fd0ff93c0bcea1

Running Locally

1. Setup your local project

# Clone this repository locally
git clone https://github.com/yamanoku-playground/2021-05-15-notion-sdk-js-playground.git

# Switch into this project
cd 2021-05-15-notion-sdk-js-playground

# Install the dependencies
npm ci

2. Set your enviornment variables in a .env file

ref: https://developers.notion.com/reference/get-database

touch .env
NOTION_KEY=<your-notion-api-key>
NOTION_DATABASE_ID=<notion-database-id>

3. Run code

$ node notion.js
{
  object: 'database',
  id: 'd23d73e2-e3bc-4150-82fd-0ff93c0bcea1',
  created_time: '2021-05-15T04:29:17.237Z',
  last_edited_time: '2021-05-15T04:30:00.000Z',
  title: [
    {
      type: 'text',
      text: [Object],
      annotations: [Object],
      plain_text: 'Notion API テスト用',
      href: null
    }
  ],
  properties: {
    Tags: { id: 'QipU', type: 'multi_select', multi_select: [Object] },
    Name: { id: 'title', type: 'title', title: {} }
  }
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published