Skip to main content
Glama

helius_get_minimum_balance_for_rent_exemption

Calculate the minimum SOL balance required for an account of a given data size to be rent-exempt on Solana. Avoid paying rent by ensuring your account meets the exemption threshold.

Instructions

Get the minimum balance required for rent exemption

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataSizeYes
commitmentNo

Implementation Reference

  • Main handler function that calls Helius SDK to get minimum balance for rent exemption based on dataSize and optional commitment.
    export const getMinimumBalanceForRentExemptionHandler = async (input: GetMinimumBalanceForRentExemptionInput): Promise<ToolResultSchema> => {
      try {
        const minBalance = await (helius as any as Helius).connection.getMinimumBalanceForRentExemption(input.dataSize, input.commitment);
        return createSuccessResponse(`Minimum balance for rent exemption: ${minBalance}`);
      } catch (error) {
        return createErrorResponse(`Error getting minimum balance: ${error instanceof Error ? error.message : String(error)}`);
      }
    }
  • TypeScript type definition for the input parameters (dataSize required, commitment optional).
    export type GetMinimumBalanceForRentExemptionInput = {
      dataSize: number;
      commitment?: "confirmed" | "finalized" | "processed";
    }
  • src/tools.ts:177-188 (registration)
    Tool definition in the tools array with name, description, and inputSchema.
    {
      name: "helius_get_minimum_balance_for_rent_exemption",
      description: "Get the minimum balance required for rent exemption",
      inputSchema: {
        type: "object",
        properties: {
          dataSize: { type: "number" },
          commitment: { type: "string", enum: ["confirmed", "finalized", "processed"] }
        },
        required: ["dataSize"]
      }
    },
  • src/tools.ts:563-563 (registration)
    Handler mapping in the handlers dictionary that links the tool name to the handler function.
    "helius_get_minimum_balance_for_rent_exemption": getMinimumBalanceForRentExemptionHandler,
  • Import of the handler from the handlers file (part of the registration chain).
    getMinimumBalanceForRentExemptionHandler,
Behavior2/5

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

With no annotations, the description carries full burden but only states the return value; it fails to disclose read-only semantics, error conditions, or limitations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single concise sentence, but its brevity sacrifices necessary parameter details, making it neither optimally structured nor informative.

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?

Although the tool is simple, the description omits parameter semantics and usage context, leaving the agent underinformed for correct invocation.

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

Parameters1/5

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

Schema description coverage is 0% and the description adds no explanation for 'dataSize' or 'commitment', forcing the agent to infer meaning solely from parameter names.

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

Purpose5/5

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

The description uses the specific verb 'Get' and clearly identifies the resource as 'minimum balance for rent exemption', which is distinct from sibling get_* tools that retrieve different data.

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, nor any prerequisites for computing rent exemption.

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

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