{"uid":"cap_nHpiAsLSqJ6wbdvy1d3Bc","slug":"brainiac-agent-contract-retry-safety-check-9e1a6931","name":"BRAINIAC Agent Contract Retry Safety Check","description":"Pay-per-call APIs for AI agents: OFAC sanctions screening, compliance checks, token security, and Base chain data via x402. No account. Fixed USDC price. MCP-ready.","url":"https://www.brainiac.software/api/v1/agent-contracts/retry-safety-check?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"openapi":{"type":"object","propertyNames":{"type":"string","maxLength":80},"additionalProperties":{}},"workflows":{"type":"array","items":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":160,"minLength":1},"steps":{"type":"array","items":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":160,"minLength":1},"operation":{"type":"string","maxLength":160},"description":{"type":"string","maxLength":4000}},"additionalProperties":false},"maxItems":30},"states":{"type":"array","items":{"type":"string","maxLength":80,"minLength":1},"maxItems":40},"description":{"type":"string","maxLength":8000},"transitions":{"type":"array","items":{"type":"object","required":["from","to"],"properties":{"on":{"type":"string","maxLength":200},"to":{"type":"string","maxLength":80,"minLength":1},"from":{"type":"string","maxLength":80,"minLength":1},"operation":{"type":"string","maxLength":160}},"additionalProperties":false},"maxItems":80}},"additionalProperties":false},"maxItems":12},"operations":{"type":"array","items":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":160,"minLength":1},"path":{"type":"string","maxLength":400},"steps":{"type":"array","items":{"type":"string","maxLength":200,"minLength":1},"maxItems":20},"method":{"type":"string","maxLength":16},"summary":{"type":"string","maxLength":1000},"examples":{"type":"array","items":{},"maxItems":8},"responses":{"type":"array","items":{"type":"object","properties":{"schema":{"type":"object","propertyNames":{"type":"string","maxLength":80},"additionalProperties":{}},"status":{"type":"string","maxLength":40},"example":{},"examples":{"type":"array","items":{},"maxItems":8},"description":{"type":"string","maxLength":4000}},"additionalProperties":false},"maxItems":20},"parameters":{"type":"array","items":{"type":"object","required":["name"],"properties":{"in":{"enum":["query","header","path","cookie","body"],"type":"string"},"name":{"type":"string","maxLength":120,"minLength":1},"schema":{"type":"object","propertyNames":{"type":"string","maxLength":80},"additionalProperties":{}},"required":{"type":"boolean"},"description":{"type":"string","maxLength":4000}},"additionalProperties":false},"maxItems":40},"description":{"type":"string","maxLength":8000},"outputSchema":{"type":"object","propertyNames":{"type":"string","maxLength":80},"additionalProperties":{}},"requestSchema":{"type":"object","propertyNames":{"type":"string","maxLength":80},"additionalProperties":{}}},"additionalProperties":false},"maxItems":40}}},"responseSchema":{"type":"json","example":{"score":55,"issues":[{"type":"missing_retry_policy","evidence":"Charges the saved card. A timeout means the outcome is uncertain. Gateway timeout.","location":"operations[0]","severity":"high","description":"The contract describes a timeout or an uncertain outcome and does not say whether to retry. The HTTP method was not treated as a retry rule.","agent_impact":"After a timeout an agent may charge or create a second time, or it may stop even though the first call succeeded.","suggested_fix":"State whether that timeout is safe to retry, or tell the agent to read a status operation instead."},{"type":"contradictory_retry","evidence":"Reserves stock. Safe to retry. Do not retry after a timeout.","location":"operations[1]","severity":"high","description":"The contract both says a retry is safe and says not to retry. The HTTP method was not used.","agent_impact":"An agent can repeat a call the contract also forbids, or abandon a call the contract says to repeat.","suggested_fix":"Keep one retry rule and name the status or timeout it applies to."}],"success":true,"analysis":"Checked retry sentences on 3 operations. A method name was not read as safe or unsafe.","warnings":[{"type":"retry_not_documented","evidence":"GET","location":"operations[2]","severity":"medium","description":"The contract does not say whether a retry is safe. Silence is not a retry policy, and the HTTP method is not one either.","agent_impact":"An agent has no contract rule for a dropped response and may invent one from the method.","suggested_fix":"Add a sentence such as safe to retry or do not retry, and the outcome it applies to."}],"limitations":["Checks read only the supplied operations, workflows, and OpenAPI document. No URL is fetched and no model reads the text.","A missing sentence is an undocumented contract. It is not a confirmed defect in a running implementation.","A contradiction is two statements in the supplied text. It is not proof of how a server behaves.","The HTTP method is not evidence that an operation is safe to retry or that it is idempotent.","Matches are fixed phrases and field names. They do not infer a business rule that the text does not state.","Safe phrases include safe to retry, may be retried, and retries are safe. Unsafe phrases include do not retry and not safe to retry.","Uncertain outcomes are the words timeout, uncertain, unknown outcome, may have succeeded, and in-flight, plus response statuses 408 and 504.","A contradiction subtracts 25. A timeout with no retry sentence subtracts 20. Silence without a timeout is a warning and does not change the score."],"recommendations":[]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.03","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.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_J8Qiim7FbwAQjHsz5PpSh","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Analyzes agent contract definitions (OpenAPI, workflows, operations) for missing, ambiguous, or contradictory retry policies that could cause AI agents to double-charge, duplicate actions, or stall after timeouts.","exampleAgentPrompt":"Can you check my agent contract for retry safety issues? Here are my operations — one charges a saved card on timeout and another reserves stock but I'm not sure if retrying is safe. I want a score and a list of any missing or contradictory retry policies with suggested fixes.","exampleUseCases":[{"title":"Payment operation timeout retry audit","prompt":"I have an agent that charges a customer's saved card via a POST operation, and I'm worried about what happens if the call times out — can you check my OpenAPI spec and operation definitions to see if the retry policy is safe and flag any missing or contradictory rules?"},{"title":"E-commerce stock reservation workflow check","prompt":"My agent workflow reserves inventory and I'm not sure whether retrying after a failure is safe or not — can you analyze my workflow steps and states for missing retry documentation and tell me exactly what an agent might do wrong if no policy is stated?"},{"title":"Multi-step agent contract compliance review","prompt":"Before we ship this agent contract with 8 operations and 3 workflows, can you run a retry safety check on the whole thing and give us a score plus a list of every high-severity issue, contradiction, or undocumented retry scenario we need to fix?"}],"resultDescription":"Returns a JSON object with a numeric safety score (0-100), an array of issues (each with type, severity, location, evidence, description, agent impact, and suggested fix), an array of warnings for undocumented retry behaviors, an overall analysis summary string, and a limitations array explaining what the check does and does not cover. Also includes a success boolean.","failureModes":["Malformed or missing required fields in operations or workflows cause validation errors","Truncated or overly large OpenAPI documents may exceed schema limits","Contradictions can only be detected in supplied text — runtime server behavior is not tested","Missing retry sentences are flagged as undocumented, not confirmed bugs","Payment via x402 may fail if USDC balance is insufficient or Base network is congested"],"whenToPreferThis":"Use this endpoint when you need automated, deterministic analysis of agent contract retry semantics before deployment — especially for contracts involving payment operations, state-modifying calls, or multi-step workflows where timeouts could cause double-charges or stuck agents. Prefer this over manual review when you have structured OpenAPI or workflow definitions and want scored, actionable feedback with per-operation impact analysis.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-12T18:39:45.754Z","isFirstParty":false,"canonicalSlug":"brainiac-agent-contract-retry-safety-check-9e1a6931"}