getPriceHistoryByStation

fun getPriceHistoryByStation(stationId: String, since: Date, granularity: String, forecast: Boolean = false, completion: (Completion<List<PriceHistory>>) -> Unit)

Returns the price history for the specified gas station.

Parameters

stationId

The gas station ID.

since

Must be less than now and not more than 1 year ago.

granularity

Number&Unit (m,d,w,M,y); Example: 15m.

forecast

Determines if the response includes a price forecast.

completion

Returns a list of PriceHistory objects on success or a Throwable on failure.

fun getPriceHistoryByStation(stationId: String, fuelType: String, since: Date, granularity: String, forecast: Boolean = false, completion: (Completion<List<PriceHistoryFuelType>>) -> Unit)

Returns the price history for the specified gas station and fuel type.

Parameters

stationId

The gas station ID.

fuelType

Fuel type for cars, based on the EU fuel marking.

since

Must be less than now and not more than 1 year ago.

granularity

Number&Unit (m,d,w,M,y); Example: 15m.

forecast

Determines if the response includes a price forecast.

completion

Returns a list of PriceHistoryFuelType objects on success or a Throwable on failure.