-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathplaces.schema.json
More file actions
62 lines (62 loc) · 2.14 KB
/
Copy pathplaces.schema.json
File metadata and controls
62 lines (62 loc) · 2.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://github.com/StudentSuite/StudyMap/blob/main/data/places.schema.json",
"title": "StudyMap place record",
"description": "Canonical schema for one entry in data/places/<type>.json. Mirrors the Place type in src/lib/types.ts. See data/CONTRIBUTING.md for the human-readable guide.",
"type": "object",
"additionalProperties": false,
"required": ["id", "name", "type", "city", "lat", "lng", "gmaps_link", "added_by"],
"properties": {
"id": {
"type": "string",
"minLength": 1,
"description": "<city-prefix>-<type>-<number>, unique within the file, e.g. mum-library-07"
},
"name": {
"type": "string",
"minLength": 1
},
"type": {
"type": "string",
"enum": ["library", "other_places", "airport", "sat_centre", "foreign_lang_exam_centre", "gov_offices"],
"description": "Must match the filename it lives in, e.g. data/places/library.json -> \"library\""
},
"city": {
"type": "string",
"minLength": 1,
"description": "Lowercase, underscore-separated slug, e.g. \"mumbai\", \"navi_mumbai\". Any city worldwide is welcome, not a fixed enum."
},
"lat": {
"type": "number",
"minimum": -90,
"maximum": 90
},
"lng": {
"type": "number",
"minimum": -180,
"maximum": 180
},
"address": {
"type": "string",
"description": "Optional, short, human-readable"
},
"gmaps_link": {
"type": "string",
"pattern": "^https://(maps\\.google\\.com(\\?|/)|maps\\.app\\.goo\\.gl/|www\\.google\\.com/maps/|goo\\.gl/maps/)"
},
"added_by": {
"type": "string",
"minLength": 1,
"description": "GitHub username of the contributor"
},
"exam": {
"type": "string",
"description": "Optional. Only for sat_centre / foreign_lang_exam_centre, e.g. \"SAT\", \"IELTS\", \"Goethe-Zertifikat (A1-C2)\""
},
"valid_till": {
"type": "string",
"format": "date",
"description": "Optional. Only for sat_centre / foreign_lang_exam_centre. ISO date (YYYY-MM-DD) the entry should be reconfirmed by."
}
}
}