aspro_list_modules
List all top-level Aspro.Cloud API modules with entity and operation counts to discover available modules like CRM, fin, agile, task.
Instructions
List all top-level Aspro.Cloud API modules (crm, fin, agile, task, etc.) with entity and operation counts.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:43-51 (registration)Registration of the 'aspro_list_modules' tool via server.registerTool, with schema and handler that delegates to spec.listModules().
server.registerTool( "aspro_list_modules", { description: "List all top-level Aspro.Cloud API modules (crm, fin, agile, task, etc.) with entity and operation counts.", inputSchema: {}, }, async () => asJson(spec.listModules()), ); - src/index.ts:45-48 (schema)Input schema for aspro_list_modules: description text, empty inputSchema (no parameters).
{ description: "List all top-level Aspro.Cloud API modules (crm, fin, agile, task, etc.) with entity and operation counts.", inputSchema: {}, - src/index.ts:50-50 (handler)Handler function: async () => asJson(spec.listModules()) — calls SpecIndex.listModules() and wraps result in JSON text content.
async () => asJson(spec.listModules()), - src/spec.ts:147-159 (helper)SpecIndex.listModules() — iterates operations to count per module, returns sorted array of {module, entityCount, operationCount}.
listModules(): { module: string; entityCount: number; operationCount: number }[] { const counts = new Map<string, number>(); for (const op of this.operations) { counts.set(op.module, (counts.get(op.module) ?? 0) + 1); } return [...this.modules.entries()] .map(([module, entities]) => ({ module, entityCount: entities.size, operationCount: counts.get(module) ?? 0, })) .sort((a, b) => a.module.localeCompare(b.module)); }