Gasoline Rbob (GASOLINE_RBOB_USD)
Status: ✅ Available | ⚡ Real-time | 📊 Live Data
Real-time pricing data for Gasoline Rbob. Access current and historical prices via our API.
Quick Reference
| Property | Value |
|---|---|
| Commodity Code | GASOLINE_RBOB_USD |
| Name | Gasoline Rbob |
| Category | Natural Gas |
| Currency | USD |
| Unit | USD/gallon |
| Current Price | $1.69 |
| Last Updated | 2025-12-16T15:24:10Z | | Source | oilprice.ft |
Get Latest Price
GET/v1/prices/latest?by_code=GASOLINE_RBOB_USD
Request
curl -X GET "https://api.oilpriceapi.com/v1/prices/latest?by_code=GASOLINE_RBOB_USD" \
-H "Authorization: Token YOUR_API_KEY" \
-H "Accept: application/json"
Response
{
"status": "success",
"data": {
"price": 1.69,
"formatted": "$1.69",
"currency": "USD",
"code": "GASOLINE_RBOB_USD",
"created_at": "2025-12-16T15:24:10Z",
"type": "spot_price",
"source": "oilprice.ft"
}
}
Get Historical Data
Past 24 Hours
GET /v1/prices/past_day?by_code=GASOLINE_RBOB_USD
Past 7 Days
GET /v1/prices/past_week?by_code=GASOLINE_RBOB_USD
Past 30 Days
GET /v1/prices/past_month?by_code=GASOLINE_RBOB_USD
Past Year
GET /v1/prices/past_year?by_code=GASOLINE_RBOB_USD
See Historical Prices API for full documentation.
Code Examples
cURL
# Get latest price
curl -H "Authorization: Token YOUR_API_KEY" \
"https://api.oilpriceapi.com/v1/prices/latest?by_code=GASOLINE_RBOB_USD"
Python
import requests
api_key = "YOUR_API_KEY"
url = "https://api.oilpriceapi.com/v1/prices/latest"
response = requests.get(
url,
params={"by_code": "GASOLINE_RBOB_USD"},
headers={"Authorization": f"Token {api_key}"}
)
data = response.json()
print(f"Gasoline Rbob: {data['data']['formatted']}")
JavaScript
const apiKey = 'YOUR_API_KEY';
const code = 'GASOLINE_RBOB_USD';
fetch(`https://api.oilpriceapi.com/v1/prices/latest?by_code=${code}`, {
headers: {
'Authorization': `Token ${apiKey}`
}
})
.then(res => res.json())
.then(data => {
console.log(`Gasoline Rbob: ${data.data.formatted}`);
});
Related Endpoints
- Get All Prices - Get all commodity prices in one call
- Historical Prices - Time-series data
- Commodities List - Browse all commodities
Last Updated: 2025-12-16