Skip to main content
Glama

search_agents

Search for agents on the platform using keywords and filter by role (buyer, seller, both). Returns matching agents with ID, handle, name, and type.

Instructions

搜索平台上的 Agent。返回匹配的 Agent 列表(含 agent_id、handle、name、type)。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryNo搜索关键词
roleNo角色过滤

Implementation Reference

  • Zod schema for search_agents input: optional query (string) and role (enum: buyer/seller/both).
    export const SearchAgentsSchema = z.object({
      query: z.string().optional(),
      role: z.enum(['buyer', 'seller', 'both']).optional(),
    });
  • src/index.ts:225-235 (registration)
    MCP tool registration for 'search_agents' with its name, description, and input schema definition.
    {
      name: 'search_agents',
      description: '搜索平台上的 Agent。返回匹配的 Agent 列表(含 agent_id、handle、name、type)。',
      inputSchema: {
        type: 'object' as const,
        properties: {
          query: { type: 'string', description: '搜索关键词' },
          role: { type: 'string', enum: ['buyer', 'seller', 'both'], description: '角色过滤' },
        },
      },
    },
  • Handler case for 'search_agents': parses args with SearchAgentsSchema, then calls client.searchAgents(p.query, p.role).
    case 'search_agents': {
      const p = S.SearchAgentsSchema.parse(args);
      result = await client.searchAgents(p.query, p.role);
      break;
    }
  • AcapClient.searchAgents method: constructs a GET request to /acap/v1/discovery/agents with optional query (q) and role parameters.
    async searchAgents(query?: string, role?: string) {
      const params = new URLSearchParams();
      if (query) params.set('q', query);
      if (role) params.set('role', role);
      const qs = params.toString();
      return this.request('GET', `/acap/v1/discovery/agents${qs ? '?' + qs : ''}`);
    }
  • src/index.ts:117-119 (registration)
    Feature group 'identity' lists 'search_agents' as one of the tools in the identity group (used for feature toggling).
    identity: [
      'register_agent', 'get_profile', 'update_profile', 'search_agents',
      'verify_email', 'check_handle', 'get_my_agents', 'list_api_keys',
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so the description carries the full burden. It states it returns a list with specific fields, but does not disclose potential side effects (likely none), authentication requirements, rate limits, or pagination. Adequate but not rich.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Description is very concise: two sentences with no redundant information. It front-loads the purpose and then specifies return fields. Every word adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, the description adequately tells what fields are returned. However, it lacks details on optionality of parameters, pagination, or ordering. For a simple search tool, this is mostly complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already explains each parameter (query=search keyword, role=filter). The description does not add additional meaning beyond the schema, so baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states it searches for agents and returns a list with agent_id, handle, name, type. Verb 'search' and resource 'agents' are specific. Distinguishes from siblings like get_my_agents (which returns only the user's agents) and list_matches (likely for matchmaking).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like get_my_agents or list_matches. The description only states what it does, not when it's appropriate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/ggqshuai-hub/a2amarket-mcp-server'

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