health_check
Monitor and verify the operational status of the Advanced PocketBase MCP Server to ensure system health and identify potential issues proactively.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/agent-cloudflare.ts:215-233 (handler)Handler function for the health_check tool. Returns a JSON status object including server health, timestamp, agent state, PocketBase connection status, and available services (Stripe, Email).const status = { server: 'healthy', timestamp: new Date().toISOString(), state: this.state, pocketbase: this.pb ? 'connected' : 'not initialized', services: { stripe: Boolean(this.stripeService), email: Boolean(this.emailService) } }; return { content: [{ type: 'text', text: JSON.stringify(status, null, 2) }] }; } );
- src/agent-cloudflare.ts:211-234 (registration)Registration of the health_check tool using McpServer.tool() method with description, empty input schema, and inline handler."health_check", "Check the health status of the MCP server and PocketBase connection", {}, async () => { const status = { server: 'healthy', timestamp: new Date().toISOString(), state: this.state, pocketbase: this.pb ? 'connected' : 'not initialized', services: { stripe: Boolean(this.stripeService), email: Boolean(this.emailService) } }; return { content: [{ type: 'text', text: JSON.stringify(status, null, 2) }] }; } );
- src/agent-worker-compatible.ts:104-117 (handler)Handler case for health_check in the tool request switch statement. Returns health status including initialization and PocketBase connection.case "health_check": return { content: [ { type: "text", text: JSON.stringify({ status: "healthy", initialized: this.initialized, pocketbaseConnected: Boolean(this.pb), timestamp: new Date().toISOString() }, null, 2) } ] };
- src/agent-worker-compatible.ts:173-181 (registration)Tool schema and description registration for health_check in the tools/list response.{ name: "health_check", description: "Check the health status of the MCP server", inputSchema: { type: "object", properties: {}, required: [] } },