Skip to main content
Glama
edkdev

DeFi Trading Agent MCP Server

by edkdev

get_new_pools

Retrieve newly created liquidity pools across multiple blockchain networks to identify emerging trading opportunities in decentralized finance.

Instructions

Get latest new pools across all networks

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
includeNoAttributes to include: 'base_token', 'quote_token', 'dex', 'network' (comma-separated)
pageNoPage number for pagination (optional, default: 1)

Implementation Reference

  • Defines the input schema, description, and metadata for the 'get_new_pools' MCP tool in the tools list returned by ListToolsRequestHandler.
    {
      name: TOOL_NAMES.GET_NEW_POOLS,
      description: "Get latest new pools across all networks",
      inputSchema: {
        type: "object",
        properties: {
          include: {
            type: "string",
            description:
              "Attributes to include: 'base_token', 'quote_token', 'dex', 'network' (comma-separated)",
          },
          page: {
            type: "integer",
            description: "Page number for pagination (optional, default: 1)",
          },
        },
        required: [],
      },
    },
  • src/index.js:1057-1062 (registration)
    Registers the 'get_new_pools' tool handler dispatch in the CallToolRequestHandler switch statement, mapping tool calls to toolService.getNewPools().
    case TOOL_NAMES.GET_NEW_POOLS:
      result = await toolService.getNewPools({
        include: args.include,
        page: args.page,
      });
      break;
  • The primary handler function for the 'get_new_pools' tool. Delegates to CoinGeckoApiService, formats the response with message, data, and summary.
    async getNewPools(options = {}) {
      const result = await this.coinGeckoApi.getNewPools(options);
    
      return {
        message: "New pools retrieved successfully",
        data: result,
        summary: `Found ${
          result.data?.length || 0
        } new pools across all networks`,
      };
    }
  • Core helper function that performs the HTTP request to CoinGecko's /networks/new_pools endpoint to fetch new pools data.
    async getNewPools(options = {}) {
      try {
        const queryParams = new URLSearchParams();
        
        if (options.include) queryParams.append('include', options.include);
        if (options.page) queryParams.append('page', options.page);
    
        const url = `${this.baseUrl}/networks/new_pools${queryParams.toString() ? '?' + queryParams.toString() : ''}`;
        
        const response = await fetch(url, {
          headers: {
            'x-cg-demo-api-key': this.apiKey
          }
        });
        
        if (!response.ok) {
          throw new Error(`HTTP ${response.status}: ${response.statusText}`);
        }
        
        return await response.json();
      } catch (error) {
        throw new Error(`Failed to get new pools: ${error.message}`);
      }
    }
  • Constant definition for the tool name 'get_new_pools' used throughout the codebase.
    GET_NEW_POOLS: "get_new_pools",
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 'latest new pools' and 'across all networks', hinting at recency and scope, but fails to detail critical aspects like rate limits, authentication needs, data freshness, pagination behavior beyond the schema, or what 'new' means (e.g., time window). This leaves significant gaps for a tool that likely involves network calls.

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, efficient sentence that front-loads the core purpose without unnecessary words. Every part ('Get latest new pools across all networks') contributes directly to understanding the tool's function, making it highly concise and well-structured.

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 of fetching data across networks with parameters, no annotations, and no output schema, the description is insufficient. It lacks details on behavior (e.g., how 'latest' is defined, error handling), output format, or integration with sibling tools, leaving the agent under-informed 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 both parameters ('include' and 'page'). The description adds no additional parameter semantics beyond implying a focus on 'latest new pools', which doesn't clarify parameter usage. This meets the baseline for high schema coverage, but doesn't enhance understanding.

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 action ('Get') and resource ('latest new pools across all networks'), making the purpose immediately understandable. It doesn't explicitly differentiate from sibling tools like 'get_trending_pools' or 'search_pools', which prevents a perfect score, but the scope ('latest new pools across all networks') provides reasonable distinction.

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 is provided on when to use this tool versus alternatives like 'get_trending_pools', 'search_pools', or 'get_multiple_pools_data'. The description implies it's for retrieving newly created pools, but it doesn't specify use cases, prerequisites, or exclusions, leaving the agent to infer context.

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/edkdev/defi-trading-mcp'

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