openmobilityfoundation / curb-data-specification

A data specification to help cities manage their curb zone programs and surrounding areas, and measure the utilization and impact.
https://www.openmobilityfoundation.org/about-cds/
Other
47 stars 18 forks source link

Currency field for Rate #120

Open InrixParking opened 1 year ago

InrixParking commented 1 year ago

Is your feature request related to a problem? Please describe.

We have data in non-USD countries

Describe the solution you'd like

An optional field for currency that takes ISO currency code

Is this a breaking change

Impacted Spec

Describe alternatives you've considered

Might be better in a higher-level object.

schnuerle commented 1 year ago

Discussion needed if people think this is urgent enough to including in the 1.0.1 patch release as a new rate_currency field, maybe at the Policy object level.

mplsmitch commented 4 months ago

The rate object is defined as

cents (or the smallest denomination of local currency)

So it seems this is possible but I agree using ISO 4217 would be much clearer.

andrewdgh commented 4 months ago

Using agreed-upon currency codes for the "local currency" seems to be the most straight forward

schnuerle commented 4 months ago

The 'Rate' object seems like the right place, as this is where the rate in cents field is.

In MDS we specify a currency field e.g. in the cost of Trips, and description of the ISO 4217 code here.

Recommend adding an optional (empty means USD, like in MDS) currency field here to the Rate object. Actually seems like an oversight that we didn't do this at launch. May also want to add it to the Curb Event object?

jiffyclub commented 1 week ago

There is a currency field described at the top level of responses here: https://github.com/openmobilityfoundation/curb-data-specification/blob/1.0.0/general-information.md#rest-endpoints

Have not thought through how that intersects with every part of CDS to see whether that solves this use case or whether it's needed lower down as well.

schnuerle commented 1 week ago

I think @jiffyclub is right, currency in meant to be returned with every single CDS endpoint.

Maybe what's needed here is better linking to this documentation so it can be more easily findable.