Skip to main content
Glama
chainfetch

ChainFETCH MCP Server

Official
by chainfetch

search_addresses_json

Search Ethereum addresses using JSON queries with 150+ parameters to filter by balance, contract status, transaction history, and verification.

Instructions

JSON search for addresses with 150+ parameters for comprehensive filtering

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
eth_balance_minNoMinimum ETH balance (in ETH, e.g., "1.5")
eth_balance_maxNoMaximum ETH balance (in ETH, e.g., "10.0")
is_contractNoWhether the address is a contract
is_verifiedNoWhether the address is verified
has_token_transfersNoWhether the address has token transfers
transactions_count_minNoMinimum transactions count
transactions_count_maxNoMaximum transactions count
limitNoNumber of results to return (default: 10, max: 50)
offsetNoNumber of results to skip for pagination (default: 0)

Implementation Reference

  • The handler case within the handleToolCall switch statement that dispatches the tool call to the ChainFETCH API endpoint for JSON-based address searching.
    case 'search_addresses_json':
      return await this.makeRequest('/api/v1/ethereum/addresses/json_search', 'GET', args, null, token);
  • The input schema defining all parameters for the JSON search tool, supporting comprehensive filtering with parameters like ETH balance ranges, contract status, transaction counts, pagination, etc.
    inputSchema: {
      type: 'object',
      properties: {
        eth_balance_min: {
          type: 'string',
          description: 'Minimum ETH balance (in ETH, e.g., "1.5")',
        },
        eth_balance_max: {
          type: 'string',
          description: 'Maximum ETH balance (in ETH, e.g., "10.0")',
        },
        is_contract: {
          type: 'boolean',
          description: 'Whether the address is a contract',
        },
        is_verified: {
          type: 'boolean',
          description: 'Whether the address is verified',
        },
        has_token_transfers: {
          type: 'boolean',
          description: 'Whether the address has token transfers',
        },
        transactions_count_min: {
          type: 'integer',
          description: 'Minimum transactions count',
        },
        transactions_count_max: {
          type: 'integer',
          description: 'Maximum transactions count',
        },
        limit: {
          type: 'integer',
          description: 'Number of results to return (default: 10, max: 50)',
          default: 10,
        },
        offset: {
          type: 'integer',
          description: 'Number of results to skip for pagination (default: 0)',
          default: 0,
        },
      },
      required: [],
    },
  • index.js:60-107 (registration)
    Registration of the tool in the listTools response, including name, description, and full input schema.
    {
      name: 'search_addresses_json',
      description: 'JSON search for addresses with 150+ parameters for comprehensive filtering',
      inputSchema: {
        type: 'object',
        properties: {
          eth_balance_min: {
            type: 'string',
            description: 'Minimum ETH balance (in ETH, e.g., "1.5")',
          },
          eth_balance_max: {
            type: 'string',
            description: 'Maximum ETH balance (in ETH, e.g., "10.0")',
          },
          is_contract: {
            type: 'boolean',
            description: 'Whether the address is a contract',
          },
          is_verified: {
            type: 'boolean',
            description: 'Whether the address is verified',
          },
          has_token_transfers: {
            type: 'boolean',
            description: 'Whether the address has token transfers',
          },
          transactions_count_min: {
            type: 'integer',
            description: 'Minimum transactions count',
          },
          transactions_count_max: {
            type: 'integer',
            description: 'Maximum transactions count',
          },
          limit: {
            type: 'integer',
            description: 'Number of results to return (default: 10, max: 50)',
            default: 10,
          },
          offset: {
            type: 'integer',
            description: 'Number of results to skip for pagination (default: 0)',
            default: 0,
          },
        },
        required: [],
      },
    },
  • Shared helper method that performs authenticated HTTP requests to the ChainFETCH API, handling query parameters, authentication, and error handling. This is the core logic executed for the tool.
    async makeRequest(endpoint, method = 'GET', params = {}, body = null, token = null) {
      const chainfetchToken = token || process.env.CHAINFETCH_API_TOKEN;
      
      if (!chainfetchToken) {
        throw new McpError(
          ErrorCode.InvalidRequest,
          'CHAINFETCH_API_TOKEN is required'
        );
      }
    
      const url = new URL(`${API_BASE_URL}${endpoint}`);
      
      // Add query parameters for GET requests
      if (method === 'GET' && Object.keys(params).length > 0) {
        Object.entries(params).forEach(([key, value]) => {
          if (value !== undefined && value !== null) {
            if (Array.isArray(value)) {
              value.forEach(v => url.searchParams.append(`${key}[]`, v));
            } else {
              url.searchParams.append(key, value.toString());
            }
          }
        });
      }
    
      const fetchOptions = {
        method,
        headers: {
          'Authorization': `Bearer ${chainfetchToken}`,
          'Content-Type': 'application/json',
        },
      };
    
      if (body && method !== 'GET') {
        fetchOptions.body = JSON.stringify(body);
      }
    
      const response = await fetch(url.toString(), fetchOptions);
      
      if (!response.ok) {
        const errorText = await response.text();
        throw new McpError(
          ErrorCode.InternalError,
          `API request failed: ${response.status} ${response.statusText} - ${errorText}`
        );
      }
    
      return await response.json();
    }
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 mentions '150+ parameters for comprehensive filtering' which hints at complexity, but fails to describe critical behaviors such as pagination mechanics (implied by offset/limit in schema but not explained), rate limits, authentication requirements, or what the search returns. For a search tool with many parameters, this is a significant gap in transparency.

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 a single, efficient sentence that front-loads key information (JSON search, addresses, 150+ parameters). It avoids redundancy but could be slightly more structured by explicitly mentioning the tool's output or context. Overall, it's appropriately sized with no wasted words.

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 complexity implied by '150+ parameters' and the lack of annotations and output schema, the description is incomplete. It doesn't explain the return format, error handling, or how to interpret results, which are crucial for a search tool. The schema covers the 9 listed parameters well, but the description fails to address the broader context needed for effective use.

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%, so the schema fully documents all 9 parameters. The description adds minimal value beyond the schema by mentioning '150+ parameters for comprehensive filtering', which suggests broader parameter availability than shown in the schema but doesn't clarify semantics for the undocumented parameters. This meets the baseline of 3 when schema coverage is high.

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 performs 'JSON search for addresses' with 'comprehensive filtering', which specifies the verb (search), resource (addresses), and scope (JSON format, 150+ parameters). It distinguishes from siblings like get_address_info by emphasizing search functionality, though it doesn't explicitly contrast with search_addresses_llm or search_addresses_semantic beyond the JSON format mention.

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

Usage Guidelines3/5

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

The description implies usage for comprehensive filtering via JSON, suggesting it's appropriate when detailed parameter control is needed. However, it lacks explicit guidance on when to choose this tool over alternatives like search_addresses_llm or search_addresses_semantic, and doesn't mention prerequisites or exclusions, leaving usage context somewhat vague.

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/chainfetch/chainfetch-mcp-server'

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