From c97c5876f263e2abb7d6a0aba3d7416c32d474c3 Mon Sep 17 00:00:00 2001 From: AnthorNet Date: Mon, 15 Jun 2015 09:08:09 +0200 Subject: [PATCH] Update proposal #16 --- schemas/shipyard-v1.0-draft.json | 157 ++++++++++++++----------------- 1 file changed, 71 insertions(+), 86 deletions(-) diff --git a/schemas/shipyard-v1.0-draft.json b/schemas/shipyard-v1.0-draft.json index 7d2df41..4e241ed 100644 --- a/schemas/shipyard-v1.0-draft.json +++ b/schemas/shipyard-v1.0-draft.json @@ -1,92 +1,77 @@ { - "$schema" : "http://json-schema.org/draft-04/schema#", - "id" : "http://schemas.elite-markets.net/eddn/shipyard/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", "ships" ], - "properties": { - "systemName": { - "type" : "string", - "minLength" : 1 + "$schema" : "http://json-schema.org/draft-04/schema#", + "id" : "http://schemas.elite-markets.net/eddn/shipyard/1#", + "type" : "object", + "additionalProperties" : false, + "required" : [ "$schemaRef", "header", "message" ], + "properties" : { + "$schemaRef": { + "type" : "string" }, - "stationName": { - "type" : "string", - "minLength" : 1 - }, - "timestamp": { - "type" : "string", - "format" : "date-time" - }, - "ships": { - "type" : "array", - "items" : { - "oneOf": [ - { - "type" : "object", - "additionalProperties" : false, - "required" : [ "name" ], - "properties" : { - "name": { - "$ref": "#/definitions/shipsName" - }, - "fdId": { - "type" : "number", - "multipleOf" : 1.0, - "minimum": 1 - } + "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", "ships" ], + "properties" : { + "systemName": { + "type" : "string", + "minLength" : 1 + }, + "stationName": { + "type" : "string", + "minLength" : 1 + }, + "timestamp": { + "type" : "string", + "format" : "date-time" + }, + "ships": { + "type" : "array", + "items" : { + "oneOf" : [ + { + "type" : "object", + "additionalProperties" : false, + "required" : [ "name" ], + "properties" : { + "name":{ + "type" : "string", + "minLength" : 1, + "description" : "Must be one of: Sidewinder (128049249), Eagle (128049255), Hauler (128049261), Adder (128049267), Viper (128049273), Cobra Mk III (128049279), Type-6 Transporter (128049285), Type-7 Transporter (128049297), Asp (128049303), Vulture (128049309), Imperial Clipper (128049315), Federal Dropship (128049321), Orca (128049327), Type-9 Heavy (128049333), Python (128049339), Fer-de-Lance (128049351), Anaconda (128049363), DiamondBack Scout (128671217), Imperial Courier (128671223), Diamondback Explorer (128671831)" + }, + "fdId":{ + "type" : "number", + "multipleOf" : 1.0, + "minimum" : 1, + "description" : "For OCR free tools, this correspond to the frontier ID. See name description." + } + } + } + ] + } + } + } } - } } - }, - - "definitions" : { - "shipsName" : { - "enum": [ - "SideWinder", - "Eagle", - "Hauler", - "Adder", - "Viper", - "Cobra Mk III", - "Type-6 Transporter", - "Type-7 Transporter", - "Asp", - "Vulture", - "Orca", - "Type-9 Heavy", - "Python", - "Fer-de-Lance", - "Anaconda", - "DiamondBack Scout", - "Diamondback Explorer", - ] - } - } } \ No newline at end of file