monica_health_check
Verify configured Monica CRM credentials to ensure proper connection and functionality for managing contacts, activities, and tasks.
Instructions
Verify that the configured Monica credentials work.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/registerTools.ts:52-62 (handler)Inline handler function for the 'monica_health_check' tool. It invokes the MonicaClient's healthCheck method and returns a standardized success message confirming connectivity to the Monica CRM API.async () => { await client.healthCheck(); return { content: [ { type: 'text' as const, text: 'Successfully connected to Monica CRM API.' } ] }; }
- src/tools/registerTools.ts:46-63 (registration)Registration of the 'monica_health_check' tool using the MCP server's registerTool method, providing tool metadata (title and description) and the inline handler.server.registerTool( 'monica_health_check', { title: 'Test Monica connectivity', description: 'Verify that the configured Monica credentials work.' }, async () => { await client.healthCheck(); return { content: [ { type: 'text' as const, text: 'Successfully connected to Monica CRM API.' } ] }; } );
- src/client/MonicaClient.ts:1480-1482 (helper)The MonicaClient.healthCheck() supporting method that performs the actual connectivity verification by making a lightweight API request to fetch contacts with limit=1.async healthCheck(): Promise<void> { await this.request('contacts', { searchParams: { limit: 1 } }); }