Skip to main content
Glama
by trainual

get_collaboration_health

Assess the operational status and performance of the Tiptap collaborative document service by retrieving its current health metrics for effective monitoring and troubleshooting.

Instructions

Get the health status of the Tiptap collaboration service

Input Schema

NameRequiredDescriptionDefault

No arguments

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": {}, "type": "object" }

Implementation Reference

  • The tool handler that performs a health check on the Tiptap collaboration service by fetching the /health endpoint with appropriate headers and authorization token, returning a structured text response with the result or error message.
    async () => { try { const headers: Record<string, string> = { 'User-Agent': 'tiptap-collaboration-mcp', 'Content-Type': 'application/json', }; const token = getToken(); if (token) headers.Authorization = token; const response = await fetch(`${getBaseUrl()}/health`, { headers }); if (!response.ok) { return { content: [ { type: 'text', text: `Health check HTTP error: ${response.status} ${response.statusText}`, }, ], }; } return { content: [ { type: 'text', text: `Health check response: ${await response.text()}`, }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error connecting to Tiptap collaboration service: ${ error instanceof Error ? error.message : 'Unknown error' }`, }, ], }; } }
  • The exported registration function that defines and registers the 'get_collaboration_health' tool on the MCP server, including name, description, empty input schema, and the handler.
    export default function registerGetCollaborationHealth( server: McpServer, getBaseUrl: () => string, getToken: () => string | undefined ) { server.tool( 'get-collaboration-health', 'Check Tiptap collaboration service health status', {}, async () => { try { const headers: Record<string, string> = { 'User-Agent': 'tiptap-collaboration-mcp', 'Content-Type': 'application/json', }; const token = getToken(); if (token) headers.Authorization = token; const response = await fetch(`${getBaseUrl()}/health`, { headers }); if (!response.ok) { return { content: [ { type: 'text', text: `Health check HTTP error: ${response.status} ${response.statusText}`, }, ], }; } return { content: [ { type: 'text', text: `Health check response: ${await response.text()}`, }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error connecting to Tiptap collaboration service: ${ error instanceof Error ? error.message : 'Unknown error' }`, }, ], }; } } ); }
  • src/server.ts:52-52 (registration)
    Invocation of the tool registration function during MCP server initialization.
    registerGetCollaborationHealth(server, getBaseUrl, getToken);
  • src/server.ts:8-8 (registration)
    Import of the registration function for the get_collaboration_health tool.
    import registerGetCollaborationHealth from './tools/get-collaboration-health.js';

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/trainual/tiptap-collaboration-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server