Skip to content
Fourohtwo

Review a PostgreSQL EXPLAIN (FORMAT JSON) plan

code.halowerk.com/v1/explain-review

Review a PostgreSQL EXPLAIN (FORMAT JSON) plan: exclusive time per node, hotspots, misestimates, disk spills, wasteful scans and index candidates from filter columns. Reads EXPLAIN output in JSON format (with or without ANALYZE/BUFFERS) and walks the plan tree.

BaseAnswering
POSThttps://code.halowerk.com/v1/explain-review

Uptime100% of 4 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://code.halowerk.com/v1/explain-review", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"plan":[{"Execution Time":12.6,"Plan":{"Actual Loops":1,"Actual Rows":950,"Actual Total Time":12.4,"Alias":"orders","Filter":"(status = 'open'::text)","Node Type":"Seq Scan","Plan Rows":1000,"Relation Name":"orders","Rows Removed by Filter":99050,"Total Cost":1693},"Planning Time":0.1}]}),
});
console.log(await res.json());

Example input

{
  "plan": [
    {
      "Execution Time": 12.6,
      "Plan": {
        "Actual Loops": 1,
        "Actual Rows": 950,
        "Actual Total Time": 12.4,
        "Alias": "orders",
        "Filter": "(status = 'open'::text)",
        "Node Type": "Seq Scan",
        "Plan Rows": 1000,
        "Relation Name": "orders",
        "Rows Removed by Filter": 99050,
        "Total Cost": 1693
      },
      "Planning Time": 0.1
    }
  ]
}