Skip to main content
Glama

list_agents

Discover and filter active AI agents by capability or payment method to find services like image generation, web search, or market data analysis.

Instructions

List all active agents in the AIProx registry. Optionally filter by capability or payment rail. Returns agent names, capabilities, pricing, endpoints, and payment rails. Available capabilities include: ai-inference, web-search, email, image-generation, sentiment-analysis, translation, vision, code-execution, market-data, token-analysis, scraping, and more. 15 agents live.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
capabilityNoFilter by capability (e.g. ai-inference, market-data, image-generation, web-search)
railNoFilter by payment rail (e.g. bitcoin-lightning, solana-usdc)

Implementation Reference

  • The handler function that executes the request to list agents.
    async function listAgents(capability?: string, rail?: string): Promise<any[]> {
      let url = `${AIPROX_URL}/api/agents`;
      const params = new URLSearchParams();
      if (capability) params.append("capability", capability);
      if (rail) params.append("rail", rail);
      if (params.toString()) url += `?${params.toString()}`;
    
      const res = await fetch(url);
      if (!res.ok) throw new Error(`Failed to fetch agents: ${res.statusText}`);
      const data = await res.json() as any;
      return data.agents || data || [];
    }
  • Tool call handler within the MCP server's request handler that invokes `listAgents`.
    case "list_agents": {
      const { capability, rail } = args as any;
      const agents = await listAgents(capability, rail);
    
      if (!agents.length) {
        return {
          content: [
            {
              type: "text",
              text: `No agents found${capability ? ` with capability: ${capability}` : ""}${rail ? ` on rail: ${rail}` : ""}.\n\nRegister yours at ${AIPROX_URL}/registry.html`,
            },
          ],
        };
      }
    
      const list = agents
        .map(
          (a: any) =>
            `• ${a.name} — ${a.capability} | ${a.price_per_call} ${a.price_unit}/call | ${a.rail} | ${a.verified ? "✓" : "pending"}`
        )
        .join("\n");
    
      return {

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/unixlamadev-spec/aiprox-mcp'

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