capacities_list_spaces
Retrieve all personal spaces from your Capacities knowledge management system to organize and access your content efficiently.
Instructions
Get a list of all personal spaces in Capacities
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/listSpaces.ts:11-21 (handler)The execute function that performs the core logic: makes an API request to '/spaces', parses the JSON response, stringifies it, and handles errors.execute: async () => { try { const response = await makeApiRequest("/spaces"); const data = await response.json(); return JSON.stringify(data, null, 2); } catch (error) { throw new Error( `Failed to list spaces: ${error instanceof Error ? error.message : String(error)}`, ); } },
- src/tools/listSpaces.ts:23-23 (schema)Zod schema for tool parameters: empty object, indicating no input parameters required.parameters: z.object({}),
- src/server.ts:25-25 (registration)Registers the 'listSpacesTool' (which has name 'capacities_list_spaces') with the FastMCP server instance.server.addTool(listSpacesTool);
- src/tools/index.ts:1-1 (registration)Re-exports the listSpacesTool from listSpaces.ts for use in server.ts.export { listSpacesTool } from "./listSpaces.js";
- src/server.ts:6-6 (registration)Imports the listSpacesTool into server.ts.listSpacesTool,