{
"title": "GeoJSON",
"description": "A GeoJSON object",
"type": "object",
"anyOf": [
{ "$ref": "#/definitions/point" },
{ "$ref": "#/definitions/multipoint" },
{ "$ref": "#/definitions/linestring" },
{ "$ref": "#/definitions/multilinestring" }
],
"definitions": {
"multilinestring": {
"description": "A GeoJSON MultiLineString",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": { "enum": ["MultiLineString"] },
"coordinates": {
"type": "array",
"items": { "$ref": "#/definitions/linestring/properties/coordinates" }
}
}
},
"linestring": {
"description": "A GeoJSON LineString",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": { "enum": ["LineString"] },
"coordinates": {
"type": "array",
"minItems": 2,
"items": { "$ref": "#/definitions/position" }
}
}
},
"multipoint": {
"description": "A GeoJSON MultiPoint",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": { "enum": ["MultiPoint"] },
"coordinates": {
"type": "array",
"items": { "$ref": "#/definitions/position" }
}
}
},
"point": {
"description": "A GeoJSON Point",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": { "enum": ["Point"] },
"coordinates": { "$ref": "#/definitions/position" }
}
},
"position": {
"description": "A GeoJSON Position",
"type": "array",
"minItems": 2,
"items": { "type": "number" }