Skip to main content
Glama

joules_balance

Read-only

Your own wallet balance, free. A GreenlandAI agent key (gai_/gqa_) reads its own wallet with no arguments; a JoulePAI or ENYAL credential passes wallet_id. The graph meter debits this same wallet.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "joules_balance"
  }
}

Input Schema

NameRequiredDescriptionDefault
wallet_idNoWallet id (UUID) to read

Output Schema

NameRequiredDescriptionDefault
idNo
handleNo
balanceNo
agent_idNo
wallet_idNo
agent_nameNo
owner_typeNo
balance_joulesNo
verification_statusNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed27 schema fields changed
    • removedInput schema / properties / wallet_id / default
      Removed value: -null
    • changedInput schema / properties / wallet_id / description
      Previous value: -"Wallet id (UUID) to read — needed for a JoulePAI (jlp_) or ENYAL (eyl_) credential; not needed with a GreenlandAI agent key (gai_/gqa_), which reads its own wallet."New value: +"Wallet id (UUID) to read"
    • removedInput schema / properties / wallet_id / title
      Removed value: -"Wallet Id"
    • removedInput schema / title
      Removed value: -"joules_balanceArguments"
    • removedOutput schema / description
      Removed value: -"joules_balance — the union of its two branches. GAI agent-key branch returns\n{agent_id, agent_name, wallet_id, balance_joules} (+ the `balance` shape-compat shim added by\nthis relay); the JoulePAI branch returns WalletOut, whose wallet id field is `id`, not\n`wallet_id`. Both are declared so either branch is structured. PII the JP branch may carry\n(email, bsv_address, signup_grant) is deliberately NOT declared — it still passes through as an\nextra, but it is not advertised in a schema that anonymous clients can enumerate."
    • removedOutput schema / properties / agent_id / default
      Removed value: -null
    • removedOutput schema / properties / agent_id / title
      Removed value: -"Agent Id"
    • removedOutput schema / properties / agent_name / default
      Removed value: -null
    • removedOutput schema / properties / agent_name / title
      Removed value: -"Agent Name"
    • removedOutput schema / properties / balance / default
      Removed value: -null
    • removedOutput schema / properties / balance / description
      Removed value: -"spendable joules; the field to act on"
    • removedOutput schema / properties / balance / title
      Removed value: -"Balance"
    • removedOutput schema / properties / balance_joules / default
      Removed value: -null
    • removedOutput schema / properties / balance_joules / description
      Removed value: -"GAI agent-branch name for the same figure"
    • removedOutput schema / properties / balance_joules / title
      Removed value: -"Balance Joules"
    • removedOutput schema / properties / handle / default
      Removed value: -null
    • removedOutput schema / properties / handle / title
      Removed value: -"Handle"
    • removedOutput schema / properties / id / default
      Removed value: -null
    • removedOutput schema / properties / id / description
      Removed value: -"JoulePAI branch returns the wallet id here"
    • removedOutput schema / properties / id / title
      Removed value: -"Id"
    • removedOutput schema / properties / owner_type / default
      Removed value: -null
    • removedOutput schema / properties / owner_type / title
      Removed value: -"Owner Type"
    • removedOutput schema / properties / verification_status / default
      Removed value: -null
    • removedOutput schema / properties / verification_status / title
      Removed value: -"Verification Status"
    • removedOutput schema / properties / wallet_id / default
      Removed value: -null
    • removedOutput schema / properties / wallet_id / title
      Removed value: -"Wallet Id"
    • removedOutput schema / title
      Removed value: -"BalanceOut"
  2. Changed3 schema fields changed
    • addedInput schema / properties / wallet_id / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / wallet_id / description
      Added value: +"Wallet id (UUID) to read — needed for a JoulePAI (jlp_) or ENYAL (eyl_) credential; not needed with a GreenlandAI agent key (gai_/gqa_), which reads its own wallet."
    • removedInput schema / properties / wallet_id / type
      Removed value: -"string"
  3. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "description": "joules_balance — the union of its two branches. GAI agent-key branch returns\n{agent_id, agent_name, wallet_id, balance_joules} (+ the `balance` shape-compat shim added by\nthis relay); the JoulePAI branch returns WalletOut, whose wallet id field is `id`, not\n`wallet_id`. Both are declared so either branch is structured. PII the JP branch may carry\n(email, bsv_address, signup_grant) is deliberately NOT declared — it still passes through as an\nextra, but it is not advertised in a schema that anonymous clients can enumerate.",
      +  "properties": {
      +    "agent_id": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Agent Id"
      +    },
      +    "agent_name": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Agent Name"
      +    },
      +    "balance": {
      +      "anyOf": [
      +        {
      +          "type": "integer"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "description": "spendable joules; the field to act on",
      +      "title": "Balance"
      +    },
      +    "balance_joules": {
      +      "anyOf": [
      +        {
      +          "type": "integer"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "description": "GAI agent-branch name for the same figure",
      +      "title": "Balance Joules"
      +    },
      +    "handle": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Handle"
      +    },
      +    "id": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "description": "JoulePAI branch returns the wallet id here",
      +      "title": "Id"
      +    },
      +    "owner_type": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Owner Type"
      +    },
      +    "verification_status": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Verification Status"
      +    },
      +    "wallet_id": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Wallet Id"
      +    }
      +  },
      +  "title": "BalanceOut",
      +  "type": "object"
      +}
  4. Changed2 schema fields changed
    • addedInput schema / properties / wallet_id / default
      Added value: +null
    • removedInput schema / required
      Removed value: -[
      -  "wallet_id"
      -]
  5. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already cover read-only, non-destructive, closed-world semantics, and the description adds genuinely new context: the call is free and 'the graph meter debits this same wallet', which tells the agent the balance is the metered/spendable one. It does not disclose error behavior for mismatched credentials or cross-wallet reads.

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?

Three short sentences, purpose front-loaded, then the credential branching rule, then the metering note. No filler and nothing repeated from the schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema covering return values and annotations covering safety, the description only needs to supply auth/cost context, which it does. Minor gaps remain around failure modes and whether a wallet other than your own can be read.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description earns an upgrade by explaining that wallet_id is credential-conditional — required only for JoulePAI/ENYAL, omitted for GreenlandAI agent keys — which the schema's plain 'Wallet id (UUID) to read' does not convey.

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 states a specific verb+resource ('Your own wallet balance') and adds that it is free of charge, so an agent knows exactly what is returned. It does not explicitly distinguish itself from nearby siblings such as deposits, balance_proof, or joules_deficit, so differentiation is only implied by 'your own wallet'.

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

Usage Guidelines4/5

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

It gives concrete calling conditions: a gai_/gqa_ agent key reads its own wallet with no arguments, while JoulePAI or ENYAL credentials must pass wallet_id. It stops short of naming when to prefer an alternative sibling (e.g. a proof or history tool) or when this call would fail.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources