{"uid":"cap_487VET8mrGKY6nsfpBRLb","slug":"agent-credit-line-utilization-and-evaluation-based-settlement-procedure-1dad9755","name":"Agent Credit-Line Utilization and Evaluation-Based Settlement Procedure","description":"Deterministic procedure for agents that pay from credit lines and escrow balances via x402. Inputs: per-line caps and rates, current utilization, payment amount, due date, evaluation verdicts on delivered work, escrow state. Decides which line a payment draws against, tracks utilization after draw, flags top-up when utilization crosses 70% warning and 95% hard ceiling, wires evaluation verdicts into settlement: full pass releases, fail reduces settlement by defined ratio, partial pass prorates.","url":"https://k2so-8080.on.ascii.dev/api/services/agent-credit-line-utilization-and-evaluation-set","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 credit-line utilization and evaluation-based settlement 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":null,"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_vt_ilV5c3U3Kd034dKtoI","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 deterministic decision procedure for agents managing credit-line draws, utilization tracking, top-up warnings, and evaluation-verdict-based escrow settlement via x402.","exampleAgentPrompt":"I need to know which credit line to draw this $0.85 payment from — line A is at 68% utilization with a $10 cap, line B is at 40% with a $5 cap — the delivered work got a partial-pass evaluation verdict, so what's the prorated settlement amount and do I need to flag a top-up?","exampleUseCases":[{"title":"Partial-pass escrow settlement for delivered work","prompt":"The contractor agent delivered the report but evaluation came back as partial pass — I need to figure out the prorated settlement amount from escrow and which credit line absorbs it given line A is at 72% of its $20 cap and line B is at 30% of its $8 cap."},{"title":"Hard-ceiling enforcement before payment draw","prompt":"Before my agent sends the next x402 payment of $1.50, check whether any of my credit lines can absorb it without hitting the 95% ceiling — line X is at 91% utilization on a $15 cap and line Y is at 60% on a $10 cap."},{"title":"Full-pass escrow release with top-up warning","prompt":"The work passed evaluation fully, so I want to release the full escrow amount — the draw will come from line B which is currently at 71% of a $25 cap, and I need to know if a top-up warning should be triggered after this settlement."}],"resultDescription":"Returns a structured procedure result including a decision brief (prose for agents), the chosen credit line, post-draw utilization, any top-up warning flags (70% or 95% thresholds), and the settlement amount adjusted by evaluation verdict (full release, prorated partial, or reduced fail ratio), plus a timestamp and generation source.","failureModes":["Missing required credit-line caps or utilization values — returns ok: false with handler error","Payment amount exceeds all available credit lines below hard ceiling — procedure flags no viable line","Invalid or missing evaluation verdict — settlement calculation cannot be completed","Service unavailable or unpaid request — returns 402 Payment Required","Malformed query parameters — schema validation failure"],"whenToPreferThis":"Choose this endpoint when an agent must simultaneously decide which credit line to use for an x402 payment AND reconcile escrow settlement against evaluation verdicts in a single deterministic procedure. It is specifically suited for multi-line credit scenarios with utilization thresholds and evaluation-gated escrow release, rather than simple single-payment routing or generic budget checks.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T19:02:13.541Z","isFirstParty":false}