ACTIONS
  • Home
  • My Actions
  • My Projects
  • My Packages
Notion -> Page: Retrieve a property item
Readonly
How to Get a Notion API Key

Action summary

Notion -> Page: Retrieve a property item

Xano / Notion

How to Get a Notion API Key

  1. Create an Integration

    • Go to the Notion Developers Portal.
    • Click "New Integration", name it, select a workspace, and submit.
  2. Get Your API Key

    • Copy the Internal Integration Token from the integration settings page.
  3. Grant Database Access

    • Open your Notion database.
    • Click the three button dropdown at the top right of your screen, click Connections, and then select your integration.
  4. Use the API Key

    • Add it to your Xano Actions in the Settings Registry input option:

For more details, see the Notion API Docs.

Notion → Page: Retrieve a property item

Overview

This Xano action retrieves a specific property item from a Notion page using its page ID and property ID. It uses the Notion API's GET method to fetch the property details.


Inputs

Name Type Description
notion_api_key registry text
page_id text The unique identifier of the page
property_id text The unique identifier of the property

Function Stack

  1. Notion API Request

    • API Endpoint: https://api.notion.com/v1/pages/%s/properties/%s
    • HTTP Method: GET
    • Headers:
      • Authorization: Bearer <notion_api_key>
      • Notion-Version: 2022-06-28
    • Replace first %s with page_id and second %s with property_id
  2. Precondition

    • Ensures that the HTTP request was successful
    • Condition: notion_api_response.status == 200
    • If this condition fails, execution halts and an error is thrown

Response

Key Value
As Self Returns notion_api_response.result

Example

Input

{
  "page_id": "9bc30ad4-9373-46a5-84ab-0a7845ee52e6",
  "property_id": "title"
}

Output

{
  "object": "property_item",
  "type": "title",
  "id": "title",
  "title": [
    {
      "type": "text",
      "text": {
        "content": "Example Title",
        "link": null
      },
      "annotations": {
        "bold": false,
        "italic": false,
        "strikethrough": false,
        "underline": false,
        "code": false,
        "color": "default"
      },
      "plain_text": "Example Title",
      "href": null
    }
  ]
}
}

Version notes

2025-01-13 15:43:59
Current
2025-04-15T22:44:42.000+00:00