Skip to main content
Glama

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
NameRequiredDescriptionDefault
typeNoFilter by protocol type (dex, bridge, naming-service, nft-marketplace, etc.)

Implementation Reference

  • 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,
        })),
      );
    },
  • 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.)"),
  • 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,
          })),
        );
      },
    );
  • 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;
    }

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/MaidToShelly/UluVoiMCP'

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