get_protocols
List and filter Voi ecosystem protocols by type to identify services like DEX, bridges, NFT marketplaces, and naming services for blockchain exploration.
Instructions
List all known Voi ecosystem protocols with type and description
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | Filter by protocol type (dex, bridge, naming-service, nft-marketplace, etc.) |
Implementation Reference
- tools/protocols.js:20-35 (handler)The handler function for the get_protocols tool. It retrieves the protocol list using getProtocols(), optionally filters by type, and returns mapped protocol data.
async ({ type }) => { let list = getProtocols(); if (type) { list = list.filter((p) => p.type === type); } return toolResult( list.map((p) => ({ id: p.id, name: p.name, type: p.type, description: p.description, website: p.website, tags: p.tags, })), ); }, - tools/protocols.js:15-18 (schema)Zod schema definition for the get_protocols tool input - defines an optional 'type' parameter for filtering protocols by type.
type: z .string() .optional() .describe("Filter by protocol type (dex, bridge, naming-service, nft-marketplace, etc.)"), - tools/protocols.js:11-36 (registration)Registration of the get_protocols tool with the MCP server. Defines the tool name, description, input schema, and handler function.
server.tool( "get_protocols", "List all known Voi ecosystem protocols with type and description", { type: z .string() .optional() .describe("Filter by protocol type (dex, bridge, naming-service, nft-marketplace, etc.)"), }, async ({ type }) => { let list = getProtocols(); if (type) { list = list.filter((p) => p.type === type); } return toolResult( list.map((p) => ({ id: p.id, name: p.name, type: p.type, description: p.description, website: p.website, tags: p.tags, })), ); }, ); - lib/registry.js:18-21 (helper)Helper function that loads and returns the protocols data from protocols.json file. Uses lazy loading with caching.
export function getProtocols() { if (!protocols) protocols = loadJSON("protocols.json"); return protocols; }