Skip to main content
POST
/
v1
/
search
TypeScript SDK
import { Client } from "@notionhq/client"

const notion = new Client({ auth: process.env.NOTION_API_KEY })

const response = await notion.search({
  query: "meeting notes",
  filter: {
    property: "object",
    value: "page"
  },
  sort: {
    direction: "descending",
    timestamp: "last_edited_time"
  }
})
{
  "type": "page_or_data_source",
  "page_or_data_source": {},
  "object": "list",
  "next_cursor": "<string>",
  "has_more": true,
  "results": [
    {
      "object": "<string>",
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "created_time": "2023-12-25",
      "last_edited_time": "2023-12-25",
      "archived": true,
      "in_trash": true,
      "is_locked": true,
      "url": "<string>",
      "public_url": "<string>",
      "parent": {
        "type": "<string>",
        "database_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "properties": {},
      "icon": {
        "type": "<string>",
        "emoji": "<string>"
      },
      "cover": {
        "type": "<string>",
        "file": {
          "url": "<string>",
          "expiry_time": "2023-12-25"
        }
      },
      "created_by": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "object": "<string>"
      },
      "last_edited_by": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "object": "<string>"
      }
    }
  ]
}
Returns all pages or data_sources , excluding duplicated linked databases, that have titles that include the query param. If no query param is provided, then the response contains all pages or data_sources that have been shared with the integration. The results adhere to any limitations related to an integration’s capabilities. To limit the request to search only pages or to search only data_source, use the filter param.

Errors

Each Public API endpoint can return several possible error codes. See the Error codes section of the Status codes documentation for more information.
The Search endpoint supports pagination. To learn more about working with paginated responses, see the pagination section of the Notion API Introduction.
To search a specific data_source — not all sources shared with the integration — use the Query a data_source endpoint instead.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Notion-Version
enum<string>
required

The API version to use for this request. The latest version is 2025-09-03.

Available options:
2025-09-03

Body

application/json
sort
object
query
string
start_cursor
string<uuid>
page_size
number
filter
object

Response

type
enum<string>
required
Available options:
page_or_data_source
page_or_data_source
object
required
object
enum<string>
required
Available options:
list
next_cursor
string | null
required
has_more
boolean
required
results
object[]
required