Skip to main content
Glama
Seitrace

Seitrace Insights MCP Server

Official
by Seitrace

get_resource_action_schema

Retrieve the JSON Schema for a specific resource action to define and validate data structures in blockchain queries using the Seitrace API.

Instructions

Get the JSON Schema for a specific resource action.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionYes
resourceYes

Implementation Reference

  • The handler function that implements the core logic of the 'get_resource_action_schema' tool. It resolves the resource from the topic map, validates its existence, and delegates to the resource's getResourceActionSchema method.
    export const getResourceActionSchemaHandler = async (
      toolArgs: ToolArgs
    ): Promise<CallToolResult> => {
      const { resource } = toolArgs;
      const topicKey = resource.split('_')[0];
      const foundResource = TOPIC_KEY_MAP[topicKey] || TOPIC_KEY_MAP[resource];
    
      /**
       * Check if the resource exists
       */
      if (!foundResource || !(await foundResource.getResources()).has(resource)) {
        return McpResponse(JSON.stringify({ error: `Unknown or missing resource '${resource}'.` }));
      }
    
      /**
       * List actions for the resource
       */
      return foundResource.getResourceActionSchema(toolArgs);
    };
  • Defines the Tool object including name, description, and inputSchema for the 'get_resource_action_schema' tool, used in tool listing and validation.
    const listResourceActionSchema: Tool = {
      name: GET_RESOURCE_ACTION_SCHEMA_TOOL,
      description:
        'Get the JSON Schema for a specific resource action (step 3 - REQUIRED before invoking). This reveals the exact parameter names, types, and requirements. Always call this before invoke_resource_action.',
      inputSchema: {
        type: 'object',
        properties: {
          resource: { type: 'string' },
          action: { type: 'string' },
        },
        required: ['resource', 'action'],
        additionalProperties: false,
        description: 'Provide resource and action from previous steps.',
      },
    };
  • Registers the getResourceActionSchemaHandler under the tool name GET_RESOURCE_ACTION_SCHEMA_TOOL in the central handlerMap.
    export const handlerMap = {
      [LIST_RESOURCES_TOOL]: listResourcesHandler,
      [LIST_RESOURCE_ACTIONS_TOOL]: listResourceActionsHandler,
      [GET_RESOURCE_ACTION_SCHEMA_TOOL]: getResourceActionSchemaHandler,
      [GET_RESOURCE_ACTION_SNIPPET_TOOL]: getResourceActionSnippetHandler,
      [INVOKE_RESOURCE_ACTION_TOOL]: invokeResourceActionHandler,
    };
  • Defines the constant string for the tool name 'get_resource_action_schema'.
    export const GET_RESOURCE_ACTION_SCHEMA_TOOL = 'get_resource_action_schema';
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves a JSON Schema but does not specify whether this is a read-only operation, if it requires authentication, what happens on errors (e.g., invalid resource/action), or the format of the returned schema. This leaves critical behavioral traits unclear for a tool that likely interacts with system resources.

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?

The description is a single, clear sentence that directly states the tool's function without any unnecessary words. It is front-loaded and efficiently conveys the core purpose, making it easy to parse and understand quickly.

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

Completeness2/5

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

Given the tool's complexity (involves specific resources and actions) and the lack of annotations, output schema, and schema descriptions, the description is incomplete. It does not address key contextual aspects like error handling, return format, or dependencies on other tools (e.g., needing to list resources first). For a tool that likely returns structured data, more detail is needed to ensure proper use.

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

Parameters2/5

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

The input schema has 0% description coverage, so the parameters 'resource' and 'action' are undocumented in the schema. The description mentions 'specific resource action' but does not add meaning beyond this, such as examples of valid resources/actions, their formats, or where to find them. This fails to compensate for the schema's lack of documentation, leaving parameters ambiguous.

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 with a specific verb ('Get') and resource ('JSON Schema for a specific resource action'), making it immediately understandable. However, it does not explicitly differentiate from sibling tools like 'get_resource_action_snippet' or 'list_resource_actions', which might also involve resource actions, leaving some ambiguity about its unique role.

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?

The description provides no guidance on when to use this tool versus alternatives. It does not mention prerequisites, such as needing to know the resource and action names beforehand, or contrast it with siblings like 'list_resource_actions' (which might list available actions) or 'invoke_resource_action' (which might execute an action). This lack of context could lead to misuse.

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

Related 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/Seitrace/seitrace-mcp'

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