From 33d1b1ee1e49ae9d786d1fc5eabb62b649cc6a05 Mon Sep 17 00:00:00 2001 From: AnthorNet Date: Fri, 12 Jun 2015 18:51:38 +0200 Subject: [PATCH] Forget to push proposal for issue #20 --- schemas/outfitting-v1.0-draft.json | 70 ++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 schemas/outfitting-v1.0-draft.json diff --git a/schemas/outfitting-v1.0-draft.json b/schemas/outfitting-v1.0-draft.json new file mode 100644 index 0000000..ae6a502 --- /dev/null +++ b/schemas/outfitting-v1.0-draft.json @@ -0,0 +1,70 @@ +{ + "$schema" : "http://json-schema.org/draft-04/schema#", + "id" : "http://schemas.elite-markets.net/eddn/outfitting/1#", + "type" : "object", + "additionalProperties" : false, + "required" : [ "$schemaRef", "header", "message" ], + "properties" : { + "$schemaRef" : { "type": "string" }, + + "header" : { + "type" : "object", + "additionalProperties" : true, + "required": [ "uploaderID", "softwareName", "softwareVersion" ], + "properties" : { + "uploaderID" : { "type": "string" }, + "softwareName" : { "type": "string" }, + "softwareVersion" : { "type": "string" }, + "gatewayTimestamp" : { + "type": "string", + "format": "date-time", + "description": "Timestamp upon receipt at the gateway. If present, this property will be overwritten by the gateway; submitters are not intended to populate this property." + } + } + }, + + "message": { + "type": "object", + "additionalProperties": false, + "required": [ "systemName", "stationName", "timestamp", "modules" ], + "properties": { + "systemName": { + "type" : "string", + "minLength" : 1 + }, + "stationName": { + "type" : "string", + "minLength" : 1 + }, + "timestamp": { + "type" : "string", + "format" : "date-time" + }, + "modules": { + "type" : "array", + "minItems" : 1, + "items" : { + "oneOf": [ + { + "type" : "object", + "additionalProperties" : false, + "required" : [ "name" ], + "properties" : { + "name": { + "type" : "string", + "minLength" : 1 + }, + "fdId": { + "type" : "number", + "multipleOf" : 1.0, + "minimum": 1 + } + } + } + ] + } + } + } + } + } +} \ No newline at end of file