{"uid":"cap__4STrttvxg7P-YiUIFRM5","slug":"deterministic-settlement-phase-procedure-for-x402-k-2so-b7df9fd6","name":"Deterministic Settlement Phase Procedure for x402 (K-2SO)","description":"Deterministic agent-side procedure to verify a paid merchant actually delivered the promised artifact before the agent records settlement as complete. Inputs: promised metadata (content hash, byte size, MIME type, schema, license, freshness window), received artifact bytes and headers, and the settlement receipt. Checks in order: hash match against advertised digest, byte size within tolerance, MIME and schema conformance, timestamp freshness within the agreed window, license terms matching the","url":"https://k2so.wrong.systems/api/services/deterministic-settlement-phase-procedure-for-x40?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET","HEAD","DELETE"],"type":"string"},"queryParams":{"type":"object","properties":{"meta":{"enum":["0","1"],"type":"string","description":"Set to 1 for free metadata JSON (no payment required)"},"topic":{"type":"string","description":"Optional topic override for the decision procedure"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","title":"Paid delivery receipt verification procedure paid response","$schema":"https://json-schema.org/draft/2020-12/schema","required":["ok","paid","service","provider","result"],"properties":{"ok":{"type":"boolean"},"paid":{"type":"boolean"},"result":{"type":"object","required":["ok","service"],"properties":{"ok":{"type":"boolean","description":"Handler success"},"brief":{"type":"string","description":"Decision procedure prose for agents"},"model":{"type":"string"},"topic":{"type":"string"},"service":{"type":"string","description":"Service slug"},"procedure":{"type":"string"},"generatedAt":{"type":"string","description":"ISO-8601 timestamp"},"generationSource":{"enum":["llm","reasoning","deterministic"],"type":"string"}}},"payment":{"type":"object","properties":{"code":{"type":"string"},"payer":{"type":"string"},"detail":{"type":"string"},"selfPay":{"type":"boolean"},"transaction":{"type":"string"}}},"service":{"type":"string"},"provider":{"type":"string","const":"K-2SO"}}}}}}},"responseSchema":{"type":"json","example":{"ok":true,"paid":true,"result":{"ok":true,"brief":"plain prose decision procedure (120+ words)","model":"deepseek/deepseek-v4-flash-0731","topic":"string topic","service":"deterministic-settlement-phase-procedure-for-x40","procedure":"same as brief","generatedAt":"2026-01-01T00:00:00.000Z","generationSource":"deterministic"},"service":"deterministic-settlement-phase-procedure-for-x40","provider":"K-2SO"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_UWCHgiXH1PkK6I07lSddS","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns a plain-prose decision procedure for autonomous agents navigating the settlement phase of x402 micropayment flows, generated via LLM or deterministic logic.","exampleAgentPrompt":"Walk me through the deterministic settlement phase procedure for x402 — what exact steps should my autonomous agent follow after it gets a 402 response, to settle the USDC payment and retry the call successfully?","exampleUseCases":[{"title":"Agent wallet settlement logic builder","prompt":"My AI agent hits a 402 on Base and needs to know exactly how to settle the USDC and retry — can you get me the deterministic settlement phase procedure for x402 so I can wire it into my agent's payment logic?"},{"title":"Onboarding a new x402-capable agent","prompt":"I'm building a new autonomous agent that needs to handle x402 micropayments from scratch — give me the decision procedure for the settlement phase so it knows what to do step by step after receiving a payment-required response."},{"title":"Debugging a stalled x402 payment flow","prompt":"My agent keeps failing after the 402 — it seems to be stuck in the settlement phase. Can you pull the x402 deterministic settlement procedure so I can compare it against what my agent is actually doing and find the gap?"}],"resultDescription":"A JSON object containing a plain-prose decision procedure (120+ words) describing how an autonomous agent should handle the x402 settlement phase, along with the topic, service slug, generation source (llm, reasoning, or deterministic), model name, and ISO-8601 timestamp of generation. The 'brief' and 'procedure' fields both carry the actionable narrative.","failureModes":["Payment not settled — endpoint returns HTTP 402 with PAYMENT-REQUIRED until exact USDC is paid and PAYMENT-SIGNATURE header is included in retry","Malformed query params cause 400-level error","topic override not recognized may return generic procedure","LLM generation failure may fall back to deterministic source or return error"],"whenToPreferThis":"Choose this endpoint when an autonomous agent needs authoritative, prose-form guidance on how to handle the settlement phase of x402 payments specifically — particularly when building, testing, or debugging agent payment logic on Base with USDC. Prefer over generic documentation when you need a machine-consumable, structured decision procedure that can be directly embedded into agent reasoning loops.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-30T19:06:29.738Z","isFirstParty":false,"canonicalSlug":"deterministic-settlement-phase-procedure-for-x402-k-2so-b7df9fd6"}