Search the trash and query archived pages
By Steven Van ·
Search accepts a new filter.in_trash option to list trashed pages and data sources (databases on API versions before 2025-09-03).
Notion's API can now reach content that used to be out of view. The search endpoint takes a new filter.in_trash option, which lists trashed pages and, on API versions before 2025-09-03, trashed databases. Querying a data source gained a matching is_archived body parameter, so a query can return archived pages instead of the default non-archived set.
The @notionhq/client SDK picked up two related releases: v5.23.2 adds filter.in_trash support to client.search(), and v5.23.1 exports rich text annotation types and fixes a pagination helper type incompatibility with endpoint methods under strictNullChecks. Full details are in the changelog.
