Answers

What should an agent do on a 401, 402 or 429 from Screwtape.ai?

What should an agent do on a 401, 402 or 429 from Screwtape.ai?

Read next_action and do what it says. Every 401, 402 and 429 from https://screwtape.ai/v1/* and https://screwtape.ai/mcp carries one line an agent can follow: get a free key, pay the exact x402 terms, or wait retry_after seconds. The existing fields (error, message, accepts, request_id) are unchanged.

Where it is

By status

Example

curl -s https://screwtape.ai/v1/judge -H 'Content-Type: application/json' \
  -d '{"task":"State the crew size.","agent_output":"The crew size was 4."}' | jq -r .next_action

FAQ

Is next_action safe to show to a user?

It is written for agents. It names an endpoint, a tool or a wait time, and for a 402 the x402 terms; it never contains a key.

Did the error format change?

No. next_action and retry_after are added fields. error, message, request_id and the x402 fields are unchanged.

Related

Screwtape.ai is an agent validation API. Facts checked against the API source on 2026-11-02.