Crude oil

WTI or Brent in US dollars per barrel. /wti and /brent force the benchmark. /units and /history are there too.

View Docs

Parameters

benchmark string

wti or brent. Defaults to wti.

Example: brent

unit string

bbl, gal, l, or impgal. Defaults to bbl.

Example: l

amount number

How many of that unit to price. Defaults to 1.

Example: 1

Responses

200 OK Success
{
  "ok": true,
  "commodity": "crude oil",
  "benchmark": "wti",
  "currency": "USD",
  "price": 92.56,
  "unit": "bbl",
  "amount": 1,
  "totalUsd": 92.56
}
400 BAD_REQUEST unknown benchmark
502 BAD_GATEWAY could not load the crude oil price