Skip to main content
Glama

complete_work_ticket_grant

Create or recover a work ticket using the buyer's EIP-191 signature of the exact grant challenge. No private key is sent. Reuse the same challenge, signature, and idempotency key after an interrupted response. New Work Ticket grants retain the exact verified message and buyer signature atomically with creation. Replays preserve the original proof. Older grants may lack a stored signature; migration and replay do not reconstruct it. Status and inbox APIs omit these proofs; the buyer or selected merchant can use the private Transaction Evidence export. Save the original message, signature and idempotency key locally. A grant is not payment authorization.

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": {
      "buyer": "<buyer>",
      "merchantId": "<merchantId>",
      "capability": "<capability>",
      "input": "<input>",
      "maxPriceUSDC": "<maxPriceUSDC>",
      "expiresInSeconds": "<expiresInSeconds>",
      "idempotencyKey": "<idempotencyKey>",
      "challengeId": "<challengeId>",
      "signature": "<signature>"
    },
    "name": "complete_work_ticket_grant"
  }
}

Input Schema

NameRequiredDescriptionDefault
buyerYes
inputYes
agreementNo
signatureYes
capabilityYes3–100 Unicode code points after trimming.
merchantIdYes
challengeIdYes
maxPriceUSDCYes
idempotencyKeyYes
expiresInSecondsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / agreement
      Added value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "proposalId": {
      +      "format": "uuid",
      +      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      +      "type": "string"
      +    },
      +    "proposalTermsHash": {
      +      "pattern": "^[a-f0-9]{64}$",
      +      "type": "string"
      +    },
      +    "protocol": {
      +      "const": "402mob.work-agreement.v1",
      +      "type": "string"
      +    },
      +    "requestId": {
      +      "format": "uuid",
      +      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      +      "type": "string"
      +    },
      +    "settlementMode": {
      +      "const": "direct_prepayment",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "protocol",
      +    "requestId",
      +    "proposalId",
      +    "proposalTermsHash",
      +    "settlementMode"
      +  ],
      +  "type": "object"
      +}
  2. Changed3 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / capability / description
      Added value: +"3–100 Unicode code points after trimming."
    • changedInput schema / properties / maxPriceUSDC / pattern
      Previous value: -"^(?!0+(?:\\.0{1,6})?$)(?:0|[1-9][0-9]{0,17})(?:\\.[0-9]{1,6})?$"New value: +"^(?!0+(?:\\.0{1,6})?$)(?:0|[1-9][0-9]{0,5})(?:\\.[0-9]{1,6})?$"
  3. Added

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral burden and does well: it states that no private key is sent, that proof is retained atomically with new grants, that replays preserve the original proof, and that older grants may lack a stored signature. It also clarifies that status and inbox APIs omit these proofs and that the tool is not payment authorization.

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?

The description is front-loaded with the core action and then layers in recovery, proof retention, storage, and authorization caveats without obvious filler. Each sentence contributes operational context for a complex signed grant flow.

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

Completeness3/5

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

The behavioral context is rich for a mutation-like flow with no annotations and no output schema. However, given 10 parameters and very low schema description coverage, the definition is still incomplete about several inputs and does not describe the response shape.

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

Parameters2/5

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

Schema description coverage is only 10% across 10 parameters, so the description must compensate heavily. It adds meaning for signature, challenge, and idempotency key, but leaves buyer, merchantId, capability, input, maxPriceUSDC, expiresInSeconds, and agreement largely unexplained beyond schema constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource: creating or recovering a work ticket using the buyer's EIP-191 signature of the grant challenge. It is clear enough to separate this from challenge-creation siblings, although it does not explicitly name an alternative tool.

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?

It gives useful usage context, especially for interrupted responses: reuse the same challenge, signature, and idempotency key. It also says to save those values locally, but it does not explicitly compare this tool with sibling tools such as create_work_ticket_grant_challenge.

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