Skip to main content
Glama
Blink MCP Server

Blink MCP Server

Official
by blinkbitcoin

l402_payment_verify

Verifies client-submitted L402 payment tokens by checking the preimage, HMAC signature, and caveats, returning whether the token is valid.

Instructions

Verify an L402 payment token submitted by a client. Checks three layers: 1) preimage proves payment (SHA-256), 2) HMAC signature proves authenticity, 3) caveats (expiry, resource) are satisfied. Returns valid: true/false.

Input Schema

NameRequiredDescriptionDefault
tokenNoL402 token in <macaroon>:<preimage> format (colon-separated)
macaroonNobase64url-encoded macaroon (alternative to token)
preimageNo64-char hex preimage (alternative to token)
resourceNoExpected resource identifier to check against the macaroon caveat

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv2.0.0
    • addedInput schema / properties / macaroon / description
      Added value: +"base64url-encoded macaroon (alternative to token)"
    • addedInput schema / properties / preimage / description
      Added value: +"64-char hex preimage (alternative to token)"
    • addedInput schema / properties / resource / description
      Added value: +"Expected resource identifier to check against the macaroon caveat"
    • addedInput schema / properties / token / description
      Added value: +"L402 token in <macaroon>:<preimage> format (colon-separated)"
  2. First observedv1.2.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the exact checks performed (SHA-256 preimage, HMAC authenticity, caveat expiry/resource) and the return shape. It stops short of stating that the operation is side-effect-free/idempotent or describing failure modes beyond a false result.

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 tight sentences: what it does, what it checks (numbered), and what it returns. Zero filler and the core action is front-loaded.

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?

Because there is no output schema, the description correctly includes the return value ('valid: true/false'). It could go further by explaining which of the three layers failed or what an agent should do on an invalid result, but for a focused verification tool it is nearly complete.

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?

Schema description coverage is 100%, so token/macaroon/preimage/resource are already fully documented, including the alternative input forms. The description adds no additional parameter guidance, which is the expected baseline when the schema does the work.

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 ('Verify an L402 payment token') and immediately enumerates the three concrete layers being validated. This clearly separates it from siblings like l402_pay, l402_challenge_create, and l402_store, which create or consume rather than validate tokens.

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

Usage Guidelines3/5

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

The phrase 'submitted by a client' implies a server-side verification flow, giving implicit usage context. However, it never states when to prefer this over sibling tools or what to do on failure, so guidance remains implied rather than explicit.

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