Questions tagged [notion-api]

Questions related to the Notion API. The API is REST-based and the officially supported SDK is written in TypeScript.

The Notion API is a JSON-based REST API for working with the Notion application.

It allows you to work with and manipulate data in Databases, Pages, and Properties in your Notion workspace(s).

You can find documentation for the API on Notion's Developer Portal.

The official client is written in TypeScript.

299 questions
0
votes
1 answer

How to use Notion API to create a database item with a particular select tag as a property?

I have an API POST request that creates an item within my Notion database. But I want to add it with a particular Select tag as a property. This is the JSON I'm sending: { "parent":{ …
Donz
  • 23
  • 2
0
votes
0 answers

How to add secure urls when uploading externally hosted files using notion api?

We are trying to upload files to notion using notion api. As per the documentation, notion api doesn't support file uploads. It does support adding files or media which are hosted on third-party services. If we are uploading externally hosted media…
0
votes
0 answers

Combining multiple databases in Notion

I am more familiar with Excel but want all my information in Notion since it’s so powerful. I’m trying to track weeks of results for multiple individuals on a team. I would like to see a team view but also see the individual performance on a weekly…
0
votes
0 answers

How to change notion api default view in python

The default view could not be found in the code below. Is there a way to specify a default view in the code? I want the default view to show the…
bin
  • 3
  • 3
0
votes
2 answers

Notion API quickly delete and repopulate entire DB

Background I'm creating a Notion DB that will contain data about different analyzers my team uses (analyzer name, location, last time the analyzer sent data, etc.). Since I'm using live data I need to have a way to quickly update the data of all…
snatchysquid
  • 1,283
  • 9
  • 24
0
votes
1 answer

Notion Search API didn't return all page IDs under my account

I'm writing an app leveraging Notion APIs to fetch all pages under my account but it couldn't get all Page IDs. I'm aware of pagination in the POST https://api.notion.com/v1/search endpoint and implemented a recursion function to fetch all of them…
Andy Lu
  • 29
  • 1
  • 7
0
votes
1 answer

Parsing a list of images from NOTION database to flutter app

I am trying to display Notion content such as texts, dates, booleans and images on flutter app.. For texts, dates, and booleans, everything is working.. but I am stuck at displaying images. Please kindly take a look at my JSON file and my code.. and…
0
votes
1 answer

How to retrieve database ID within Notion page?

I have got a database table within a Notion page. I would like to use the Notion API to populate values to the database. However, since I have multiple of these pages it would be impractical to hardcode the database ID each time. Is there a way to…
Xenos
  • 73
  • 2
  • 11
0
votes
1 answer

How to create a database (Calendar) in a page in notion use to python?

I want to create a calendar for the database in the page. But I get the following error. The error code 400 occurs and I want to get the same result as the picture…
bin
  • 3
  • 3
0
votes
1 answer

trying to add several pages to a relation field in Notion database

Imagine a database table with two columns, Name (title) and Collaborators (relation). Things work fine when I add a row with a single collaborator like so. qveri <- list( parent = list(database_id = "database_id"), properties = list( Name =…
Roman Luštrik
  • 69,533
  • 24
  • 154
  • 197
0
votes
1 answer

How long is the access_token from notion-api valid?

I'm working on an integration for notion-api and I couldn't find how long is the access_token returned from their OAuth valid. Is it always valid?
0
votes
0 answers

Form can't reach Next.js Dynamic API to update Notion's database using Notion API: error 500

I'm trying an integration with Notion API using Next.JS api to fulfill a table using form values from my site. The form logic is shown bellow. I'm using Formik to handle values and changes. Handle response just allows me to display a feedback for…
Eduardo Oliveira
  • 395
  • 2
  • 18
0
votes
1 answer

Trying to query a database using the Notion API with JavaScript and it returns only the id for all the properties whilst the same works in Postman

const dotenv = require('dotenv').config() const {Client} = require('@notionhq/client') const notion = new Client({ auth: process.env.NOTION_TOKEN }) const database_id = process.env.NOTION_DATABASE_ID const getVideos = async () => { // code…
0
votes
1 answer

Notion API Pagination (Retrieval Limitation)

Recently, I encountered an issue when trying to retrieve data from Notion using its API. The data consists of more than 300 values, which is a problem since Notion only lets you extract 100 elements at a time. Fortunately, I could find a solution to…
Andy Lee
  • 43
  • 4
0
votes
1 answer

Is it possible to access a public Notion page without OAuth using a supported Notion API?

Is it possible to access public pages without OAuth using an officially supported API, like https://api.notion.com/v1/...? So far it seems the answer is no (I get 404 if the page is public but hasn't been explicitly shared with my integration), but…
lgaud
  • 2,430
  • 20
  • 30