list-databases
Retrieve all accessible databases within a Notion workspace to view, manage, and organize related data efficiently. This tool connects AI assistants to Notion for enhanced database operations.
Instructions
List all databases the integration has access to
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- server.js:327-348 (handler)Handler for the 'list-databases' tool: searches Notion for databases using the search API with filter for object type 'database', sorts by last_edited_time descending, and returns the results as a JSON-formatted text content block.if (name === "list-databases") { const response = await notion.search({ filter: { property: "object", value: "database", }, page_size: 100, sort: { direction: "descending", timestamp: "last_edited_time", }, }); return { content: [ { type: "text", text: JSON.stringify(response.results, null, 2), }, ], }; }
- server.js:42-49 (registration)Registration of the 'list-databases' tool in the tools/list endpoint response, defining its name, description, and input schema (no required parameters).{ name: "list-databases", description: "List all databases the integration has access to", inputSchema: { type: "object", properties: {} } },