{"openapi":"3.1.0","info":{"title":"x402 Fuel Price API","version":"2.0.0","description":"Pay-per-call UK weekly average road fuel price for AI agents.","x-guidance":"Use GET /price to get the current UK weekly average petrol and diesel price in pence/litre, sourced live from DESNZ. You are charged only for a real price row — if the gov.uk source does not answer you get 502 and pay nothing. Optional params: country (GB only) and fuel (petrol|diesel).","x-payment-policy":"NEVER CHARGED FOR AN UNDELIVERABLE ANSWER. The x402 middleware cancels settlement for any response >= 400, so every error below moves $0.00 and emits no payment-response header.","x-limitations":["UK national average only — no regional/per-state breakdown and no other countries; an unsupported country param returns 400 rather than being silently ignored.","Weekly cadence, not real-time or daily: the response carries staleness.ageDays for the returned row."]},"paths":{"/price":{"get":{"operationId":"fuelPrice","summary":"UK weekly average fuel price","tags":["Data"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.010000"},"protocols":[{"x402":{}}]},"parameters":[{"name":"country","in":"query","required":false,"schema":{"type":"string","enum":["GB"]}},{"name":"fuel","in":"query","required":false,"schema":{"type":"string","enum":["petrol","diesel"]}}],"responses":{"200":{"description":"Current UK weekly average fuel price with source provenance and staleness. The only response you are charged for."},"400":{"description":"NOT CHARGED. Unsupported country (this source is UK national average only) or an invalid fuel value. Do not retry with the same params."},"402":{"description":"Payment Required"},"405":{"description":"NOT CHARGED. Wrong HTTP verb for this resource; see the Allow header."},"502":{"description":"NOT CHARGED. The gov.uk (DESNZ) upstream did not answer or returned no usable row, so no price could be served. Retryable."}}}}}}