Skip to main content
Glama
io.github.JC7333/mandatia

io.github.JC7333/mandatia

by JC7333

prepare_revocation_signature

Prepares the exact payload a principal must sign to revoke a mandate, returning UTF-8 and base64url bytes without writing changes; use it before calling revoke_mandate.

Instructions

Return the exact bytes a principal must sign to revoke one of its mandates.

Nothing is written. The principal signs payload (UTF-8 bytes; payload_b64url is the same bytes) with its Ed25519 key, then calls revoke_mandate with the same mandate_id and reason plus principal_signature and this signed_at.

Args: mandate_id: UUID of the mandate to revoke. reason: Why it is revoked, as it will be recorded (1 to 500 characters). signed_at: ISO 8601 timestamp with timezone. Default: now (UTC).

Returns: JSON string with keys: payload (str), payload_b64url, signed_at, principal_id. On error: {"error": "...", "code": "..."}.

Input Schema

NameRequiredDescriptionDefault
reasonYes
signed_atNo
mandate_idYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations present, the description carries the full behavioral burden and does so: "Nothing is written" declares the absence of side effects, and it discloses that the caller must hold the principal's Ed25519 signing key. It also notes signed_at defaults to now in UTC and that the same timestamp must be carried forward to revoke_mandate, which is exactly the coordination detail an agent would otherwise miss.

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-loaded with the core purpose, then Args and Returns blocks that are easy to scan, and the clarification that payload_b64url is the same bytes as payload prevents an encoding mistake. The Returns key list partially duplicates the output schema, which is the only mildly redundant element.

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

Completeness5/5

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

Despite zero annotation coverage and zero schema description coverage, the description covers purpose, side-effect status, signing requirements, sequencing into revoke_mandate, all parameter constraints, and the error shape. For a three-parameter cryptographic preparation tool, nothing an agent needs in order to invoke it correctly is missing.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate and it does for all three parameters: mandate_id is a mandate UUID, reason is what will be recorded and must be 1-500 characters, and signed_at is an ISO 8601 timestamp with timezone defaulting to now UTC. These constraints exist nowhere in the schema and directly prevent invalid calls.

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: returning the exact bytes a principal must sign to revoke one of its mandates. It is clearly distinguished from the sibling signing helpers prepare_mandate_signature and prepare_contest_signature by naming the revoke workflow and the downstream revoke_mandate call.

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

Usage Guidelines5/5

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

Gives an explicit two-step workflow: call this to get the payload, sign it with the Ed25519 key, then call revoke_mandate with the same mandate_id and reason plus principal_signature and this signed_at. The alternative is named and the condition that selects it is spelled out, leaving nothing to inference.

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