query_database
Query a Notion database with optional filters, sorts, or text search to retrieve matching entries.
Instructions
Query a database with optional filters, sorts, or text search. Use text for simple keyword search across title, rich_text, url, email, and phone fields. For advanced filters, pass Notion filter syntax and call get_database first to see property names and valid options.
Response shape: { results: Array, warnings?: Array }. Multi-value properties are capped by max_property_items and can emit truncated_properties; read resources easy-notion://docs/property-pagination and easy-notion://docs/warnings for details.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database_id | Yes | Database ID | |
| filter | No | Optional Notion filter object | |
| sorts | No | Optional Notion sorts array | |
| text | No | Search text — matches across all text fields (title, rich_text, url, email, phone) | |
| max_property_items | No | Max items returned per multi-value property (title, rich_text, relation, people). Default 75. Set to 0 for unlimited. Negative values rejected. When the cap is hit, the response includes a truncated_properties warning with a how_to_fetch_all hint. |