82trust / 100
Energy
by x402stock.xyz in Markets & finance
x402 APIPassing, checked 3 h ago
Every energy benchmark in one call: WTI and Brent crude oil spot, Henry Hub natural gas spot, and US regular retail gasoline — each with its latest price, prior reading, and change. The catalog's commodities feed (no equity/forex/crypto endpoint carries these). For one benchmark with history use /api/v1/energy/{product}. Source: U.S. Energy Information Administration (EIA). From x402stock
GET https://x402stock.xyz/api/v1/energy
Last 30 days
All checks passedSome failedAll failedNot checked
- Uptime
- 100%
- Response time
- 211 ms typical, 211 ms slowest 5%
- Last check
- 3 h ago
- Next check
- any minute now
How to call it
# See the payment challenge (nothing is charged)
curl -i -X GET "https://x402stock.xyz/api/v1/energy"import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client().register(
"eip155:8453",
new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? Preflight it first for $0.005:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fx402stock.xyz%2Fapi%2Fv1%2Fenergy
const res = await pay("https://x402stock.xyz/api/v1/energy");
console.log(await res.json());Example input
{}Example output
{
"as_of": "2026-06-01T00:00:00.000Z",
"attribution": "Source: U.S. Energy Information Administration (EIA)",
"products": [
{
"change": 4.8,
"change_percent": 5.27,
"eia_units": "$/BBL",
"frequency": "daily",
"latest": {
"date": "2026-06-01",
"value": 95.96
},
"name": "WTI Crude Oil — Cushing, OK Spot Price FOB",
"prior": {
"date": "2026-05-29",
"value": 91.16
},
"product": "wti",
"series_id": "RWTC",
"unit": "usd_per_barrel"
},
{
"change": -0.27,
"change_percent": -8.08,
"eia_units": "$/MMBTU",
"frequency": "daily",
"latest": {
"date": "2026-06-01",
"value": 3.07
},
"name": "Henry Hub Natural Gas Spot Price",
"prior": {
"date": "2026-05-29",
"value": 3.34
},
"product": "natural-gas",
"series_id": "RNGWHHD",
"unit": "usd_per_mmbtu"
}
],
"series": "energy_prices",
"source": "eia"
}Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 3 h ago | Passed | 402 | 211 ms | $0.02 |
| 8 h ago | Passed | 402 | 240 ms | $0.02 |