Skip to main content
Glama

verify_fair

Read-onlyIdempotent

Verify a provably fair result locally, with no network call and no key. Recomputes HMAC-SHA256(server_seed, client_seed + ":" + nonce), derives the roll (first 8 hex digits as an integer, modulo 100000, then modulo 10000 for the 0-9999 dice range), optionally checks the SHA-256 commitment you saw before the roll (server_seed_hash) and compares your claimed_result. Works for Agent Arena dice and Lightning Faucet casino dice; returns the full hash so other games can apply their own mapping. Use the nonce the roll consumed, not the next one.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "server_seed": "<server_seed>",
      "client_seed": "<client_seed>",
      "nonce": "<nonce>"
    },
    "name": "verify_fair"
  }
}

Input Schema

NameRequiredDescriptionDefault
nonceYesNonce the roll consumed
client_seedYesThe client seed used for the roll, as the exact string shown in the roll result, for example my-seed-123
result_typeNoMapping claimed_result uses: dice (0-9999) or roll (0-99999)dice
server_seedYesRevealed server seed
claimed_resultNoOptional reported roll to compare
server_seed_hashNoOptional SHA-256 commitment to check

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / client_seed / description
      Added value: +"The client seed used for the roll, as the exact string shown in the roll result, for example my-seed-123"
  2. First observed

TDQS

A4.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so the safety profile is covered. The description adds genuinely useful behavior beyond that: it runs entirely locally with no key or network, discloses the exact derivation, and notes it returns the full hash for custom mappings. It does not cover failure behavior (e.g. what happens when server_seed_hash doesn't match the seed), which keeps it from a top score.

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?

Front-loads the core purpose in the first clause, then layers algorithm, applicability, and the nonce caveat in an order that matches how an agent would need the information. The parenthetical derivation is dense but every clause carries operational meaning; there is no filler.

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 six parameters, full schema coverage, and no output schema, the description competently fills the gaps: it explains the return (full hash) and the derivation, and clarifies the optional parameters' roles. It leaves mismatch/error handling and exact response shape unspecified, a minor gap for a deterministic read-only verifier.

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 3 baseline applies automatically, but the description goes further by clarifying that nonce must be the one the roll consumed, that server_seed_hash is the optional pre-roll commitment to check, and that claimed_result is an optional comparison target. That is meaningful guidance on how to combine the optional parameters, not just a restatement of field 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?

States a specific verb and resource — locally recomputing a provably fair roll — and immediately distinguishes itself from server-side verification with 'no network call and no key.' It even specifies the exact algorithm (HMAC-SHA256 of client_seed + ':' + nonce) and the mapping to the 0-9999 range, so an agent knows precisely what computation it performs.

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?

Gives concrete operating context: works for Agent Arena dice and Lightning Faucet casino dice, returns the full hash so other games can apply their own mapping, and warns to use the nonce the roll consumed rather than the next one. It stops short of explicitly naming an alternative tool (e.g. arena_fairness) that would cover server-side verification, so the when-not guidance is implied rather than stated.

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.