Skip to main content
Glama
buildwithgrove

Grove's MCP Server for Pocket Network

get_cosmos_proposals

Retrieve governance proposals from Cosmos blockchains to track voting status, filter by proposal stage, and monitor network decisions.

Instructions

Get governance proposals on a Cosmos chain

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
blockchainYesBlockchain name
statusNoOptional: Filter by proposal status
networkNoNetwork type (defaults to mainnet)

Implementation Reference

  • Input schema definition for the 'get_cosmos_proposals' tool, specifying parameters like blockchain, optional status filter, and network.
    {
      name: 'get_cosmos_proposals',
      description: 'Get governance proposals on a Cosmos chain',
      inputSchema: {
        type: 'object',
        properties: {
          blockchain: {
            type: 'string',
            description: 'Blockchain name',
          },
          status: {
            type: 'string',
            enum: ['deposit_period', 'voting_period', 'passed', 'rejected', 'failed'],
            description: 'Optional: Filter by proposal status',
          },
          network: {
            type: 'string',
            enum: ['mainnet', 'testnet'],
            description: 'Network type (defaults to mainnet)',
          },
        },
        required: ['blockchain'],
      },
    },
  • Handler logic for 'get_cosmos_proposals' tool within the handleCosmosTool switch statement. Extracts input arguments and delegates execution to CosmosService.getProposals, formats the response.
    case 'get_cosmos_proposals': {
      const blockchain = args?.blockchain as string;
      const status = args?.status as
        | 'deposit_period'
        | 'voting_period'
        | 'passed'
        | 'rejected'
        | 'failed'
        | undefined;
      const network = (args?.network as 'mainnet' | 'testnet') || 'mainnet';
    
      const result = await cosmosService.getProposals(blockchain, status, network);
    
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(result, null, 2),
          },
        ],
        isError: !result.success,
      };
    }
  • Core implementation of proposal fetching in CosmosService. Constructs the REST API endpoint (/cosmos/gov/v1beta1/proposals) with optional status filter and performs HTTP GET request.
    async getProposals(
      blockchain: string,
      status?: 'deposit_period' | 'voting_period' | 'passed' | 'rejected' | 'failed',
      network: 'mainnet' | 'testnet' = 'mainnet'
    ): Promise<EndpointResponse> {
      try {
        const baseUrl = this.getRestUrl(blockchain, network);
        const statusFilter = status ? `?proposal_status=${status}` : '';
        const url = `${baseUrl}/cosmos/gov/v1beta1/proposals${statusFilter}`;
    
        return this.fetchRest(url);
      } catch (error) {
        return {
          success: false,
          error: error instanceof Error ? error.message : 'Failed to get Cosmos proposals',
        };
      }
    }
  • src/index.ts:123-124 (registration)
    Registration of cosmos tool handler in the main MCP CallToolRequestHandler. Includes handleCosmosTool in the execution chain for tool dispatch.
    (await handleSolanaTool(name, args, solanaService)) ||
    (await handleCosmosTool(name, args, cosmosService)) ||
  • src/index.ts:97-101 (registration)
    Tool schema registration: collects Tool objects from registerCosmosHandlers (which defines the schema for get_cosmos_proposals) into the main tools list provided to the MCP server.
      ...registerSolanaHandlers(server, solanaService),
      ...registerCosmosHandlers(server, cosmosService),
      ...registerSuiHandlers(server, suiService),
      ...registerDocsHandlers(server, docsManager),
    ];
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 states the tool 'gets' proposals, implying a read-only operation, but doesn't clarify if it lists all proposals, supports pagination, returns structured data, or has rate limits. For a tool with no annotation coverage, this leaves significant gaps in understanding its behavior.

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 with no wasted words. It's front-loaded with the core purpose and efficiently conveys the tool's function. Every part of the description earns its place by directly stating what the tool does.

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 querying governance proposals and the lack of annotations and output schema, the description is insufficient. It doesn't explain what data is returned (e.g., proposal details, counts, or metadata), how results are formatted, or any limitations. For a tool with no structured output information, this leaves the agent poorly equipped to use it effectively.

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?

The schema description coverage is 100%, with clear descriptions for all parameters, including enums for 'status' and 'network.' The description adds no additional parameter semantics beyond what the schema provides, such as default behaviors or examples. 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 tool's purpose: 'Get governance proposals on a Cosmos chain.' It specifies the action ('Get') and resource ('governance proposals'), and distinguishes it from siblings like 'get_cosmos_proposal' (singular) and 'get_cosmos_proposal_votes.' However, it doesn't explicitly differentiate scope (e.g., all proposals vs. filtered), which prevents 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 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 doesn't mention sibling tools like 'get_cosmos_proposal' (for a single proposal) or 'get_cosmos_proposal_votes,' nor does it specify prerequisites or contexts for use. The agent must infer usage from the name and schema alone.

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/buildwithgrove/mcp-pocket'

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