Skip to content

Commit a783523

Browse files
Alessandro100qcdyxrichfab
authored
version 3.1-RC2 release (#166)
* version 3.1-RC2 release * Update v3.1-RC2/system_pricing_plans.json Co-authored-by: Fabien Richard Allouard (MobilityData) <fabien@mobilitydata.org> * Update v3.1-RC2/vehicle_availability.json Co-authored-by: Fabien Richard Allouard (MobilityData) <fabien@mobilitydata.org> * Update v3.1-RC2/gbfs.json I believe that's also a typo. Co-authored-by: Fabien Richard Allouard (MobilityData) <fabien@mobilitydata.org> * Add period between file name and json to schema ids --------- Co-authored-by: Jingsi Lu <jingsi@mobilitydata.org> Co-authored-by: Fabien Richard Allouard (MobilityData) <fabien@mobilitydata.org>
1 parent e98344a commit a783523

13 files changed

+3289
-0
lines changed

v3.1-RC2/gbfs.json

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema",
3+
"$id": "https://github.com/MobilityData/gbfs-json-schema/blob/master/v3.1-RC2/gbfs.json",
4+
"description": "Auto-discovery file that links to all of the other files published by the system.",
5+
"type": "object",
6+
"properties": {
7+
"last_updated": {
8+
"description": "Last time the data in the feed was updated in RFC3339 format.",
9+
"type": "string",
10+
"format": "date-time"
11+
},
12+
"ttl": {
13+
"description": "Number of seconds before the data in the feed will be updated again (0 if the data should always be refreshed).",
14+
"type": "integer",
15+
"minimum": 0
16+
},
17+
"version": {
18+
"description": "GBFS version number to which the feed conforms, according to the versioning framework (added in v1.1).",
19+
"type": "string",
20+
"const": "3.1-RC2"
21+
},
22+
"data": {
23+
"type": "object",
24+
"properties": {
25+
"feeds": {
26+
"description": "An array of all of the feeds that are published by the auto-discovery file. Each element in the array is an object with the keys below.",
27+
"type": "array",
28+
"items": {
29+
"type": "object",
30+
"properties": {
31+
"name": {
32+
"description": "Key identifying the type of feed this is. The key must be the base file name defined in the spec for the corresponding feed type.",
33+
"type": "string",
34+
"enum": [
35+
"gbfs",
36+
"gbfs_versions",
37+
"system_information",
38+
"vehicle_types",
39+
"station_information",
40+
"station_status",
41+
"vehicle_status",
42+
"system_alerts",
43+
"system_regions",
44+
"vehicle_availability",
45+
"system_pricing_plans",
46+
"geofencing_zones"
47+
]
48+
},
49+
"url": {
50+
"description": "URL for the feed.",
51+
"type": "string",
52+
"format": "uri"
53+
}
54+
},
55+
"required": ["name", "url"]
56+
},
57+
"minItems": 1,
58+
"contains": {
59+
"properties": {
60+
"name": { "const": "system_information" }
61+
}
62+
}
63+
}
64+
},
65+
"required": ["feeds"]
66+
}
67+
},
68+
"additionalProperties": false,
69+
"required": ["last_updated", "ttl", "version", "data"]
70+
}

v3.1-RC2/gbfs_versions.json

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema",
3+
"$id": "https://github.com/MobilityData/gbfs-json-schema/blob/master/v3.1-RC2/gbfs_versions.json",
4+
"description": "Lists all feed endpoints published according to version sof the GBFS documentation. (added in v1.1)",
5+
"type": "object",
6+
"properties": {
7+
"last_updated": {
8+
"description": "Last time the data in the feed was updated in RFC3339 format.",
9+
"type": "string",
10+
"format": "date-time"
11+
},
12+
"ttl": {
13+
"description": "Number of seconds before the data in the feed will be updated again (0 if the data should always be refreshed).",
14+
"type": "integer",
15+
"minimum": 0
16+
},
17+
"version": {
18+
"description": "GBFS version number to which the feed conforms, according to the versioning framework.",
19+
"type": "string",
20+
"const": "3.1-RC2"
21+
},
22+
"data": {
23+
"description": "Response data in the form of name:value pairs.",
24+
"type": "object",
25+
"properties": {
26+
"versions": {
27+
"description": "Contains one object, as defined below, for each of the available versions of a feed. The array must be sorted by increasing MAJOR and MINOR version number.",
28+
"type": "array",
29+
"items": {
30+
"type": "object",
31+
"properties": {
32+
"version": {
33+
"description": "The semantic version of the feed in the form X.Y",
34+
"type": "string",
35+
"enum": [
36+
"1.0",
37+
"1.1",
38+
"2.0",
39+
"2.1",
40+
"2.2",
41+
"2.3",
42+
"3.0",
43+
"3.1-RC2"
44+
]
45+
},
46+
"url": {
47+
"description": "URL of the corresponding gbfs.json endpoint",
48+
"type": "string",
49+
"format": "uri"
50+
}
51+
},
52+
"required": ["version", "url"]
53+
}
54+
}
55+
},
56+
"required": ["versions"],
57+
"additionalProperties": false
58+
}
59+
},
60+
"required": ["last_updated", "ttl", "version", "data"]
61+
}

v3.1-RC2/geofencing_zones.json

Lines changed: 202 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,202 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema",
3+
"$id": "https://github.com/MobilityData/gbfs-json-schema/blob/master/v3.1-RC2/geofencing_zones.json",
4+
"description": "Describes geofencing zones and their associated rules and attributes (added in v2.1-RC).",
5+
"type": "object",
6+
"properties": {
7+
"last_updated": {
8+
"description": "Last time the data in the feed was updated in RFC3339 format.",
9+
"type": "string",
10+
"format": "date-time"
11+
},
12+
"ttl": {
13+
"description": "Number of seconds before the data in the feed will be updated again (0 if the data should always be refreshed).",
14+
"type": "integer",
15+
"minimum": 0
16+
},
17+
"version": {
18+
"description": "GBFS version number to which the feed conforms, according to the versioning framework.",
19+
"type": "string",
20+
"const": "3.1-RC2"
21+
},
22+
"data": {
23+
"description": "Array that contains geofencing information for the system.",
24+
"type": "object",
25+
"properties": {
26+
"geofencing_zones": {
27+
"type": "object",
28+
"description": "Each geofenced zone and its associated rules and attributes is described as an object within the array of features.",
29+
"properties": {
30+
"type": {
31+
"description": "FeatureCollection as per IETF RFC 7946.",
32+
"type": "string",
33+
"enum": ["FeatureCollection"]
34+
},
35+
"features": {
36+
"description": "Array of objects.",
37+
"type": "array",
38+
"items": {
39+
"title": "GeoJSON Feature",
40+
"type": "object",
41+
"properties": {
42+
"type": {
43+
"type": "string",
44+
"enum": ["Feature"]
45+
},
46+
"properties": {
47+
"description": "Describing travel allowances and limitations.",
48+
"type": "object",
49+
"properties": {
50+
"name": {
51+
"description": "Public name of the geofencing zone.",
52+
"type": "array",
53+
"items": {
54+
"type": "object",
55+
"properties": {
56+
"text": {
57+
"description": "The translated text.",
58+
"type": "string"
59+
},
60+
"language": {
61+
"description": "IETF BCP 47 language code.",
62+
"type": "string",
63+
"pattern": "^[a-z]{2,3}(-[A-Z]{2})?$"
64+
}
65+
},
66+
"required": ["text", "language"]
67+
}
68+
},
69+
"start": {
70+
"description": "Start time of the geofencing zone in RFC3339 format.",
71+
"type": "string",
72+
"format": "date-time"
73+
},
74+
"end": {
75+
"description": "End time of the geofencing zone in RFC3339 format.",
76+
"type": "string",
77+
"format": "date-time"
78+
},
79+
"rules": {
80+
"description": "Array of Rule objects defining restrictions that apply within the area of the polygon.",
81+
"type": "array",
82+
"items": {
83+
"type": "object",
84+
"properties": {
85+
"vehicle_type_ids": {
86+
"type": "array",
87+
"description": "Array of vehicle type IDs for which these restrictions apply.",
88+
"items": { "type": "string" }
89+
},
90+
"ride_start_allowed": {
91+
"description": "Is the ride allowed to start in this zone?",
92+
"type": "boolean"
93+
},
94+
"ride_end_allowed": {
95+
"description": "Is the ride allowed to end in this zone?",
96+
"type": "boolean"
97+
},
98+
"ride_through_allowed": {
99+
"description": "Is the ride allowed to travel through this zone?",
100+
"type": "boolean"
101+
},
102+
"maximum_speed_kph": {
103+
"description": "What is the maximum speed allowed, in kilometers per hour?",
104+
"type": "integer",
105+
"minimum": 0
106+
},
107+
"station_parking": {
108+
"description": "Vehicle MUST be parked at stations defined in station_information.json within this geofence zone",
109+
"type": "boolean"
110+
}
111+
},
112+
"required": [
113+
"ride_start_allowed",
114+
"ride_end_allowed",
115+
"ride_through_allowed"
116+
]
117+
}
118+
}
119+
}
120+
},
121+
"geometry": {
122+
"description": "A polygon that describes where rides might not be able to start, end, go through, or have other limitations. Must follow the right-hand rule.",
123+
"title": "GeoJSON MultiPolygon",
124+
"type": "object",
125+
"properties": {
126+
"type": {
127+
"type": "string",
128+
"enum": ["MultiPolygon"]
129+
},
130+
"coordinates": {
131+
"type": "array",
132+
"items": {
133+
"type": "array",
134+
"items": {
135+
"type": "array",
136+
"minItems": 4,
137+
"items": {
138+
"type": "array",
139+
"minItems": 2,
140+
"items": {
141+
"type": "number"
142+
}
143+
}
144+
}
145+
}
146+
}
147+
},
148+
"required": ["type", "coordinates"]
149+
}
150+
},
151+
"required": ["type", "geometry", "properties"]
152+
}
153+
}
154+
},
155+
"required": ["type", "features"]
156+
},
157+
"global_rules": {
158+
"description": "Array of Rule objects defining restrictions that apply globally in all areas as the default restrictions, except where overridden with an explicit geofencing zone.",
159+
"type": "array",
160+
"items": {
161+
"type": "object",
162+
"properties": {
163+
"vehicle_type_ids": {
164+
"type": "array",
165+
"description": "Array of vehicle type IDs for which these restrictions apply.",
166+
"items": { "type": "string" }
167+
},
168+
"ride_start_allowed": {
169+
"description": "Is the ride allowed to start in this zone?",
170+
"type": "boolean"
171+
},
172+
"ride_end_allowed": {
173+
"description": "Is the ride allowed to end in this zone?",
174+
"type": "boolean"
175+
},
176+
"ride_through_allowed": {
177+
"description": "Is the ride allowed to travel through this zone?",
178+
"type": "boolean"
179+
},
180+
"maximum_speed_kph": {
181+
"description": "What is the maximum speed allowed, in kilometers per hour?",
182+
"type": "integer",
183+
"minimum": 0
184+
},
185+
"station_parking": {
186+
"description": "Vehicle MUST be parked at stations defined in station_information.json within this geofence zone",
187+
"type": "boolean"
188+
}
189+
},
190+
"required": [
191+
"ride_start_allowed",
192+
"ride_end_allowed",
193+
"ride_through_allowed"
194+
]
195+
}
196+
}
197+
},
198+
"required": ["geofencing_zones", "global_rules"]
199+
}
200+
},
201+
"required": ["last_updated", "ttl", "version", "data"]
202+
}

0 commit comments

Comments
 (0)