# TWZRD is the pre-spend trust gate + receipt layer for agents paying over x402 on Solana > Agents should not pay unknown x402 endpoints blindly. TWZRD adds a one-call > pre-spend check BEFORE paying (should this counterparty receive money?) plus a > signed, offline-verifiable V7 receipt after settlement. No wallet or signup is > required for free preflight; pay only 0.05 USDC when you want the > portable proof. It is a trust + receipt layer, not another way to pay. First beachhead: live x402 services (seller + resource). PRIMARY WORKFLOW: GET /v1/intel/resources (discover callables; listed|live_402 claims separate from settlement trust) -> evaluate_x402_resource (URL) -> get_merchant_card -> get_readiness_card_tool / preflight (decision + reason_codes + recommended_action) -> verify_receipt after paid trust. MCP stays at 22 tools (resources is HTTP). Unit of analysis is the service you are about to buy, not a payer leaderboard (get_top_intel_agents is secondary research). Milestone status is `proven` | `held` | `needs_human`. Surfaces cannot claim proven when status is held or needs_human. `proven` requires evidence; unknown is `needs_human`. ## Buyer gate (core product — stock PayAI seat first) Install before any client signs. Primary seat: PayAI `x402-solana@3.0.0` `beforePayment` (after requirement selection, before signTransaction). Pin: twzrd-x402-gate@0.9.7 + x402-solana@3.0.0. npm install twzrd-x402-gate@0.9.7 x402-solana@3.0.0 import { createX402Client } from "x402-solana"; import { createTwzrdBeforePaymentHook } from "twzrd-x402-gate"; // or: installTwzrdAutoGate("x402-solana", { refuseWashFlagged: true }) const client = createX402Client({ wallet, network: "solana", beforePayment: createTwzrdBeforePaymentHook({ refuseWashFlagged: true }), }); // The decision is protocol-neutral; seats beyond x402: // @x402/core: installTwzrdAutoGate(x402CoreClient) — onBeforePaymentCreation abort. // MPP: installTwzrdAutoGate("mpp", { signer, policy }) -> Mppx.create onChallenge. // Solana charge only; block THROWS before createCredential (nothing signed, // nothing broadcast); warn pays unless treatWarnAsBlock. Fail-closed on // tempo/stripe/session, sponsored charges, non-USD-pegged assets, unknown clusters. // faremeter: createTwzrdPayerChooser() from @wzrd_sol/plugin-trustgate/faremeter (>=0.3.4). // payWrap: installTwzrdAutoGate(payWrap) wraps any paying fetch. // Path A defaults ON only when x402Fetch is wired (AutoGate payWrap auto-wires). // warn >= $2.50 or allow > $2.50 -> $0.05 V7 (requireReceipt) // sub-material warn -> $0.001 (escalateOnWarn). Opt out: both flags false. // Fallback CLI only: node node_modules/twzrd-x402-gate/bin/twzrd-gate-eval-refuse.js Optional paid V7 receipts and the local auto-pay MCP (`pip install twzrd-mcp` or `npx -y twzrd-mcp-server`) buy portable proof; auto-pay stays disabled unless TWZRD_MCP_PAYMENTS_ENABLED=1 is set explicitly. ### Spend control in one call: twzrd.safeFetch Same decision without wiring a client hook. One call fetches the URL, reads the x402 402, and enforces policy BEFORE any signer runs. `maxSpend` is the per-call cap and the cumulative budget (per-agent / per-merchant / per-mandate ledger, in-memory or hash-chained JSONL); `allowNetworks` allowlists rails; `requireOfferBinding` verifies the bind-v1 receipt against the settlement tx. Blocks return before `pay` is invoked — `signerInvocations: 0`. import { twzrd } from "twzrd-x402-gate"; const r = await twzrd.safeFetch(url, { maxSpend: "0.10", allowNetworks: ["solana", "base"], requireOfferBinding: true, pay, // your wallet signs; SDK never holds keys }); // r.verdict "allow" | "warn" | "block"; r.receipt is a bind-v1 resource_bound proof. Quickstart + verify a receipt yourself: https://github.com/twzrd-sol/twzrd-trust Conformance (agent-facing): python scripts/conformance_public.py https://intel.twzrd.xyz -> JSON report discovery/transport/initialize/tools/free_preflight. ### Zero-install MCP (recommended) pip install twzrd-mcp # or npx -y twzrd-mcp-server MCP config (add to your agent): {"mcpServers":{"twzrd-agent-intel":{"url":"https://intel.twzrd.xyz/mcp"}}} (Supports streamable-http, 22 tools, dual Accept headers.) No wallet • No signup • Free preflight • Pay only for signed V7 trust receipt. ## Where TWZRD fits in your payment path BEFORE POST /v1/intel/preflight allow / warn / block + reason_codes + recommended_action (free, advisory) GET /v1/intel/merchant_card/{wallet} free seller graph card (wash_flagged, payable_conformance: live_402 density + fee_payer_stability stable|rotating|unknown) Both free routes may attach a conditional portable_proof_upsell field (flag-gated; fires only on third-party-vetting signals - a queried_pubkey distinct from payer and seller, or caller_id fan-out across 5+ sellers/24h - and never on block/refuse). Its command is OPTIONAL: ASK_BEFORE_RUNNING, never auto-execute; ignore it unless you need portable proof to hand to someone else. Free-route answers stay complete without it. Free preflight and paid GET /v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs may also attach top-level aop_bind (program_registry: markets rebuild / rails artifact_hash / AO unreproduced hierarchy + live hash observation). Orthogonal: never mutates decision/can_spend/scores. Default-on (AOP_BIND_SURFACE_ENABLED); ignore if you are not binding AOP on-chain evidence. AO remains refuse-class for commerce hard-bind even when the on-chain hash matches the pin. DURING Path A paid routes only: ?seller_wallet= can refuse below-threshold sellers (402, charged:false). Refusal needs settle_gate_enabled=true AND settle_gate_shadow=false - shadow only logs a would-block and lets the payment through. Read settle_gate_enforcing from GET /health for the resolved answer; it is runtime config, so do not assume a default. SETTLE Settle rail (opt-in facilitator — gas-sponsorship + trust attach): GET /supported exact + kinds[].extra.feePayer (currently GWRLgRB6diC2zG9BaoGJsan9T8JvJCk7usFruiefnfMP) — not /health.fee_payer (Path A) and not settlement_policy.path_s_fee_payer. POST /verify then POST /settle → tx + best-effort twzrd_receipt + merchant_attach (attach never voids chain success). Settle rail is a cosign+attach rail, not a trust-gated settlement firewall. Path A note: paid trust 402 may still list external feePayers (CDP/PayAI/ Dexter). accepts[0] is not the settle rail unless feePayer matches /supported. Path B = buyer AutoGate refuse (pre-sign), not this facilitator surface. AFTER GET /v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs signed V7 receipt - verify the paid response happened, offline, trusting no TWZRD code GET /v1/intel/merchant/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs signed merchant track-record receipt (observed receive-side graph quality; NOT demand proof or a payer trust score; 0.05 USDC) DISCOVERY GET /v1/intel/resources resource join SOT (callable + claims) GET /v1/intel/x402-directory wash overlay on ingested listings (PayAI not_indexed) GET /v1/intel/merchant_card/{wallet} qualify a seller before paying RESEARCH GET /v1/intel/get_top_intel_agents payer-corpus leaderboard (secondary) Infra one-liner: call TWZRD before x402 payment authorization to decide whether an agent should pay this seller/service; route settlement through TWZRD to attach merchant intel + portable receipt when money moves; verify offline after. ## The happy path: seller-first flywheel (then pay) Payment is self-proving. Score the SELLER before money moves: 1. Free preflight POST https://intel.twzrd.xyz/v1/intel/preflight body: {"seller_wallet":"GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs","agent_intent":"preflight"} add price_usdc only when the caller supplied a unit price (unlabeled leftover 0.05 is not a unit price; read price_kind) → readiness_card.decision (allow | warn | block) 2. Free merchant card GET https://intel.twzrd.xyz/v1/intel/merchant_card/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs optional header X-Twzrd-Caller: @ (e.g. clawrouter@0.9.4) or /; fallback X-TWZRD-Client when Caller is absent. Free; no auth. Well-formed token is recorded (preflight_requests resource=merchant_card) and acknowledged as caller_recorded=true / X-Twzrd-Caller-Recorded: 1. Raw token is not echoed. → refuse if wash_flagged=true (default); read payable_conformance (listed ≠ live_402; fee_payer_stability for sponsored Solana exact) 3. Optional paid GET https://intel.twzrd.xyz/v1/intel/quick/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs ($0.001 seller wash risk + wallet reputation) or GET https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs ($0.05 + V7 receipt) or GET https://intel.twzrd.xyz/v1/intel/reality-check ($15 Reality Check PDF) 4. Verify receipt POST https://intel.twzrd.xyz/v1/receipts/verify (or sample first: GET https://intel.twzrd.xyz/v1/receipts/example) 5. Only then pay the seller's x402 resource (or settle via TWZRD facilitator for free merchant_attach on POST /settle) Secondary branches: - wash_flagged=true → hard-stop (preflight block, merchant refuse). Never warn / allow / quick / proceed. - wash_flagged=null → never evaluated, not clean. Do not pay as if clean. - decision=block → do NOT pay. Wash/fleet-flagged seller. Abort. - decision=warn → unknown or thin history (the conservative default). If the spend matters (>= $1.00, or you want portable proof), buy the $0.05 trust receipt: GET https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs?seller_wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs route on reputation_credential.credentialSubject.effectiveTrustScore (< 30 block | 30-60 warn | > 60 allow), then verify the signed receipt offline. - decision=allow + wash_flagged=false + small spend → pay without further paid calls. Free `allow` is deliberately conservative (anti-sybil): it fires for established organic sellers and diversified, cross-facilitator agents, and stays `warn` for thin/unknown wallets. The precise score + signed receipt are the paid /v1/intel/trust surface. Conditional ROI for the $0.05 trust receipt: Always buy if payment_amount >= $1.00 (receipt cost < 5% of spend) Always buy if decision = warn (unknown/thin — buy the proof) Skip if decision = allow + payment < $0.10 Cache/share within one task, buy once and reuse across your agents Re-verify when a cached decision is stale. Trust scores DECAY: an `allow` drifts toward `warn`/`block` over days-to-weeks as a seller goes dormant or a captive fleet forms around it. Re-check a counterparty you keep paying before a large or recurring settle — the fresh receipt is anchored to the NEW settlement tx, the cached one is not. Re-call contract (machine-readable): The paid receipt carries the re-call fields at JSON path twzrd_receipt.preimage.*: recheck_after_unix int UNIX time hint; = timestamp_unix + staleness_days*86400 staleness_days int recommended re-check cadence in days (7 for high/real_corpus data quality, 3 for partial/stale/low) score_decay_model str step:<=7d=1.0,<=30d=0.8,<=90d=0.5,>90d=0.25 Those three fields are untrusted on V5/V6 (not in the keccak leaf). evaluateRecall(receipt) from @wzrd_sol/sdk is the consumer gate (action=untrusted-recheck). Do not treat raw due / recheck_after_unix as a trusted allow. Stale != invalid - a cached score is still a snapshot. Optional paid refresh: GET https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs Watch lane (push side of the re-call contract): Receipt holders use evaluateRecall (V5/V6 freshness is untrusted, not a trusted due bit). Watch is a push hint: register a watch and TWZRD re-checks the seller for you (polled every ~120s once due). Register POST https://intel.twzrd.xyz/v1/intel/watch body: {"payer_wallet":"...","seller_wallet":"...","webhook_url":"https://..."} webhook_url is optional - omit it for poll-only watches. Notify when a re-check is due AND the intel materially changed (decision change, score moves > 5 points, or first check after registration), TWZRD POSTs event twzrd.watch.recheck_due to your webhook with fresh_intel: {trust_score, decision, recheck_after_unix, staleness_days, seller_wallet}. Webhooks public HTTPS only - private/reserved IPs are rejected at registration and redirects are never followed on delivery. Limits max 25 active watches per payer_wallet. List GET https://intel.twzrd.xyz/v1/intel/watch?payer_wallet=... (webhook URLs masked to host) Remove DELETE https://intel.twzrd.xyz/v1/intel/watch/123?payer_wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs MCP twzrd_watch_add / twzrd_watch_list / twzrd_watch_remove. ## Routing table | Need | Call | Cost | Gate field | |------|------|------|-----------| | Pre-spend gate (first step) | POST /v1/intel/preflight | Free | readiness_card.decision (HTTP) | | Pre-spend gate via MCP | get_readiness_card_tool | Free | decision (top-level, no nesting) | | Free seller graph card | GET /v1/intel/merchant_card/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs | Free | wash_flagged / catalog_enriched / payable_conformance | | Facilitator kinds + feePayer | GET /supported | Free | twzrd.merchant_attach | | Settle + free merchant attach | POST /settle | rail fee | merchant_attach + twzrd_receipt | | Full trust + signed receipt | GET /v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs | 0.05 USDC | reputation_credential.credentialSubject.effectiveTrustScore | | Seller wash risk / wallet reputation | GET /v1/intel/quick/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs | 0.001 USDC | wash_label / fleet_pct / active_payers | | Reality Check PDF | GET /v1/intel/reality-check | 15.0 USDC | application/pdf | | Merchant track-record receipt | GET /v1/intel/merchant/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs | 0.05 USDC | attestation_kind=merchant_track_record | | Market data via MCP | get_solana_market_status only (data tools unlisted) | Free | - | | Market data via HTTP | GET /v1/intel/solana_market_* | 503 (no upstream configured; never cached data) | - | | Verify receipt | POST /v1/receipts/verify | Free | result.valid | | Wash/payTo deny-list feed | GET /v1/intel/payto-feed | Free | wash_flagged diffs (X-Twzrd-Caller) | | Notarize caller-local deny | POST /v1/intel/refuse-receipt | Free | kind=twzrd_refuse_receipt_v0 — not a wash verdict | | Verify refuse-receipt | POST /v1/intel/refuse-receipt/verify | Free | kind_ok / domain_ok (rejects V6) | | Resource join SOT | GET /v1/intel/resources | Free | callable URL + discovery/counterparty claims | | Service directory | GET /v1/intel/x402-directory | Free | wash overlay on ingested listings (PayAI not_indexed) | | Seller card | GET /v1/intel/merchant_card/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs | Free | wash_flagged / catalog | | Payer leaderboard (secondary) | GET /v1/intel/get_top_intel_agents | Free | - | ## Start here (one command, free) — vet a seller before you pay curl -s -X POST https://intel.twzrd.xyz/v1/intel/preflight \ -H 'content-type: application/json' \ -d '{"seller_wallet":"GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs","price_usdc":0.01}' # established seller -> readiness_card.decision="allow", can_spend=true -> pay. # Swap in your own seller_wallet: unknown/thin -> "warn" (buy the $0.05 receipt); # wash/fleet -> "block" (don't pay). No auth, no payment. The free preflight already gives you allow / warn / block. The paid trust call (https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs, 0.05 USDC) is where you buy the PROOF: a portable, Ed25519-signed V7 receipt anchored to your settlement transaction, offline-verifiable with no trust in TWZRD (plus the renormalized model). To explore the corpus instead, curl /v1/intel/get_top_intel_agents?limit=1 (leaderboard + total_payers_observed + denoised corpus_slices; free). ## What the corpus numbers mean (honest) total_payers_observed (curl /v1/intel/get_top_intel_agents?limit=1 for the live count) is the RAW observed payer total and INCLUDES the April-2026 CDP demo/onboarding faucet wave (the bulk of it: one-shot payers + single-merchant bots; see corpus_slices.one_shot_le1 and .single_merchant_bots_ge100tx). The durable, real graph is in corpus_slices in that same get_top_intel_agents response: pre_spike_base_last_seen_pre_2026_04 (payers whose entire footprint predates the April faucet) and multi_merchant_ge2 (agents that paid 2+ distinct resources -- the real comparison-shoppers). Read the live values from the response; they drift slowly as the corpus updates. These are ECOSYSTEM payment behaviors we observe and score - NOT calls or revenue to TWZRD. TWZRD's own paid usage of this surface is pre-demand (one external settlement all-time; payer attribution is verified on-chain, never client-declared). ## Paid (x402, USDC on Solana mainnet) - GET https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs?seller_wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs -> 0.05 USDC. Live trust intel + portable V7 receipt. Proven on mainnet. - GET https://intel.twzrd.xyz/v1/intel/quick/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs -> 0.001 USDC. Seller wash risk + wallet reputation (wash label, fleet %, payer count). No V7 receipt. - GET https://intel.twzrd.xyz/v1/intel/reality-check -> 15.0 USDC. Reality Check market-intelligence PDF. - POST https://intel.twzrd.xyz/v1/intel/verify-endpoint {"url": "https://your-api.example"} -> 0.05 USDC. SELLER-SIDE: probes YOUR x402 surface (discovery, unpaid-402 conformance, wash screen per resolved payTo) and returns a portable signed AgentReadinessReceipt of what was observed - a failing result is still delivered and still charged, because you are paying for the check, not for a pass. basis=endpoint_conformance, not_a_trust_vouch=true: it is not a trust vouch, it does not affect any ranking, and it is not proof you own the endpoint. Free unsigned equivalent: POST /v1/agent-readiness. Funding: the payer wallet must hold the USDC itself. Gas is sponsored (the 402 challenge advertises a TWZRD feePayer that co-signs the network fee) - the payment amount is NOT. An unfunded payer gets a machine-readable 402 (reason source_token_account_missing / insufficient_funds) with the exact token account, mint, and required amount to act on. Pass the seller counterparty on every paid call: ?merchant= on market routes, ?seller_wallet= (or X-TWZRD-Seller-Wallet header) on the trust route. It is optional, but it is what arms the settle-time trust gate: if that seller scores below threshold the server refuses to settle (402, charged:false, NO on-chain tx) before your payment broadcasts. Omit it and the gate has nothing to evaluate. On the trust route the scored {pubkey} itself is never gated -- only the seller_wallet counterparty. ## Free (no payment, no auth) - Market-data discovery routes are temporarily unlisted: no market-data upstream is configured (routes answer honest HTTP 503; get_solana_market_status reports available=false). - POST https://intel.twzrd.xyz/v1/intel/preflight (the one-command demo; BEFORE-path ReadinessCard) - GET https://intel.twzrd.xyz/v1/intel/score_wallet_for_intel?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs - GET https://intel.twzrd.xyz/v1/intel/get_poec_score?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (PoEC v0 preview: floors + components; claimable always false) - GET https://intel.twzrd.xyz/v1/intel/get_top_intel_agents?limit=10&min_paid_calls=2&max_days_since_last=14 (leaderboard; filters optional - min_paid_calls suppresses one-shots, max_days_since_last suppresses dormant) - GET https://intel.twzrd.xyz/v1/intel/get_facilitator_footprint?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (which x402 facilitators a payer settled through) - GET https://intel.twzrd.xyz/v1/intel/get_counterparties?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs&limit=10 (capped teaser: top merchants this wallet pays; limit<=25) - GET https://intel.twzrd.xyz/v1/intel/compare_wallets?wallet_a=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs&wallet_b=46vMcwuC4sK11sB3gkLhyA7J7GEwfkhn5rFyDtihBwqe (side-by-side intel for two wallets) - POST https://intel.twzrd.xyz/v1/intel/score_wallets_batch (body: {"wallets":[...]}, up to 25) - GET https://intel.twzrd.xyz/v1/receipts/example (no-wallet SAMPLE signed receipt -> verify offline before you spend) - POST https://intel.twzrd.xyz/v1/receipts/verify (recompute + check a portable V7 receipt leaf) - GET https://intel.twzrd.xyz/.well-known/twzrd-receipt-pubkey (canonical issuer key to pin out-of-band) - GET https://intel.twzrd.xyz/.well-known/x402 (machine-readable service descriptor) - GET https://intel.twzrd.xyz/openapi.json (OpenAPI 3.1 with x402 annotations) - GET https://intel.twzrd.xyz/health ## See the gate return a block (the secondary branch, free) curl -s -X POST https://intel.twzrd.xyz/v1/intel/preflight \ -H 'content-type: application/json' \ -d '{"resource_name":"Jupiter Quote Preview","price_usdc":0.01}' # a low-quality / flagged resource -> readiness_card.decision="block", can_spend=false. # This is the gate doing its job, not the happy path — most established sellers -> allow # (see "Start here" above). ## Receipt (portable + signed, V7) The signed receipt is a PORTABLE keccak256 leaf (tamper-evidence) PLUS an Ed25519 signature over the leaf bytes (authenticity). As of V6 the leaf binds the full reputation provenance (reputation_score, score_version, data_quality, ...), so those surfaced fields are now signed -- editing any of them invalidates the receipt. Verify it offline: recompute the keccak leaf from the preimage AND check the signature against the published TWZRD receipt-signing key set (current key_id twzrd-receipt-ed25519-v2, base58 Ak5SQwHpuQAqU7ty7ZWX7qgF39A9yi72c22KNn8sHzvS; legacy v1 is verify-only), ed25519 -- pinned at /.well-known/twzrd-receipt-pubkey (also in /.well-known/x402 and /openapi.json). Unsigned or wrong-key receipts are rejected. The settlement_tx anchor stays independently checkable on-chain for ground truth. ## Verify offline (standalone tool, trusts no TWZRD code) A stranger can verify a signed receipt with only the published key + audited crypto libs. Use >=1.4.0 (1.3.x has the strict domain allowlist, proof-depth cap, and future-timestamp skew cap, but rejects live V7: unknown domain TWZRD:AO_REPUTATION_RECEIPT_V7, and it reports freshness fields as unbound when V7 is the version that binds them): npx twzrd-receipt-verifier@^1.4.0 receipt.json --pubkey Ak5SQwHpuQAqU7ty7ZWX7qgF39A9yi72c22KNn8sHzvS The V7-capable verifier is on **both registries**: npm 1.4.0 and PyPI 1.4.0 - so `pip install 'twzrd-receipt-verifier>=1.4.0'` now resolves and is a supported path. Keep the >=1.4.0 floor explicit on either registry: a bare `pip install twzrd-receipt-verifier` against a stale or cached index can still land 1.3.3, which rejects GET /v1/receipts/example. Treat any resolved 1.3.x as unable to read live V7 regardless of registry. ## Install - Skill (one URL, save + self-update): https://intel.twzrd.xyz/skill.md Tell your agent: "set up https://intel.twzrd.xyz/skill.md". Canonical twzrd-trust skill; also on ClawHub: npx clawhub install twzrd-trust - MCP (22 tools, streamable-http): https://intel.twzrd.xyz/mcp (card: /.well-known/mcp.json) openclaw mcp add twzrd --url https://intel.twzrd.xyz/mcp --transport streamable-http Note: dual Accept (application/json, text/event-stream) is optimal; plain application/json, */*, or missing Accept are accepted (server normalizes). - Auto-pay MCP (local, Solana x402): pip install twzrd-mcp npx -y twzrd-mcp-server --help Auto-pay is disabled by default. Every paying config must set TWZRD_MCP_PAYMENTS_ENABLED=1. Minimal Node config: {"mcpServers":{"twzrd":{"command":"npx","args":["-y","twzrd-mcp-server"],"env":{"TWZRD_MCP_PAYMENTS_ENABLED":"1","TWZRD_RPC_URL":"","TWZRD_WALLET_SECRET_KEY":""}}}} Node config: {"mcpServers":{"twzrd":{"command":"npx","args":["-y","twzrd-mcp-server"],"env":{"TWZRD_MCP_PAYMENTS_ENABLED":"1","TWZRD_RPC_URL":"","TWZRD_WALLET_SECRET_KEY":"","TWZRD_MAX_USDC_PER_CALL":"0.05","TWZRD_MAX_USDC_TOTAL":"1.00"}}}} - OpenClaw preflight plugin (gates payment-shaped tool calls on the free preflight): npm install twzrd-preflight # shadow mode by default; see its README for enforce/config - Direct HTTP: every endpoint is in /openapi.json (OpenAPI 3.1 with x402 annotations). - Receipt verify (offline, no engine): npx twzrd-receipt-verifier@^1.4.0 receipt.json --pubkey Ak5SQwHpuQAqU7ty7ZWX7qgF39A9yi72c22KNn8sHzvS ## More No wallet • No signup • Free preflight • Pay only for signed V7 trust receipt. Get started in <60s: - Run the free preflight curl above. - pip install twzrd-mcp (or npm gate wrapper). - Browse OpenAPI: https://intel.twzrd.xyz/openapi.json - Verify receipts with npx twzrd-receipt-verifier@^1.4.0 (issuer key: https://intel.twzrd.xyz/.well-known/twzrd-receipt-pubkey). - Full tool reference + per-endpoint details: https://intel.twzrd.xyz/llms-full.txt and /openapi.json - Machine-readable service descriptor: /.well-known/x402 - MCP registry: https://smithery.ai/servers/wzrd/twzrd-agent-intel - Public source: https://github.com/twzrd-sol/twzrd-trust - Live mainnet proof tx: 3aXGtvmNvFhSSDXF8D4DBDntXFczraUABg75MdWtCgchdYAApRwC7KxdGxbCmewYcA6ZNzw6FvdAHcoevMUG44Sc - Live at https://intel.twzrd.xyz | health: /health (package_version, gate status) ## Docs - [Preflight](https://intel.twzrd.xyz/v1/intel/preflight): free pre-spend gate (POST) - allow/warn/block ReadinessCard before you pay (Solana base58 **or** Base `0x` payTo) - [Merchant card](https://intel.twzrd.xyz/v1/intel/merchant_card/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs): free seller graph card - wash_flagged, observed graph quality, payable_conformance (live_402 + fee_payer_stability). Base example: `https://intel.twzrd.xyz/v1/intel/merchant_card/0xe9030014f5dae217d0a152f02a043567b16c1abf` - [Trust receipt](https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs): paid (0.05 USDC) - live trust intel + signed offline-verifiable V7 receipt (**Solana only**; Base paid receipts deferred) - [x402 directory](https://intel.twzrd.xyz/v1/intel/x402-directory): wash overlay on ingested listings (PayAI not_indexed; coverage_complete false) - [Leaderboard](https://intel.twzrd.xyz/v1/intel/get_top_intel_agents): free payer-corpus leaderboard + corpus_slices - [Receipt example](https://intel.twzrd.xyz/v1/receipts/example): free sample signed receipt - verify offline before you spend - [Receipt verify](https://intel.twzrd.xyz/v1/receipts/verify): free (POST) - recompute + check a portable V7 receipt leaf - [OpenAPI](https://intel.twzrd.xyz/openapi.json): OpenAPI 3.1 with x402 payment annotations for every endpoint - [MCP](https://intel.twzrd.xyz/mcp): streamable-http MCP server (22 tools, dual Accept headers) - [Full reference](https://intel.twzrd.xyz/llms-full.txt): this document plus the complete tool + endpoint contract ## Optional - [Health](https://intel.twzrd.xyz/health): service health - package_version, gate status - [Service descriptor](https://intel.twzrd.xyz/.well-known/x402): machine-readable x402 service card ## Trust gate semantics (twzrd-agent-intel service v0.5.10) - v0.5.10 is THIS service's package version. The authoritative source is **/health package_version** on this host, not PyPI: /health moves on every deploy while PyPI moves only on publish, so the two drift routinely and PyPI is not a way to check what is actually running. It is NOT the version of the npm buyer-side gate (twzrd-x402-gate) or any other client SDK - those are versioned independently. - Free preflight (POST /v1/intel/preflight): advisory ReadinessCard only. Preflight does NOT block settlement -- it returns a decision your client chooses to honor (see onBeforeSettle hook above). Pass queried_pubkey for consumer attribution on the velocity corpus. seller_wallet may be Solana base58 or a Base EVM address (0x + 40 hex). Base scores high-confidence EIP-3009 USDC settlements from the live Base corpus — observational, not a payment guarantee. - Free merchant_card (GET /v1/intel/merchant_card/{wallet}): same dual-chain address acceptance as preflight. `chain` + `corpus` fields identify the source. Base cards set `paid_receipts: deferred` (no paid-receipt upgrade path yet). - Paid settle gate (Path A paid trust/market routes only): blocks x402 settlement when TWZRD_SETTLE_GATE_ENABLED=true and seller counterparty score is below threshold. Refusal requires settle_gate_enabled=true AND settle_gate_shadow=false: with shadow on, a would-block is only logged (measure-don't-enforce) and the payment settles. Read settle_gate_enforcing from GET /health for the resolved posture - settle_gate_enabled alone does not mean you can be refused. It is runtime config and changes without a release. Supply the counterparty per call so the armed path works in any posture: ?merchant= (market routes) or ?seller_wallet= / X-TWZRD-Seller-Wallet (trust route). Settle rail POST /settle calls evaluate_settle_gate (seated #2049). Refusal still requires settle_gate_enforcing=true on GET /health; shadow logs a would-block and lets the payment through. - Client hook: packages/twzrd-agent-intel/verifier/on_before_settle.py (preflight before pay). - MCP registry auth key (/.well-known/mcp-registry-auth) is NOT the receipt-signing key (/.well-known/twzrd-receipt-pubkey). ## Integration variants and optional operator policies The canonical `installTwzrdAutoGate` buyer install is near the top of this document (alias: `installTwzrdX402ClientHook`). These are secondary framework adapters and operator policies. The gate core is dependency-free (no @elizaos/core required). Failure modes, one per line - they differ: - Preflight outage: buyer gate fails CLOSED by default (TWZRD_FAIL_OPEN=true opts into legacy fail-open). - merchant_card unreachable: wash check fails OPEN (never invent wash). - Paid settle gate shadow: a would-block is only logged and the payment settles; refusal needs settle_gate_enabled=true AND settle_gate_shadow=false (read settle_gate_enforcing on GET /health). npm install @wzrd_sol/plugin-trustgate@^0.3.7 # elizaOS plugin + facilitator hook Install exactly `twzrd-x402-gate@0.9.7` (older pins circulating in cached docs are stale) or check the registry first: `npm view twzrd-x402-gate version` / `pip index versions twzrd-mcp`. Explicit minimum-version pins stated in this document (e.g. twzrd-receipt-verifier>=1.4.0 for V7 freshness binding; 1.3.x rejects live V7) still apply. The live /health package_version field is the **twzrd-agent-intel service** (PyPI), not the npm gate version — they move independently. ### Wrap any fetch that may receive a 402 import { wrapFetchWithTwzrdGate } from "twzrd-x402-gate"; const gated = wrapFetchWithTwzrdGate(fetch); // THROWS on block-rated merchant before USDC leaves your wallet. ### elizaOS agents (one line) import { canSpendSafely, withTwzrdGuard } from "@wzrd_sol/plugin-trustgate"; if (!(await canSpendSafely(payTo))) throw new Error("TWZRD: blocked seller"); // or decorator-style: await withTwzrdGuard(payTo, () => signAndSendPayment(payTo, amount)); ### MCP hook (x402/core onPaymentRequested) import { twzrdOnPaymentRequested } from "twzrd-x402-gate"; const client = createX402MCPClient({ onPaymentRequested: twzrdOnPaymentRequested }); ### onWarnUpsell (auto-trigger paid receipt on unknown merchants) import { createTwzrdGate } from "twzrd-x402-gate"; const gate = createTwzrdGate({ onWarnUpsell: (ctx) => paidFetch("https://intel.twzrd.xyz" + ctx.upsellUrl), }); ### Facilitator operators (screen the MERCHANT on every brokered settlement) import { createOnBeforeSettleHook } from "@wzrd_sol/plugin-trustgate/facilitator"; const facilitator = createFacilitator({ hooks: { onBeforeSettle: createOnBeforeSettleHook() }, }); // Buyer-side counterparty check at the rail: score payTo before settle. ### Resource-server operators (optional merchant policy on the PAYER) // Optional settle hook (0.8.x) — not an equal product to the buyer gate. Settled USDC is final. // Use for abuse / sanctions / bots / customer selection before you settle and serve. // Wash resistance is mainly TWZRD scoring (discount bad edges), not forced revenue rejection. import { createTwzrdSettleGuard, twzrdPayerScreen } from "twzrd-x402-gate"; import { x402ResourceServer } from "@x402/core/server"; const server = new x402ResourceServer(facilitator); server.onBeforeSettle(createTwzrdSettleGuard({ screen: twzrdPayerScreen() })); // Default abort: wash_flagged or decision=block; warn continues. Free merchant_card screen. // Paid /v1/intel/trust screening is inject-your-own screen (not defaulted — per-payment cost). # 🛡️ Self-Serve Trust Badges (free, no auth, embed in any marketplace) Drop these in your Smithery or Bazaar listing. Render instantly, auto-update hourly, zero setup. Wash integrity badge (is this wallet clean?): Provider reputation badge (is this merchant legit?): Intel trust-tier badge (how reputable is this agent?): All: append ?format=json for JSON. Free tier, no API key. Full API (api.twzrd.xyz, not intel): POST https://api.twzrd.xyz/v1/wash/analyze | POST https://api.twzrd.xyz/v1/reputation/analyze (Pro tier) Receipts: GET /v1/receipts | GET /v1/receipts/:id (Pro tier, api.twzrd.xyz) ## Full MCP tools reference (22) 1) get_readiness_card_tool(resource_name?, seller_wallet?, resource_url?, price_usdc?, buyer_wallet?, agent_intent?, marketplace_score?) - Pre-spend readiness card: decision/can_spend/trust_score/proof/caveats/next_fixes + root_provenance (for WZRD protocol resources: onchain_match:null, optional market_velocity when the market data service is configured). 2) evaluate_x402_resource(resource_url, method?) - One-shot URL guard: fetch the resource URL, extract the 402 seller wallet (Solana preferred), run free preflight, return decision/trust_score/seller_wallet/receipt_url. Use when you have a URL but not the seller wallet. 3) low_level_preflight(resource_name?, seller_wallet?, price_usdc?, agent_intent?, marketplace_score?) - Lower-level preflight with max_spend_recommendation_usdc and paid_trust_endpoint hints. 4) verify_root_inputs(root_seq?, resource_name?, seller_wallet?) - Free MCP + GET /v1/intel/verify_root: fetches public leaves, recomputes every GLOBAL_V5 leaf + sorted-pair merkle + dataset_hash. Returns PASS|FAIL|ERROR + leaf_hash_match. onchain_match=null on ReadinessCard.root_provenance tells agents to call this before deposit/claim/settle. Canonical samples for hermetic tests. 5) score_wallet_for_intel(wallet) - Free wallet intel score from x402 payment-history signals. 6) get_top_intel_agents(limit=10, min_paid_calls=0, max_days_since_last=None) - Free leaderboard of active x402 payer wallets; behavioral cohort, not identity proof. 7) get_solana_market_status() - Market data-service health/status. 8) get_provider_reputation(merchant) - Free provider/merchant reputation from the observed x402 corpus. 9) submit_contribution_claims(wallet, claims) - PoECX bridge: cross-check self-reported settlements from a counterparty's own rails against TWZRD's independently-observed x402 corpus (by on-chain signature). Preview only; claimable is always false. 10) get_merchant_card(wallet) - Free merchant card: observed receive-side graph quality (offering unknown unless catalog-enriched; not identity or demand proof). Includes payable_conformance (live_402 density, fee_payer_stability: stable|rotating|unknown). Listed ≠ live_402. 11) is_wash_fleet(wallet) - Free wash/sybil-fleet check on a single wallet. 12) verify_receipt(receipt, require_signature?, max_age_seconds?) - Free offline v6 receipt verification: recompute the keccak256 leaf + check the Ed25519 signature. Optional max_age_seconds (>0) rejects stale receipts (replay protection). 13) get_facilitator_footprint(wallet) - Free discovery: which x402 facilitators a payer has settled through (1 = thin/captive). 14) get_counterparties(wallet, limit=10) - Free discovery (capped teaser): top merchants a wallet pays (limit<=25). 15) score_wallets_batch(wallets) - Free discovery: score up to 25 wallets in one call. 16) compare_wallets(wallet_a, wallet_b) - Free discovery: side-by-side intel for two wallets by wash-discounted effective_score. 17) get_x402_directory(flagged_only?) - Free discovery: wash overlay on ingested PayAI/CDP/Agentic listings (PayAI pager not_indexed; coverage_complete false). Base listings include a high-confidence EIP-3009 corpus-membership overlay, while wash_unknown remains honest because the Solana wash graph is not cross-chain; Polygon remains unavailable. 18) twzrd_demo_gate(integration?, run_id?) - Runnable no-spend proof of the buyer-side x402 trust gate: returns a deterministic transcript (block path aborts, wallet/signer never contacted, ok=true). Spends nothing, contacts no wallet, needs no human. Surfaces an EXTERNAL_RUN candidate (not proof) tagged with your inbound IP + run_id. 19) get_poec_score(wallet) - Free preview: PoEC v0 (Proof of Economic Contribution) from the observed corpus snapshot - floors, components, eligible_v0. claimable is always false; success_quality has no live source yet, so poec_score reads 0.0 (see evidence_gaps). 20) twzrd_watch_add(payer_wallet, seller_wallet, webhook_url?) - Register a re-call watch: TWZRD re-checks the seller when recheck_after_unix elapses and POSTs event twzrd.watch.recheck_due to your webhook when the score/decision materially changes. webhook_url optional - omit for poll-only. 21) twzrd_watch_list(payer_wallet) - List your active re-call watches with current score/decision and recheck_after_unix (webhook URLs masked to host). 22) twzrd_watch_remove(watch_id, payer_wallet) - Deactivate a re-call watch by ID; payer_wallet must match the watch owner. ## Full x402 flow (paid HTTP endpoints) Easiest path — let a payer client handle 402 + settle for you. This is the same command the 402 body returns as `next_action.command`: ``` # one-time: create and fund a wallet (needs >= 0.05 USDC on Solana) npx agentcash@latest onboard npx agentcash@latest balance # then pay any TWZRD paid route in one call npx agentcash@latest fetch 'https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs' ``` Without a funded wallet that command fails at SETTLE, not at the gate — the 402 is served to everyone, so "I got a 402" does not mean you were refused. Hand-rolled alternative (any x402 client + your own signer): 1. Request paid endpoint without payment header. 2. Receive HTTP 402 with `payment-required` header. 3. Decode challenge and choose `accepts` payment requirement. 4. Build/sign payment payload using x402 client + wallet. 5. Retry same request with `payment-signature` header. 6. Receive paid JSON payload (includes tx anchor and route data; full trust includes signed V7 receipt fields). Challenge example (runnable as-is; substitute your own pubkey when you have one): curl -i -s https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs Python header inspection: python3 - <<'PY' import requests u = "https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs" r = requests.get(u, timeout=15) print(r.status_code) print(r.headers.get("payment-required")) PY ## Endpoint reference with request/response examples - POST https://api.twzrd.xyz/v1/chat/completions (paid 0.01 USDC on api.twzrd.xyz) - OpenAI-compatible chat completions; unpaid 402; payTo DB2s5PeotN1zwb9WpLQMAYqdHnf86SfjYUhbe1Nm8D1e. Not intel-settled. - GET https://intel.twzrd.xyz/v1/intel/trust/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (paid 0.05 USDC) - 402 when unpaid; 200 keys: pubkey, trust, paid, network, tx/tx_pending, twzrd_receipt|receipt_error - GET https://intel.twzrd.xyz/v1/intel/merchant/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (paid 0.05 USDC) - Merchant track-record receipt (observed inbound graph; not a payer trust score). - GET https://intel.twzrd.xyz/v1/intel/quick/GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (paid 0.001 USDC) - Seller wash risk + wallet reputation: wash_label, fleet_pct, active_payers, tier, score. No V7 receipt. - GET /v1/intel/reality-check (paid 15.0 USDC) - Reality Check market-intelligence PDF (Aug 2026). - GET /v1/intel/solana_market_visibility_map (FREE - discovery; no x402 payment) - GET /v1/intel/solana_market_orderbook_depth?ticker=SOL (FREE - discovery; no x402 payment) - GET /v1/intel/solana_market_shape?ticker=SOL (FREE - discovery; no x402 payment) - GET /v1/intel/solana_market_onchain_trades_summary[?ticker=SOL] (FREE - discovery; no x402 payment) - POST /v1/intel/preflight (free) request: {"resource_name":"Jupiter Quote Preview","price_usdc":0.01} response: readiness_card + paid_trust_endpoint hints - POST /v1/receipts/verify (free) request: the twzrd_receipt object AS-IS from GET /v1/receipts/example or a paid /trust response — {"leaf":"","preimage":{},"signature":"","signing_pubkey":"Ak5SQwHpuQAqU7ty7ZWX7qgF39A9yi72c22KNn8sHzvS"}. preimage must be the COMPLETE object, not a subset — GET /v1/receipts/example returns a ready-to-paste curl_verify command with a real preimage. response: ok, version, result - GET /v1/intel/score_wallet_for_intel?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (free) - GET /v1/intel/get_poec_score?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (free; PoEC v0 preview, claimable always false) - GET /v1/intel/get_top_intel_agents?limit=10[&min_paid_calls=2&max_days_since_last=14] (free) - GET /v1/intel/get_facilitator_footprint?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs (free) - GET /v1/intel/get_counterparties?wallet=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs&limit=10 (free; limit<=25) - GET /v1/intel/compare_wallets?wallet_a=GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs&wallet_b=46vMcwuC4sK11sB3gkLhyA7J7GEwfkhn5rFyDtihBwqe (free) - POST /v1/intel/score_wallets_batch (free) request: {"wallets":["GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs", "GFpLvocNdEjnSsLH3VJQL6wGcjGxTbUBrj6fqN3Qe1Gs"]} (up to 25) - GET /health (free) - Discovery: /, /.well-known/x402, /.well-known/x402.json, /.well-known/agent-card.json, /.well-known/mcp, /.well-known/mcp.json, /.well-known/mcp-server.json, /mcp/agent-intel-mcp-card.json, /openapi.json, /llms.txt, /llms-full.txt ## Integration guide for LLM agents - Read /llms.txt for quick orientation. - Read /llms-full.txt for complete tool + endpoint contract. - Parse /openapi.json for machine-readable schemas. - Always call POST /v1/intel/preflight before paid actions. - Only pay when decision/risk is acceptable. - Persist tx + receipt fields from paid responses. - Verify receipts via POST /v1/receipts/verify (or offline verifier).