Skip to main content
Glama

Random code lock codes that avoid the ones raiders try first

generate_door_code
Read-onlyIdempotent

[Calculators] Random code lock codes that avoid the ones raiders try first. The door code generator (https://rust.wiki/calculators/door-code): random four-digit codes from the server's cryptographic random source, re-drawn until they match none of the guessable patterns the page checks (the 10 most common codes, one digit four times, runs like 1234, repeated pairs, mirrors, years, dates, two-digit codes), each with a different guest code. Codes are made fresh per request and never stored (the response is marked no-store); for a code that never leaves your device, use the page, which makes them in your browser. Give the user the code and guest code; they set them on the lock in game.

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": "generate_door_code"
  }
}

Input Schema

NameRequiredDescriptionDefault
countNoHow many code pairs to make.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior4/5

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

The description adds substantial behavior beyond the annotations: cryptographic random source, re-draw on pattern match, per-request generation, no storage, and a no-store response marker. The only friction is that 'made fresh per request' sits in tension with idempotentHint=true, though this reads as 'no side effects to repeat' rather than a true repeatable-value contract, so I do not treat it as a contradiction. What an agent does with the two returned values is also spelled out.

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?

Purpose is front-loaded in the first sentence, before the pattern list and the link. The parenthetical URL and long enumeration of excluded patterns make it denser than needed, but each clause carries real information an agent would otherwise have to guess.

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?

No output schema exists, and the description compensates by describing the return shape (a code plus a guest code per pair, fresh and unstored) and the required follow-up action. For a one-parameter, non-destructive generator, nothing essential is missing apart from an explicit statement that count defaults to 1.

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?

Single optional parameter with 100% schema coverage ('How many code pairs to make', 1-10), so the schema already carries the meaning. The description adds only the implicit clarification that every generated code comes with a distinct guest code, i.e. each unit is a pair. Baseline 3 for a fully documented single parameter.

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?

Names a specific artifact (random four-digit door codes), the exact filter applied (avoiding the guessable patterns: top 10 common codes, repeated digits, runs, pairs, mirrors, years, dates), and the paired guest code. It is clearly a generator, not a lookup, distinguishing it from check_door_code and get_door_code_rules.

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?

Explicit about the use case and tells the agent it must hand both the code and the guest code back to the user to set on the lock. It also states the alternative for a privacy-sensitive path (use the page so the code never leaves the device). It does not name a sibling tool as an alternative, but sibling behavior isn't asserted anywhere, so this is close to complete.

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