Skip to main content
Glama
amranu

DigitalOcean MCP Server

by amranu

search_endpoints

Locate specific DigitalOcean API endpoints by entering a search query and optionally setting a result limit. Enhances access to over 471 endpoints via the MCP server, enabling precise filtering and direct API calls with authentication.

Instructions

Search for DigitalOcean API endpoints

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoLimit number of results
queryYesSearch query

Implementation Reference

  • Primary execution handler for the search_endpoints tool. It destructures the query and optional limit from args, searches using the helper, limits results, formats as bullet list, and returns formatted text content.
    private async handleSearchEndpoints(args: any) { const { query, limit = 20 } = args; const endpoints = searchEndpoints(query).slice(0, limit); const endpointList = endpoints.map(ep => `• ${ep.method} ${ep.path} - ${ep.summary} (${ep.operationId})` ).join('\n'); return { content: [ { type: 'text', text: `Found ${endpoints.length} endpoints matching "${query}":\n\n${endpointList}`, }, ], }; }
  • src/index.ts:95-113 (registration)
    Tool registration in the MCP server's listTools response, defining name, description, and inputSchema for search_endpoints.
    { name: 'search_endpoints', description: 'Search for DigitalOcean API endpoints', inputSchema: { type: 'object', properties: { query: { type: 'string', description: 'Search query', }, limit: { type: 'number', description: 'Limit number of results', default: 20, }, }, required: ['query'], }, } as Tool,
  • Core helper function implementing the search logic by filtering endpoints based on case-insensitive matches in operationId, summary, description, or tags.
    export function searchEndpoints(query: string): DOEndpoint[] { const endpoints = loadEndpoints(); const lowercaseQuery = query.toLowerCase(); return endpoints.filter(ep => ep.operationId.toLowerCase().includes(lowercaseQuery) || ep.summary.toLowerCase().includes(lowercaseQuery) || ep.description.toLowerCase().includes(lowercaseQuery) || ep.tags.some(tag => tag.toLowerCase().includes(lowercaseQuery)) ); }

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