Skip to content
Fourohtwo

agents.writerslogic.com/api/v1/schema-witness

Walks a caller-supplied JSON Schema 2020-12 and, for every constraint keyword (type, enum, const, minimum, maximum, exclusiveMinimum, exclusiveMaximum, multipleOf, minLength, maxLength, pattern, format, minItems, maxItems, uniqueItems, required, minProperties, maxProperties, additionalProperties false, dependentRequired), returns the JSON pointer of the constraint, an example that satisfies it and

BaseAnswering
POSThttps://agents.writerslogic.com/api/v1/schema-witness

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.writerslogic.com/api/v1/schema-witness", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"schema":{"type":"object","required":["name","age"],"properties":{"age":{"type":"integer","maximum":150,"minimum":0},"name":{"type":"string","maxLength":5,"minLength":2}},"additionalProperties":false}}),
});
console.log(await res.json());

Example input

{
  "schema": {
    "type": "object",
    "required": [
      "name",
      "age"
    ],
    "properties": {
      "age": {
        "type": "integer",
        "maximum": 150,
        "minimum": 0
      },
      "name": {
        "type": "string",
        "maxLength": 5,
        "minLength": 2
      }
    },
    "additionalProperties": false
  }
}