Skip to main content
Glama
amranu

DigitalOcean MCP Server

by amranu

get_endpoint_details

Retrieve comprehensive details for a specific DigitalOcean API endpoint using its operation ID, enabling precise API integration and management via the MCP server.

Instructions

Get detailed information about a specific endpoint

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationIdYesOperation ID of the endpoint

Implementation Reference

  • The handler function that implements the core logic of the get_endpoint_details tool. It retrieves the endpoint by operationId using the findEndpoint helper, formats a detailed markdown-like string with method, path, operationId, summary, description, tags, and parameters list, and returns it as text content.
    private async handleGetEndpointDetails(args: any) { const { operationId } = args; const endpoint = findEndpoint(operationId); if (!endpoint) { throw new Error(`Endpoint not found: ${operationId}`); } const paramsList = endpoint.parameters.length > 0 ? endpoint.parameters.map(p => ` • ${p.name} (${p.in}): ${p.type} ${p.required ? '(required)' : '(optional)'} - ${p.description}` ).join('\n') : ' None'; const details = ` **${endpoint.method} ${endpoint.path}** **Operation ID:** ${endpoint.operationId} **Summary:** ${endpoint.summary} **Description:** ${endpoint.description} **Tags:** ${endpoint.tags.join(', ')} **Parameters:** ${paramsList} `.trim(); return { content: [ { type: 'text', text: details, }, ], }; }
  • The input schema defining the parameters for the get_endpoint_details tool, which requires a string 'operationId'.
    inputSchema: { type: 'object', properties: { operationId: { type: 'string', description: 'Operation ID of the endpoint', }, }, required: ['operationId'], },
  • src/index.ts:114-127 (registration)
    Registration of the get_endpoint_details tool in the ListToolsRequest handler, including name, description, and input schema.
    { name: 'get_endpoint_details', description: 'Get detailed information about a specific endpoint', inputSchema: { type: 'object', properties: { operationId: { type: 'string', description: 'Operation ID of the endpoint', }, }, required: ['operationId'], }, } as Tool,
  • src/index.ts:174-175 (registration)
    Dispatch registration in the CallToolRequest switch statement that calls the handler for get_endpoint_details.
    case 'get_endpoint_details': return await this.handleGetEndpointDetails(args);
  • Key helper function used by the handler to locate the specific endpoint by its operationId from the cached endpoints list.
    export function findEndpoint(operationId: string): DOEndpoint | undefined { const endpoints = loadEndpoints(); return endpoints.find(ep => ep.operationId === operationId); }

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/amranu/digitalocean-mcp'

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