{"uid":"cap_O2HIyMYSixaNAKo-T8e2F","slug":"agent-post-settlement-failure-recovery-decision-procedure-281f4109","name":"Agent Post-Settlement Failure Recovery Decision Procedure","description":"Classify paid x402/MPP call failures after settlement as timeout, malformed response, silent drop, partial data, or wrong data. Decide between retry, refund request, or provider switch. Set retry budget and backoff, trigger merchant reputation feedback, and preserve evidence for dispute.","url":"https://k2so.wrong.systems/api/services/agent-post-settlement-failure-recovery-decision","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":"Agent post-settlement failure recovery 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":"agent-post-settlement-failure-recovery-decision","procedure":"same as brief","generatedAt":"2026-01-01T00:00:00.000Z","generationSource":"deterministic"},"service":"agent-post-settlement-failure-recovery-decision","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_b-LgNHMqtlisCOiwRrDaE","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":"Classifies paid x402/MPP call failures after settlement and prescribes a recovery action (retry, refund request, or provider switch) with retry budget, backoff strategy, reputation feedback, and dispute evidence preservation.","exampleAgentPrompt":"My agent just paid for an x402 call but got a malformed response after settlement — can you classify the failure type and tell me whether to retry, request a refund, or switch providers, including what retry budget and backoff to use?","exampleUseCases":[{"title":"Recovering from a paid silent drop","prompt":"My agent settled an x402 micropayment but the provider just dropped the connection silently with no response — classify this as a silent drop and give me the recommended recovery action, retry budget, and whether I should flag the merchant's reputation."},{"title":"Deciding after partial data delivery","prompt":"An x402 call was paid and settled but I only received partial data in the response — tell me how to classify this failure and whether I should retry with the same provider, ask for a refund, or switch, along with backoff settings I should use."},{"title":"Building dispute evidence for wrong data","prompt":"My agent paid for a call via x402 and got back data that's clearly wrong — I need you to classify this as a wrong-data failure, decide if I should pursue a refund, and tell me what evidence I should preserve for a potential dispute."}],"resultDescription":"A structured decision brief containing: failure classification (timeout/malformed/silent drop/partial data/wrong data), recommended recovery action (retry/refund request/provider switch), retry budget and backoff parameters, a flag indicating whether merchant reputation feedback should be triggered, guidance on preserving dispute evidence, and a prose explanation of the decision procedure for the agent.","failureModes":["Missing or invalid 'type' or 'method' fields returns a schema validation error","Ambiguous failure scenario may produce a non-actionable 'insufficient context' brief","LLM generation failure falls back to deterministic or cached response","Payment not settled causes 402 response before any decision is generated","Rate limiting or quota exhaustion may return 429 with no result"],"whenToPreferThis":"Choose this endpoint when an AI agent has already completed x402/MPP payment settlement and needs a structured, opinionated recovery decision rather than generic error handling logic. It is specifically designed for the post-settlement failure window where the agent must quickly decide between retrying, escalating to a refund, or switching providers, and needs retry budgets, backoff parameters, and reputation feedback guidance in one call. Prefer it over generic error-handling libraries when operating in an autonomous agentic commerce context where financial accountability and dispute evidence are important.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:32:09.072Z","isFirstParty":false}