-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CODV2API (#1): now schema is explicitly in English; schema/CODV2API/v…
…1.0/location-item.schema.json
- Loading branch information
Showing
3 changed files
with
60 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{ | ||
"$schema": "https://json-schema.org/draft/2020-12/schema", | ||
"$id": "https://hapi.etica.ai/schema/CODV2API/v1.0/location-item.eng.schema.json", | ||
"title": "UN/CODV2API v1.0 location-item", | ||
"description": "JSON schema (English descriptions) from items of https://beta.itos.uga.edu/CODV2API/api/v1/locations (as 2021-05-05) \nJSON Schem specification here https://json-schema.org/ \nExample of online editor: https://www.jsonschemavalidator.net/", | ||
"type": "object", | ||
"required": [ | ||
"location_iso", | ||
"location_name", | ||
"Themes", | ||
"Total" | ||
], | ||
"additionalProperties": false, | ||
"properties": { | ||
"location_iso": { | ||
"description": "TODO: location_iso description", | ||
"type": "string", | ||
"minLength": 3, | ||
"maxLength": 3 | ||
}, | ||
"location_name": { | ||
"description": "TODO: location_name description", | ||
"type": "string", | ||
"minLength": 3, | ||
"maxLength": 128 | ||
}, | ||
"Themes": { | ||
"description": "TODO: location_iso description", | ||
"$comment": "How to use enums: https://json-schema.org/understanding-json-schema/reference/generic.html?highlight=enum#enumerated-values", | ||
"type": "array", | ||
"items": { | ||
"type": "string", | ||
"enum": [ | ||
"Administrative Boundary", | ||
"Population Statistics" | ||
] | ||
} | ||
}, | ||
"Total": { | ||
"description": "TODO: Total description", | ||
"type": "integer" | ||
}, | ||
"status": { | ||
"description": "TODO: status description", | ||
"type": "string" | ||
} | ||
}, | ||
"patternProperties": { | ||
"^_": { | ||
"type": [ | ||
"string", | ||
"array", | ||
"object" | ||
], | ||
"description": "Properties starting with Properties are tolerated, since we're enforcing additionalProperties=false" | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.