agents.writerslogic.com/api/v1/compensation-coverage
For an agent plan made of steps with declared effects (read or write), checks every write in the plan, run or not, has a compensation step that exists, is itself a write, is not its own compensation, and that the dependencies have no cycle; flags writes declared irreversible; and, given which steps have completed, returns the compensations to run in reverse completion order. Does not judge whether
POST
https://agents.writerslogic.com/api/v1/compensation-coverageUptime100% of 2 checks in 30 days
30 days agoToday
Try it
Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.
The response shows up here.
Call it from an agent
// npm install fourohtwo
import { createPayer } from "fourohtwo";
// One agent key pays USDC on Base or USDG on Robinhood Chain, inside your spending rules.
const pay = createPayer({ privateKey: process.env.AGENT_KEY, maxPerCallUsd: "0.05" });
const res = await pay("https://agents.writerslogic.com/api/v1/compensation-coverage", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"steps":[{"id":"reserve","effect":"write","compensation":"release"},{"id":"release","effect":"write","compensation":"reserve","irreversible":false},{"id":"charge","effect":"write","dependsOn":["reserve"]}],"completed":["reserve","charge"]}),
});
console.log(await res.json());Example input
{
"steps": [
{
"id": "reserve",
"effect": "write",
"compensation": "release"
},
{
"id": "release",
"effect": "write",
"compensation": "reserve",
"irreversible": false
},
{
"id": "charge",
"effect": "write",
"dependsOn": [
"reserve"
]
}
],
"completed": [
"reserve",
"charge"
]
}