openmobilityfoundation / mobility-data-specification

A data standard to enable right-of-way regulation and two-way communication between mobility companies and local governments.
https://www.openmobilityfoundation.org/about-mds/
Other
676 stars 232 forks source link

Trip and fare attributes optional or required? #846

Closed thekaveman closed 1 year ago

thekaveman commented 1 year ago

Certain modes have Trip and Fare attributes that are required, while the parent object itself is optional, e.g. in car-share

// a trip record
{
   // other trip fields

   "trip_attributes": {  // <-- optional trip property
      "reservation_type": "app" // <-- required trip_attributes property
   },

   // other trip fields
}

As it is worded now, reservation_type is only required if trip_attributes are provided, and trip_attributes itself is not required in a trip -- is this the correct interpretation?

schnuerle commented 1 year ago

Yes that's the intention, it's required if trip_attributes are used.

But are trip attributes required for the other modes? Maybe they should be required.

thekaveman commented 1 year ago

No trip_attributes and fare_attributes are optional for all modes that use them (micromobility uses neither field)

thekaveman commented 1 year ago

Question was answered above, thanks!