Skip to main content
Glama
clarenous
by clarenous

tool_call

Execute methods from integrated tools by specifying tool name, method, and required parameters. Access multiple tools through unified VeyraX MCP authentication.

Instructions

"Use this tool to execute a specific method of another tool with the provided parameters based on get-tools tool response. You need to specify the tool name, method name, and any required parameters for that method."

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toolYesThe name of the tool to call (e.g., 'gmail', 'google-calendar', 'slack')
methodYesThe method of the tool to call (e.g., 'get_messages', 'send_message', 'list_events')
parametersNoThe parameters required by the specific tool method being called, it is MUST HAVE field.
questionNoUser question that you want find answer for. Try to ALWAYS provide this field based on conversation with user. Could be your reasoning for calling tool.

Implementation Reference

  • The `execute` method implements the core logic of the 'tool_call' tool. It constructs a URL with the specified tool and method, sends a POST request with parameters using veyraxClient, and returns the response as formatted JSON. Includes error handling for 404 (not found) and 500 (server error) cases.
    async execute({ tool, method, parameters, question }: z.infer<typeof this.schema>) {
      try {
        const url = `/tool-call/${tool}/${method}?include_component=false${question ? `&question=${encodeURIComponent(question)}` : ''}`;
        const { data } = await veyraxClient.post(url, parameters);
    
        return {
          content: [
            {
              type: "text" as const,
              text: JSON.stringify(data, null, 2),
            },
          ],
        };
      } catch (error: any) {
        console.error(`Error calling tool ${tool}.${method}:`, error);
        
        if (error?.response) {
          if (error.response.status === 404) {
            return {
              content: [
                {
                  type: "text" as const,
                  text: `Tool or method not found: ${tool}.${method}. Please check the tool name and method name.`,
                },
              ],
            };
          } else if (error.response.status === 500) {
            return {
              content: [
                {
                  type: "text" as const,
                  text: `Server error occurred while calling ${tool}.${method}. Please try again later.`,
                },
              ],
            };
          }
        }
        
        throw error;
      }
    }
  • Zod schema defining the input structure for the 'tool_call' tool, including required fields: tool (string), method (string), parameters (object), and optional question (string).
    schema = z.object({
      tool: z.string().describe("The name of the tool to call (e.g., 'gmail', 'google-calendar', 'slack')"),
      method: z.string().describe("The method of the tool to call (e.g., 'get_messages', 'send_message', 'list_events')"),
      parameters: z.record(z.any())
        .default({})
        .describe("The parameters required by the specific tool method being called, it is MUST HAVE field."),
      question: z.string()
        .optional()
        .describe("User question that you want find answer for. Try to ALWAYS provide this field based on conversation with user. Could be your reasoning for calling tool.")
    });
  • src/index.ts:14-14 (registration)
    Registration of the ToolCallTool instance with the MCP server, making the 'tool_call' tool available.
    new ToolCallTool().register(server);
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions the tool executes methods with parameters but fails to describe critical traits: error handling, authentication requirements, rate limits, or what happens if parameters are invalid. For a meta-tool that invokes other tools, this lack of behavioral context is a significant gap, though it doesn't contradict any annotations.

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

Conciseness4/5

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

The description is appropriately sized with two sentences that front-load the core purpose. Each sentence adds value: the first defines the tool's function, and the second specifies required inputs. There's no wasted text, though it could be slightly more structured for clarity.

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

Completeness3/5

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

Given the tool's complexity (meta-invocation with 4 parameters, no output schema, and no annotations), the description is minimally adequate. It covers the basic purpose and usage context but lacks details on behavior, error cases, or return values. Without annotations or output schema, more completeness is needed for safe operation, but it's not entirely inadequate.

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 description coverage is 100%, providing clear documentation for all 4 parameters. The description adds minimal value beyond the schema, only reiterating that parameters are 'required' and referencing 'get-tools tool response.' It doesn't explain parameter interactions or provide examples, so it meets the baseline of 3 where the schema does the heavy lifting.

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

Purpose4/5

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

The description clearly states the tool's purpose: 'execute a specific method of another tool with the provided parameters based on get-tools tool response.' It specifies the verb ('execute') and resource ('method of another tool'), and distinguishes it from siblings by referencing 'get-tools tool response.' However, it doesn't explicitly name the sibling tools or contrast their purposes directly, preventing a perfect score.

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

Usage Guidelines4/5

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

The description provides clear context for usage: 'based on get-tools tool response' implies this tool should be used after get_tools to invoke methods discovered there. It distinguishes from get_tools (which lists tools) and get_flow (unclear but likely different). However, it lacks explicit when-not-to-use guidance or alternative scenarios, such as direct tool calls without get_tools, keeping it from a 5.

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/clarenous/veyrax-mcp'

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