Skip to main content
Glama

Agent Data Tools: Utilities

Random number

random_number
Read-only

One or more random whole numbers in a range (inclusive), optionally all different, from a cryptographic random source. Use for draws, sampling and games. Example: min=1, max=100, count=3, unique=true. Price $0.003/call via x402 USDC or a card key (/credits), first 25 free; failed calls free. Reads or computes only and changes nothing; each call is charged, so repeats are not free.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
maxNoHighest value (default 100)
minNoLowest value (default 1)
countNoHow many (1-1000, default 1)
uniqueNotrue for no repeats

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the annotations it discloses the cryptographic source, the inclusive range semantics, and a full billing model ($0.003/call via x402 USDC or card key, first 25 free, failed calls free). 'Each call is charged, so repeats are not free' usefully explains the practical consequence of idempotentHint=false.

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?

Front-loads purpose and usage before the example and pricing tail. Every sentence earns its place, though the pricing clause is long enough that it slightly dilutes the quick-scan shape of the opening.

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 no output schema the description should ideally hint at the return shape (single integer vs array of count integers) and what happens when unique=true with count exceeding the range size. Those gaps aside, purpose, billing, and parameter behavior are all covered for a simple 4-param tool.

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 adds real meaning the schema lacks: the range is inclusive, unique means no repeats, and the worked example (min=1, max=100, count=3, unique=true) shows the parameters together. Minor credit withheld only because defaults already live in the schema.

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+resource ('One or more random whole numbers in a range (inclusive)') plus the differentiator ('optionally all different, from a cryptographic random source'). That scope cleanly separates it from siblings like random_pick, random_shuffle, dice, and coin.

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?

'Use for draws, sampling and games' gives clear situational context, and an inline example anchors the call shape. It stops short of naming alternatives (e.g. random_pick for choosing from a list) or stating when not to use it, so it is clear but not exclusionary.

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.