Skip to content

Commit

Permalink
Fix examples (#575) (#577)
Browse files Browse the repository at this point in the history
* Fix json



* Fix examples to make them conform to json/GBFS specification



* Update version in examples

* Internationalization of free-form text

---------

Signed-off-by: Tom <[email protected]>
Co-authored-by: Tom <[email protected]>
  • Loading branch information
richfab and tdelmas committed Dec 12, 2023
1 parent 3208248 commit 49b74f8
Showing 1 changed file with 60 additions and 28 deletions.
88 changes: 60 additions & 28 deletions gbfs.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,9 +266,14 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 3600,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"name": "Example Bike Rental",
"name": [
{
"text": "Example Bike Rental",
"language": "en"
}
],
"system_id": "example_cityname",
"timezone": "America/Chicago",
"languages": ["en"]
Expand All @@ -292,7 +297,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"feeds": [
{
Expand Down Expand Up @@ -379,15 +384,15 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"versions": [
{
"version": "2.0",
"url": "https://www.example.com/gbfs/2/gbfs"
},
{
"version": "3.0-RC",
"version": "3.0-RC2",
"url": "https://www.example.com/gbfs/3/gbfs"
}
]
Expand Down Expand Up @@ -444,7 +449,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 1800,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"system_id": "example_cityname",
"languages": ["en"],
Expand Down Expand Up @@ -556,7 +561,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"vehicle_types": [
{
Expand Down Expand Up @@ -609,7 +614,7 @@ Field Name | REQUIRED | Type | Defines
"icon_last_modified": "2021-06-15"
},
"default_pricing_plan_id": "cargo_plan_1",
"pricing_plans_ids": [
"pricing_plan_ids": [
"cargo_plan_1",
"cargo_plan_2",
"cargo_plan_3"
Expand Down Expand Up @@ -680,7 +685,7 @@ Field Name | REQUIRED | Type | Defines
"model": [
{
"text": "Clio",
"language": "en",
"language": "en"
}
],
"color": "white",
Expand Down Expand Up @@ -739,7 +744,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
Expand Down Expand Up @@ -775,7 +780,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
Expand Down Expand Up @@ -867,7 +872,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
Expand Down Expand Up @@ -1071,7 +1076,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 86400,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"regions": [
{
Expand Down Expand Up @@ -1151,7 +1156,7 @@ The user does not pay more than the base price for the first 10 km. After 10 km
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"plans": [
{
Expand Down Expand Up @@ -1204,7 +1209,7 @@ This example demonstrates a pricing scheme that has a rate both by minute and by
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 0,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"plans": [
{
Expand Down Expand Up @@ -1270,7 +1275,7 @@ Field Name | REQUIRED | Type | Defines
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"alerts": [
{
Expand Down Expand Up @@ -1305,7 +1310,7 @@ Field Name | REQUIRED | Type | Defines
"language": "en"
}
],
"last_updated": "2023-07-17T13:34:13+02:00",
"last_updated": "2023-07-17T13:34:13+02:00"
}
]
}
Expand Down Expand Up @@ -1367,7 +1372,7 @@ See examples below.
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"geofencing_zones": {
"type": "FeatureCollection",
Expand Down Expand Up @@ -1653,17 +1658,24 @@ Other supported parameters include:
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"name": "Example Bike Rental",
"name": [
{
"text": "Example Bike Rental",
"language": "en"
}
],
"system_id": "example_cityname",
"timezone": "America/Chicago",
"languages": ["en"],
"rental_apps": {
"android": {
"store_uri": "https://play.google.com/store/apps/details?id=com.example.android",
"discovery_uri": "com.example.android://"
},
"ios": {
"store_uri": "https://apps.apple.com/app/apple-store/id123456789",
"discovery_uri": "com.example.ios://"
}
}
Expand All @@ -1677,12 +1689,17 @@ Other supported parameters include:
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
"station_id": "425",
"name": "Coppertail",
"name": [
{
"text": "Coppertail",
"language": "en"
}
],
"lat": 27.956333,
"lon": -82.430436,
"rental_uris": {
Expand All @@ -1705,9 +1722,14 @@ Note that the Android URI and iOS Universal Link URLs do not necessarily use the
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"name": "Example Bike Rental",
"name": [
{
"text": "Example Bike Rental",
"language": "en"
}
],
"system_id": "example_cityname",
"timezone": "America/Chicago",
"languages": ["en"],
Expand All @@ -1731,12 +1753,17 @@ Note that the Android URI and iOS Universal Link URLs do not necessarily use the
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
"station_id": "425",
"name": "Coppertail",
"name": [
{
"text": "Coppertail",
"language": "en"
}
],
"lat": 27.956333,
"lon": -82.430436,
"rental_uris":{
Expand All @@ -1757,12 +1784,17 @@ Note that the Android URI and iOS Universal Link URLs do not necessarily use the
{
"last_updated": "2023-07-17T13:34:13+02:00",
"ttl": 60,
"version": "3.0-RC",
"version": "3.0-RC2",
"data": {
"stations": [
{
"station_id": "425",
"name": "Coppertail",
"name": [
{
"text": "Coppertail",
"language": "en"
}
],
"lat": 27.956333,
"lon": -82.430436,
"rental_uris": {
Expand Down

0 comments on commit 49b74f8

Please sign in to comment.