Skip to content
Fourohtwo

agents.204-168-199-108.sslip.io/v1/util/json-patch

Apply JSON Patch operations (add, remove, replace, move, copy, test) to a JSON document and get the result. Supports '-' to append to arrays, ~0/~1 escaping, and 'test' guards (the whole patch fails with 422 if a test fails, nothing is half-applied). Also accepts the 'pointer' key from /v1/util/json-diff changes. Prototype-pollution keys are refused.

BaseSolanaaws:baseAnswering
GEThttps://agents.204-168-199-108.sslip.io/v1/util/json-patch

Uptime100% of 1 check 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.204-168-199-108.sslip.io/v1/util/json-patch?data=%7B%22name%22%3A%22Acme%22%2C%22plan%22%3A%22basic%22%2C%22tags%22%3A%5B%22ai%22%5D%7D&patch=%5B%7B%22op%22%3A%22test%22%2C%22path%22%3A%22%2Fplan%22%2C%22value%22%3A%22basic%22%7D%2C%7B%22op%22%3A%22replace%22%2C%22path%22%3A%22%2Fplan%22%2C%22value%22%3A%22pro%22%7D%2C%7B%22op%22%3A%22add%22%2C%22path%22%3A%22%2Ftags%2F-%22%2C%22value%22%3A%22x402%22%7D%2C%7B%22op%22%3A%22add%22%2C%22path%22%3A%22%2Fseats%22%2C%22value%22%3A10%7D%2C%7B%22op%22%3A%22move%22%2C%22from%22%3A%22%2Fname%22%2C%22path%22%3A%22%2Fcompany%22%7D%5D");
console.log(await res.json());

Example input

{
  "data": "{\"name\":\"Acme\",\"plan\":\"basic\",\"tags\":[\"ai\"]}",
  "patch": "[{\"op\":\"test\",\"path\":\"/plan\",\"value\":\"basic\"},{\"op\":\"replace\",\"path\":\"/plan\",\"value\":\"pro\"},{\"op\":\"add\",\"path\":\"/tags/-\",\"value\":\"x402\"},{\"op\":\"add\",\"path\":\"/seats\",\"value\":10},{\"op\":\"move\",\"from\":\"/name\",\"path\":\"/company\"}]"
}
agents.204-168-199-108.sslip.io/v1/util/json-patch by JSON Patch apply RFC 6902 · x402 API | Fourohtwo