Skip to main content
Glama
Critical Raw Minerals & ESG Compliance Oracle(x402)

Critical Raw Minerals & ESG Compliance Oracle(x402)

generate_zk_compliance_proof

Read-onlyIdempotent

Generate a zero-knowledge compliance proof to shield exact mine coordinates and unit costs while proving concession validity and China content below 0.1%.

Instructions

Generates a zero-knowledge compliance proof that shields exact extraction coordinates and unit production costs while mathematically proving concession validity and China content < 0.1%. Returns structured JSON verdict, audit metadata, and cryptographic reference. Requires x402 USDC payment (Polygon/Base/Arbitrum/Solana) or Pre-Funded Agent Vault key after 1 free One-Shot Proof.

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": {
      "batch_id": "<batch_id>",
      "mineral_type": "<mineral_type>",
      "secret_mine_latitude": "<secret_mine_latitude>",
      "secret_mine_longitude": "<secret_mine_longitude>",
      "secret_supplier_id": "<secret_supplier_id>",
      "secret_unit_cost_usd": "<secret_unit_cost_usd>",
      "public_china_origin_ratio": "<public_china_origin_ratio>",
      "public_carbon_intensity_kg_co2": "<public_carbon_intensity_kg_co2>"
    },
    "name": "generate_zk_compliance_proof"
  }
}

Input Schema

NameRequiredDescriptionDefault
batch_idYesUnique mineral batch identifier to bind to the zero-knowledge compliance proof.
mineral_typeYesCritical mineral commodity type (e.g. LITHIUM_HYDROXIDE, NICKEL_MHP, COBALT_HYDROXIDE).
secret_supplier_idYesConfidential supplier identifier hashed into the private ZK witness.
secret_mine_latitudeYesConfidential mine latitude kept private inside the ZK witness (-90 to 90).
secret_unit_cost_usdYesConfidential unit procurement price in USD per metric ton kept private.
secret_mine_longitudeYesConfidential mine longitude kept private inside the ZK witness (-180 to 180).
public_china_origin_ratioYesPublicly disclosed China/FEOC origin share ratio (0.0 to 1.0) proven below statutory threshold.
public_carbon_intensity_kg_co2YesPublicly disclosed carbon footprint intensity in kg CO2e per kg of mineral.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed13 schema fields changedv1.0.11
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / batch_id / description
      Added value: +"Unique mineral batch identifier to bind to the zero-knowledge compliance proof."
    • addedInput schema / properties / mineral_type / description
      Added value: +"Critical mineral commodity type (e.g. LITHIUM_HYDROXIDE, NICKEL_MHP, COBALT_HYDROXIDE)."
    • addedInput schema / properties / public_carbon_intensity_kg_co2 / description
      Added value: +"Publicly disclosed carbon footprint intensity in kg CO2e per kg of mineral."
    • addedInput schema / properties / public_china_origin_ratio / description
      Added value: +"Publicly disclosed China/FEOC origin share ratio (0.0 to 1.0) proven below statutory threshold."
    • addedInput schema / properties / secret_mine_latitude / description
      Added value: +"Confidential mine latitude kept private inside the ZK witness (-90 to 90)."
    • addedInput schema / properties / secret_mine_latitude / maximum
      Added value: +90
    • addedInput schema / properties / secret_mine_latitude / minimum
      Added value: +-90
    • addedInput schema / properties / secret_mine_longitude / description
      Added value: +"Confidential mine longitude kept private inside the ZK witness (-180 to 180)."
    • addedInput schema / properties / secret_mine_longitude / maximum
      Added value: +180
    • addedInput schema / properties / secret_mine_longitude / minimum
      Added value: +-180
    • addedInput schema / properties / secret_supplier_id / description
      Added value: +"Confidential supplier identifier hashed into the private ZK witness."
    • addedInput schema / properties / secret_unit_cost_usd / description
      Added value: +"Confidential unit procurement price in USD per metric ton kept private."
  2. Addedv1.0.7

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false and openWorldHint=true, so the safety profile is covered. The description nonetheless adds genuinely useful context the annotations cannot convey: what stays private in the witness, what is mathematically asserted, what the call returns, and the x402/vault payment model with a one-free-proof allowance. It stops short of describing failure behavior or how an x402 challenge is handled.

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 sentences, front-loaded with what the tool does, then its return shape, then its payment gate. Every sentence carries information an agent needs and there is no filler or repetition of the schema.

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 correctly compensates by stating the return shape (JSON verdict, audit metadata, cryptographic reference). For an 8-parameter, payment-gated proof generator the essential facts are present; only error paths and the relationship to the x402 challenge tool are unstated.

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 coverage is 100% and each parameter already carries a description marking it secret or public, so the schema does most of the work. The description contributes the proof semantics on top of that, notably the threshold (China content < 0.1%) that public_china_origin_ratio is tested against and the fact that coordinates and cost are witness-private, but it adds no per-parameter format or unit detail beyond the schema.

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?

States a specific verb and resource ('Generates a zero-knowledge compliance proof') and defines its exact scope: shielding extraction coordinates and unit costs while proving concession validity and China content below 0.1%. That is enough for an agent to tell it apart from verify_* siblings on purpose, but it never names a sibling or explicitly contrasts itself with them.

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

Usage Guidelines2/5

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

There is no when-to-use or when-not guidance and no named alternative among the many verify_* / get_compliance_status siblings. The only conditional information is a commercial prerequisite (one free proof, then x402 payment or vault key), which is a billing fact rather than a usage rule.

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