Skip to main content
Glama

getProposal

Retrieve detailed information about a specific Snapshot.org proposal using its unique ID to analyze governance decisions and voting data.

Instructions

Get details of a specific proposal

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
proposalIdYesID of the proposal

Implementation Reference

  • MCP tool handler for 'getProposal': validates input arguments using Zod schema and delegates execution to SnapshotService.getProposal, returning the result as JSON string.
    case "getProposal": {
      const parsedArgs = ProposalParamsSchema.parse(args);
      const proposal = await this.snapshotService.getProposal(parsedArgs.proposalId);
      return {
        content: [{
          type: "text",
          text: JSON.stringify(proposal, null, 2)
        }]
      };
  • Zod schema defining the input parameters for the getProposal tool (proposalId: string). Used for runtime validation in the handler.
    const ProposalParamsSchema = z.object({
      proposalId: z.string()
    });
  • src/server.ts:93-103 (registration)
    Registers the 'getProposal' tool in the MCP tools/list response, providing name, description, and JSON inputSchema for validation.
    {
      name: "getProposal",
      description: "Get details of a specific proposal",
      inputSchema: {  // Changed from parameters to inputSchema
        type: "object",
        properties: {
          proposalId: { type: "string", description: "ID of the proposal" }
        },
        required: ["proposalId"]
      }
    },
  • Core implementation of getProposal: executes GraphQL query against Snapshot API to fetch detailed proposal information by ID.
    async getProposal(proposalId: string): Promise<Proposal> {
      const query = `
        query Proposal {
          proposal(id: "${proposalId}") {
            id
            title
            body
            choices
            start
            end
            snapshot
            state
            author
            space {
              id
              name
            }
          }
        }
      `;
    
      const result = await this.queryGraphQL(query);
      return result.proposal;
    }
Behavior2/5

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

No annotations are provided, so the description carries full burden for behavioral disclosure. It states a read operation ('Get'), implying it's likely safe and non-destructive, but doesn't confirm this or add context like authentication needs, rate limits, error handling, or return format. The description is minimal and lacks behavioral details beyond the basic action.

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, clear sentence with no wasted words, making it appropriately concise. It's front-loaded with the core action, though it could be more structured if it included additional context. Efficiency is high, but it borders on under-specification.

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 no annotations, no output schema, and a simple input schema, the description is incomplete. It doesn't explain what details are returned, error conditions, or behavioral traits. For a tool with minimal structured data, the description should provide more context to aid the agent in correct invocation.

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%, with the parameter 'proposalId' fully documented in the schema. The description adds no additional meaning about the parameter beyond what the schema provides (e.g., format examples or constraints). Baseline 3 is appropriate as the schema handles parameter documentation adequately.

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

Purpose3/5

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

The description states the verb ('Get') and resource ('details of a specific proposal'), which provides a basic understanding of purpose. However, it lacks specificity about what details are retrieved and doesn't differentiate from sibling tools like 'getProposals' (which presumably lists multiple proposals). The description is functional but vague about scope.

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. The description doesn't mention prerequisites (e.g., needing a proposal ID), exclusions, or comparisons to siblings like 'getProposals' for listing or 'getUser' for user-related data. Usage is implied but not explicitly stated.

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

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