Get pricing

GET https://{POS_API}/api/v2/stations/{:external_id}/pricing

Retrieves the pricing information for a pickup at the given station.

Path parameters

  • external_id (string, required) The external identifier of the station. It usually consists of 4 lowercase alphanumeric characters (e.g. abc1)

Query parameters

  • auth0_id (string, optional) The Auth0 identifier of the user, if connected. This identifier may affect the pricing, if the user has any coupons attached to his accounts.

  • lang (string, optional) 2-digit lowercase language code (ISO 639-1 Code). Supported values: Locales.

Response

Success

HTTP 200

{ "data": { "station": { "external_id": "abc1", "coupon_type": null, "charge_currency": "CHF", "vat_rate": "7.7", "total_amounts": { "charge": 4.0, "quick_charge": 2.0, "deposit": 15.0, "weekly_late_fee": 2.0 }, "stripe_price_id": <stripe_price_id> }, "locale": "de-CH", "country": "CH" } }

Response elements

  • stripe_price_id: The relevant Stripe Price ID. Defined in Stripe Dashboard. See Stripe docs.

  • coupon_type : This field is filled only if a user coupon can be applied to the rental. Currently possible values are: [null, free_charge ]

Error

The following errors are possible:

  • The Chimpy Station has not been set up correctly in our system (error_type: station_setup_error)

  • The Chimpy Station is disconnected (error_type: station_offline_error)

  • The Chimpy Station doesn't have any charged batteries at the moment (error_type: no_battery_available_error)

  • In rare cases, some param validation or general error

The error_message field is localised for the supported locales (see Locales). The error_type field can be used to overwrite the different error messages on the client side.

HTTP 400

{ "error": { "type": "station_offline_error", "message": "Sorry, this station is currently offline." }, "req": {}, "locale": "en-CH" }