From 63401cfab52d02d9641e5920cd56443916003f04 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 12 Feb 2016 11:05:50 +0100 Subject: [PATCH 01/55] Add the raml and json-schema files from the oic core spec. --- oic.collection.json | 141 +++++++++++++++ oic.core.json | 37 ++++ oic.oic-link.json | 68 ++++++++ oic.rd.publish.json | 26 +++ oic.rd.selection.json | 70 ++++++++ oic.rule-Update.json | 56 ++++++ oic.rule.json | 56 ++++++ oic.ruleMember.json | 47 +++++ oic.sceneCollection-Update.json | 54 ++++++ oic.sceneCollection.json | 54 ++++++ oic.sceneMember.json | 59 +++++++ oic.wk.con.json | 39 +++++ oic.wk.con.raml | 66 +++++++ oic.wk.d.json | 35 ++++ oic.wk.d.raml | 41 +++++ oic.wk.ifs.json | 22 +++ oic.wk.ifs.raml | 37 ++++ oic.wk.mnt.json | 28 +++ oic.wk.mnt.raml | 81 +++++++++ oic.wk.mon.json | 31 ++++ oic.wk.mon.raml | 40 +++++ oic.wk.p.json | 67 +++++++ oic.wk.p.raml | 41 +++++ oic.wk.ping.json | 28 +++ oic.wk.ping.raml | 38 ++++ oic.wk.res.json | 37 ++++ oic.wk.res.raml | 53 ++++++ oic.wk.rts.json | 22 +++ oic.wk.rts.raml | 38 ++++ rdpublish.raml | 158 +++++++++++++++++ rules.raml | 255 +++++++++++++++++++++++++++ scene.raml | 297 ++++++++++++++++++++++++++++++++ 32 files changed, 2122 insertions(+) create mode 100755 oic.collection.json create mode 100755 oic.core.json create mode 100755 oic.oic-link.json create mode 100755 oic.rd.publish.json create mode 100755 oic.rd.selection.json create mode 100755 oic.rule-Update.json create mode 100755 oic.rule.json create mode 100755 oic.ruleMember.json create mode 100755 oic.sceneCollection-Update.json create mode 100755 oic.sceneCollection.json create mode 100755 oic.sceneMember.json create mode 100755 oic.wk.con.json create mode 100755 oic.wk.con.raml create mode 100755 oic.wk.d.json create mode 100755 oic.wk.d.raml create mode 100755 oic.wk.ifs.json create mode 100755 oic.wk.ifs.raml create mode 100755 oic.wk.mnt.json create mode 100755 oic.wk.mnt.raml create mode 100755 oic.wk.mon.json create mode 100755 oic.wk.mon.raml create mode 100755 oic.wk.p.json create mode 100755 oic.wk.p.raml create mode 100755 oic.wk.ping.json create mode 100755 oic.wk.ping.raml create mode 100755 oic.wk.res.json create mode 100755 oic.wk.res.raml create mode 100755 oic.wk.rts.json create mode 100755 oic.wk.rts.raml create mode 100755 rdpublish.raml create mode 100755 rules.raml create mode 100755 scene.raml diff --git a/oic.collection.json b/oic.collection.json new file mode 100755 index 0000000..a82700b --- /dev/null +++ b/oic.collection.json @@ -0,0 +1,141 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.collection.json#", + "title": "Collection", + "definitions": { + "oic.collection.setoflinks": { + "type": "object", + "description": "A set (array) of simple or individual OIC Links", + "properties": { + "links": { + "type": "array", + "description": "Array of OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", + "items": { + "allOf": [ + { + "$ref": "oic.oic-link.json#" + } + ], + "required": ["ins"] + } + } + } + }, + "oic.collection.tagged-setoflinks": { + "type": "object", + "description": "A tagged link is a set (array) of links that are tagged with one or more key-value pairs usually either an ID or Name or both", + "allOf": [ + { + "$ref": "#/definitions/oic.collection.setoflinks" + }, + { + "properties": { + "n": { + "type": "string", + "description": "Used to name i.e. tag the set of links", + "format": "UTF8" + }, + "id": { + "oneOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "type": "string", + "format": "UUID", + "description": "A unique string that could be a UUIDv4" + } + ], + "description": "Id for each set of links i.e. tag. Can be an value that is unique to the use context or a UUIDv4" + }, + "di": { + "type": "string", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res", + "format": "UUID" + } + } + } + ], + "required": [ "links" ] + }, + "oic.collection.setof-tagged-setoflinks": { + "type": "array", + "items": { + "$ref": "#/definitions/oic.collection.tagged-setoflinks" + } + }, + "oic.collection.alllinks": { + "description": "All forms of links in a collection", + "oneOf": [ + { + "$ref": "#/definitions/oic.collection.setof-tagged-setoflinks" + }, + { + "$ref": "#/definitions/oic.collection.setoflinks" + } + ], + "required": [ "links" ] + }, + "oic.collection": { + "type": "object", + "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", + "allOf": [ + { + "$ref": "#/definitions/oic.collection.alllinks" + }, + { + "properties": { + "n": { + "type": "string", + "description": "User friendly name of the collection", + "format": "UTF8" + }, + "id": { + "oneOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "type": "string", + "format": "UUID", + "description": "A unique string that could be a UUIDv4" + } + ], + "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" + }, + "rts": { + "type": "string", + "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list", + "format": "UTF8" + }, + "drel": { + "type": "string", + "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" + } + } + } + ] + } + }, + + "type": "object", + "allOf": [ + { + "$ref": "oic.core.json#/definitions/oic.core" + }, + { + "$ref": "#/definitions/oic.collection" + } + ] +} diff --git a/oic.core.json b/oic.core.json new file mode 100755 index 0000000..96d471a --- /dev/null +++ b/oic.core.json @@ -0,0 +1,37 @@ +{ + "id": "http://openinterconnect.org/schemas/oic.core#", + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "title": "Core", + "$ref": "#/definitions/oic.core", + "definitions": { + "oic.core": { + "type": "object", + "properties": { + "rt": { + "type": "string", + "description": "ReadOnly, Resource Type" + }, + "if": { + "type": "array", + "items": [ + { + "type" : "string", + "enum" : ["oic.if.def", "oic.if.ll", "oic.if.b", "oic.if.rp", "oic.if.p", "oic.if.a", "oic.if.s" ] + } + ], + "minItems": 1, + "description": "ReadOnly, The interface set supported by this resource" + }, + "p": { + "type": "string", + "description": "ReadOnly, bitmap indicating observable and discoverable" + }, + "n": { + "type": "string", + "description": "Friendly name of the resource" + } + } + } + } +} diff --git a/oic.oic-link.json b/oic.oic-link.json new file mode 100755 index 0000000..ed209d8 --- /dev/null +++ b/oic.oic-link.json @@ -0,0 +1,68 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/rm/oic.oic-link.json", + "type": "object", + "properties": { + "href": { + "type": "string", + "description": "RFC5988 style web-links serialized into JSON. This is the target URI", + "format": "uri" + }, + "rel": { + "type": "string", + "default": "advertises", + "description": "The relation of the target URI referenced by the link to the context URI" + }, + "rt": { + "type": "string", + "description": "Resource Type - A standard OIC specified or vendor defined resource type of the resource referenced by the target URI" + }, + "if": { + "type": "string", + "description": "Interface - The interfaces supported by the resource referenced by the target URI" + }, + "obs": { + "type": "boolean", + "description": "Specifies if the resource referenced by the target URIis observable or not", + "default": false + }, + "title": { + "type": "string", + "description": "A title for the link relation. Can be used by the UI to provide a context" + }, + "anchor": { + "type": "string", + "description": "This is used to override the context URI e.g. override the URI of the containing collection", + "format": "uri" + }, + "ins": { + "oneOf": [ + { + "type": "integer", + "description": "An ordinal number that is not repeated - must be unique in the collection context" + }, + { + "type": "string", + "description": "Any unique string including a URI" + }, + { + "type": "string", + "format": "uuid", + "description": "Use UUID for universal uniqueness - used in /oic/res to identify the device" + } + ], + "description": "The instance identifier for this web link in an array of web links - used in collections" + }, + "ttl": { + "type": "integer", + "description": "The time to live for this link in seconds - value is specified in a request only and is not returned on response. Max integer size to represent time is 4 octets" + }, + "type": { + "type": "string", + "description": "A hint at the representation of the resource referenced by the target URI", + "default": "application/json" + } + }, + "required": [ "href", "rt", "if" ] +} \ No newline at end of file diff --git a/oic.rd.publish.json b/oic.rd.publish.json new file mode 100755 index 0000000..a2fd3e6 --- /dev/null +++ b/oic.rd.publish.json @@ -0,0 +1,26 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.rd.publish.json#", + "title": "RD Publish & Update", + "definitions": { + "oic.rd.publish": { + "description": "Publishes resources as OIC Links into the resource directory", + "properties": { + "linkSet": { + "$ref": "oic.collection.json#/definitions/oic.collection.setof-tagged-setoflinks" + }, + "ttl": { + "type": "integer", + "description": "Time to indicate a RD, how long to keep this published item. After this time (in seconds) elapses, the RD invalidates the links. To keep link alive the publishing device updates the ttl using the update schema" + } + } + } + }, + "type": "object", + "allOf": [{ "$ref": "#/definitions/oic.rd.publish" }], + "required": [ "links" ], + "dependencies": { + "links": [ "ttl" ] + } +} diff --git a/oic.rd.selection.json b/oic.rd.selection.json new file mode 100755 index 0000000..2d89c50 --- /dev/null +++ b/oic.rd.selection.json @@ -0,0 +1,70 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.rd.selection.json#", + "title" : "RD Selection", + "definitions": { + "oic.rd.attributes": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "A human friendly name for the Resource Directory", + "format": "UTF8" + }, + "di": { + "type": "string", + "description": "A unique identifier for the Resource Directory - the same as the device ID of the RD", + "format": "uuid" + }, + "sel": { + "description": "Selection criteria that a device wanting to publish to any RD can use to choose this Resource Directory over others that are discovered", + "oneOf": [ + { + "type": "object", + "properties": { + "pwr": { + "type": "string", + "enum": [ "ac", "batt", "safe" ], + "description": "A hint about how the RD is powered. If AC then this is stronger than battery powered. If source is reliable (safe) then appropriate mechanism for managing power failure exists" + }, + "conn": { + "type": "string", + "enum": [ "wrd", "wrls" ], + "description": "A hint about the networking connectivity of the RD. *wrd* if wired connected and *wrls* if wireless connected." + }, + "bw": { + "type": "string", + "description": "Qualitative bandwidth of the connection", + "enum": [ "high", "low", "lossy" ] + }, + "mf": { + "type": "integer", + "description": "Memory factor - Ratio of available memory to total memory expressed as a percentage" + }, + "load": { + "type": "array", + "items": { + "type": "number" + }, + "minitems": 3, + "maxitems": 3, + "description": "Current load capacity of the RD. Expressed as a load factor 3-tuple (upto two decimal points each). Load factor is based on request processed in a 1 minute, 5 minute window and 15 minute window" + } + } + }, + { + "type": "integer", + "minimum": 0, + "maximum": 100, + "description": "A bias factor calculated by the Resource directory - the value is in the range of 0 to 100 - 0 implies that RD is not to be selected. Client chooses RD with highest bias factor or randomly between RDs that have same bias factor" + } + ] + } + } + } + }, + "type": "object", + "allOf": [ {"$ref": "#/definitions/oic.rd.attributes"}], + "required": ["sel"] +} diff --git a/oic.rule-Update.json b/oic.rule-Update.json new file mode 100755 index 0000000..65b0ca4 --- /dev/null +++ b/oic.rule-Update.json @@ -0,0 +1,56 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.rule.json#", + "title" : "Rule", + "definitions": { + "oic.rule": { + "type": "object", + "properties": { + "condition": { + "type": "string", + "description": "condition of the rule", + "format": "UTF8" + }, + "currentStatus": { + "type": "string", + "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" + }, + "n": { + "type": "string", + "description": "Used to name the Rule collection", + "format": "UTF8" + }, + "test": { + "type": "boolean", + "description": "Inidcates initiation of test mode for the rule" + }, + "id": { + "type": "string", + "description": "Can be an value that is unique to the use context or a UUIDv4" + }, + "rts": { + "type": "string", + "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" + }, + "links": { + "type": "array", + "description": "Array of OIC web links that are the rule members, this is the script", + "items" : { + "allOf": [ + { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "required" : [ "ins" ] } + ] + } + } + }, + "required": [ "currentStatus" ] + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.rule" } + ] +} diff --git a/oic.rule.json b/oic.rule.json new file mode 100755 index 0000000..cd893c2 --- /dev/null +++ b/oic.rule.json @@ -0,0 +1,56 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.rule.json#", + "title" : "Rule", + "definitions": { + "oic.rule": { + "type": "object", + "properties": { + "condition": { + "type": "string", + "description": "condition of the rule", + "format": "UTF8" + }, + "currentStatus": { + "type": "string", + "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" + }, + "n": { + "type": "string", + "description": "Used to name the Rule collection", + "format": "UTF8" + }, + "test": { + "type": "boolean", + "description": "Inidcates initiation of test mode for the rule" + }, + "id": { + "type": "string", + "description": "Can be an value that is unique to the use context or a UUIDv4" + }, + "rts": { + "type": "string", + "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" + }, + "links": { + "type": "array", + "description": "Array of OIC web links that are the rule members, this is the script", + "items" : { + "allOf": [ + { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "required" : [ "ins" ] } + ] + } + } + }, + "required": [ "links", "condition", "currentStatus", "test", "id", "rts" ] + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.rule" } + ] +} diff --git a/oic.ruleMember.json b/oic.ruleMember.json new file mode 100755 index 0000000..cde3b79 --- /dev/null +++ b/oic.ruleMember.json @@ -0,0 +1,47 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.ruleMember.json#", + "title" : "Rule Member", + "definitions": { + "oic.ruleMember": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "Used to name the Rule member", + "format": "UTF8" + }, + "id": { + "type": "string", + "description": "Can be an value that is unique to the use context or a UUIDv4" + }, + "memberProperty": { + "type": "string", + "description": "ReadOnly, property name that will be mapped" + }, + "memberValue": { + "oneOf" : [ + { "type": "number", "description": "if member property is an number" }, + { "type": "string", "description": "if member property is an number" }, + { "type": "boolean", "description": "if member property is an boolean" } + ], + "description": "ReadOnly, value of the Member Property" + }, + "link": { + "type": "string", + "description": "web link that points at a resource", + "$ref": "oic.oic-link.json#" + } + }, + "required": [ "id", "link", "memberProperty", "memberValue" ], + "additionalProperties": false + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.ruleMember" } + ] +} diff --git a/oic.sceneCollection-Update.json b/oic.sceneCollection-Update.json new file mode 100755 index 0000000..3583a5b --- /dev/null +++ b/oic.sceneCollection-Update.json @@ -0,0 +1,54 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", + "title" : "Scene Collection", + "definitions": { + "oic.sceneCollection": { + "type": "object", + "properties": { + "lastScene": { + "type": "string", + "description": "Last selected Scene, shall be part of sceneValues", + "format": "UTF8" + }, + "sceneValues": { + "type": "string", + "description": "ReadOnly, All available scene values", + "format": "CSV" + }, + "n": { + "type": "string", + "description": "Used to name the Scene collection", + "format": "UTF8" + }, + "id": { + "type": "string", + "description" : "A unique string that could be a hash or similarly unique" + }, + "rts": { + "type": "string", + "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", + "format": "UTF8" + }, + "links": { + "type": "array", + "description": "Array of OIC web links that are reference from this collection", + "items" : { + "allOf": [ + { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "required" : [ "ins" ] } + ] + } + } + }, + "required": [ "lastScene" ] + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.sceneCollection" } + ] +} diff --git a/oic.sceneCollection.json b/oic.sceneCollection.json new file mode 100755 index 0000000..d935aed --- /dev/null +++ b/oic.sceneCollection.json @@ -0,0 +1,54 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", + "title" : "Scene Collection", + "definitions": { + "oic.sceneCollection": { + "type": "object", + "properties": { + "lastScene": { + "type": "string", + "description": "Last selected Scene, shall be part of sceneValues", + "format": "UTF8" + }, + "sceneValues": { + "type": "string", + "description": "ReadOnly, All available scene values", + "format": "CSV" + }, + "n": { + "type": "string", + "description": "Used to name the Scene collection", + "format": "UTF8" + }, + "id": { + "type": "string", + "description" : "A unique string that could be a hash or similarly unique" + }, + "rts": { + "type": "string", + "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", + "format": "UTF8" + }, + "links": { + "type": "array", + "description": "Array of OIC web links that are reference from this collection", + "items" : { + "allOf": [ + { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "required" : [ "ins" ] } + ] + } + } + }, + "required": [ "lastScene","sceneValues","rts","id" ] + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.sceneCollection" } + ] +} diff --git a/oic.sceneMember.json b/oic.sceneMember.json new file mode 100755 index 0000000..729c00d --- /dev/null +++ b/oic.sceneMember.json @@ -0,0 +1,59 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.sceneMember.json#", + "title" : "Scene Member", + "definitions": { + "oic.sceneMember": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "Used to name the Scene collection", + "format": "UTF8" + }, + "id": { + "type": "string", + "description": "Can be an value that is unique to the use context or a UUIDv4" + }, + "SceneMappings" : { + "type": "array", + "description": "array of mappings per scene, can be 1", + "items": [ + { + "type": "object", + "properties": { + "scene": { + "type": "string", + "description": "Specifies a scene value that will acted upon" + }, + "memberProperty": { + "type": "string", + "description": "ReadOnly, property name that will be mapped" + }, + "memberValue": { + "type": "string", + "description": "ReadOnly, value of the Member Property" + } + }, + "required": [ "scene", "memberProperty", "memberValue" ] + } + ] + }, + + "link": { + "type": "string", + "description": "web link that points at an resource", + "$ref": "oic.oic-link.json#" + } + }, + "required": [ "link" ] + } + }, + + "type": "object", + "allOf" : [ + { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "#/definitions/oic.sceneMember" } + ] +} diff --git a/oic.wk.con.json b/oic.wk.con.json new file mode 100755 index 0000000..8003094 --- /dev/null +++ b/oic.wk.con.json @@ -0,0 +1,39 @@ +{ + "id": "http://openinterconnect.org/oic.wk.con#", + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "definitions": { + "oic.wk.con": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "Human friendly name" + }, + "loc": { + "type": "string", + "description": "Location information", + "format": "json" + }, + "locn": { + "type": "string", + "description": "Human Friendly Name" + }, + "c": { + "type": "string", + "description": "Currency" + }, + "r": { + "type": "string", + "description": "Region" + } + } + } + }, + "type": "object", + "allOf": [ + {"$ref": "oic.core.json#/definitions/oic.core"}, + { "$ref": "#/definitions/oic.wk.con" } + ], + "required": [ "n" ] +} diff --git a/oic.wk.con.raml b/oic.wk.con.raml new file mode 100755 index 0000000..cabbcfb --- /dev/null +++ b/oic.wk.con.raml @@ -0,0 +1,66 @@ +#%RAML 0.8 +title: OIC Configuration +version: v1-20150807 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Configuration: !include oic.wk.con.json + + +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.rw"] + +/oic/con: + displayName: OIC Configuration + is: [ interface ] + description: | + Known resource that is hosted by every OIC Server. + Allows for device specific information to be configured. + + get: + description: | + Retrieves the current configuration settings + responses: + 200: + body: + application/json: + schema: Configuration + example: | + { + "rt": "oic.wk.con", + "n": "My Friendly Device Name", + "loc": "My Location Information", + "locn": "My Location Name", + "c": "USD", + "r": "MyRegion" + } + + post: + description: | + Update the information about the OIC device + body: + application/json: + schema: Configuration + example: | + { + "n": "My Friendly Device Name" + } + responses: + 200: + body: + application/json: + schema: Configuration + example: | + { + "n": "My Friendly Device Name" + } diff --git a/oic.wk.d.json b/oic.wk.d.json new file mode 100755 index 0000000..8acfb97 --- /dev/null +++ b/oic.wk.d.json @@ -0,0 +1,35 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.d#", + "definitions": { + "oic.wk.d": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "Readonly, Human friendly name" + }, + "di": { + "type": "string", + "description": "ReadOnly, Unique identifier for device (UUID)", + "format": "uuid" + }, + "icv": { + "type": "string", + "description": "ReadOnly, The version of the OIC Server" + }, + "dmv": { + "type": "string", + "description": "ReadOnly, The spec version of the vertical specification", + "format": "csv" + } + } + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.wk.d" } + ], + "required": [ "n", "di", "icv" ] +} diff --git a/oic.wk.d.raml b/oic.wk.d.raml new file mode 100755 index 0000000..9d362fb --- /dev/null +++ b/oic.wk.d.raml @@ -0,0 +1,41 @@ +#%RAML 0.8 +title: OIC Root Device +version: v1-20150811 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Device: !include oic.wk.d.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/d: + displayName: OIC Logical Device + is: [ interface ] + description: | + Known resource that is hosted by every OIC Server. + Allows for logical device specific information to be discovered. + get: + description: | + Retrieve the information about the OIC device + responses: + 200: + body: + application/json: + schema: Device + example: | + { + "n": "Device 1", + "rt": "oic.wk.d", + "di": "54919CA5-4101-4AE4-595B-353C51AA983C", + "icv": "OIC 1.0" + } diff --git a/oic.wk.ifs.json b/oic.wk.ifs.json new file mode 100755 index 0000000..4803679 --- /dev/null +++ b/oic.wk.ifs.json @@ -0,0 +1,22 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.ifs#", + "definitions": { + "oic.wk.ifs": { + "type": "object", + "properties": { + "il": { + "type": "string", + "description": "Readonly, list of interface names", + "format": "bsv" + } + } + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.wk.ifs" } + ], + "required": ["il"] +} diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml new file mode 100755 index 0000000..8080af3 --- /dev/null +++ b/oic.wk.ifs.raml @@ -0,0 +1,37 @@ +#%RAML 0.8 +title: OIC Interface Types +version: v1-20150811 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - IFS: !include oic.wk.ifs.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/ifs: + displayName: OIC Inteface Types + is: [ interface ] + description: | + List of resource interfaces that are supported by this OIC Server + get: + description: Retrieve the resource interface list + responses: + 200: + body: + application/json: + schema: IFS + example: | + { + "rt": "oic.wk.ifs", + "il": "oic.if.ll oic.if.bat oic.if.r" + } diff --git a/oic.wk.mnt.json b/oic.wk.mnt.json new file mode 100755 index 0000000..ba7ecef --- /dev/null +++ b/oic.wk.mnt.json @@ -0,0 +1,28 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.mnt#", + "definitions": { + "oic.wk.mnt": { + "type": "object", + "fr":{ + "type": "boolean", + "description": "Factory Reset" + }, + "rb": { + "type": "boolean", + "description": "Reboot Action" + }, + "ssc": { + "type": "boolean", + "description": "Start Stat Collection Action Toggle" + } + } + }, + "type": "object", + "allOf": [ + {"$ref": "http://openinterconnect.org/oic.core.json#/definitions/oic.core"}, + {"$ref": "#/definitions/oic.wk.mnt" } + ], + "required": ["fr", "rb", "ssc"] +} diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml new file mode 100755 index 0000000..0f8259e --- /dev/null +++ b/oic.wk.mnt.raml @@ -0,0 +1,81 @@ +#%RAML 0.8 +title: OIC Maintenance +version: v1-20150811 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - MNT: !include oic.wk.mnt.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/mnt: + displayName: OIC Maintenance + is: [ interface ] + description: | + The resource through which an OIC Device is maintained and can be used for diagnostic purposes. + fr (Factory Reset) is a boolean. + The value 0 means No action (Default), the value 1 means Start Factory Reset + After factory reset, this value shall be changed back to the default value + rb (Reboot) is a boolean. + The value 0 means No action (Default), the value 1 means Start Reboot + After Reboot, this value shall be changed back to the default value + ssc (Start Stat Collection) is a boolean. + The value 0 means No collection of statistics, the value 1 means Starts collecting statistics + + get: + description: Retrieve the maintenance action status + queryParameters: + if: + enum: ["oic.if.r"] + responses: + 200: + body: + application/json: + schema: MNT + example: | + { + "rt": "oic.wk.mnt", + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": false + } + + post: + description: | + Set the maintenance action(s) + queryParameters: + if: + enum: ["oic.if.rw"] + body: + application/json: + schema: MNT + example: | + { + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": true + } + responses: + 200: + body: + application/json: + schema: MNT + example: | + { + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": true + } diff --git a/oic.wk.mon.json b/oic.wk.mon.json new file mode 100755 index 0000000..884dc96 --- /dev/null +++ b/oic.wk.mon.json @@ -0,0 +1,31 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.mon#", + "definitions": { + "oic.wk.mon": { + "type": "object", + "properties": { + "av":{ + "type": "boolean", + "description": "ReadOnly, Indicates if the device is available or not on the network (like ping)" + }, + "lat": { + "type": "integer", + "description": "ReadOnly, Indicates the elapsed time in seconds after the device was invoked or acted upon" + }, + "ds": { + "type": "string", + "description": "ReadOnly, Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)", + "format": "csv" + } + } + } + }, + "type": "object", + "allOf": [ + {"$ref": "oic.core.json#/definitions/oic.core"}, + {"$ref": "#/definitions/oic.wk.mon"} + ], + "required": ["av", "lat"] +} diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml new file mode 100755 index 0000000..f1e4ed9 --- /dev/null +++ b/oic.wk.mon.raml @@ -0,0 +1,40 @@ +#%RAML 0.8 +title: OIC Monitoring +version: v1-20150401 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - MON: !include oic.wk.mon.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/mon: + displayName: OIC Monitoring + is: [ interface ] + description: | + The resource through which an OIC Device is monitored. + get: + description: Retrieve the monitor information + responses: + 200: + body: + application/json: + schema: MON + example: | + { + "rt": "oic.wk.mon", + "name": "My Monitor Information", + "av": true, + "lat": 50, + "ds": "1500, 2750, 0" + } diff --git a/oic.wk.p.json b/oic.wk.p.json new file mode 100755 index 0000000..29ce04c --- /dev/null +++ b/oic.wk.p.json @@ -0,0 +1,67 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.p#", + "definitions": { + "oic.wk.p": { + "type": "object", + "properties": { + "pi": { + "type": "string", + "description": "ReadOnly, Platform Identifier" + }, + "mnmn": { + "type": "string", + "description": "ReadOnly, Manufacturer Name", + "maxLength": 16 + }, + "mnml": { + "type": "string", + "description": "ReadOnly, Manufacturer's URL", + "maxLength": 32, + "format": "uri" + }, + "mnmo": { + "type": "string", + "description": "ReadOnly, Model number as designated by manufacturer" + }, + "mndt": { + "type": "string", + "description": "ReadOnly, Manufacturing Date", + "format": "date-time" + }, + "mnpv": { + "type": "string", + "description": "ReadOnly, Platform Version" + }, + "mnos": { + "type": "string", + "description": "Readonly, Platform Resident OS Version" + }, + "mnhw": { + "type": "string", + "description": "Readonly, Platform Hardware Version" + }, + "mnfv": { + "type": "string", + "description": "ReadOnly, Manufacturer's firmware version" + }, + "mnsl": { + "type": "string", + "description": "ReadOnly, Manufacturer's Support Information URL", + "format": "uri" + }, + "st": { + "type": "string", + "description": "ReadOnly, Reference time for the device", + "format": "date-time" + } + } + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.wk.p" } + ], + "required": [ "pi", "mnmn" ] +} diff --git a/oic.wk.p.raml b/oic.wk.p.raml new file mode 100755 index 0000000..5b51bea --- /dev/null +++ b/oic.wk.p.raml @@ -0,0 +1,41 @@ +#%RAML 0.8 +title: OIC Base Platform +version: v1-20150804 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Platform: !include oic.wk.p.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/p: + displayName: OIC Base Platform + is: [ interface ] + description: | + Known resource that is defines the platform on which an OIC Server is hosted. + Allows for platform specific information to be discovered. + get: + description: | + Retrieve the information about the OIC Platform + + responses: + 200: + body: + application/json: + schema: Platform + example: | + { + "pi": "my-platform-identfier", + "rt": "oic.wk.p", + "mnmn": "Acme, Inc" + } diff --git a/oic.wk.ping.json b/oic.wk.ping.json new file mode 100755 index 0000000..ffadd1c --- /dev/null +++ b/oic.wk.ping.json @@ -0,0 +1,28 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.ping#", + "definitions": { + "oic.wk.ping": { + "type": "object", + "properties": { + "in": { + "type": "integer", + "description": "ReadWrite, Indicates the interval for which connection shall be kept alive" + } + } + } + }, + "type": "object", + "allOf": [ + { + "$ref": "oic.core.json#/definitions/oic.core" + }, + { + "$ref": "#/definitions/oic.wk.ping" + } + ], + "required": [ + "in" + ] +} diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml new file mode 100755 index 0000000..385cc46 --- /dev/null +++ b/oic.wk.ping.raml @@ -0,0 +1,38 @@ +#%RAML 0.8 +title: OIC Ping +version: v1-20150814 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - PING: !include oic.wk.ping.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.rw"] + +/oic/ping: + displayName: OIC Ping + is: [ interface ] + description: | + The resource using which an OIC Client keeps its Connection with an OIC Server active. + get: + description: Retrieve the ping information + responses: + 200: + body: + application/json: + schema: PING + example: | + { + "rt": "oic.wk.ping", + "name": "Ping Information", + "in": 16 + } diff --git a/oic.wk.res.json b/oic.wk.res.json new file mode 100755 index 0000000..aae0eb9 --- /dev/null +++ b/oic.wk.res.json @@ -0,0 +1,37 @@ +{ + "$schema": "http://json-schema.org/draft-v4/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/schemas/oic.wk.res.json/", + "definitions": { + "oic.res-links.json": { + "type": "object", + "properties": { + "n": { + "type": "string", + "description": "ReadOnly, Human friendly name" + }, + "di": { + "description": "The device identifier as indicated by the /oic/d resource of the device", + "type": "string", + "format": "UUID" + }, + "mpro": { + "description": "ReadOnly, Supported messaging protocols", + "type": "string" + }, + "links": { + "type": "array", + "items": { + "$ref": "oic.oic-link.json#" + } + } + } + } + }, + "description": "The list of resources expressed as OIC links", + "type": "array", + "items": { + "$ref": "#/definitions/oic.res-links.json" + }, + "required": ["di", "links"] +} diff --git a/oic.wk.res.raml b/oic.wk.res.raml new file mode 100755 index 0000000..0fe8554 --- /dev/null +++ b/oic.wk.res.raml @@ -0,0 +1,53 @@ +#%RAML 0.8 +title: OIC Discoverable Resources +version: v1-20150807 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Resources: !include oic.wk.res.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.ll"] + +/oic/res: + displayName: OIC Discoverable Resources + is: [ interface ] + description: | + The resource through which the corresponding OIC Server is discovered and introspected for available resources. + get: + description: | + Retrieve the discoverable resource set + + responses: + 200: + body: + application/json: + schema: Resources + example: | + [{ + "rt": "oic.wk.res", + "di": "0685B960-736F-46F7-BEC0-9E6CBD61ADC1", + "links": + [ + { + "href": "/res", + "rel": "self", + "rt": "oic.r.collection", + "if": "oic.if.ll" }, + { + "href": "/smartDevice", + "rel": "contained", + "rt": "oic.d.smartDevice", + "if": "oic.if.a" + } + ] + }] diff --git a/oic.wk.rts.json b/oic.wk.rts.json new file mode 100755 index 0000000..6ae81c0 --- /dev/null +++ b/oic.wk.rts.json @@ -0,0 +1,22 @@ +{ + "$schema": "http://json-schemas.org/draft-04/schema#", + "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "id": "http://openinterconnect.org/oic.wk.rts#", + "definitions": { + "oic.wk.rts": { + "type": "object", + "properties": { + "tl": { + "type": "string", + "description": "Readonly, list of resource type names", + "format": "bsv" + } + } + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.wk.rts" } + ], + "required": ["tl"] +} \ No newline at end of file diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml new file mode 100755 index 0000000..77f1901 --- /dev/null +++ b/oic.wk.rts.raml @@ -0,0 +1,38 @@ +#%RAML 0.8 +title: OIC Resource Types +version: v1-20150811 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - RTS: !include oic.wk.rts.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + + +/oic/rts: + displayName: OIC Resource Types + is: [ interface ] + description: | + List of resource types that are supported by this OIC Server + get: + description: Retrieve the resource type list + responses: + 200: + body: + application/json: + schema: RTS + example: | + { + "rt": "oic.wk.rts", + "tl": "oic.r.example oic.r.other-example" + } diff --git a/rdpublish.raml b/rdpublish.raml new file mode 100755 index 0000000..758ad4e --- /dev/null +++ b/rdpublish.raml @@ -0,0 +1,158 @@ +#%RAML 0.8 +#RAML for OIC Resource Directory +title: Resource Directory +version: 1.0-090215 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +documentation: + - title: OIC Rsource Directory + content: | + A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. + - title: Introduction + content: | + For resource in other OIC Devices to be discovered using the Resource Directory, these other devices have to publish the resource links they would otherwise have advertised through /oic/res to the Resource Directory. Once the information has been published then the OIC Devices may stop responding to discovery queries and may also go to sleep. + + The Resource Directory will respond to all discovery queries with resources that it directly advertises and also the resource information that has been published to it. + - title: Resource Directory discovery + content: | + Before an OIC Device publishes its resource information, it must first discover available Resource Directories and then select one of those to publish the information to. + + This doscovery is done with a multicast query to /oic/rd. The information returned is either a bais factor or a list of attributes that help the discovering OIC Device to select one of the RDs. This RD will be used till the RD does not respond or another RD is selected. + - title: Resource Directory publish + content: | + Once the RD has been discovery and selected, the OIC Device can publish its resoure information. The resource information are published to the /oic/rd resource using the "publish" interface. The information that needs to tbe available in /oic/res is then populated by the Resource Directory. + + Periodically based on the TTL set by the publishing OIC Device, the information that is published has to be refreshed with a new TTL or the TTL can be updated if there is no change in the information. It is the responsibility of the publishing OIC Device to ensure that the information or TTL is updated before the previous TTL expires; failing this the RD will garbage collect all the information related to the publishing OIC Device. + - title: Resource discovery + content: | + The discovery of resources is done in the same manner as for any OIC Server. A query to /oic/res either over multicast or uincast is required. + +schemas: +- + # Each schema represents an OIC Resource Type. The baseline interface operates on the entire representation + rdPublish: !include oic.rd.publish.json + rdSelection: !include oic.rd.selection.json + # rdDelLink: !include oic.rd.del-link.json + +traits: +- rddefinterface: + queryParameters: + if: + description: | + Interface is optional since there is only one interface supported for the OIC Resource Type + Both for RD selectin and for publish + type: string + enum: [ "oic.if.baseline" ] + default: "oic.if.baseline" + required: false + example: | + GET /oic/rd?if=oic.wk.baseline + +/oic/rd: + displayName: Resource directory resource + description: | + Resource to be exposed by any OIC Device that can act as a Resource Directory + get: + description: | + Get the attributes of the Resource Directory for selection purposes. + queryParameters: + rt: + description: | + Only one OIC Resource Type is used for GET; OIC RT is optional + type: string + enum: [ "oic.wk.rd" ] + default: "oic.wk.rd" + required: false + example: | + GET /oic/rd?rt=oic.wk.rd + is: [ rddefinterface ] + responses: + 200: + description: | + Respond with the selector criteria - either the set of attributes or the bias factor + body: + application/json: + schema: rdSelection + example: | + { + "rt": "oic.wk.rd", + "sel": 50 + } + post: + description: | + Publish the resource information. Appropriates parts of the information posted will be discovered through /oic/res + body: + application/json: + schema: rdPublish + # Maybe the entire published information should be treated as a new resource - as if created using the link-batch interface. + queryParameters: + rt: + description: | + Only one OIC Resource Type is used for GET; OIC RT is optional + type: string + enum: [ "oic.wk.rdpub" ] + default: "oic.wk.rdpub" + required: false + example: | + GET /oic/rd?rt=oic.wk.rdpub + is: [ rddefinterface ] + responses: + 200: + description: | + Respond with the same schema as publish but with the links have the "ins" parameter set to the appropriate instance value. + This value is used by the receiver to manage that OIC Link instance. + body: + application/json: + schema: rdPublish + example: | + { + "links": [ + { + "href": "coap://someAuthority:1000/somePath", + "rt": "oic.r.someResource", + "if": "oic.if.a", + "ins": 12345 + }, + { + "href": "coap://someAuthority:1000/somePath", + "rt": "oic.r.someOtherResource", + "if": "oic.if.baseline", + "ins": 54321 + } + ], + "ttl": 600 + } + + delete: + description: | + Delete a particular OIC Link - the link may be a simple link or a link in a tagged set. + queryParameters: + di: + displayName: ID of the device making request + description: | + This is used to determine which set of links to operata on. (Need authentication to ensure that there is no spoofing). If instance is ommitted then the entire set of links from this device ID is deleted + type: string + required: true + example: | + DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" + ins: + displayName: Link instance for deletion + description: | + Instance of the link to delete + Value of parameter is a string where instance to be deleted are comma separated + type: string + required: false + example: | + DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1";ins="20" + responses: + 200: + description: The delete succeeded + +# The discovery through the /oic/res of the resource directory is the same as the standard resource discovery +# Need to include the RAML for /oic/res based resource discovery diff --git a/rules.raml b/rules.raml new file mode 100755 index 0000000..d0be9cb --- /dev/null +++ b/rules.raml @@ -0,0 +1,255 @@ +#%RAML 0.8 +title: OICRules +version: v1.0-20150810 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Collection: !include oic.collection.json + Rule: !include oic.rule.json + RuleUpdate: !include oic.rule-Update.json + RuleMember: !include oic.ruleMember.json + +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.a", "oic.if.ll"] + + +/RuleListResURI: + description: | + Toplevel Rule resource. + This resource is a generic collection resource + The rts value shall contain oic.wk.rule resource types + displayName: Rules (Top level) + + get: + description: | + Provides the current list of web links pointing to rules + responses: + 200: + body: + application/json: + schema: Collection + example: | + { + "rt": "oic.wk.ruleList", + "n": "list of rules", + "rts": "oic.wk.rule", + "links": [ + ] + } + + post: + description: | + Provides the action to create a new rule in the ruleList resource + The only resource type that is allowed to be created "oic.wk.rule". + The example contains a condition, currentStatus and test. + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value = true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "off", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "my_rule1", + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The created resource attributes are provided in the response, + including the server generated identifier. + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "off", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" , + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + + +/RuleResURI: + description: | + Collection that models a rule. + This resource is an generic collection resource with additional parameters. + The rts value shall contain oic.wk.ruleMember resource types. + The additional parameters are + condition, this is the rule that will be evaluated + currentStatus, the current state of the rule, can be "enabled, disabled, error" + test an trigger once activation of the rule + displayName: Rule + + get: + description: | + Provides the current rule and list of web links to the rule members + responses: + 200: + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "disabled", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + put: + description: | + Provides the action to enable/disable the rule and an test mode for the rule. + Calling this method with test = true will update of all ruleMembers to the prescribed membervalue. + + body: + application/json: + schema: RuleUpdate + example: | + { + "currentStatus": "enabled" + } + + responses: + 200: + description: | + Indicates that the value is changed. + The changed properties are provided in the response. + body: + application/json: + schema: RuleUpdate + example: | + { + "currentStatus": "enabled" + } + + + post: + description: | + Provides the action to create a new ruleMember in the rule resource + The only resource type that is allowed to be created is "oic.wk.ruleMember". + The id of the resource will be generated by the implementation. + + body: + application/json: + schema: RuleMember + example: | + { + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "id": "", + "n": "my binary switch (for light bulb) mappings", + "memberProperty": "value", + "memberValue": true + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The new resource attributes are provided in the response. + body: + application/json: + schema: RuleMember + example: | + { + "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "memberProperty": "value", + "memberValue": true + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + +/RuleMemberResURI: + description: | + Rule member resource. + This resource is assignment statement of an property in a resource indicated by an URI + displayName: Rule Member + + get: + description: | + Provides the rule mappings + responses: + 200: + body: + application/json: + schema: RuleMember + example: | + { + "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "memberProperty": "value", + "memberValue": true + } diff --git a/scene.raml b/scene.raml new file mode 100755 index 0000000..2688a70 --- /dev/null +++ b/scene.raml @@ -0,0 +1,297 @@ +#%RAML 0.8 +title: OICScene +version: v1.0-20150630 +documentation: + - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + content: | + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +schemas: + - Collection: !include oic.collection.json + SceneCollection: !include oic.sceneCollection.json + SceneCollectionUpdate: !include oic.sceneCollection-Update.json + SceneMember: !include oic.sceneMember.json + +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.a", "oic.if.ll"] + + +/SceneListResURI: + description: | + Toplevel Scene resource. + This resource is a generic collection resource. + The rts value shall contain oic.sceneCollection resource types. + displayName: Scenes (Top level) + + get: + description: | + Provides the current list of web links pointing to scenes + responses: + 200: + body: + application/json: + schema: Collection + example: | + { + "rt": "oic.wk.sceneList", + "n": "list of scene Collections", + "rts": "oic.wk.sceneCollection", + "links": [ + ] + } + + post: + description: | + Provides the action to create a new sceneCollection in the SceneList resource + The only resource type that is allowed to be created "oic.wk.sceneCollection". + The example contains 3 scene values off, Reading and TVWatching. + body: + application/json: + schema: SceneCollection + example: | + { + "scenevalue": "off", + "sceneValues": "off,Reading,TVWatching", + "lastScene": "off", + "rt": "oic.wk.sceneCollection", + "n": "my first scene", + "id": "my_scene1", + "rts": "oic.r.sceneMember" + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The created resource attributes are provided in the response, + including the server generated identifier. + body: + application/json: + schema: SceneCollection + example: | + { + "scenevalue": "off", + "sceneValues": "off,Reading,TVWatching", + "lastScene": "off", + "rt": "oic.r.sceneCollection", + "n": "mymembername", + "link": "coap://newscene", + "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.r.sceneMember" + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + + +/SceneCollectionResURI: + description: | + Collection that models a set of Scenes. + This resource is a generic collection resource with additional parameters. + The rts value shall contain oic.sceneMember resource types. + The additional parameters are + lastScene, this is the scene value last set by any OIC Client + sceneValueList, this is the list of available scenes + lastScene shall be listed in sceneValueList. + displayName: Scene Collections + + get: + description: | + Provides the current list of web links pointing to scenes + responses: + 200: + body: + application/json: + schema: SceneCollection + example: | + { + "lastScene": "off", + "sceneValues": "off,Reading,TVWatching", + "rt": "oic.wk.sceneCollection", + "n": "My Scenes for my living room", + "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.wk.sceneMember", + "links": [ + ] + } + + put: + description: | + Provides the action to change the last settted scene selection. + Calling this method shall update of all sceneMembers to the prescribed membervalue. + When this method is called with the same value as the current lastScene value + then all sceneMembers shall be updated. + + body: + application/json: + schema: SceneCollectionUpdate + example: | + { + "lastScene": "Reading" + } + + responses: + 200: + description: | + Indicates that the value is changed. + The changed properties are provided in the response. + body: + application/json: + schema: SceneCollectionUpdate + example: | + { + "lastScene": "Reading" + } + + + post: + description: | + Provides the action to create a new sceneMember in the SceneCollection resource + The only resource type that is allowed to be created is "oic.wk.sceneMember". + The id of the resource will be generated by the implementation. + As example the mappings of the 3 scenes are mapped to different states of an binary switch + + body: + application/json: + schema: SceneMember + example: | + { + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "n": "my binary switch (for light bulb) mappings", + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The new resource attributes are provided in the response. + body: + application/json: + schema: SceneMember + example: | + { + "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="0685B960-FFFF-46F7-BEC0-9E6234671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + +/SceneMemberResURI: + description: | + Collection that models a sceneMember. + displayName: Scene Member + + get: + description: | + Provides the scene member + responses: + 200: + body: + application/json: + schema: SceneMember + example: | + { + "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } From a34483c5a716e2798839a3ac71bc0939db1bda13 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 12 Feb 2016 17:29:10 +0100 Subject: [PATCH 02/55] dos2unix. --- oic.wk.d.raml | 66 +++--- oic.wk.ifs.raml | 58 ++--- oic.wk.mnt.raml | 146 ++++++------ oic.wk.mon.raml | 64 +++--- oic.wk.p.raml | 66 +++--- oic.wk.ping.raml | 60 ++--- oic.wk.rts.raml | 60 ++--- rules.raml | 494 ++++++++++++++++++++-------------------- scene.raml | 578 +++++++++++++++++++++++------------------------ 9 files changed, 796 insertions(+), 796 deletions(-) diff --git a/oic.wk.d.raml b/oic.wk.d.raml index 9d362fb..48446dc 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Root Device -version: v1-20150811 +#%RAML 0.8 +title: OIC Root Device +version: v1-20150811 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,33 +9,33 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - Device: !include oic.wk.d.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - -/oic/d: - displayName: OIC Logical Device - is: [ interface ] - description: | - Known resource that is hosted by every OIC Server. - Allows for logical device specific information to be discovered. - get: - description: | - Retrieve the information about the OIC device - responses: - 200: - body: - application/json: - schema: Device - example: | - { - "n": "Device 1", - "rt": "oic.wk.d", - "di": "54919CA5-4101-4AE4-595B-353C51AA983C", - "icv": "OIC 1.0" - } + +schemas: + - Device: !include oic.wk.d.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/d: + displayName: OIC Logical Device + is: [ interface ] + description: | + Known resource that is hosted by every OIC Server. + Allows for logical device specific information to be discovered. + get: + description: | + Retrieve the information about the OIC device + responses: + 200: + body: + application/json: + schema: Device + example: | + { + "n": "Device 1", + "rt": "oic.wk.d", + "di": "54919CA5-4101-4AE4-595B-353C51AA983C", + "icv": "OIC 1.0" + } diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index 8080af3..70d0a83 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Interface Types -version: v1-20150811 +#%RAML 0.8 +title: OIC Interface Types +version: v1-20150811 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,29 +9,29 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - IFS: !include oic.wk.ifs.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - -/oic/ifs: - displayName: OIC Inteface Types - is: [ interface ] - description: | - List of resource interfaces that are supported by this OIC Server - get: - description: Retrieve the resource interface list - responses: - 200: - body: - application/json: - schema: IFS - example: | - { - "rt": "oic.wk.ifs", - "il": "oic.if.ll oic.if.bat oic.if.r" - } + +schemas: + - IFS: !include oic.wk.ifs.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/ifs: + displayName: OIC Inteface Types + is: [ interface ] + description: | + List of resource interfaces that are supported by this OIC Server + get: + description: Retrieve the resource interface list + responses: + 200: + body: + application/json: + schema: IFS + example: | + { + "rt": "oic.wk.ifs", + "il": "oic.if.ll oic.if.bat oic.if.r" + } diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index 0f8259e..a5b1b52 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Maintenance -version: v1-20150811 +#%RAML 0.8 +title: OIC Maintenance +version: v1-20150811 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,73 +9,73 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - MNT: !include oic.wk.mnt.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - -/oic/mnt: - displayName: OIC Maintenance - is: [ interface ] - description: | - The resource through which an OIC Device is maintained and can be used for diagnostic purposes. - fr (Factory Reset) is a boolean. - The value 0 means No action (Default), the value 1 means Start Factory Reset - After factory reset, this value shall be changed back to the default value - rb (Reboot) is a boolean. - The value 0 means No action (Default), the value 1 means Start Reboot - After Reboot, this value shall be changed back to the default value - ssc (Start Stat Collection) is a boolean. - The value 0 means No collection of statistics, the value 1 means Starts collecting statistics - - get: - description: Retrieve the maintenance action status - queryParameters: - if: - enum: ["oic.if.r"] - responses: - 200: - body: - application/json: - schema: MNT - example: | - { - "rt": "oic.wk.mnt", - "n": "My Maintenance Actions", - "fr": false, - "rb": false, - "ssc": false - } - - post: - description: | - Set the maintenance action(s) - queryParameters: - if: - enum: ["oic.if.rw"] - body: - application/json: - schema: MNT - example: | - { - "n": "My Maintenance Actions", - "fr": false, - "rb": false, - "ssc": true - } - responses: - 200: - body: - application/json: - schema: MNT - example: | - { - "n": "My Maintenance Actions", - "fr": false, - "rb": false, - "ssc": true - } + +schemas: + - MNT: !include oic.wk.mnt.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/mnt: + displayName: OIC Maintenance + is: [ interface ] + description: | + The resource through which an OIC Device is maintained and can be used for diagnostic purposes. + fr (Factory Reset) is a boolean. + The value 0 means No action (Default), the value 1 means Start Factory Reset + After factory reset, this value shall be changed back to the default value + rb (Reboot) is a boolean. + The value 0 means No action (Default), the value 1 means Start Reboot + After Reboot, this value shall be changed back to the default value + ssc (Start Stat Collection) is a boolean. + The value 0 means No collection of statistics, the value 1 means Starts collecting statistics + + get: + description: Retrieve the maintenance action status + queryParameters: + if: + enum: ["oic.if.r"] + responses: + 200: + body: + application/json: + schema: MNT + example: | + { + "rt": "oic.wk.mnt", + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": false + } + + post: + description: | + Set the maintenance action(s) + queryParameters: + if: + enum: ["oic.if.rw"] + body: + application/json: + schema: MNT + example: | + { + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": true + } + responses: + 200: + body: + application/json: + schema: MNT + example: | + { + "n": "My Maintenance Actions", + "fr": false, + "rb": false, + "ssc": true + } diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index f1e4ed9..203be0d 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Monitoring -version: v1-20150401 +#%RAML 0.8 +title: OIC Monitoring +version: v1-20150401 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,32 +9,32 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - MON: !include oic.wk.mon.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - -/oic/mon: - displayName: OIC Monitoring - is: [ interface ] - description: | - The resource through which an OIC Device is monitored. - get: - description: Retrieve the monitor information - responses: - 200: - body: - application/json: - schema: MON - example: | - { - "rt": "oic.wk.mon", - "name": "My Monitor Information", - "av": true, - "lat": 50, - "ds": "1500, 2750, 0" - } + +schemas: + - MON: !include oic.wk.mon.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/mon: + displayName: OIC Monitoring + is: [ interface ] + description: | + The resource through which an OIC Device is monitored. + get: + description: Retrieve the monitor information + responses: + 200: + body: + application/json: + schema: MON + example: | + { + "rt": "oic.wk.mon", + "name": "My Monitor Information", + "av": true, + "lat": 50, + "ds": "1500, 2750, 0" + } diff --git a/oic.wk.p.raml b/oic.wk.p.raml index 5b51bea..f797575 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Base Platform -version: v1-20150804 +#%RAML 0.8 +title: OIC Base Platform +version: v1-20150804 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,33 +9,33 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - Platform: !include oic.wk.p.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - -/oic/p: - displayName: OIC Base Platform - is: [ interface ] - description: | - Known resource that is defines the platform on which an OIC Server is hosted. - Allows for platform specific information to be discovered. - get: - description: | - Retrieve the information about the OIC Platform - - responses: - 200: - body: - application/json: - schema: Platform - example: | - { - "pi": "my-platform-identfier", - "rt": "oic.wk.p", - "mnmn": "Acme, Inc" - } + +schemas: + - Platform: !include oic.wk.p.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + +/oic/p: + displayName: OIC Base Platform + is: [ interface ] + description: | + Known resource that is defines the platform on which an OIC Server is hosted. + Allows for platform specific information to be discovered. + get: + description: | + Retrieve the information about the OIC Platform + + responses: + 200: + body: + application/json: + schema: Platform + example: | + { + "pi": "my-platform-identfier", + "rt": "oic.wk.p", + "mnmn": "Acme, Inc" + } diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index 385cc46..f92dd35 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Ping -version: v1-20150814 +#%RAML 0.8 +title: OIC Ping +version: v1-20150814 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,30 +9,30 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - PING: !include oic.wk.ping.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.rw"] - -/oic/ping: - displayName: OIC Ping - is: [ interface ] - description: | - The resource using which an OIC Client keeps its Connection with an OIC Server active. - get: - description: Retrieve the ping information - responses: - 200: - body: - application/json: - schema: PING - example: | - { - "rt": "oic.wk.ping", - "name": "Ping Information", - "in": 16 - } + +schemas: + - PING: !include oic.wk.ping.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.rw"] + +/oic/ping: + displayName: OIC Ping + is: [ interface ] + description: | + The resource using which an OIC Client keeps its Connection with an OIC Server active. + get: + description: Retrieve the ping information + responses: + 200: + body: + application/json: + schema: PING + example: | + { + "rt": "oic.wk.ping", + "name": "Ping Information", + "in": 16 + } diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index 77f1901..d8a6259 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OIC Resource Types -version: v1-20150811 +#%RAML 0.8 +title: OIC Resource Types +version: v1-20150811 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,30 +9,30 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - RTS: !include oic.wk.rts.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r"] - - -/oic/rts: - displayName: OIC Resource Types - is: [ interface ] - description: | - List of resource types that are supported by this OIC Server - get: - description: Retrieve the resource type list - responses: - 200: - body: - application/json: - schema: RTS - example: | - { - "rt": "oic.wk.rts", - "tl": "oic.r.example oic.r.other-example" - } + +schemas: + - RTS: !include oic.wk.rts.json +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.r"] + + +/oic/rts: + displayName: OIC Resource Types + is: [ interface ] + description: | + List of resource types that are supported by this OIC Server + get: + description: Retrieve the resource type list + responses: + 200: + body: + application/json: + schema: RTS + example: | + { + "rt": "oic.wk.rts", + "tl": "oic.r.example oic.r.other-example" + } diff --git a/rules.raml b/rules.raml index d0be9cb..b5c29a0 100755 --- a/rules.raml +++ b/rules.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OICRules -version: v1.0-20150810 +#%RAML 0.8 +title: OICRules +version: v1.0-20150810 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,247 +9,247 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - Collection: !include oic.collection.json - Rule: !include oic.rule.json - RuleUpdate: !include oic.rule-Update.json - RuleMember: !include oic.ruleMember.json - -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.a", "oic.if.ll"] - - -/RuleListResURI: - description: | - Toplevel Rule resource. - This resource is a generic collection resource - The rts value shall contain oic.wk.rule resource types - displayName: Rules (Top level) - - get: - description: | - Provides the current list of web links pointing to rules - responses: - 200: - body: - application/json: - schema: Collection - example: | - { - "rt": "oic.wk.ruleList", - "n": "list of rules", - "rts": "oic.wk.rule", - "links": [ - ] - } - - post: - description: | - Provides the action to create a new rule in the ruleList resource - The only resource type that is allowed to be created "oic.wk.rule". - The example contains a condition, currentStatus and test. - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value = true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "off", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "my_rule1", - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The created resource attributes are provided in the response, - including the server generated identifier. - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "off", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" , - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - - -/RuleResURI: - description: | - Collection that models a rule. - This resource is an generic collection resource with additional parameters. - The rts value shall contain oic.wk.ruleMember resource types. - The additional parameters are - condition, this is the rule that will be evaluated - currentStatus, the current state of the rule, can be "enabled, disabled, error" - test an trigger once activation of the rule - displayName: Rule - - get: - description: | - Provides the current rule and list of web links to the rule members - responses: - 200: - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "disabled", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1", - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - put: - description: | - Provides the action to enable/disable the rule and an test mode for the rule. - Calling this method with test = true will update of all ruleMembers to the prescribed membervalue. - - body: - application/json: - schema: RuleUpdate - example: | - { - "currentStatus": "enabled" - } - - responses: - 200: - description: | - Indicates that the value is changed. - The changed properties are provided in the response. - body: - application/json: - schema: RuleUpdate - example: | - { - "currentStatus": "enabled" - } - - - post: - description: | - Provides the action to create a new ruleMember in the rule resource - The only resource type that is allowed to be created is "oic.wk.ruleMember". - The id of the resource will be generated by the implementation. - - body: - application/json: - schema: RuleMember - example: | - { - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "id": "", - "n": "my binary switch (for light bulb) mappings", - "memberProperty": "value", - "memberValue": true - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The new resource attributes are provided in the response. - body: - application/json: - schema: RuleMember - example: | - { - "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "memberProperty": "value", - "memberValue": true - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - -/RuleMemberResURI: - description: | - Rule member resource. - This resource is assignment statement of an property in a resource indicated by an URI - displayName: Rule Member - - get: - description: | - Provides the rule mappings - responses: - 200: - body: - application/json: - schema: RuleMember - example: | - { - "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "memberProperty": "value", - "memberValue": true - } + +schemas: + - Collection: !include oic.collection.json + Rule: !include oic.rule.json + RuleUpdate: !include oic.rule-Update.json + RuleMember: !include oic.ruleMember.json + +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.a", "oic.if.ll"] + + +/RuleListResURI: + description: | + Toplevel Rule resource. + This resource is a generic collection resource + The rts value shall contain oic.wk.rule resource types + displayName: Rules (Top level) + + get: + description: | + Provides the current list of web links pointing to rules + responses: + 200: + body: + application/json: + schema: Collection + example: | + { + "rt": "oic.wk.ruleList", + "n": "list of rules", + "rts": "oic.wk.rule", + "links": [ + ] + } + + post: + description: | + Provides the action to create a new rule in the ruleList resource + The only resource type that is allowed to be created "oic.wk.rule". + The example contains a condition, currentStatus and test. + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value = true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "off", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "my_rule1", + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The created resource attributes are provided in the response, + including the server generated identifier. + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "off", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" , + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + + +/RuleResURI: + description: | + Collection that models a rule. + This resource is an generic collection resource with additional parameters. + The rts value shall contain oic.wk.ruleMember resource types. + The additional parameters are + condition, this is the rule that will be evaluated + currentStatus, the current state of the rule, can be "enabled, disabled, error" + test an trigger once activation of the rule + displayName: Rule + + get: + description: | + Provides the current rule and list of web links to the rule members + responses: + 200: + body: + application/json: + schema: Rule + example: | + { + "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", + "currentStatus": "disabled", + "test": false, + "rt": "oic.wk.rule", + "n": "my first rule", + "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.r.ruleMember", + "links": [ + ] + } + + put: + description: | + Provides the action to enable/disable the rule and an test mode for the rule. + Calling this method with test = true will update of all ruleMembers to the prescribed membervalue. + + body: + application/json: + schema: RuleUpdate + example: | + { + "currentStatus": "enabled" + } + + responses: + 200: + description: | + Indicates that the value is changed. + The changed properties are provided in the response. + body: + application/json: + schema: RuleUpdate + example: | + { + "currentStatus": "enabled" + } + + + post: + description: | + Provides the action to create a new ruleMember in the rule resource + The only resource type that is allowed to be created is "oic.wk.ruleMember". + The id of the resource will be generated by the implementation. + + body: + application/json: + schema: RuleMember + example: | + { + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "id": "", + "n": "my binary switch (for light bulb) mappings", + "memberProperty": "value", + "memberValue": true + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The new resource attributes are provided in the response. + body: + application/json: + schema: RuleMember + example: | + { + "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "memberProperty": "value", + "memberValue": true + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + +/RuleMemberResURI: + description: | + Rule member resource. + This resource is assignment statement of an property in a resource indicated by an URI + displayName: Rule Member + + get: + description: | + Provides the rule mappings + responses: + 200: + body: + application/json: + schema: RuleMember + example: | + { + "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "memberProperty": "value", + "memberValue": true + } diff --git a/scene.raml b/scene.raml index 2688a70..33823c5 100755 --- a/scene.raml +++ b/scene.raml @@ -1,6 +1,6 @@ -#%RAML 0.8 -title: OICScene -version: v1.0-20150630 +#%RAML 0.8 +title: OICScene +version: v1.0-20150630 documentation: - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | @@ -9,289 +9,289 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -schemas: - - Collection: !include oic.collection.json - SceneCollection: !include oic.sceneCollection.json - SceneCollectionUpdate: !include oic.sceneCollection-Update.json - SceneMember: !include oic.sceneMember.json - -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.a", "oic.if.ll"] - - -/SceneListResURI: - description: | - Toplevel Scene resource. - This resource is a generic collection resource. - The rts value shall contain oic.sceneCollection resource types. - displayName: Scenes (Top level) - - get: - description: | - Provides the current list of web links pointing to scenes - responses: - 200: - body: - application/json: - schema: Collection - example: | - { - "rt": "oic.wk.sceneList", - "n": "list of scene Collections", - "rts": "oic.wk.sceneCollection", - "links": [ - ] - } - - post: - description: | - Provides the action to create a new sceneCollection in the SceneList resource - The only resource type that is allowed to be created "oic.wk.sceneCollection". - The example contains 3 scene values off, Reading and TVWatching. - body: - application/json: - schema: SceneCollection - example: | - { - "scenevalue": "off", - "sceneValues": "off,Reading,TVWatching", - "lastScene": "off", - "rt": "oic.wk.sceneCollection", - "n": "my first scene", - "id": "my_scene1", - "rts": "oic.r.sceneMember" - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The created resource attributes are provided in the response, - including the server generated identifier. - body: - application/json: - schema: SceneCollection - example: | - { - "scenevalue": "off", - "sceneValues": "off,Reading,TVWatching", - "lastScene": "off", - "rt": "oic.r.sceneCollection", - "n": "mymembername", - "link": "coap://newscene", - "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", - "rts": "oic.r.sceneMember" - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - - -/SceneCollectionResURI: - description: | - Collection that models a set of Scenes. - This resource is a generic collection resource with additional parameters. - The rts value shall contain oic.sceneMember resource types. - The additional parameters are - lastScene, this is the scene value last set by any OIC Client - sceneValueList, this is the list of available scenes - lastScene shall be listed in sceneValueList. - displayName: Scene Collections - - get: - description: | - Provides the current list of web links pointing to scenes - responses: - 200: - body: - application/json: - schema: SceneCollection - example: | - { - "lastScene": "off", - "sceneValues": "off,Reading,TVWatching", - "rt": "oic.wk.sceneCollection", - "n": "My Scenes for my living room", - "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", - "rts": "oic.wk.sceneMember", - "links": [ - ] - } - - put: - description: | - Provides the action to change the last settted scene selection. - Calling this method shall update of all sceneMembers to the prescribed membervalue. - When this method is called with the same value as the current lastScene value - then all sceneMembers shall be updated. - - body: - application/json: - schema: SceneCollectionUpdate - example: | - { - "lastScene": "Reading" - } - - responses: - 200: - description: | - Indicates that the value is changed. - The changed properties are provided in the response. - body: - application/json: - schema: SceneCollectionUpdate - example: | - { - "lastScene": "Reading" - } - - - post: - description: | - Provides the action to create a new sceneMember in the SceneCollection resource - The only resource type that is allowed to be created is "oic.wk.sceneMember". - The id of the resource will be generated by the implementation. - As example the mappings of the 3 scenes are mapped to different states of an binary switch - - body: - application/json: - schema: SceneMember - example: | - { - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "n": "my binary switch (for light bulb) mappings", - "sceneMappings": [ - { - "scene": "off", - "memberProperty": "value", - "memberValue": true - }, - { - "scene": "Reading", - "memberProperty": "value", - "memberValue": false - }, - { - "scene": "TVWatching", - "memberProperty": "value", - "memberValue": true - } - ] - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The new resource attributes are provided in the response. - body: - application/json: - schema: SceneMember - example: | - { - "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "sceneMappings": [ - { - "scene": "off", - "memberProperty": "value", - "memberValue": true - }, - { - "scene": "Reading", - "memberProperty": "value", - "memberValue": false - }, - { - "scene": "TVWatching", - "memberProperty": "value", - "memberValue": true - } - ] - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="0685B960-FFFF-46F7-BEC0-9E6234671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - -/SceneMemberResURI: - description: | - Collection that models a sceneMember. - displayName: Scene Member - - get: - description: | - Provides the scene member - responses: - 200: - body: - application/json: - schema: SceneMember - example: | - { - "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "sceneMappings": [ - { - "scene": "off", - "memberProperty": "value", - "memberValue": true - }, - { - "scene": "Reading", - "memberProperty": "value", - "memberValue": false - }, - { - "scene": "TVWatching", - "memberProperty": "value", - "memberValue": true - } - ] - } + +schemas: + - Collection: !include oic.collection.json + SceneCollection: !include oic.sceneCollection.json + SceneCollectionUpdate: !include oic.sceneCollection-Update.json + SceneMember: !include oic.sceneMember.json + +traits: + - interface: + queryParameters: + if: + enum: ["oic.if.a", "oic.if.ll"] + + +/SceneListResURI: + description: | + Toplevel Scene resource. + This resource is a generic collection resource. + The rts value shall contain oic.sceneCollection resource types. + displayName: Scenes (Top level) + + get: + description: | + Provides the current list of web links pointing to scenes + responses: + 200: + body: + application/json: + schema: Collection + example: | + { + "rt": "oic.wk.sceneList", + "n": "list of scene Collections", + "rts": "oic.wk.sceneCollection", + "links": [ + ] + } + + post: + description: | + Provides the action to create a new sceneCollection in the SceneList resource + The only resource type that is allowed to be created "oic.wk.sceneCollection". + The example contains 3 scene values off, Reading and TVWatching. + body: + application/json: + schema: SceneCollection + example: | + { + "scenevalue": "off", + "sceneValues": "off,Reading,TVWatching", + "lastScene": "off", + "rt": "oic.wk.sceneCollection", + "n": "my first scene", + "id": "my_scene1", + "rts": "oic.r.sceneMember" + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The created resource attributes are provided in the response, + including the server generated identifier. + body: + application/json: + schema: SceneCollection + example: | + { + "scenevalue": "off", + "sceneValues": "off,Reading,TVWatching", + "lastScene": "off", + "rt": "oic.r.sceneCollection", + "n": "mymembername", + "link": "coap://newscene", + "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.r.sceneMember" + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + + +/SceneCollectionResURI: + description: | + Collection that models a set of Scenes. + This resource is a generic collection resource with additional parameters. + The rts value shall contain oic.sceneMember resource types. + The additional parameters are + lastScene, this is the scene value last set by any OIC Client + sceneValueList, this is the list of available scenes + lastScene shall be listed in sceneValueList. + displayName: Scene Collections + + get: + description: | + Provides the current list of web links pointing to scenes + responses: + 200: + body: + application/json: + schema: SceneCollection + example: | + { + "lastScene": "off", + "sceneValues": "off,Reading,TVWatching", + "rt": "oic.wk.sceneCollection", + "n": "My Scenes for my living room", + "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", + "rts": "oic.wk.sceneMember", + "links": [ + ] + } + + put: + description: | + Provides the action to change the last settted scene selection. + Calling this method shall update of all sceneMembers to the prescribed membervalue. + When this method is called with the same value as the current lastScene value + then all sceneMembers shall be updated. + + body: + application/json: + schema: SceneCollectionUpdate + example: | + { + "lastScene": "Reading" + } + + responses: + 200: + description: | + Indicates that the value is changed. + The changed properties are provided in the response. + body: + application/json: + schema: SceneCollectionUpdate + example: | + { + "lastScene": "Reading" + } + + + post: + description: | + Provides the action to create a new sceneMember in the SceneCollection resource + The only resource type that is allowed to be created is "oic.wk.sceneMember". + The id of the resource will be generated by the implementation. + As example the mappings of the 3 scenes are mapped to different states of an binary switch + + body: + application/json: + schema: SceneMember + example: | + { + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "n": "my binary switch (for light bulb) mappings", + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } + + responses: + 200: + description: | + Indicates that the target resource was created. + The new resource attributes are provided in the response. + body: + application/json: + schema: SceneMember + example: | + { + "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } + + delete: + description: | + No change from collection. + When delete is used with the URI of the collection without and query parameters then the entire collection is deleted + When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted + queryParameters: + ins: + type: string + description: | + Delete the Web link identified by the string - could be a UUID. + required: false + example: | + DELETE /mycollection?ins="0685B960-FFFF-46F7-BEC0-9E6234671ADC1" + responses: + 200: + description: The web link instance or the the entire collection has been successfully deleted + 400: + description: The request is invalid + + +/SceneMemberResURI: + description: | + Collection that models a sceneMember. + displayName: Scene Member + + get: + description: | + Provides the scene member + responses: + 200: + body: + application/json: + schema: SceneMember + example: | + { + "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", + "n": "my binary switch (for light bulb) mappings", + "link": { "href":"coap://mydevice/mybinaryswitch", + "if": "oic.if.a", + "rt": "oic.r.switch.binary" }, + "sceneMappings": [ + { + "scene": "off", + "memberProperty": "value", + "memberValue": true + }, + { + "scene": "Reading", + "memberProperty": "value", + "memberValue": false + }, + { + "scene": "TVWatching", + "memberProperty": "value", + "memberValue": true + } + ] + } From e635f68f6f9e832203950aa59755b76039de6752 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 12 Feb 2016 17:34:57 +0100 Subject: [PATCH 03/55] =?UTF-8?q?Changed=20the=20'=C2=A9'=20in=20the=20JSO?= =?UTF-8?q?N=20to=20'Copyright=20(c)'.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is needed as the raml2doc tool has an issue with '©'. --- oic.collection.json | 2 +- oic.core.json | 2 +- oic.oic-link.json | 2 +- oic.rd.publish.json | 2 +- oic.rd.selection.json | 2 +- oic.rule-Update.json | 2 +- oic.rule.json | 2 +- oic.ruleMember.json | 2 +- oic.sceneCollection-Update.json | 2 +- oic.sceneCollection.json | 2 +- oic.sceneMember.json | 2 +- oic.wk.con.json | 2 +- oic.wk.d.json | 2 +- oic.wk.ifs.json | 2 +- oic.wk.mnt.json | 2 +- oic.wk.mon.json | 2 +- oic.wk.p.json | 2 +- oic.wk.ping.json | 2 +- oic.wk.res.json | 2 +- oic.wk.rts.json | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/oic.collection.json b/oic.collection.json index a82700b..7685c88 100755 --- a/oic.collection.json +++ b/oic.collection.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.collection.json#", "title": "Collection", "definitions": { diff --git a/oic.core.json b/oic.core.json index 96d471a..a6f8106 100755 --- a/oic.core.json +++ b/oic.core.json @@ -1,7 +1,7 @@ { "id": "http://openinterconnect.org/schemas/oic.core#", "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "title": "Core", "$ref": "#/definitions/oic.core", "definitions": { diff --git a/oic.oic-link.json b/oic.oic-link.json index ed209d8..f4f805f 100755 --- a/oic.oic-link.json +++ b/oic.oic-link.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/rm/oic.oic-link.json", "type": "object", "properties": { diff --git a/oic.rd.publish.json b/oic.rd.publish.json index a2fd3e6..c94a6bb 100755 --- a/oic.rd.publish.json +++ b/oic.rd.publish.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.rd.publish.json#", "title": "RD Publish & Update", "definitions": { diff --git a/oic.rd.selection.json b/oic.rd.selection.json index 2d89c50..b52054c 100755 --- a/oic.rd.selection.json +++ b/oic.rd.selection.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.rd.selection.json#", "title" : "RD Selection", "definitions": { diff --git a/oic.rule-Update.json b/oic.rule-Update.json index 65b0ca4..2b200da 100755 --- a/oic.rule-Update.json +++ b/oic.rule-Update.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.rule.json#", "title" : "Rule", "definitions": { diff --git a/oic.rule.json b/oic.rule.json index cd893c2..4ed0911 100755 --- a/oic.rule.json +++ b/oic.rule.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.rule.json#", "title" : "Rule", "definitions": { diff --git a/oic.ruleMember.json b/oic.ruleMember.json index cde3b79..9f4895f 100755 --- a/oic.ruleMember.json +++ b/oic.ruleMember.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.ruleMember.json#", "title" : "Rule Member", "definitions": { diff --git a/oic.sceneCollection-Update.json b/oic.sceneCollection-Update.json index 3583a5b..f5ccfe8 100755 --- a/oic.sceneCollection-Update.json +++ b/oic.sceneCollection-Update.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", "title" : "Scene Collection", "definitions": { diff --git a/oic.sceneCollection.json b/oic.sceneCollection.json index d935aed..a56fc4c 100755 --- a/oic.sceneCollection.json +++ b/oic.sceneCollection.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", "title" : "Scene Collection", "definitions": { diff --git a/oic.sceneMember.json b/oic.sceneMember.json index 729c00d..1e4d26b 100755 --- a/oic.sceneMember.json +++ b/oic.sceneMember.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.sceneMember.json#", "title" : "Scene Member", "definitions": { diff --git a/oic.wk.con.json b/oic.wk.con.json index 8003094..f499c13 100755 --- a/oic.wk.con.json +++ b/oic.wk.con.json @@ -1,7 +1,7 @@ { "id": "http://openinterconnect.org/oic.wk.con#", "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "definitions": { "oic.wk.con": { "type": "object", diff --git a/oic.wk.d.json b/oic.wk.d.json index 8acfb97..3450dbf 100755 --- a/oic.wk.d.json +++ b/oic.wk.d.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.d#", "definitions": { "oic.wk.d": { diff --git a/oic.wk.ifs.json b/oic.wk.ifs.json index 4803679..6cf8d17 100755 --- a/oic.wk.ifs.json +++ b/oic.wk.ifs.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.ifs#", "definitions": { "oic.wk.ifs": { diff --git a/oic.wk.mnt.json b/oic.wk.mnt.json index ba7ecef..445e6bc 100755 --- a/oic.wk.mnt.json +++ b/oic.wk.mnt.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.mnt#", "definitions": { "oic.wk.mnt": { diff --git a/oic.wk.mon.json b/oic.wk.mon.json index 884dc96..81ce5ac 100755 --- a/oic.wk.mon.json +++ b/oic.wk.mon.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.mon#", "definitions": { "oic.wk.mon": { diff --git a/oic.wk.p.json b/oic.wk.p.json index 29ce04c..a471c99 100755 --- a/oic.wk.p.json +++ b/oic.wk.p.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.p#", "definitions": { "oic.wk.p": { diff --git a/oic.wk.ping.json b/oic.wk.ping.json index ffadd1c..bf6f524 100755 --- a/oic.wk.ping.json +++ b/oic.wk.ping.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.ping#", "definitions": { "oic.wk.ping": { diff --git a/oic.wk.res.json b/oic.wk.res.json index aae0eb9..89dea19 100755 --- a/oic.wk.res.json +++ b/oic.wk.res.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/schemas/oic.wk.res.json/", "definitions": { "oic.res-links.json": { diff --git a/oic.wk.rts.json b/oic.wk.rts.json index 6ae81c0..e0ee9de 100755 --- a/oic.wk.rts.json +++ b/oic.wk.rts.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "© 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "id": "http://openinterconnect.org/oic.wk.rts#", "definitions": { "oic.wk.rts": { From dfda5027a50643dcd8b5d0dca8a99e3bf4e7f42f Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 12 Feb 2016 17:41:35 +0100 Subject: [PATCH 04/55] =?UTF-8?q?Changed=20the=20'=C2=A9'=20in=20the=20JSO?= =?UTF-8?q?N=20to=20'Copyright=20(c)'.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is needed as the raml2doc tool has an issue with '©'. --- oic.wk.con.raml | 2 +- oic.wk.d.raml | 2 +- oic.wk.ifs.raml | 2 +- oic.wk.mnt.raml | 2 +- oic.wk.mon.raml | 2 +- oic.wk.p.raml | 2 +- oic.wk.ping.raml | 2 +- oic.wk.res.raml | 2 +- oic.wk.rts.raml | 2 +- rdpublish.raml | 2 +- rules.raml | 2 +- scene.raml | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/oic.wk.con.raml b/oic.wk.con.raml index cabbcfb..7e0cc41 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -2,7 +2,7 @@ title: OIC Configuration version: v1-20150807 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.d.raml b/oic.wk.d.raml index 48446dc..49ec76f 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -2,7 +2,7 @@ title: OIC Root Device version: v1-20150811 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index 70d0a83..10fc648 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -2,7 +2,7 @@ title: OIC Interface Types version: v1-20150811 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index a5b1b52..cc71910 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -2,7 +2,7 @@ title: OIC Maintenance version: v1-20150811 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index 203be0d..7f901b2 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -2,7 +2,7 @@ title: OIC Monitoring version: v1-20150401 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.p.raml b/oic.wk.p.raml index f797575..c4c1204 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -2,7 +2,7 @@ title: OIC Base Platform version: v1-20150804 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index f92dd35..5108089 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -2,7 +2,7 @@ title: OIC Ping version: v1-20150814 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.res.raml b/oic.wk.res.raml index 0fe8554..e16e6bc 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -2,7 +2,7 @@ title: OIC Discoverable Resources version: v1-20150807 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index d8a6259..5871f35 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -2,7 +2,7 @@ title: OIC Resource Types version: v1-20150811 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/rdpublish.raml b/rdpublish.raml index 758ad4e..7a2e892 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -3,7 +3,7 @@ title: Resource Directory version: 1.0-090215 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/rules.raml b/rules.raml index b5c29a0..f7c43ec 100755 --- a/rules.raml +++ b/rules.raml @@ -2,7 +2,7 @@ title: OICRules version: v1.0-20150810 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. diff --git a/scene.raml b/scene.raml index 33823c5..53a0c2a 100755 --- a/scene.raml +++ b/scene.raml @@ -2,7 +2,7 @@ title: OICScene version: v1.0-20150630 documentation: - - title: © 2016 Open Interconnect Consortium, Inc. All rights reserved. + - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. content: | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. From 63c40e4ccde889bbde2c3dbe42f760cd3e51a82f Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Sat, 13 Feb 2016 23:20:25 +0100 Subject: [PATCH 05/55] oic.core resolve $ref. --- oic.core.json | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/oic.core.json b/oic.core.json index a6f8106..0324908 100755 --- a/oic.core.json +++ b/oic.core.json @@ -3,7 +3,6 @@ "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "title": "Core", - "$ref": "#/definitions/oic.core", "definitions": { "oic.core": { "type": "object", @@ -33,5 +32,9 @@ } } } - } + }, + "type": "object", + "allOf": [ + {"$ref": "#/definitions/oic.core"} + ] } From 0c13ff8472282b139128bdcfbc9768899dd58aef Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 7 Mar 2016 17:45:50 +0100 Subject: [PATCH 06/55] Refactoring work for adding directory structure to schemas. --- oic.wk.con.raml | 2 +- oic.wk.d.raml | 2 +- oic.wk.ifs.raml | 2 +- oic.wk.mnt.raml | 2 +- oic.wk.mon.raml | 2 +- oic.wk.p.raml | 2 +- oic.wk.ping.raml | 2 +- oic.wk.res.raml | 2 +- oic.wk.rts.raml | 2 +- rdpublish.raml | 6 +++--- rules.raml | 8 ++++---- scene.raml | 8 ++++---- oic.collection.json => schemas/oic.collection-schema.json | 2 +- oic.core.json => schemas/oic.core-schema.json | 2 +- oic.oic-link.json => schemas/oic.oic-link-schema.json | 2 +- oic.rd.publish.json => schemas/oic.rd.publish-schema.json | 2 +- .../oic.rd.selection-schema.json | 2 +- .../oic.rule-Update-schema.json | 4 ++-- oic.rule.json => schemas/oic.rule-schema.json | 4 ++-- oic.ruleMember.json => schemas/oic.ruleMember-schema.json | 2 +- .../oic.sceneCollection-Update-schema.json | 4 ++-- .../oic.sceneCollection-schema.json | 4 ++-- .../oic.sceneMember-schema.json | 2 +- oic.wk.con.json => schemas/oic.wk.con-schema.json | 2 +- oic.wk.d.json => schemas/oic.wk.d-schema.json | 2 +- oic.wk.ifs.json => schemas/oic.wk.ifs-schema.json | 2 +- oic.wk.mnt.json => schemas/oic.wk.mnt-schema.json | 4 ++-- oic.wk.mon.json => schemas/oic.wk.mon-schema.json | 2 +- oic.wk.p.json => schemas/oic.wk.p-schema.json | 2 +- oic.wk.ping.json => schemas/oic.wk.ping-schema.json | 2 +- oic.wk.res.json => schemas/oic.wk.res-schema.json | 2 +- oic.wk.rts.json => schemas/oic.wk.rts-schema.json | 2 +- 32 files changed, 45 insertions(+), 45 deletions(-) rename oic.collection.json => schemas/oic.collection-schema.json (98%) rename oic.core.json => schemas/oic.core-schema.json (93%) rename oic.oic-link.json => schemas/oic.oic-link-schema.json (96%) rename oic.rd.publish.json => schemas/oic.rd.publish-schema.json (91%) rename oic.rd.selection.json => schemas/oic.rd.selection-schema.json (97%) rename oic.rule-Update.json => schemas/oic.rule-Update-schema.json (90%) rename oic.rule.json => schemas/oic.rule-schema.json (90%) rename oic.ruleMember.json => schemas/oic.ruleMember-schema.json (94%) rename oic.sceneCollection-Update.json => schemas/oic.sceneCollection-Update-schema.json (89%) rename oic.sceneCollection.json => schemas/oic.sceneCollection-schema.json (89%) rename oic.sceneMember.json => schemas/oic.sceneMember-schema.json (95%) rename oic.wk.con.json => schemas/oic.wk.con-schema.json (93%) rename oic.wk.d.json => schemas/oic.wk.d-schema.json (93%) rename oic.wk.ifs.json => schemas/oic.wk.ifs-schema.json (88%) rename oic.wk.mnt.json => schemas/oic.wk.mnt-schema.json (80%) rename oic.wk.mon.json => schemas/oic.wk.mon-schema.json (93%) rename oic.wk.p.json => schemas/oic.wk.p-schema.json (96%) rename oic.wk.ping.json => schemas/oic.wk.ping-schema.json (90%) rename oic.wk.res.json => schemas/oic.wk.res-schema.json (92%) rename oic.wk.rts.json => schemas/oic.wk.rts-schema.json (88%) diff --git a/oic.wk.con.raml b/oic.wk.con.raml index 7e0cc41..b2a7546 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Configuration: !include oic.wk.con.json + - Configuration: !include schemas/oic.wk.con-schema.json traits: diff --git a/oic.wk.d.raml b/oic.wk.d.raml index 49ec76f..f630ce9 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Device: !include oic.wk.d.json + - Device: !include schemas/oic.wk.d-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index 10fc648..29dd906 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - IFS: !include oic.wk.ifs.json + - IFS: !include schemas/oic.wk.ifs-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index cc71910..f708c29 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - MNT: !include oic.wk.mnt.json + - MNT: !include schemas/oic.wk.mnt-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index 7f901b2..9726230 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - MON: !include oic.wk.mon.json + - MON: !include schemas/oic.wk.mon-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.p.raml b/oic.wk.p.raml index c4c1204..caec049 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Platform: !include oic.wk.p.json + - Platform: !include schemas/oic.wk.p-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index 5108089..0874efb 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - PING: !include oic.wk.ping.json + - PING: !include schemas/oic.wk.ping-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.res.raml b/oic.wk.res.raml index e16e6bc..c58e80b 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Resources: !include oic.wk.res.json + - Resources: !include schemas/oic.wk.res-schema.json traits: - interface: queryParameters: diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index 5871f35..ada86bc 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -11,7 +11,7 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - RTS: !include oic.wk.rts.json + - RTS: !include schemas/oic.wk.rts-schema.json traits: - interface: queryParameters: diff --git a/rdpublish.raml b/rdpublish.raml index 7a2e892..5cff1dd 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -36,9 +36,9 @@ documentation: schemas: - # Each schema represents an OIC Resource Type. The baseline interface operates on the entire representation - rdPublish: !include oic.rd.publish.json - rdSelection: !include oic.rd.selection.json - # rdDelLink: !include oic.rd.del-link.json + rdPublish: !include schemas/oic.rd.publish-schema.json + rdSelection: !include schemas/oic.rd.selection-schema.json + # rdDelLink: !include schemas/oic.rd.del-link-schema.json traits: - rddefinterface: diff --git a/rules.raml b/rules.raml index f7c43ec..b3c2f7b 100755 --- a/rules.raml +++ b/rules.raml @@ -11,10 +11,10 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Collection: !include oic.collection.json - Rule: !include oic.rule.json - RuleUpdate: !include oic.rule-Update.json - RuleMember: !include oic.ruleMember.json + - Collection: !include schemas/oic.collection-schema.json + Rule: !include schemas/oic.rule-schema.json + RuleUpdate: !include schemas/oic.rule-Update-schema.json + RuleMember: !include schemas/oic.ruleMember-schema.json traits: - interface: diff --git a/scene.raml b/scene.raml index 53a0c2a..9a6a0ce 100755 --- a/scene.raml +++ b/scene.raml @@ -11,10 +11,10 @@ documentation: THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. schemas: - - Collection: !include oic.collection.json - SceneCollection: !include oic.sceneCollection.json - SceneCollectionUpdate: !include oic.sceneCollection-Update.json - SceneMember: !include oic.sceneMember.json + - Collection: !include schemas/oic.collection-schema.json + SceneCollection: !include schemas/oic.sceneCollection-schema.json + SceneCollectionUpdate: !include schemas/oic.sceneCollection-Update-schema.json + SceneMember: !include schemas/oic.sceneMember-schema.json traits: - interface: diff --git a/oic.collection.json b/schemas/oic.collection-schema.json similarity index 98% rename from oic.collection.json rename to schemas/oic.collection-schema.json index 7685c88..97d5170 100755 --- a/oic.collection.json +++ b/schemas/oic.collection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.collection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.collection.json#", "title": "Collection", "definitions": { "oic.collection.setoflinks": { diff --git a/oic.core.json b/schemas/oic.core-schema.json similarity index 93% rename from oic.core.json rename to schemas/oic.core-schema.json index 0324908..a3fdf82 100755 --- a/oic.core.json +++ b/schemas/oic.core-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openinterconnect.org/schemas/oic.core#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.core#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "title": "Core", diff --git a/oic.oic-link.json b/schemas/oic.oic-link-schema.json similarity index 96% rename from oic.oic-link.json rename to schemas/oic.oic-link-schema.json index f4f805f..edcb8de 100755 --- a/oic.oic-link.json +++ b/schemas/oic.oic-link-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/rm/oic.oic-link.json", + "id": "http://openconnectivityfoundation.org/core/rm/oic.oic-link.json", "type": "object", "properties": { "href": { diff --git a/oic.rd.publish.json b/schemas/oic.rd.publish-schema.json similarity index 91% rename from oic.rd.publish.json rename to schemas/oic.rd.publish-schema.json index c94a6bb..0416d2b 100755 --- a/oic.rd.publish.json +++ b/schemas/oic.rd.publish-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.rd.publish.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.publish.json#", "title": "RD Publish & Update", "definitions": { "oic.rd.publish": { diff --git a/oic.rd.selection.json b/schemas/oic.rd.selection-schema.json similarity index 97% rename from oic.rd.selection.json rename to schemas/oic.rd.selection-schema.json index b52054c..6669169 100755 --- a/oic.rd.selection.json +++ b/schemas/oic.rd.selection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.rd.selection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.selection.json#", "title" : "RD Selection", "definitions": { "oic.rd.attributes": { diff --git a/oic.rule-Update.json b/schemas/oic.rule-Update-schema.json similarity index 90% rename from oic.rule-Update.json rename to schemas/oic.rule-Update-schema.json index 2b200da..bd5d4f0 100755 --- a/oic.rule-Update.json +++ b/schemas/oic.rule-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.rule.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule.json#", "title" : "Rule", "definitions": { "oic.rule": { @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, { "required" : [ "ins" ] } ] } diff --git a/oic.rule.json b/schemas/oic.rule-schema.json similarity index 90% rename from oic.rule.json rename to schemas/oic.rule-schema.json index 4ed0911..08d94e9 100755 --- a/oic.rule.json +++ b/schemas/oic.rule-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.rule.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule.json#", "title" : "Rule", "definitions": { "oic.rule": { @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, { "required" : [ "ins" ] } ] } diff --git a/oic.ruleMember.json b/schemas/oic.ruleMember-schema.json similarity index 94% rename from oic.ruleMember.json rename to schemas/oic.ruleMember-schema.json index 9f4895f..9b45ab3 100755 --- a/oic.ruleMember.json +++ b/schemas/oic.ruleMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.ruleMember.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.ruleMember.json#", "title" : "Rule Member", "definitions": { "oic.ruleMember": { diff --git a/oic.sceneCollection-Update.json b/schemas/oic.sceneCollection-Update-schema.json similarity index 89% rename from oic.sceneCollection-Update.json rename to schemas/oic.sceneCollection-Update-schema.json index f5ccfe8..8755224 100755 --- a/oic.sceneCollection-Update.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, { "required" : [ "ins" ] } ] } diff --git a/oic.sceneCollection.json b/schemas/oic.sceneCollection-schema.json similarity index 89% rename from oic.sceneCollection.json rename to schemas/oic.sceneCollection-schema.json index a56fc4c..dce0eb8 100755 --- a/oic.sceneCollection.json +++ b/schemas/oic.sceneCollection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.sceneCollection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openinterconnect.org/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, { "required" : [ "ins" ] } ] } diff --git a/oic.sceneMember.json b/schemas/oic.sceneMember-schema.json similarity index 95% rename from oic.sceneMember.json rename to schemas/oic.sceneMember-schema.json index 1e4d26b..d8da417 100755 --- a/oic.sceneMember.json +++ b/schemas/oic.sceneMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.sceneMember.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneMember.json#", "title" : "Scene Member", "definitions": { "oic.sceneMember": { diff --git a/oic.wk.con.json b/schemas/oic.wk.con-schema.json similarity index 93% rename from oic.wk.con.json rename to schemas/oic.wk.con-schema.json index f499c13..0b4d065 100755 --- a/oic.wk.con.json +++ b/schemas/oic.wk.con-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openinterconnect.org/oic.wk.con#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.con#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "definitions": { diff --git a/oic.wk.d.json b/schemas/oic.wk.d-schema.json similarity index 93% rename from oic.wk.d.json rename to schemas/oic.wk.d-schema.json index 3450dbf..3915e5d 100755 --- a/oic.wk.d.json +++ b/schemas/oic.wk.d-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.d#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.d#", "definitions": { "oic.wk.d": { "type": "object", diff --git a/oic.wk.ifs.json b/schemas/oic.wk.ifs-schema.json similarity index 88% rename from oic.wk.ifs.json rename to schemas/oic.wk.ifs-schema.json index 6cf8d17..5eee7bb 100755 --- a/oic.wk.ifs.json +++ b/schemas/oic.wk.ifs-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.ifs#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.ifs#", "definitions": { "oic.wk.ifs": { "type": "object", diff --git a/oic.wk.mnt.json b/schemas/oic.wk.mnt-schema.json similarity index 80% rename from oic.wk.mnt.json rename to schemas/oic.wk.mnt-schema.json index 445e6bc..3646f19 100755 --- a/oic.wk.mnt.json +++ b/schemas/oic.wk.mnt-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.mnt#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.mnt#", "definitions": { "oic.wk.mnt": { "type": "object", @@ -21,7 +21,7 @@ }, "type": "object", "allOf": [ - {"$ref": "http://openinterconnect.org/oic.core.json#/definitions/oic.core"}, + {"$ref": "http://openconnectivityfoundation.org/core/oic.core.json#/definitions/oic.core"}, {"$ref": "#/definitions/oic.wk.mnt" } ], "required": ["fr", "rb", "ssc"] diff --git a/oic.wk.mon.json b/schemas/oic.wk.mon-schema.json similarity index 93% rename from oic.wk.mon.json rename to schemas/oic.wk.mon-schema.json index 81ce5ac..7d50175 100755 --- a/oic.wk.mon.json +++ b/schemas/oic.wk.mon-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.mon#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.mon#", "definitions": { "oic.wk.mon": { "type": "object", diff --git a/oic.wk.p.json b/schemas/oic.wk.p-schema.json similarity index 96% rename from oic.wk.p.json rename to schemas/oic.wk.p-schema.json index a471c99..ebbdd8a 100755 --- a/oic.wk.p.json +++ b/schemas/oic.wk.p-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.p#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.p#", "definitions": { "oic.wk.p": { "type": "object", diff --git a/oic.wk.ping.json b/schemas/oic.wk.ping-schema.json similarity index 90% rename from oic.wk.ping.json rename to schemas/oic.wk.ping-schema.json index bf6f524..d2107d6 100755 --- a/oic.wk.ping.json +++ b/schemas/oic.wk.ping-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.ping#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.ping#", "definitions": { "oic.wk.ping": { "type": "object", diff --git a/oic.wk.res.json b/schemas/oic.wk.res-schema.json similarity index 92% rename from oic.wk.res.json rename to schemas/oic.wk.res-schema.json index 89dea19..5c5f062 100755 --- a/oic.wk.res.json +++ b/schemas/oic.wk.res-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/schemas/oic.wk.res.json/", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res.json/", "definitions": { "oic.res-links.json": { "type": "object", diff --git a/oic.wk.rts.json b/schemas/oic.wk.rts-schema.json similarity index 88% rename from oic.wk.rts.json rename to schemas/oic.wk.rts-schema.json index e0ee9de..7c91946 100755 --- a/oic.wk.rts.json +++ b/schemas/oic.wk.rts-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openinterconnect.org/oic.wk.rts#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.rts#", "definitions": { "oic.wk.rts": { "type": "object", From 8c73c87933b2c800b88ad3d5ad2bb3395f077262 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 7 Mar 2016 17:58:14 +0100 Subject: [PATCH 07/55] Refactor: continued teh rename *.json -> *-schema.json --- schemas/oic.collection-schema.json | 6 +++--- schemas/oic.oic-link-schema.json | 2 +- schemas/oic.rd.publish-schema.json | 4 ++-- schemas/oic.rd.selection-schema.json | 2 +- schemas/oic.rule-Update-schema.json | 6 +++--- schemas/oic.rule-schema.json | 6 +++--- schemas/oic.ruleMember-schema.json | 6 +++--- schemas/oic.sceneCollection-Update-schema.json | 6 +++--- schemas/oic.sceneCollection-schema.json | 6 +++--- schemas/oic.sceneMember-schema.json | 6 +++--- schemas/oic.wk.con-schema.json | 2 +- schemas/oic.wk.mnt-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 2 +- schemas/oic.wk.ping-schema.json | 2 +- schemas/oic.wk.res-schema.json | 8 ++++---- 15 files changed, 33 insertions(+), 33 deletions(-) diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 97d5170..98ec196 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.collection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.collection-schema.json#", "title": "Collection", "definitions": { "oic.collection.setoflinks": { @@ -14,7 +14,7 @@ "items": { "allOf": [ { - "$ref": "oic.oic-link.json#" + "$ref": "oic.oic-link-schema.json#" } ], "required": ["ins"] @@ -132,7 +132,7 @@ "type": "object", "allOf": [ { - "$ref": "oic.core.json#/definitions/oic.core" + "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.collection" diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index edcb8de..6e00cc5 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/rm/oic.oic-link.json", + "id": "http://openconnectivityfoundation.org/core/rm/oic.oic-link-schema.json", "type": "object", "properties": { "href": { diff --git a/schemas/oic.rd.publish-schema.json b/schemas/oic.rd.publish-schema.json index 0416d2b..cd68f78 100755 --- a/schemas/oic.rd.publish-schema.json +++ b/schemas/oic.rd.publish-schema.json @@ -1,14 +1,14 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.publish.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.publish-schema.json#", "title": "RD Publish & Update", "definitions": { "oic.rd.publish": { "description": "Publishes resources as OIC Links into the resource directory", "properties": { "linkSet": { - "$ref": "oic.collection.json#/definitions/oic.collection.setof-tagged-setoflinks" + "$ref": "oic.collection-schema.json#/definitions/oic.collection.setof-tagged-setoflinks" }, "ttl": { "type": "integer", diff --git a/schemas/oic.rd.selection-schema.json b/schemas/oic.rd.selection-schema.json index 6669169..55c0141 100755 --- a/schemas/oic.rd.selection-schema.json +++ b/schemas/oic.rd.selection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.selection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.selection-schema.json#", "title" : "RD Selection", "definitions": { "oic.rd.attributes": { diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index bd5d4f0..699dd12 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { "oic.rule": { @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, { "required" : [ "ins" ] } ] } @@ -50,7 +50,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.rule" } ] } diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index 08d94e9..fa824e9 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { "oic.rule": { @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, { "required" : [ "ins" ] } ] } @@ -50,7 +50,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.rule" } ] } diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json index 9b45ab3..09504ed 100755 --- a/schemas/oic.ruleMember-schema.json +++ b/schemas/oic.ruleMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.ruleMember.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.ruleMember-schema.json#", "title" : "Rule Member", "definitions": { "oic.ruleMember": { @@ -31,7 +31,7 @@ "link": { "type": "string", "description": "web link that points at a resource", - "$ref": "oic.oic-link.json#" + "$ref": "oic.oic-link-schema.json#" } }, "required": [ "id", "link", "memberProperty", "memberValue" ], @@ -41,7 +41,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.ruleMember" } ] } diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index 8755224..6ccb6f6 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, { "required" : [ "ins" ] } ] } @@ -48,7 +48,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.sceneCollection" } ] } diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index dce0eb8..2ee8212 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link.json#" }, + { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, { "required" : [ "ins" ] } ] } @@ -48,7 +48,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.sceneCollection" } ] } diff --git a/schemas/oic.sceneMember-schema.json b/schemas/oic.sceneMember-schema.json index d8da417..8548b16 100755 --- a/schemas/oic.sceneMember-schema.json +++ b/schemas/oic.sceneMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneMember.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneMember-schema.json#", "title" : "Scene Member", "definitions": { "oic.sceneMember": { @@ -44,7 +44,7 @@ "link": { "type": "string", "description": "web link that points at an resource", - "$ref": "oic.oic-link.json#" + "$ref": "oic.oic-link-schema.json#" } }, "required": [ "link" ] @@ -53,7 +53,7 @@ "type": "object", "allOf" : [ - { "$ref": "oic.core.json#/definitions/oic.core" }, + { "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.sceneMember" } ] } diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index 0b4d065..bcf628a 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -32,7 +32,7 @@ }, "type": "object", "allOf": [ - {"$ref": "oic.core.json#/definitions/oic.core"}, + {"$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.con" } ], "required": [ "n" ] diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index 3646f19..9af5a75 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -21,7 +21,7 @@ }, "type": "object", "allOf": [ - {"$ref": "http://openconnectivityfoundation.org/core/oic.core.json#/definitions/oic.core"}, + {"$ref": "http://openconnectivityfoundation.org/core/oic.core-schema.json#/definitions/oic.core"}, {"$ref": "#/definitions/oic.wk.mnt" } ], "required": ["fr", "rb", "ssc"] diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 7d50175..2700c96 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -24,7 +24,7 @@ }, "type": "object", "allOf": [ - {"$ref": "oic.core.json#/definitions/oic.core"}, + {"$ref": "oic.core-schema.json#/definitions/oic.core"}, {"$ref": "#/definitions/oic.wk.mon"} ], "required": ["av", "lat"] diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index d2107d6..e1847da 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -16,7 +16,7 @@ "type": "object", "allOf": [ { - "$ref": "oic.core.json#/definitions/oic.core" + "$ref": "oic.core-schema.json#/definitions/oic.core" }, { "$ref": "#/definitions/oic.wk.ping" diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 5c5f062..7109fe9 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -1,9 +1,9 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res.json/", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json/", "definitions": { - "oic.res-links.json": { + "oic.res-links-schema.json": { "type": "object", "properties": { "n": { @@ -22,7 +22,7 @@ "links": { "type": "array", "items": { - "$ref": "oic.oic-link.json#" + "$ref": "oic.oic-link-schema.json#" } } } @@ -31,7 +31,7 @@ "description": "The list of resources expressed as OIC links", "type": "array", "items": { - "$ref": "#/definitions/oic.res-links.json" + "$ref": "#/definitions/oic.res-links-schema.json" }, "required": ["di", "links"] } From dd79a69fbd91cbf5e01e6607c9490c3df69243ea Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 7 Mar 2016 18:32:47 +0100 Subject: [PATCH 08/55] Also refactor id's that were not terminated with .json --- schemas/oic.core-schema.json | 2 +- schemas/oic.wk.con-schema.json | 2 +- schemas/oic.wk.d-schema.json | 2 +- schemas/oic.wk.ifs-schema.json | 2 +- schemas/oic.wk.mnt-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 2 +- schemas/oic.wk.p-schema.json | 2 +- schemas/oic.wk.ping-schema.json | 2 +- schemas/oic.wk.rts-schema.json | 4 ++-- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index a3fdf82..dd3a531 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openconnectivityfoundation.org/core/schemas/oic.core#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.core-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "title": "Core", diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index bcf628a..d6d6832 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openconnectivityfoundation.org/core/oic.wk.con#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.con-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", "definitions": { diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 3915e5d..f5bec0b 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.d#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.d-schema.json#", "definitions": { "oic.wk.d": { "type": "object", diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 5eee7bb..1a7060d 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.ifs#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.ifs-schema.json#", "definitions": { "oic.wk.ifs": { "type": "object", diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index 9af5a75..2bd9681 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.mnt#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.mnt-schema.json#", "definitions": { "oic.wk.mnt": { "type": "object", diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 2700c96..3470242 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.mon#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.mon-schema.json#", "definitions": { "oic.wk.mon": { "type": "object", diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index ebbdd8a..850d02c 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.p#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.p-schema.json#", "definitions": { "oic.wk.p": { "type": "object", diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index e1847da..1af7211 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.ping#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.ping-schema.json#", "definitions": { "oic.wk.ping": { "type": "object", diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 7c91946..867696f 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.rts#", + "id": "http://openconnectivityfoundation.org/core/oic.wk.rts-schema.json#", "definitions": { "oic.wk.rts": { "type": "object", @@ -19,4 +19,4 @@ { "$ref": "#/definitions/oic.wk.rts" } ], "required": ["tl"] -} \ No newline at end of file +} From 27c2fbb4da62db01b7491d9166520effcbf2695a Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 7 Mar 2016 18:45:30 +0100 Subject: [PATCH 09/55] Fix dual documentation declaration in rdpublish.raml. --- rdpublish.raml | 1 - 1 file changed, 1 deletion(-) diff --git a/rdpublish.raml b/rdpublish.raml index 5cff1dd..0f50824 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -10,7 +10,6 @@ documentation: 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -documentation: - title: OIC Rsource Directory content: | A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. From 3f099d7349a54fa83063a28b784bb61edfae37b0 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Tue, 8 Mar 2016 12:51:52 +0100 Subject: [PATCH 10/55] include legal notice from external file. --- LICENSE.md | 7 +++ oic.wk.con.raml | 9 +-- oic.wk.d.raml | 9 +-- oic.wk.ifs.raml | 9 +-- oic.wk.mnt.raml | 9 +-- oic.wk.mon.raml | 9 +-- oic.wk.p.raml | 9 +-- oic.wk.ping.raml | 9 +-- oic.wk.res.raml | 9 +-- oic.wk.rts.raml | 9 +-- rdpublish.raml | 153 +---------------------------------------------- rules.raml | 9 +-- scene.raml | 9 +-- 13 files changed, 31 insertions(+), 228 deletions(-) create mode 100644 LICENSE.md diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 0000000..f1d3677 --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,7 @@ +Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/oic.wk.con.raml b/oic.wk.con.raml index b2a7546..47c9aa8 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -2,13 +2,8 @@ title: OIC Configuration version: v1-20150807 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Configuration: !include schemas/oic.wk.con-schema.json diff --git a/oic.wk.d.raml b/oic.wk.d.raml index f630ce9..7bc7e3b 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -2,13 +2,8 @@ title: OIC Root Device version: v1-20150811 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Device: !include schemas/oic.wk.d-schema.json diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index 29dd906..ff2645a 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -2,13 +2,8 @@ title: OIC Interface Types version: v1-20150811 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - IFS: !include schemas/oic.wk.ifs-schema.json diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index f708c29..6a1ad20 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -2,13 +2,8 @@ title: OIC Maintenance version: v1-20150811 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - MNT: !include schemas/oic.wk.mnt-schema.json diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index 9726230..c547ecc 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -2,13 +2,8 @@ title: OIC Monitoring version: v1-20150401 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - MON: !include schemas/oic.wk.mon-schema.json diff --git a/oic.wk.p.raml b/oic.wk.p.raml index caec049..3757d6a 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -2,13 +2,8 @@ title: OIC Base Platform version: v1-20150804 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Platform: !include schemas/oic.wk.p-schema.json diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index 0874efb..5373714 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -2,13 +2,8 @@ title: OIC Ping version: v1-20150814 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - PING: !include schemas/oic.wk.ping-schema.json diff --git a/oic.wk.res.raml b/oic.wk.res.raml index c58e80b..b409f0a 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -2,13 +2,8 @@ title: OIC Discoverable Resources version: v1-20150807 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Resources: !include schemas/oic.wk.res-schema.json diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index ada86bc..a2f8223 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -2,13 +2,8 @@ title: OIC Resource Types version: v1-20150811 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - RTS: !include schemas/oic.wk.rts-schema.json diff --git a/rdpublish.raml b/rdpublish.raml index 0f50824..5cf5d3b 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -3,155 +3,6 @@ title: Resource Directory version: 1.0-090215 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md - title: OIC Rsource Directory - content: | - A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. - - title: Introduction - content: | - For resource in other OIC Devices to be discovered using the Resource Directory, these other devices have to publish the resource links they would otherwise have advertised through /oic/res to the Resource Directory. Once the information has been published then the OIC Devices may stop responding to discovery queries and may also go to sleep. - - The Resource Directory will respond to all discovery queries with resources that it directly advertises and also the resource information that has been published to it. - - title: Resource Directory discovery - content: | - Before an OIC Device publishes its resource information, it must first discover available Resource Directories and then select one of those to publish the information to. - - This doscovery is done with a multicast query to /oic/rd. The information returned is either a bais factor or a list of attributes that help the discovering OIC Device to select one of the RDs. This RD will be used till the RD does not respond or another RD is selected. - - title: Resource Directory publish - content: | - Once the RD has been discovery and selected, the OIC Device can publish its resoure information. The resource information are published to the /oic/rd resource using the "publish" interface. The information that needs to tbe available in /oic/res is then populated by the Resource Directory. - - Periodically based on the TTL set by the publishing OIC Device, the information that is published has to be refreshed with a new TTL or the TTL can be updated if there is no change in the information. It is the responsibility of the publishing OIC Device to ensure that the information or TTL is updated before the previous TTL expires; failing this the RD will garbage collect all the information related to the publishing OIC Device. - - title: Resource discovery - content: | - The discovery of resources is done in the same manner as for any OIC Server. A query to /oic/res either over multicast or uincast is required. - -schemas: -- - # Each schema represents an OIC Resource Type. The baseline interface operates on the entire representation - rdPublish: !include schemas/oic.rd.publish-schema.json - rdSelection: !include schemas/oic.rd.selection-schema.json - # rdDelLink: !include schemas/oic.rd.del-link-schema.json - -traits: -- rddefinterface: - queryParameters: - if: - description: | - Interface is optional since there is only one interface supported for the OIC Resource Type - Both for RD selectin and for publish - type: string - enum: [ "oic.if.baseline" ] - default: "oic.if.baseline" - required: false - example: | - GET /oic/rd?if=oic.wk.baseline - -/oic/rd: - displayName: Resource directory resource - description: | - Resource to be exposed by any OIC Device that can act as a Resource Directory - get: - description: | - Get the attributes of the Resource Directory for selection purposes. - queryParameters: - rt: - description: | - Only one OIC Resource Type is used for GET; OIC RT is optional - type: string - enum: [ "oic.wk.rd" ] - default: "oic.wk.rd" - required: false - example: | - GET /oic/rd?rt=oic.wk.rd - is: [ rddefinterface ] - responses: - 200: - description: | - Respond with the selector criteria - either the set of attributes or the bias factor - body: - application/json: - schema: rdSelection - example: | - { - "rt": "oic.wk.rd", - "sel": 50 - } - post: - description: | - Publish the resource information. Appropriates parts of the information posted will be discovered through /oic/res - body: - application/json: - schema: rdPublish - # Maybe the entire published information should be treated as a new resource - as if created using the link-batch interface. - queryParameters: - rt: - description: | - Only one OIC Resource Type is used for GET; OIC RT is optional - type: string - enum: [ "oic.wk.rdpub" ] - default: "oic.wk.rdpub" - required: false - example: | - GET /oic/rd?rt=oic.wk.rdpub - is: [ rddefinterface ] - responses: - 200: - description: | - Respond with the same schema as publish but with the links have the "ins" parameter set to the appropriate instance value. - This value is used by the receiver to manage that OIC Link instance. - body: - application/json: - schema: rdPublish - example: | - { - "links": [ - { - "href": "coap://someAuthority:1000/somePath", - "rt": "oic.r.someResource", - "if": "oic.if.a", - "ins": 12345 - }, - { - "href": "coap://someAuthority:1000/somePath", - "rt": "oic.r.someOtherResource", - "if": "oic.if.baseline", - "ins": 54321 - } - ], - "ttl": 600 - } - - delete: - description: | - Delete a particular OIC Link - the link may be a simple link or a link in a tagged set. - queryParameters: - di: - displayName: ID of the device making request - description: | - This is used to determine which set of links to operata on. (Need authentication to ensure that there is no spoofing). If instance is ommitted then the entire set of links from this device ID is deleted - type: string - required: true - example: | - DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" - ins: - displayName: Link instance for deletion - description: | - Instance of the link to delete - Value of parameter is a string where instance to be deleted are comma separated - type: string - required: false - example: | - DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1";ins="20" - responses: - 200: - description: The delete succeeded - -# The discovery through the /oic/res of the resource directory is the same as the standard resource discovery -# Need to include the RAML for /oic/res based resource discovery diff --git a/rules.raml b/rules.raml index b3c2f7b..abf8a5e 100755 --- a/rules.raml +++ b/rules.raml @@ -2,13 +2,8 @@ title: OICRules version: v1.0-20150810 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Collection: !include schemas/oic.collection-schema.json diff --git a/scene.raml b/scene.raml index 9a6a0ce..d03ee7c 100755 --- a/scene.raml +++ b/scene.raml @@ -2,13 +2,8 @@ title: OICScene version: v1.0-20150630 documentation: - - title: Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - content: | - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + - title: Legal + content: !include LICENSE.md schemas: - Collection: !include schemas/oic.collection-schema.json From 7ba5cf38da6e5a24c0f383a2272ebec58dc09085 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Tue, 8 Mar 2016 13:04:51 +0100 Subject: [PATCH 11/55] repair rdpublish which was messed up with previous commit. --- rdpublish.raml | 144 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 144 insertions(+) diff --git a/rdpublish.raml b/rdpublish.raml index 5cf5d3b..0bc5f76 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -6,3 +6,147 @@ documentation: - title: Legal content: !include LICENSE.md - title: OIC Rsource Directory + content: | + A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. + - title: Introduction + content: | + For resource in other OIC Devices to be discovered using the Resource Directory, these other devices have to publish the resource links they would otherwise have advertised through /oic/res to the Resource Directory. Once the information has been published then the OIC Devices may stop responding to discovery queries and may also go to sleep. + + The Resource Directory will respond to all discovery queries with resources that it directly advertises and also the resource information that has been published to it. + - title: Resource Directory discovery + content: | + Before an OIC Device publishes its resource information, it must first discover available Resource Directories and then select one of those to publish the information to. + + This doscovery is done with a multicast query to /oic/rd. The information returned is either a bais factor or a list of attributes that help the discovering OIC Device to select one of the RDs. This RD will be used till the RD does not respond or another RD is selected. + - title: Resource Directory publish + content: | + Once the RD has been discovery and selected, the OIC Device can publish its resoure information. The resource information are published to the /oic/rd resource using the "publish" interface. The information that needs to tbe available in /oic/res is then populated by the Resource Directory. + + Periodically based on the TTL set by the publishing OIC Device, the information that is published has to be refreshed with a new TTL or the TTL can be updated if there is no change in the information. It is the responsibility of the publishing OIC Device to ensure that the information or TTL is updated before the previous TTL expires; failing this the RD will garbage collect all the information related to the publishing OIC Device. + - title: Resource discovery + content: | + The discovery of resources is done in the same manner as for any OIC Server. A query to /oic/res either over multicast or uincast is required. + +schemas: +- + # Each schema represents an OIC Resource Type. The baseline interface operates on the entire representation + rdPublish: !include schemas/oic.rd.publish-schema.json + rdSelection: !include schemas/oic.rd.selection-schema.json + # rdDelLink: !include schemas/oic.rd.del-link-schema.json + +traits: +- rddefinterface: + queryParameters: + if: + description: | + Interface is optional since there is only one interface supported for the OIC Resource Type + Both for RD selectin and for publish + type: string + enum: [ "oic.if.baseline" ] + default: "oic.if.baseline" + required: false + example: | + GET /oic/rd?if=oic.wk.baseline + +/oic/rd: + displayName: Resource directory resource + description: | + Resource to be exposed by any OIC Device that can act as a Resource Directory + get: + description: | + Get the attributes of the Resource Directory for selection purposes. + queryParameters: + rt: + description: | + Only one OIC Resource Type is used for GET; OIC RT is optional + type: string + enum: [ "oic.wk.rd" ] + default: "oic.wk.rd" + required: false + example: | + GET /oic/rd?rt=oic.wk.rd + is: [ rddefinterface ] + responses: + 200: + description: | + Respond with the selector criteria - either the set of attributes or the bias factor + body: + application/json: + schema: rdSelection + example: | + { + "rt": "oic.wk.rd", + "sel": 50 + } + post: + description: | + Publish the resource information. Appropriates parts of the information posted will be discovered through /oic/res + body: + application/json: + schema: rdPublish + # Maybe the entire published information should be treated as a new resource - as if created using the link-batch interface. + queryParameters: + rt: + description: | + Only one OIC Resource Type is used for GET; OIC RT is optional + type: string + enum: [ "oic.wk.rdpub" ] + default: "oic.wk.rdpub" + required: false + example: | + GET /oic/rd?rt=oic.wk.rdpub + is: [ rddefinterface ] + responses: + 200: + description: | + Respond with the same schema as publish but with the links have the "ins" parameter set to the appropriate instance value. + This value is used by the receiver to manage that OIC Link instance. + body: + application/json: + schema: rdPublish + example: | + { + "links": [ + { + "href": "coap://someAuthority:1000/somePath", + "rt": "oic.r.someResource", + "if": "oic.if.a", + "ins": 12345 + }, + { + "href": "coap://someAuthority:1000/somePath", + "rt": "oic.r.someOtherResource", + "if": "oic.if.baseline", + "ins": 54321 + } + ], + "ttl": 600 + } + + delete: + description: | + Delete a particular OIC Link - the link may be a simple link or a link in a tagged set. + queryParameters: + di: + displayName: ID of the device making request + description: | + This is used to determine which set of links to operata on. (Need authentication to ensure that there is no spoofing). If instance is ommitted then the entire set of links from this device ID is deleted + type: string + required: true + example: | + DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" + ins: + displayName: Link instance for deletion + description: | + Instance of the link to delete + Value of parameter is a string where instance to be deleted are comma separated + type: string + required: false + example: | + DELETE /oic/rd?di="0685B960-736F-46F7-BEC0-9E6CBD671ADC1";ins="20" + responses: + 200: + description: The delete succeeded + +# The discovery through the /oic/res of the resource directory is the same as the standard resource discovery +# Need to include the RAML for /oic/res based resource discovery From e28a9e0a92e17042ba3e83661e4c0fbce8bdc4ba Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 18 Mar 2016 15:50:25 +0100 Subject: [PATCH 12/55] Test splitting legal content in seperate files. --- COPYRIGHT.md | 1 + DISCLAIMER.md | 1 + LICENSE.md | 4 ---- oic.wk.con.raml | 8 +++++++- oic.wk.d.raml | 8 +++++++- oic.wk.ifs.raml | 8 +++++++- oic.wk.mnt.raml | 8 +++++++- oic.wk.mon.raml | 8 +++++++- oic.wk.p.raml | 8 +++++++- oic.wk.ping.raml | 8 +++++++- oic.wk.res.raml | 8 +++++++- oic.wk.rts.raml | 8 +++++++- rdpublish.raml | 8 +++++++- rules.raml | 8 +++++++- scene.raml | 8 +++++++- 15 files changed, 86 insertions(+), 16 deletions(-) create mode 100644 COPYRIGHT.md create mode 100644 DISCLAIMER.md diff --git a/COPYRIGHT.md b/COPYRIGHT.md new file mode 100644 index 0000000..ea13d74 --- /dev/null +++ b/COPYRIGHT.md @@ -0,0 +1 @@ +Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. diff --git a/DISCLAIMER.md b/DISCLAIMER.md new file mode 100644 index 0000000..1ceb458 --- /dev/null +++ b/DISCLAIMER.md @@ -0,0 +1 @@ +THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/LICENSE.md b/LICENSE.md index f1d3677..0e4811b 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -1,7 +1,3 @@ -Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/oic.wk.con.raml b/oic.wk.con.raml index 47c9aa8..6107ec8 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -2,8 +2,14 @@ title: OIC Configuration version: v1-20150807 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Configuration: !include schemas/oic.wk.con-schema.json diff --git a/oic.wk.d.raml b/oic.wk.d.raml index 7bc7e3b..2666b80 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -2,8 +2,14 @@ title: OIC Root Device version: v1-20150811 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Device: !include schemas/oic.wk.d-schema.json diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index ff2645a..91ee6c5 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -2,8 +2,14 @@ title: OIC Interface Types version: v1-20150811 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - IFS: !include schemas/oic.wk.ifs-schema.json diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index 6a1ad20..ef36c9d 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -2,8 +2,14 @@ title: OIC Maintenance version: v1-20150811 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - MNT: !include schemas/oic.wk.mnt-schema.json diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index c547ecc..7b1a963 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -2,8 +2,14 @@ title: OIC Monitoring version: v1-20150401 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - MON: !include schemas/oic.wk.mon-schema.json diff --git a/oic.wk.p.raml b/oic.wk.p.raml index 3757d6a..dae913a 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -2,8 +2,14 @@ title: OIC Base Platform version: v1-20150804 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Platform: !include schemas/oic.wk.p-schema.json diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index 5373714..4f29bff 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -2,8 +2,14 @@ title: OIC Ping version: v1-20150814 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - PING: !include schemas/oic.wk.ping-schema.json diff --git a/oic.wk.res.raml b/oic.wk.res.raml index b409f0a..795e98d 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -2,8 +2,14 @@ title: OIC Discoverable Resources version: v1-20150807 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Resources: !include schemas/oic.wk.res-schema.json diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index a2f8223..3bc5609 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -2,8 +2,14 @@ title: OIC Resource Types version: v1-20150811 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - RTS: !include schemas/oic.wk.rts-schema.json diff --git a/rdpublish.raml b/rdpublish.raml index 0bc5f76..6e711f8 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -3,8 +3,14 @@ title: Resource Directory version: 1.0-090215 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + - title: OIC Rsource Directory content: | A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. diff --git a/rules.raml b/rules.raml index abf8a5e..d24a1ee 100755 --- a/rules.raml +++ b/rules.raml @@ -2,8 +2,14 @@ title: OICRules version: v1.0-20150810 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Collection: !include schemas/oic.collection-schema.json diff --git a/scene.raml b/scene.raml index d03ee7c..8800d19 100755 --- a/scene.raml +++ b/scene.raml @@ -2,8 +2,14 @@ title: OICScene version: v1.0-20150630 documentation: - - title: Legal + + - title: OCF Copyright + content: !include COPYRIGHT.md + - title: OCF License content: !include LICENSE.md + - title: OCF Disclaimer + content: !include DISCLAIMER.md + schemas: - Collection: !include schemas/oic.collection-schema.json From 4b7c073a5e5b9ebc53197108819996605c2691d9 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Wed, 23 Mar 2016 00:11:56 +0100 Subject: [PATCH 13/55] Implemented ocf lawyer's recommendation. Each directory needs to contain both the License and the Disclaimer. - Add License and Disclaimer to schema directory. Each file needs to contain the full copyright text. - Incorporate the copyright text instead of including the file. --- COPYRIGHT.md | 1 - oic.wk.con.raml | 2 +- oic.wk.d.raml | 2 +- oic.wk.ifs.raml | 2 +- oic.wk.mnt.raml | 2 +- oic.wk.mon.raml | 2 +- oic.wk.p.raml | 2 +- oic.wk.ping.raml | 2 +- oic.wk.res.raml | 2 +- oic.wk.rts.raml | 2 +- rdpublish.raml | 2 +- rules.raml | 2 +- scene.raml | 2 +- schemas/DISCLAIMER.md | 1 + schemas/LICENSE.md | 3 +++ 15 files changed, 16 insertions(+), 13 deletions(-) delete mode 100644 COPYRIGHT.md create mode 100644 schemas/DISCLAIMER.md create mode 100644 schemas/LICENSE.md diff --git a/COPYRIGHT.md b/COPYRIGHT.md deleted file mode 100644 index ea13d74..0000000 --- a/COPYRIGHT.md +++ /dev/null @@ -1 +0,0 @@ -Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved. diff --git a/oic.wk.con.raml b/oic.wk.con.raml index 6107ec8..391d25d 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -4,7 +4,7 @@ version: v1-20150807 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.d.raml b/oic.wk.d.raml index 2666b80..a0d76e5 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -4,7 +4,7 @@ version: v1-20150811 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index 91ee6c5..efb933e 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -4,7 +4,7 @@ version: v1-20150811 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index ef36c9d..3cc575f 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -4,7 +4,7 @@ version: v1-20150811 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index 7b1a963..ef9e54b 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -4,7 +4,7 @@ version: v1-20150401 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.p.raml b/oic.wk.p.raml index dae913a..d0aa0bf 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -4,7 +4,7 @@ version: v1-20150804 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index 4f29bff..b24e52e 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -4,7 +4,7 @@ version: v1-20150814 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.res.raml b/oic.wk.res.raml index 795e98d..7b2756d 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -4,7 +4,7 @@ version: v1-20150807 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index 3bc5609..7fd052b 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -4,7 +4,7 @@ version: v1-20150811 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/rdpublish.raml b/rdpublish.raml index 6e711f8..07d7d0a 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -5,7 +5,7 @@ version: 1.0-090215 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/rules.raml b/rules.raml index d24a1ee..74f0e64 100755 --- a/rules.raml +++ b/rules.raml @@ -4,7 +4,7 @@ version: v1.0-20150810 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/scene.raml b/scene.raml index 8800d19..77fbedc 100755 --- a/scene.raml +++ b/scene.raml @@ -4,7 +4,7 @@ version: v1.0-20150630 documentation: - title: OCF Copyright - content: !include COPYRIGHT.md + content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - title: OCF License content: !include LICENSE.md - title: OCF Disclaimer diff --git a/schemas/DISCLAIMER.md b/schemas/DISCLAIMER.md new file mode 100644 index 0000000..1ceb458 --- /dev/null +++ b/schemas/DISCLAIMER.md @@ -0,0 +1 @@ +THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/schemas/LICENSE.md b/schemas/LICENSE.md new file mode 100644 index 0000000..0e4811b --- /dev/null +++ b/schemas/LICENSE.md @@ -0,0 +1,3 @@ +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. From c903c1e4ad352d9a52fc31a1d211f0f6d257f127 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Wed, 23 Mar 2016 00:28:02 +0100 Subject: [PATCH 14/55] Replace all OIC occurences by OCF in legal content. --- DISCLAIMER.md | 2 +- schemas/DISCLAIMER.md | 2 +- schemas/oic.collection-schema.json | 2 +- schemas/oic.core-schema.json | 2 +- schemas/oic.oic-link-schema.json | 2 +- schemas/oic.rd.publish-schema.json | 2 +- schemas/oic.rd.selection-schema.json | 2 +- schemas/oic.rule-Update-schema.json | 2 +- schemas/oic.rule-schema.json | 2 +- schemas/oic.ruleMember-schema.json | 2 +- schemas/oic.sceneCollection-Update-schema.json | 2 +- schemas/oic.sceneCollection-schema.json | 2 +- schemas/oic.sceneMember-schema.json | 2 +- schemas/oic.wk.con-schema.json | 2 +- schemas/oic.wk.d-schema.json | 2 +- schemas/oic.wk.ifs-schema.json | 2 +- schemas/oic.wk.mnt-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 2 +- schemas/oic.wk.p-schema.json | 2 +- schemas/oic.wk.ping-schema.json | 2 +- schemas/oic.wk.res-schema.json | 2 +- schemas/oic.wk.rts-schema.json | 2 +- 22 files changed, 22 insertions(+), 22 deletions(-) diff --git a/DISCLAIMER.md b/DISCLAIMER.md index 1ceb458..4e81410 100644 --- a/DISCLAIMER.md +++ b/DISCLAIMER.md @@ -1 +1 @@ -THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +THIS SOFTWARE IS PROVIDED BY THE OPEN CONNECTIVITY FOUNDATION, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN CONNECTIVITY FOUNDATION, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/schemas/DISCLAIMER.md b/schemas/DISCLAIMER.md index 1ceb458..4e81410 100644 --- a/schemas/DISCLAIMER.md +++ b/schemas/DISCLAIMER.md @@ -1 +1 @@ -THIS SOFTWARE IS PROVIDED BY THE OPEN INTERCONNECT CONSORTIUM, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN INTERCONNECT CONSORTIUM, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +THIS SOFTWARE IS PROVIDED BY THE OPEN CONNECTIVITY FOUNDATION, INC. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE OR WARRANTIES OF NON-INFRINGEMENT, ARE DISCLAIMED. IN NO EVENT SHALL THE OPEN CONNECTIVITY FOUNDATION, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 98ec196..c75a551 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.collection-schema.json#", "title": "Collection", "definitions": { diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index dd3a531..e52a35e 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -1,7 +1,7 @@ { "id": "http://openconnectivityfoundation.org/core/schemas/oic.core-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "title": "Core", "definitions": { "oic.core": { diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 6e00cc5..164b1d7 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/rm/oic.oic-link-schema.json", "type": "object", "properties": { diff --git a/schemas/oic.rd.publish-schema.json b/schemas/oic.rd.publish-schema.json index cd68f78..2e1ad10 100755 --- a/schemas/oic.rd.publish-schema.json +++ b/schemas/oic.rd.publish-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.publish-schema.json#", "title": "RD Publish & Update", "definitions": { diff --git a/schemas/oic.rd.selection-schema.json b/schemas/oic.rd.selection-schema.json index 55c0141..afd3b47 100755 --- a/schemas/oic.rd.selection-schema.json +++ b/schemas/oic.rd.selection-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.selection-schema.json#", "title" : "RD Selection", "definitions": { diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index 699dd12..19ac15e 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index fa824e9..cd627a6 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json index 09504ed..a419060 100755 --- a/schemas/oic.ruleMember-schema.json +++ b/schemas/oic.ruleMember-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.ruleMember-schema.json#", "title" : "Rule Member", "definitions": { diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index 6ccb6f6..74a5931 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index 2ee8212..b73419b 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { diff --git a/schemas/oic.sceneMember-schema.json b/schemas/oic.sceneMember-schema.json index 8548b16..036b66e 100755 --- a/schemas/oic.sceneMember-schema.json +++ b/schemas/oic.sceneMember-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneMember-schema.json#", "title" : "Scene Member", "definitions": { diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index d6d6832..8aa900c 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -1,7 +1,7 @@ { "id": "http://openconnectivityfoundation.org/core/oic.wk.con-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "definitions": { "oic.wk.con": { "type": "object", diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index f5bec0b..f963b89 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.d-schema.json#", "definitions": { "oic.wk.d": { diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 1a7060d..2794016 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.ifs-schema.json#", "definitions": { "oic.wk.ifs": { diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index 2bd9681..a6ad65a 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.mnt-schema.json#", "definitions": { "oic.wk.mnt": { diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 3470242..b8e2142 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.mon-schema.json#", "definitions": { "oic.wk.mon": { diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 850d02c..7564a8e 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.p-schema.json#", "definitions": { "oic.wk.p": { diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index 1af7211..0801306 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.ping-schema.json#", "definitions": { "oic.wk.ping": { diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 7109fe9..e4dd568 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json/", "definitions": { "oic.res-links-schema.json": { diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 867696f..7ebb9dd 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -1,6 +1,6 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Interconnect Consortium, Inc. All rights reserved.", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/oic.wk.rts-schema.json#", "definitions": { "oic.wk.rts": { From 66b987251287a3f946fc7350fc769069ea00edc7 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Thu, 24 Mar 2016 11:50:40 +0100 Subject: [PATCH 15/55] All schemas id's include the 'schemas' folder and same document ref. Fixed the files that didn't have the 'schemas' subfolder in the id. Fixed the files that didn't have the '#' at the end of the id that indicates a same document reference. --- schemas/oic.oic-link-schema.json | 4 ++-- schemas/oic.wk.con-schema.json | 2 +- schemas/oic.wk.d-schema.json | 2 +- schemas/oic.wk.ifs-schema.json | 2 +- schemas/oic.wk.mnt-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 2 +- schemas/oic.wk.p-schema.json | 2 +- schemas/oic.wk.ping-schema.json | 2 +- schemas/oic.wk.res-schema.json | 2 +- schemas/oic.wk.rts-schema.json | 2 +- 10 files changed, 11 insertions(+), 11 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 164b1d7..b214f5d 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/rm/oic.oic-link-schema.json", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#", "type": "object", "properties": { "href": { @@ -65,4 +65,4 @@ } }, "required": [ "href", "rt", "if" ] -} \ No newline at end of file +} diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index 8aa900c..9c83ec4 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openconnectivityfoundation.org/core/oic.wk.con-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.con-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "definitions": { diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index f963b89..09fbcf3 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.d-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.d-schema.json#", "definitions": { "oic.wk.d": { "type": "object", diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 2794016..97c28dd 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.ifs-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.ifs-schema.json#", "definitions": { "oic.wk.ifs": { "type": "object", diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index a6ad65a..b31662e 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.mnt-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.mnt-schema.json#", "definitions": { "oic.wk.mnt": { "type": "object", diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index b8e2142..654a5d0 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.mon-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.mon-schema.json#", "definitions": { "oic.wk.mon": { "type": "object", diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 7564a8e..ee03b4f 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.p-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.p-schema.json#", "definitions": { "oic.wk.p": { "type": "object", diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index 0801306..e80d8db 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.ping-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.ping-schema.json#", "definitions": { "oic.wk.ping": { "type": "object", diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index e4dd568..c84fbb7 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json/", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json#", "definitions": { "oic.res-links-schema.json": { "type": "object", diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 7ebb9dd..0a8950d 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/oic.wk.rts-schema.json#", + "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.rts-schema.json#", "definitions": { "oic.wk.rts": { "type": "object", From 64fd9f00c954992b3477a11efce83c6eadc48be5 Mon Sep 17 00:00:00 2001 From: rabardini Date: Mon, 2 May 2016 09:09:42 -0700 Subject: [PATCH 16/55] Align schemas to OIC v1.1 changes Changes to various schema files to reflect alignment to OIC v1.1 reflected in various OIC Change Requests. --- schemas/oic.core-schema.json | 30 +++++-- schemas/oic.oic-link-schema.json | 143 +++++++++++++++++++------------ schemas/oic.wk.con-schema.json | 6 +- schemas/oic.wk.d-schema.json | 16 +++- schemas/oic.wk.ifs-schema.json | 12 ++- schemas/oic.wk.mnt-schema.json | 13 ++- schemas/oic.wk.mon-schema.json | 11 ++- schemas/oic.wk.p-schema.json | 19 +++- schemas/oic.wk.ping-schema.json | 8 +- schemas/oic.wk.res-schema.json | 12 +-- schemas/oic.wk.rts-schema.json | 12 ++- 11 files changed, 190 insertions(+), 92 deletions(-) diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index e52a35e..40b03e4 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -8,7 +8,14 @@ "type": "object", "properties": { "rt": { - "type": "string", + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "minItems" : 1, "description": "ReadOnly, Resource Type" }, "if": { @@ -16,25 +23,36 @@ "items": [ { "type" : "string", - "enum" : ["oic.if.def", "oic.if.ll", "oic.if.b", "oic.if.rp", "oic.if.p", "oic.if.a", "oic.if.s" ] + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] } ], "minItems": 1, "description": "ReadOnly, The interface set supported by this resource" }, "p": { - "type": "string", - "description": "ReadOnly, bitmap indicating observable and discoverable" + "description": "ReadOnly, JSON object containing a Bitmap indicating observable and discoverable", + "type": "object", + "properties": { + "bm": { + "type": "integer" + } + } }, "n": { "type": "string", - "description": "Friendly name of the resource" + "maxLength": 64, + "description": "ReadOnly, Friendly name of the resource" + }, + "id": { + "type": "string", + "maxLength": 64, + "description": "ReadOnly, Instance ID of this specific resource" } } } }, "type": "object", "allOf": [ - {"$ref": "#/definitions/oic.core"} + { "$ref": "#/definitions/oic.core"} ] } diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index b214f5d..ab7a159 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -2,67 +2,100 @@ "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#", - "type": "object", - "properties": { - "href": { - "type": "string", - "description": "RFC5988 style web-links serialized into JSON. This is the target URI", - "format": "uri" - }, - "rel": { - "type": "string", - "default": "advertises", - "description": "The relation of the target URI referenced by the link to the context URI" - }, - "rt": { - "type": "string", - "description": "Resource Type - A standard OIC specified or vendor defined resource type of the resource referenced by the target URI" - }, - "if": { - "type": "string", - "description": "Interface - The interfaces supported by the resource referenced by the target URI" - }, - "obs": { - "type": "boolean", - "description": "Specifies if the resource referenced by the target URIis observable or not", - "default": false - }, - "title": { - "type": "string", - "description": "A title for the link relation. Can be used by the UI to provide a context" - }, - "anchor": { - "type": "string", - "description": "This is used to override the context URI e.g. override the URI of the containing collection", - "format": "uri" - }, - "ins": { - "oneOf": [ - { - "type": "integer", - "description": "An ordinal number that is not repeated - must be unique in the collection context" + "definitions": { + "oic.oic-link": { + "type": "object", + "properties": { + "href": { + "type": "string", + "maxLength": 256, + "description": "RFC5988 style web-links serialized into JSON. This is the target URI", + "format": "uri" }, - { + "rel": { "type": "string", - "description": "Any unique string including a URI" + "default": "advertises", + "maxLength": 64, + "description": "The relation of the target URI referenced by the link to the context URI" + }, + "rt": { + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "minItems" : 1, + "description": "ReadOnly, Resource Type" }, - { + "if": { + "type": "array", + "items": [ + { + "type" : "string", + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] + } + ], + "minItems": 1, + "description": "ReadOnly, The interface set supported by this resource" + }, + "p": { + "description": "ReadOnly, JSON object containing a Bitmap indicating observable and discoverable", + "type": "object", + "properties": { + "bm": { + "type": "integer" + } + } + }, + "title": { "type": "string", - "format": "uuid", - "description": "Use UUID for universal uniqueness - used in /oic/res to identify the device" + "maxLength": 64, + "description": "A title for the link relation. Can be used by the UI to provide a context" + }, + "anchor": { + "type": "string", + "maxLength": 256, + "description": "This is used to override the context URI e.g. override the URI of the containing collection", + "format": "uri" + }, + "ins": { + "oneOf": [ + { + "type": "integer", + "description": "An ordinal number that is not repeated - must be unique in the collection context" + }, + { + "type": "string", + "maxLength": 256, + "format" : "uri", + "description": "Any unique string including a URI" + }, + { + "type": "string", + "format": "uuid", + "description": "Use UUID for universal uniqueness - used in /oic/res to identify the device" + } + ], + "description": "The instance identifier for this web link in an array of web links - used in collections" + }, + "ttl": { + "type": "integer", + "description": "The time to live for this link in seconds - value is specified in a request only and is not returned on response. Max integer size to represent time is 4 octets" + }, + "type": { + "type": "string", + "maxLength": 64, + "description": "A hint at the representation of the resource referenced by the target URI", + "default": "application/json" } - ], - "description": "The instance identifier for this web link in an array of web links - used in collections" - }, - "ttl": { - "type": "integer", - "description": "The time to live for this link in seconds - value is specified in a request only and is not returned on response. Max integer size to represent time is 4 octets" - }, - "type": { - "type": "string", - "description": "A hint at the representation of the resource referenced by the target URI", - "default": "application/json" + } } }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.oic-link" } + ], "required": [ "href", "rt", "if" ] } diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index 9c83ec4..dd032c2 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -8,6 +8,7 @@ "properties": { "n": { "type": "string", + "maxLength": 64, "description": "Human friendly name" }, "loc": { @@ -17,14 +18,17 @@ }, "locn": { "type": "string", + "maxLength": 64, "description": "Human Friendly Name" }, "c": { "type": "string", + "maxLength": 64, "description": "Currency" }, "r": { "type": "string", + "maxLength": 64, "description": "Region" } } @@ -32,7 +36,7 @@ }, "type": "object", "allOf": [ - {"$ref": "oic.core-schema.json#/definitions/oic.core"}, + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.con" } ], "required": [ "n" ] diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 09fbcf3..8af0a11 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -8,6 +8,7 @@ "properties": { "n": { "type": "string", + "maxLength": 64, "description": "Readonly, Human friendly name" }, "di": { @@ -17,19 +18,26 @@ }, "icv": { "type": "string", + "maxLength": 64, "description": "ReadOnly, The version of the OIC Server" }, "dmv": { - "type": "string", - "description": "ReadOnly, The spec version of the vertical specification", - "format": "csv" + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "description": "ReadOnly, The spec version of the vertical specification" } } } }, "type": "object", "allOf": [ + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.d" } ], - "required": [ "n", "di", "icv" ] + "required": [ "n", "di", "icv", "dmv" ] } diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 97c28dd..e35e85f 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -7,15 +7,21 @@ "type": "object", "properties": { "il": { - "type": "string", - "description": "Readonly, list of interface names", - "format": "bsv" + "type": "array", + "items" : [ + { + "type" : "string", + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] + } + ], + "description": "Readonly, list of interface names" } } } }, "type": "object", "allOf": [ + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.ifs" } ], "required": ["il"] diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index b31662e..d64b43d 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -5,6 +5,12 @@ "definitions": { "oic.wk.mnt": { "type": "object", + "properties": { + "n": { + "type" : "string", + "maxLength" : 64, + "description": "Name" + }, "fr":{ "type": "boolean", "description": "Factory Reset" @@ -18,11 +24,12 @@ "description": "Start Stat Collection Action Toggle" } } + } }, "type": "object", "allOf": [ - {"$ref": "http://openconnectivityfoundation.org/core/oic.core-schema.json#/definitions/oic.core"}, - {"$ref": "#/definitions/oic.wk.mnt" } + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, + { "$ref": "#/definitions/oic.wk.mnt" } ], - "required": ["fr", "rb", "ssc"] + "required": ["fr"] } diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 654a5d0..6783e0a 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -15,9 +15,14 @@ "description": "ReadOnly, Indicates the elapsed time in seconds after the device was invoked or acted upon" }, "ds": { - "type": "string", - "description": "ReadOnly, Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)", - "format": "csv" + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "description": "ReadOnly, Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index ee03b4f..09de7cf 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -8,59 +8,72 @@ "properties": { "pi": { "type": "string", + "format" : "uuid", "description": "ReadOnly, Platform Identifier" }, "mnmn": { "type": "string", "description": "ReadOnly, Manufacturer Name", - "maxLength": 16 + "maxLength": 64 }, "mnml": { "type": "string", "description": "ReadOnly, Manufacturer's URL", - "maxLength": 32, + "maxLength": 256, "format": "uri" }, "mnmo": { "type": "string", + "maxLength": 64, "description": "ReadOnly, Model number as designated by manufacturer" }, "mndt": { "type": "string", "description": "ReadOnly, Manufacturing Date", - "format": "date-time" + "format": "date" }, "mnpv": { "type": "string", + "maxLength": 64, "description": "ReadOnly, Platform Version" }, "mnos": { "type": "string", + "maxLength": 64, "description": "Readonly, Platform Resident OS Version" }, "mnhw": { "type": "string", + "maxLength": 64, "description": "Readonly, Platform Hardware Version" }, "mnfv": { "type": "string", + "maxLength": 64, "description": "ReadOnly, Manufacturer's firmware version" }, "mnsl": { "type": "string", "description": "ReadOnly, Manufacturer's Support Information URL", + "maxLength": 256, "format": "uri" }, "st": { "type": "string", "description": "ReadOnly, Reference time for the device", "format": "date-time" + }, + "vid": { + "type": "string", + "maxLength": 64, + "description": "ReadOnly, Manufacturer's defined string for the platform. The string is freeform and up to the manufacturer on what text to populate it" } } } }, "type": "object", "allOf": [ + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.p" } ], "required": [ "pi", "mnmn" ] diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index e80d8db..96f4b48 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -15,12 +15,8 @@ }, "type": "object", "allOf": [ - { - "$ref": "oic.core-schema.json#/definitions/oic.core" - }, - { - "$ref": "#/definitions/oic.wk.ping" - } + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, + { "$ref": "#/definitions/oic.wk.ping"} ], "required": [ "in" diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index c84fbb7..aa486c4 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -3,26 +3,28 @@ "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json#", "definitions": { - "oic.res-links-schema.json": { + "oic.res-links.json": { "type": "object", "properties": { "n": { "type": "string", + "maxLength": 64, "description": "ReadOnly, Human friendly name" }, "di": { "description": "The device identifier as indicated by the /oic/d resource of the device", "type": "string", - "format": "UUID" + "format": "uuid" }, "mpro": { "description": "ReadOnly, Supported messaging protocols", - "type": "string" + "type": "string", + "maxLength": 64 }, "links": { "type": "array", "items": { - "$ref": "oic.oic-link-schema.json#" + "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" } } } @@ -31,7 +33,7 @@ "description": "The list of resources expressed as OIC links", "type": "array", "items": { - "$ref": "#/definitions/oic.res-links-schema.json" + "$ref": "#/definitions/oic.res-links.json" }, "required": ["di", "links"] } diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 0a8950d..9edfeed 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -7,15 +7,21 @@ "type": "object", "properties": { "tl": { - "type": "string", - "description": "Readonly, list of resource type names", - "format": "bsv" + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "description": "Readonly, list of resource type names" } } } }, "type": "object", "allOf": [ + { "$ref": "oic.core-schema.json#/definitions/oic.core"}, { "$ref": "#/definitions/oic.wk.rts" } ], "required": ["tl"] From 03ce288c9a35d0d1ef55d4da9dd93d83138658fb Mon Sep 17 00:00:00 2001 From: rabardini Date: Thu, 23 Jun 2016 06:57:31 -0700 Subject: [PATCH 17/55] v1.1.0 --- oic.wk.con.raml | 14 ++--- oic.wk.d.raml | 15 ++--- oic.wk.ifs.raml | 14 ++--- oic.wk.mnt.raml | 12 ++-- oic.wk.mon.raml | 14 ++--- oic.wk.p.raml | 16 ++--- oic.wk.ping.raml | 14 ++--- oic.wk.res.raml | 28 +++++---- oic.wk.rts.raml | 14 ++--- rdpublish.raml | 33 +++++----- rules.raml | 12 ++-- scene.raml | 12 ++-- schemas/oic.core-schema.json | 9 --- schemas/oic.oic-link-schema.json | 63 ++++++++++++++----- schemas/oic.rule-Update-schema.json | 2 +- schemas/oic.rule-schema.json | 2 +- .../oic.sceneCollection-Update-schema.json | 6 +- schemas/oic.sceneCollection-schema.json | 6 +- schemas/oic.wk.con-schema.json | 3 +- schemas/oic.wk.d-schema.json | 15 ++--- schemas/oic.wk.p-schema.json | 4 +- schemas/oic.wk.res-schema.json | 10 +-- 22 files changed, 170 insertions(+), 148 deletions(-) diff --git a/oic.wk.con.raml b/oic.wk.con.raml index 391d25d..2bc4537 100755 --- a/oic.wk.con.raml +++ b/oic.wk.con.raml @@ -1,6 +1,6 @@ #%RAML 0.8 title: OIC Configuration -version: v1-20150807 +version: v1-20160622 documentation: - title: OCF Copyright @@ -13,19 +13,19 @@ documentation: schemas: - Configuration: !include schemas/oic.wk.con-schema.json - - + + traits: - interface: queryParameters: if: - enum: ["oic.if.rw"] + enum: ["oic.if.rw", "oic.if.baseline"] /oic/con: displayName: OIC Configuration is: [ interface ] description: | - Known resource that is hosted by every OIC Server. + Known resource that is hosted by every Server. Allows for device specific information to be configured. get: @@ -38,7 +38,7 @@ traits: schema: Configuration example: | { - "rt": "oic.wk.con", + "rt": ["oic.wk.con"], "n": "My Friendly Device Name", "loc": "My Location Information", "locn": "My Location Name", @@ -48,7 +48,7 @@ traits: post: description: | - Update the information about the OIC device + Update the information about the Device body: application/json: schema: Configuration diff --git a/oic.wk.d.raml b/oic.wk.d.raml index a0d76e5..9e51e49 100755 --- a/oic.wk.d.raml +++ b/oic.wk.d.raml @@ -1,6 +1,6 @@ #%RAML 0.8 title: OIC Root Device -version: v1-20150811 +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,17 +17,17 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/d: - displayName: OIC Logical Device + displayName: Device is: [ interface ] description: | - Known resource that is hosted by every OIC Server. + Known resource that is hosted by every Server. Allows for logical device specific information to be discovered. get: description: | - Retrieve the information about the OIC device + Retrieve the information about the Device responses: 200: body: @@ -36,7 +36,8 @@ traits: example: | { "n": "Device 1", - "rt": "oic.wk.d", + "rt": ["oic.wk.d"], "di": "54919CA5-4101-4AE4-595B-353C51AA983C", - "icv": "OIC 1.0" + "icv": "core.1.1.0", + "dmv": "res.1.1.0" } diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml index efb933e..4daa522 100755 --- a/oic.wk.ifs.raml +++ b/oic.wk.ifs.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Interface Types -version: v1-20150811 +title: Interface Types +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,13 +17,13 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/ifs: - displayName: OIC Inteface Types + displayName: Inteface Types is: [ interface ] description: | - List of resource interfaces that are supported by this OIC Server + List of resource interfaces that are supported by this Server get: description: Retrieve the resource interface list responses: @@ -33,6 +33,6 @@ traits: schema: IFS example: | { - "rt": "oic.wk.ifs", - "il": "oic.if.ll oic.if.bat oic.if.r" + "rt": ["oic.wk.ifs"], + "il": ["oic.if.ll", "oic.if.b", "oic.if.r"] } diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index 3cc575f..d2b5847 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Maintenance -version: v1-20150811 +title: Maintenance +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,13 +17,13 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/mnt: - displayName: OIC Maintenance + displayName: Maintenance is: [ interface ] description: | - The resource through which an OIC Device is maintained and can be used for diagnostic purposes. + The resource through which an Device is maintained and can be used for diagnostic purposes. fr (Factory Reset) is a boolean. The value 0 means No action (Default), the value 1 means Start Factory Reset After factory reset, this value shall be changed back to the default value @@ -45,7 +45,7 @@ traits: schema: MNT example: | { - "rt": "oic.wk.mnt", + "rt": ["oic.wk.mnt"], "n": "My Maintenance Actions", "fr": false, "rb": false, diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml index ef9e54b..d3a6efa 100755 --- a/oic.wk.mon.raml +++ b/oic.wk.mon.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Monitoring -version: v1-20150401 +title: Monitoring +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,13 +17,13 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/mon: - displayName: OIC Monitoring + displayName: Monitoring is: [ interface ] description: | - The resource through which an OIC Device is monitored. + The resource through which an Device is monitored. get: description: Retrieve the monitor information responses: @@ -33,9 +33,9 @@ traits: schema: MON example: | { - "rt": "oic.wk.mon", + "rt": ["oic.wk.mon"], "name": "My Monitor Information", "av": true, "lat": 50, - "ds": "1500, 2750, 0" + "ds": ["1500", "2750", "0"] } diff --git a/oic.wk.p.raml b/oic.wk.p.raml index d0aa0bf..7b1f09a 100755 --- a/oic.wk.p.raml +++ b/oic.wk.p.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Base Platform -version: v1-20150804 +title: Platform +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,17 +17,17 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/p: - displayName: OIC Base Platform + displayName: Platform is: [ interface ] description: | - Known resource that is defines the platform on which an OIC Server is hosted. + Known resource that is defines the platform on which an Server is hosted. Allows for platform specific information to be discovered. get: description: | - Retrieve the information about the OIC Platform + Retrieve the information about the Platform responses: 200: @@ -36,7 +36,7 @@ traits: schema: Platform example: | { - "pi": "my-platform-identfier", - "rt": "oic.wk.p", + "pi": "54919CA5-4101-4AE4-595B-353C51AA983C", + "rt": ["oic.wk.p"], "mnmn": "Acme, Inc" } diff --git a/oic.wk.ping.raml b/oic.wk.ping.raml index b24e52e..87bdc94 100755 --- a/oic.wk.ping.raml +++ b/oic.wk.ping.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Ping -version: v1-20150814 +title: Ping +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,13 +17,13 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.rw"] + enum: ["oic.if.rw", "oic.if.baseline"] /oic/ping: - displayName: OIC Ping + displayName: Ping is: [ interface ] description: | - The resource using which an OIC Client keeps its Connection with an OIC Server active. + The resource using which an Client keeps its Connection with an Server active. get: description: Retrieve the ping information responses: @@ -33,7 +33,7 @@ traits: schema: PING example: | { - "rt": "oic.wk.ping", - "name": "Ping Information", + "rt": ["oic.wk.ping"], + "n": "Ping Information", "in": 16 } diff --git a/oic.wk.res.raml b/oic.wk.res.raml index 7b2756d..8998d4d 100755 --- a/oic.wk.res.raml +++ b/oic.wk.res.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Discoverable Resources -version: v1-20150807 +title: Discoverable Resources +version: v1-20160622 documentation: - title: OCF Copyright @@ -13,17 +13,18 @@ documentation: schemas: - Resources: !include schemas/oic.wk.res-schema.json + traits: - interface: queryParameters: if: - enum: ["oic.if.ll"] + enum: ["oic.if.ll", "oic.if.baseline"] /oic/res: - displayName: OIC Discoverable Resources + displayName: Discoverable Resources is: [ interface ] description: | - The resource through which the corresponding OIC Server is discovered and introspected for available resources. + The resource through which the corresponding Server is discovered and introspected for available resources. get: description: | Retrieve the discoverable resource set @@ -34,21 +35,24 @@ traits: application/json: schema: Resources example: | - [{ - "rt": "oic.wk.res", + [ + { + "rt": ["oic.wk.res"], "di": "0685B960-736F-46F7-BEC0-9E6CBD61ADC1", "links": [ { "href": "/res", "rel": "self", - "rt": "oic.r.collection", - "if": "oic.if.ll" }, + "rt": ["oic.r.collection"], + "if": ["oic.if.ll"] + }, { "href": "/smartDevice", "rel": "contained", - "rt": "oic.d.smartDevice", - "if": "oic.if.a" + "rt": ["oic.d.smartDevice"], + "if": ["oic.if.a"] } ] - }] + } + ] diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml index 7fd052b..0af8b13 100755 --- a/oic.wk.rts.raml +++ b/oic.wk.rts.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OIC Resource Types -version: v1-20150811 +title: Resource Types +version: v1-20160622 documentation: - title: OCF Copyright @@ -17,14 +17,14 @@ traits: - interface: queryParameters: if: - enum: ["oic.if.r"] + enum: ["oic.if.r", "oic.if.baseline"] /oic/rts: - displayName: OIC Resource Types + displayName: Resource Types is: [ interface ] description: | - List of resource types that are supported by this OIC Server + List of resource types that are supported by this Server get: description: Retrieve the resource type list responses: @@ -34,6 +34,6 @@ traits: schema: RTS example: | { - "rt": "oic.wk.rts", - "tl": "oic.r.example oic.r.other-example" + "rt": ["oic.wk.rts"], + "tl": ["oic.r.example", "oic.r.other-example"] } diff --git a/rdpublish.raml b/rdpublish.raml index 07d7d0a..8a7f346 100755 --- a/rdpublish.raml +++ b/rdpublish.raml @@ -1,7 +1,7 @@ #%RAML 0.8 -#RAML for OIC Resource Directory +#RAML for Resource Directory title: Resource Directory -version: 1.0-090215 +version: v1-20160622 documentation: - title: OCF Copyright @@ -11,33 +11,32 @@ documentation: - title: OCF Disclaimer content: !include DISCLAIMER.md - - title: OIC Rsource Directory + - title: Resource Directory content: | - A Resoure Directory is an OIC Device that helps other OIC Devices to be discovered. + A Resoure Directory is an Device that helps other Devices to be discovered. - title: Introduction content: | - For resource in other OIC Devices to be discovered using the Resource Directory, these other devices have to publish the resource links they would otherwise have advertised through /oic/res to the Resource Directory. Once the information has been published then the OIC Devices may stop responding to discovery queries and may also go to sleep. + For resource in other Devices to be discovered using the Resource Directory, these other devices have to publish the resource links they would otherwise have advertised through /oic/res to the Resource Directory. Once the information has been published then the Devices may stop responding to discovery queries and may also go to sleep. The Resource Directory will respond to all discovery queries with resources that it directly advertises and also the resource information that has been published to it. - title: Resource Directory discovery content: | - Before an OIC Device publishes its resource information, it must first discover available Resource Directories and then select one of those to publish the information to. + Before a Device publishes its resource information, it must first discover available Resource Directories and then select one of those to publish the information to. - This doscovery is done with a multicast query to /oic/rd. The information returned is either a bais factor or a list of attributes that help the discovering OIC Device to select one of the RDs. This RD will be used till the RD does not respond or another RD is selected. + This doscovery is done with a multicast query to /oic/rd. The information returned is either a bais factor or a list of attributes that help the discovering Device to select one of the RDs. This RD will be used till the RD does not respond or another RD is selected. - title: Resource Directory publish content: | - Once the RD has been discovery and selected, the OIC Device can publish its resoure information. The resource information are published to the /oic/rd resource using the "publish" interface. The information that needs to tbe available in /oic/res is then populated by the Resource Directory. + Once the RD has been discovery and selected, the Device can publish its resoure information. The resource information are published to the /oic/rd resource using the "publish" interface. The information that needs to tbe available in /oic/res is then populated by the Resource Directory. - Periodically based on the TTL set by the publishing OIC Device, the information that is published has to be refreshed with a new TTL or the TTL can be updated if there is no change in the information. It is the responsibility of the publishing OIC Device to ensure that the information or TTL is updated before the previous TTL expires; failing this the RD will garbage collect all the information related to the publishing OIC Device. + Periodically based on the TTL set by the publishing Device, the information that is published has to be refreshed with a new TTL or the TTL can be updated if there is no change in the information. It is the responsibility of the publishing Device to ensure that the information or TTL is updated before the previous TTL expires; failing this the RD will garbage collect all the information related to the publishing Device. - title: Resource discovery content: | - The discovery of resources is done in the same manner as for any OIC Server. A query to /oic/res either over multicast or uincast is required. + The discovery of resources is done in the same manner as for any Server. A query to /oic/res either over multicast or uincast is required. schemas: -- # Each schema represents an OIC Resource Type. The baseline interface operates on the entire representation - rdPublish: !include schemas/oic.rd.publish-schema.json - rdSelection: !include schemas/oic.rd.selection-schema.json +- rdPublish: !include schemas/oic.rd.publish-schema.json +- rdSelection: !include schemas/oic.rd.selection-schema.json # rdDelLink: !include schemas/oic.rd.del-link-schema.json traits: @@ -45,7 +44,7 @@ traits: queryParameters: if: description: | - Interface is optional since there is only one interface supported for the OIC Resource Type + Interface is optional since there is only one interface supported for the Resource Type Both for RD selectin and for publish type: string enum: [ "oic.if.baseline" ] @@ -57,14 +56,14 @@ traits: /oic/rd: displayName: Resource directory resource description: | - Resource to be exposed by any OIC Device that can act as a Resource Directory + Resource to be exposed by any Device that can act as a Resource Directory get: description: | Get the attributes of the Resource Directory for selection purposes. queryParameters: rt: description: | - Only one OIC Resource Type is used for GET; OIC RT is optional + Only one Resource Type is used for GET; RT is optional type: string enum: [ "oic.wk.rd" ] default: "oic.wk.rd" @@ -94,7 +93,7 @@ traits: queryParameters: rt: description: | - Only one OIC Resource Type is used for GET; OIC RT is optional + Only one Resource Type is used for GET; RT is optional type: string enum: [ "oic.wk.rdpub" ] default: "oic.wk.rdpub" diff --git a/rules.raml b/rules.raml index 74f0e64..cf04214 100755 --- a/rules.raml +++ b/rules.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OICRules -version: v1.0-20150810 +title: Rules +version: v1-20160622 documentation: - title: OCF Copyright @@ -13,15 +13,15 @@ documentation: schemas: - Collection: !include schemas/oic.collection-schema.json - Rule: !include schemas/oic.rule-schema.json - RuleUpdate: !include schemas/oic.rule-Update-schema.json - RuleMember: !include schemas/oic.ruleMember-schema.json + - Rule: !include schemas/oic.rule-schema.json + - RuleUpdate: !include schemas/oic.rule-Update-schema.json + - RuleMember: !include schemas/oic.ruleMember-schema.json traits: - interface: queryParameters: if: - enum: ["oic.if.a", "oic.if.ll"] + enum: ["oic.if.a", "oic.if.ll", "oic.if.baseline"] /RuleListResURI: diff --git a/scene.raml b/scene.raml index 77fbedc..f59aabd 100755 --- a/scene.raml +++ b/scene.raml @@ -1,6 +1,6 @@ #%RAML 0.8 -title: OICScene -version: v1.0-20150630 +title: Scene +version: v1-20160622 documentation: - title: OCF Copyright @@ -13,15 +13,15 @@ documentation: schemas: - Collection: !include schemas/oic.collection-schema.json - SceneCollection: !include schemas/oic.sceneCollection-schema.json - SceneCollectionUpdate: !include schemas/oic.sceneCollection-Update-schema.json - SceneMember: !include schemas/oic.sceneMember-schema.json + - SceneCollection: !include schemas/oic.sceneCollection-schema.json + - SceneCollectionUpdate: !include schemas/oic.sceneCollection-Update-schema.json + - SceneMember: !include schemas/oic.sceneMember-schema.json traits: - interface: queryParameters: if: - enum: ["oic.if.a", "oic.if.ll"] + enum: ["oic.if.a", "oic.if.ll", "oic.if.baseline"] /SceneListResURI: diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index 40b03e4..29a5c33 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -29,15 +29,6 @@ "minItems": 1, "description": "ReadOnly, The interface set supported by this resource" }, - "p": { - "description": "ReadOnly, JSON object containing a Bitmap indicating observable and discoverable", - "type": "object", - "properties": { - "bm": { - "type": "integer" - } - } - }, "n": { "type": "string", "maxLength": 64, diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index ab7a159..55c6c4b 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -9,7 +9,7 @@ "href": { "type": "string", "maxLength": 256, - "description": "RFC5988 style web-links serialized into JSON. This is the target URI", + "description": "This is the target URI – can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", "format": "uri" }, "rel": { @@ -40,15 +40,46 @@ "minItems": 1, "description": "ReadOnly, The interface set supported by this resource" }, + "di": { + "type": "string", + "description": "The Device ID on which the Relative Reference in href is to be resolved on. Base URI should be used in preference where possible", + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" + }, + "buri": { + "type": "string", + "description": "The base URI used to fully qualify a Relative Reference in the href parameter. Use the OCF Schema for URI", + "maxLength": 256, + "format": "uri" + }, "p": { - "description": "ReadOnly, JSON object containing a Bitmap indicating observable and discoverable", + "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI", "type": "object", "properties": { "bm": { + "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", "type": "integer" - } + }, + "sec": { + "description": "ReadOnly, Specifies if security needs to be turned on when looking to interact with the Resource", + "type": "boolean" + }, + "port": { + "description": "ReadOnly, Secure port to be used for connection", + "type": "integer" + }, + "required" : ["bm"] } }, + "bp": { + "type": "object", + "properties": { + "q": { + "type": "string", + "maxLength": 64, + "description": "This defines the query string to be used when batch request is forwarded through this Link" + } + } + }, "title": { "type": "string", "maxLength": 64, @@ -74,28 +105,30 @@ }, { "type": "string", - "format": "uuid", + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", "description": "Use UUID for universal uniqueness - used in /oic/res to identify the device" } ], "description": "The instance identifier for this web link in an array of web links - used in collections" }, - "ttl": { - "type": "integer", - "description": "The time to live for this link in seconds - value is specified in a request only and is not returned on response. Max integer size to represent time is 4 octets" - }, "type": { - "type": "string", - "maxLength": 64, - "description": "A hint at the representation of the resource referenced by the target URI", - "default": "application/json" + "type": "array", + "description": "A hint at the representation of the resource referenced by the target URI. This represents the media types that are used for both accepting and emitting", + "items" : [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": "application/cbor" } - } + }, + "required": [ "href", "rt", "if" ] } }, "type": "object", "allOf": [ { "$ref": "#/definitions/oic.oic-link" } - ], - "required": [ "href", "rt", "if" ] + ] } diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index 19ac15e..b7d563d 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, + { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, { "required" : [ "ins" ] } ] } diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index cd627a6..cabbe03 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -38,7 +38,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, + { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link#" }, { "required" : [ "ins" ] } ] } diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index 74a5931..969685c 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -23,8 +23,8 @@ "format": "UTF8" }, "id": { - "type": "string", - "description" : "A unique string that could be a hash or similarly unique" + "type": "string", + "description" : "A unique string that could be a hash or similarly unique" }, "rts": { "type": "string", @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, + { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, { "required" : [ "ins" ] } ] } diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index b73419b..c6d6fe8 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -23,8 +23,8 @@ "format": "UTF8" }, "id": { - "type": "string", - "description" : "A unique string that could be a hash or similarly unique" + "type": "string", + "description" : "A unique string that could be a hash or similarly unique" }, "rts": { "type": "string", @@ -36,7 +36,7 @@ "description": "Array of OIC web links that are reference from this collection", "items" : { "allOf": [ - { "$ref": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#" }, + { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, { "required" : [ "ins" ] } ] } diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index dd032c2..7467e0b 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -13,8 +13,7 @@ }, "loc": { "type": "string", - "description": "Location information", - "format": "json" + "description": "Location information" }, "locn": { "type": "string", diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 8af0a11..5c7ed16 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -13,8 +13,8 @@ }, "di": { "type": "string", - "description": "ReadOnly, Unique identifier for device (UUID)", - "format": "uuid" + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { "type": "string", @@ -22,14 +22,9 @@ "description": "ReadOnly, The version of the OIC Server" }, "dmv": { - "type": "array", - "items" : [ - { - "type" : "string", - "maxLength": 64 - } - ], - "description": "ReadOnly, The spec version of the vertical specification" + "type": "string", + "maxLength": 64, + "description": "ReadOnly, The spec version of the vertical and/or resource specification" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 09de7cf..af36a91 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -8,8 +8,8 @@ "properties": { "pi": { "type": "string", - "format" : "uuid", - "description": "ReadOnly, Platform Identifier" + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { "type": "string", diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index aa486c4..b06966b 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -12,9 +12,9 @@ "description": "ReadOnly, Human friendly name" }, "di": { - "description": "The device identifier as indicated by the /oic/d resource of the device", "type": "string", - "format": "uuid" + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { "description": "ReadOnly, Supported messaging protocols", @@ -27,13 +27,13 @@ "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" } } - } + }, + "required": ["di", "links"] } }, "description": "The list of resources expressed as OIC links", "type": "array", "items": { "$ref": "#/definitions/oic.res-links.json" - }, - "required": ["di", "links"] + } } From 7134324c41f323e7f2e1a48cc031a6c13c88a69c Mon Sep 17 00:00:00 2001 From: rabardini Date: Thu, 7 Jul 2016 21:18:59 -0700 Subject: [PATCH 18/55] v1.1.0 - Added Pattern --- schemas/oic.wk.p-schema.json | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index af36a91..a6cf1ad 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -29,8 +29,8 @@ }, "mndt": { "type": "string", - "description": "ReadOnly, Manufacturing Date", - "format": "date" + "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" }, "mnpv": { "type": "string", @@ -60,7 +60,8 @@ }, "st": { "type": "string", - "description": "ReadOnly, Reference time for the device", + "description": "ReadOnly, Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z)$", "format": "date-time" }, "vid": { From df3b50ff1c9485b70ec4913911159a0f2b7453e9 Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 12 Jul 2016 11:36:46 -0700 Subject: [PATCH 19/55] v1.1.0 - Fixed pattern syntax for mndt property. Added format for all uuids and date-time --- schemas/oic.wk.d-schema.json | 1 + schemas/oic.wk.res-schema.json | 1 + 2 files changed, 2 insertions(+) diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 5c7ed16..6214c64 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -14,6 +14,7 @@ "di": { "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "format": "uuid", "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index b06966b..843d479 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -14,6 +14,7 @@ "di": { "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "format": "uuid", "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { From 26780a7a848d1e9c38cd9119cdb9f5ba406f7ded Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 12 Jul 2016 11:38:05 -0700 Subject: [PATCH 20/55] v1.1.0 - Fixed pattern syntax for mndt property. Added format for all uuids and date-time --- schemas/oic.wk.p-schema.json | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index a6cf1ad..decde5c 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -9,6 +9,7 @@ "pi": { "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", + "format": "uuid", "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { @@ -30,7 +31,8 @@ "mndt": { "type": "string", "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$", + "format": "date-time" }, "mnpv": { "type": "string", @@ -61,7 +63,7 @@ "st": { "type": "string", "description": "ReadOnly, Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z)$", + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z$", "format": "date-time" }, "vid": { From 59f96f133bac0cdaae90dc72204e58b3e496934b Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 22 Jul 2016 17:36:13 +0200 Subject: [PATCH 21/55] Add readOnly property where appropriate in the json schema's. This change is to make the readOnly properties machine readable and is compliant with the JSON-hyper schema definition. See: http://json-schema.org/latest/json-schema-hypermedia.html#anchor15 --- schemas/oic.core-schema.json | 4 ++++ schemas/oic.oic-link-schema.json | 6 ++++++ schemas/oic.rule-Update-schema.json | 2 ++ schemas/oic.rule-schema.json | 2 ++ schemas/oic.ruleMember-schema.json | 2 ++ schemas/oic.sceneCollection-Update-schema.json | 2 ++ schemas/oic.sceneCollection-schema.json | 2 ++ schemas/oic.sceneMember-schema.json | 2 ++ schemas/oic.wk.d-schema.json | 3 +++ schemas/oic.wk.mon-schema.json | 3 +++ schemas/oic.wk.p-schema.json | 10 ++++++++++ schemas/oic.wk.res-schema.json | 3 +++ 12 files changed, 41 insertions(+) diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index 29a5c33..ab9bbfa 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -16,6 +16,7 @@ } ], "minItems" : 1, + "readOnly": true, "description": "ReadOnly, Resource Type" }, "if": { @@ -27,16 +28,19 @@ } ], "minItems": 1, + "readOnly": true, "description": "ReadOnly, The interface set supported by this resource" }, "n": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Friendly name of the resource" }, "id": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Instance ID of this specific resource" } } diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 55c6c4b..6f0052b 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -27,6 +27,7 @@ } ], "minItems" : 1, + "readOnly": true, "description": "ReadOnly, Resource Type" }, "if": { @@ -38,6 +39,7 @@ } ], "minItems": 1, + "readOnly": true, "description": "ReadOnly, The interface set supported by this resource" }, "di": { @@ -52,18 +54,22 @@ "format": "uri" }, "p": { + "readOnly": true, "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI", "type": "object", "properties": { "bm": { + "readOnly": true, "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", "type": "integer" }, "sec": { + "readOnly": true, "description": "ReadOnly, Specifies if security needs to be turned on when looking to interact with the Resource", "type": "boolean" }, "port": { + "readOnly": true, "description": "ReadOnly, Secure port to be used for connection", "type": "integer" }, diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index b7d563d..b5c1bd3 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -14,6 +14,7 @@ }, "currentStatus": { "type": "string", + "readOnly": true, "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" }, "n": { @@ -31,6 +32,7 @@ }, "rts": { "type": "string", + "readOnly": true, "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" }, "links": { diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index cabbe03..b3ad597 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -14,6 +14,7 @@ }, "currentStatus": { "type": "string", + "readOnly": true, "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" }, "n": { @@ -31,6 +32,7 @@ }, "rts": { "type": "string", + "readOnly": true, "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" }, "links": { diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json index a419060..3b168e6 100755 --- a/schemas/oic.ruleMember-schema.json +++ b/schemas/oic.ruleMember-schema.json @@ -18,6 +18,7 @@ }, "memberProperty": { "type": "string", + "readOnly": true, "description": "ReadOnly, property name that will be mapped" }, "memberValue": { @@ -26,6 +27,7 @@ { "type": "string", "description": "if member property is an number" }, { "type": "boolean", "description": "if member property is an boolean" } ], + "readOnly": true, "description": "ReadOnly, value of the Member Property" }, "link": { diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index 969685c..8db4e42 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -14,6 +14,7 @@ }, "sceneValues": { "type": "string", + "readOnly": true, "description": "ReadOnly, All available scene values", "format": "CSV" }, @@ -28,6 +29,7 @@ }, "rts": { "type": "string", + "readOnly": true, "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", "format": "UTF8" }, diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index c6d6fe8..2ba0cc7 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -14,6 +14,7 @@ }, "sceneValues": { "type": "string", + "readOnly": true, "description": "ReadOnly, All available scene values", "format": "CSV" }, @@ -28,6 +29,7 @@ }, "rts": { "type": "string", + "readOnly": true, "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", "format": "UTF8" }, diff --git a/schemas/oic.sceneMember-schema.json b/schemas/oic.sceneMember-schema.json index 036b66e..83f1fe1 100755 --- a/schemas/oic.sceneMember-schema.json +++ b/schemas/oic.sceneMember-schema.json @@ -29,10 +29,12 @@ }, "memberProperty": { "type": "string", + "readOnly": true, "description": "ReadOnly, property name that will be mapped" }, "memberValue": { "type": "string", + "readOnly": true, "description": "ReadOnly, value of the Member Property" } }, diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 6214c64..d33b760 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -15,16 +15,19 @@ "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", "format": "uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, The version of the OIC Server" }, "dmv": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, The spec version of the vertical and/or resource specification" } } diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 6783e0a..eee2e51 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -8,10 +8,12 @@ "properties": { "av":{ "type": "boolean", + "readOnly": true, "description": "ReadOnly, Indicates if the device is available or not on the network (like ping)" }, "lat": { "type": "integer", + "readOnly": true, "description": "ReadOnly, Indicates the elapsed time in seconds after the device was invoked or acted upon" }, "ds": { @@ -22,6 +24,7 @@ "maxLength": 64 } ], + "readOnly": true, "description": "ReadOnly, Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)" } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index decde5c..58dd64a 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -10,15 +10,18 @@ "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", "format": "uuid", + "readOnly": true, "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { "type": "string", + "readOnly": true, "description": "ReadOnly, Manufacturer Name", "maxLength": 64 }, "mnml": { "type": "string", + "readOnly": true, "description": "ReadOnly, Manufacturer's URL", "maxLength": 256, "format": "uri" @@ -26,10 +29,12 @@ "mnmo": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Model number as designated by manufacturer" }, "mndt": { "type": "string", + "readOnly": true, "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$", "format": "date-time" @@ -37,6 +42,7 @@ "mnpv": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Platform Version" }, "mnos": { @@ -52,16 +58,19 @@ "mnfv": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Manufacturer's firmware version" }, "mnsl": { "type": "string", + "readOnly": true, "description": "ReadOnly, Manufacturer's Support Information URL", "maxLength": 256, "format": "uri" }, "st": { "type": "string", + "readOnly": true, "description": "ReadOnly, Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z$", "format": "date-time" @@ -69,6 +78,7 @@ "vid": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Manufacturer's defined string for the platform. The string is freeform and up to the manufacturer on what text to populate it" } } diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 843d479..1f1b4b1 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -9,15 +9,18 @@ "n": { "type": "string", "maxLength": 64, + "readOnly": true, "description": "ReadOnly, Human friendly name" }, "di": { "type": "string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", "format": "uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { + "readOnly": true, "description": "ReadOnly, Supported messaging protocols", "type": "string", "maxLength": 64 From 4b100b488c7137a3d05be422c741164e01326964 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Thu, 4 Aug 2016 14:18:45 +0200 Subject: [PATCH 22/55] Change the id to comply with the OCF API design guidelines. sed -i "s/http:\/\/openconnectivityfoundation.org\//https:\/\/www.openconnectivity.org\/ocf-apis\//" --- schemas/oic.collection-schema.json | 2 +- schemas/oic.core-schema.json | 2 +- schemas/oic.oic-link-schema.json | 2 +- schemas/oic.rd.publish-schema.json | 2 +- schemas/oic.rd.selection-schema.json | 2 +- schemas/oic.rule-Update-schema.json | 2 +- schemas/oic.rule-schema.json | 2 +- schemas/oic.ruleMember-schema.json | 2 +- schemas/oic.sceneCollection-Update-schema.json | 2 +- schemas/oic.sceneCollection-schema.json | 2 +- schemas/oic.sceneMember-schema.json | 2 +- schemas/oic.wk.con-schema.json | 2 +- schemas/oic.wk.d-schema.json | 2 +- schemas/oic.wk.ifs-schema.json | 2 +- schemas/oic.wk.mnt-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 2 +- schemas/oic.wk.p-schema.json | 2 +- schemas/oic.wk.ping-schema.json | 2 +- schemas/oic.wk.res-schema.json | 2 +- schemas/oic.wk.rts-schema.json | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index c75a551..9c656c8 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.collection-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", "title": "Collection", "definitions": { "oic.collection.setoflinks": { diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index 29a5c33..4b075b7 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openconnectivityfoundation.org/core/schemas/oic.core-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.core-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "title": "Core", diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 55c6c4b..e1c6ab9 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.oic-link-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.oic-link-schema.json#", "definitions": { "oic.oic-link": { "type": "object", diff --git a/schemas/oic.rd.publish-schema.json b/schemas/oic.rd.publish-schema.json index 2e1ad10..ac3a2ea 100755 --- a/schemas/oic.rd.publish-schema.json +++ b/schemas/oic.rd.publish-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.publish-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rd.publish-schema.json#", "title": "RD Publish & Update", "definitions": { "oic.rd.publish": { diff --git a/schemas/oic.rd.selection-schema.json b/schemas/oic.rd.selection-schema.json index afd3b47..c8fd9bd 100755 --- a/schemas/oic.rd.selection-schema.json +++ b/schemas/oic.rd.selection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rd.selection-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rd.selection-schema.json#", "title" : "RD Selection", "definitions": { "oic.rd.attributes": { diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index b7d563d..354ec64 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { "oic.rule": { diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index cabbe03..013733b 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.rule-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rule-schema.json#", "title" : "Rule", "definitions": { "oic.rule": { diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json index a419060..cb1937b 100755 --- a/schemas/oic.ruleMember-schema.json +++ b/schemas/oic.ruleMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.ruleMember-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.ruleMember-schema.json#", "title" : "Rule Member", "definitions": { "oic.ruleMember": { diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index 969685c..3c992cc 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index c6d6fe8..f1e8077 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneCollection-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.sceneCollection-schema.json#", "title" : "Scene Collection", "definitions": { "oic.sceneCollection": { diff --git a/schemas/oic.sceneMember-schema.json b/schemas/oic.sceneMember-schema.json index 036b66e..3aec990 100755 --- a/schemas/oic.sceneMember-schema.json +++ b/schemas/oic.sceneMember-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.sceneMember-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.sceneMember-schema.json#", "title" : "Scene Member", "definitions": { "oic.sceneMember": { diff --git a/schemas/oic.wk.con-schema.json b/schemas/oic.wk.con-schema.json index 7467e0b..f3d6844 100755 --- a/schemas/oic.wk.con-schema.json +++ b/schemas/oic.wk.con-schema.json @@ -1,5 +1,5 @@ { - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.con-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.con-schema.json#", "$schema": "http://json-schema.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "definitions": { diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 6214c64..7ff3c1c 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.d-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.d-schema.json#", "definitions": { "oic.wk.d": { "type": "object", diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index e35e85f..0a0d7eb 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.ifs-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.ifs-schema.json#", "definitions": { "oic.wk.ifs": { "type": "object", diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index d64b43d..753ece5 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.mnt-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.mnt-schema.json#", "definitions": { "oic.wk.mnt": { "type": "object", diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 6783e0a..f73f739 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.mon-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.mon-schema.json#", "definitions": { "oic.wk.mon": { "type": "object", diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index decde5c..77ed1c7 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.p-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.p-schema.json#", "definitions": { "oic.wk.p": { "type": "object", diff --git a/schemas/oic.wk.ping-schema.json b/schemas/oic.wk.ping-schema.json index 96f4b48..c08e050 100755 --- a/schemas/oic.wk.ping-schema.json +++ b/schemas/oic.wk.ping-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.ping-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.ping-schema.json#", "definitions": { "oic.wk.ping": { "type": "object", diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 843d479..4c6bce4 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-v4/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.res-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.res-schema.json#", "definitions": { "oic.res-links.json": { "type": "object", diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 9edfeed..810f99b 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schemas.org/draft-04/schema#", "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "http://openconnectivityfoundation.org/core/schemas/oic.wk.rts-schema.json#", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.rts-schema.json#", "definitions": { "oic.wk.rts": { "type": "object", From 30ce83c69b2872465d064adc5c0896c3fdc49262 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 5 Aug 2016 16:26:25 +0200 Subject: [PATCH 23/55] The json schema format uuid is not a valid schema definition. Defined a new schema with the definition of uuid to use accross all the schemas that were defining format uuid and use the common definition. --- schemas/oic.collection-schema.json | 11 ++++------- schemas/oic.rd.selection-schema.json | 6 +++--- schemas/oic.types-schema.json | 11 +++++++++++ schemas/oic.wk.d-schema.json | 4 +--- schemas/oic.wk.p-schema.json | 4 +--- schemas/oic.wk.res-schema.json | 4 +--- 6 files changed, 21 insertions(+), 19 deletions(-) create mode 100644 schemas/oic.types-schema.json diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 9c656c8..3e13ce1 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -47,17 +47,15 @@ "description": "A unique string that could be a hash or similarly unique" }, { - "type": "string", - "format": "UUID", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "A unique string that could be a UUIDv4" } ], "description": "Id for each set of links i.e. tag. Can be an value that is unique to the use context or a UUIDv4" }, "di": { - "type": "string", - "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res", - "format": "UUID" + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res" } } } @@ -107,8 +105,7 @@ "description": "A unique string that could be a hash or similarly unique" }, { - "type": "string", - "format": "UUID", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "A unique string that could be a UUIDv4" } ], diff --git a/schemas/oic.rd.selection-schema.json b/schemas/oic.rd.selection-schema.json index c8fd9bd..bb3b371 100755 --- a/schemas/oic.rd.selection-schema.json +++ b/schemas/oic.rd.selection-schema.json @@ -13,9 +13,9 @@ "format": "UTF8" }, "di": { - "type": "string", - "description": "A unique identifier for the Resource Directory - the same as the device ID of the RD", - "format": "uuid" + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "A unique identifier for the Resource Directory - the same as the device ID of the RD" + }, "sel": { "description": "Selection criteria that a device wanting to publish to any RD can use to choose this Resource Directory over others that are discovered", diff --git a/schemas/oic.types-schema.json b/schemas/oic.types-schema.json new file mode 100644 index 0000000..860410c --- /dev/null +++ b/schemas/oic.types-schema.json @@ -0,0 +1,11 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.types-schema.json#", + "definitions" : { + "uuid": { + "type":"string", + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" + } + } +} diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 7ff3c1c..af659e4 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -12,9 +12,7 @@ "description": "Readonly, Human friendly name" }, "di": { - "type": "string", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", - "format": "uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 77ed1c7..9c905d3 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -7,9 +7,7 @@ "type": "object", "properties": { "pi": { - "type": "string", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", - "format": "uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 4c6bce4..3967d41 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -12,9 +12,7 @@ "description": "ReadOnly, Human friendly name" }, "di": { - "type": "string", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", - "format": "uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { From 4f8354c56d2664413793f46f4238ffb37ec2f62a Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 5 Aug 2016 15:10:05 +0200 Subject: [PATCH 24/55] Fix validator issue with the bm definition. "required" in bm should be declared as a keyword and not a property. --- schemas/oic.oic-link-schema.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 55c6c4b..03c9fd5 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -66,9 +66,9 @@ "port": { "description": "ReadOnly, Secure port to be used for connection", "type": "integer" - }, - "required" : ["bm"] - } + } + }, + "required" : ["bm"] }, "bp": { "type": "object", From 579e7cb03706396468f86ba3ab1f14a884d6f96c Mon Sep 17 00:00:00 2001 From: SiMet Date: Wed, 7 Sep 2016 12:06:38 +0200 Subject: [PATCH 25/55] Fix for excluding mndt format Remove format from mndt. --- schemas/oic.wk.p-schema.json | 1 - 1 file changed, 1 deletion(-) diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index a8a2d67..4167865 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -34,7 +34,6 @@ "readOnly": true, "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$", - "format": "date-time" }, "mnpv": { "type": "string", From a370b8b09d7ace90873a06dcb2754a3f7515881a Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 12 Sep 2016 22:00:52 +0200 Subject: [PATCH 26/55] Add some missing readOnly properties. --- schemas/oic.wk.d-schema.json | 4 +++- schemas/oic.wk.ifs-schema.json | 3 ++- schemas/oic.wk.p-schema.json | 7 +++++-- schemas/oic.wk.res-schema.json | 1 + schemas/oic.wk.rts-schema.json | 3 ++- 5 files changed, 13 insertions(+), 5 deletions(-) diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 5f1338f..7f8feb3 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -9,10 +9,12 @@ "n": { "type": "string", "maxLength": 64, - "description": "Readonly, Human friendly name" + "readOnly": true, + "description": "ReadOnly, Human friendly name" }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 0a0d7eb..b03e361 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -14,7 +14,8 @@ "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] } ], - "description": "Readonly, list of interface names" + "readOnly": true, + "description": "ReadOnly, list of interface names" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index a8a2d67..1a70bd9 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -8,6 +8,7 @@ "properties": { "pi": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { @@ -45,12 +46,14 @@ "mnos": { "type": "string", "maxLength": 64, - "description": "Readonly, Platform Resident OS Version" + "readOnly": true, + "description": "ReadOnly, Platform Resident OS Version" }, "mnhw": { "type": "string", "maxLength": 64, - "description": "Readonly, Platform Hardware Version" + "readOnly": true, + "description": "ReadOnly, Platform Hardware Version" }, "mnfv": { "type": "string", diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 073f4ab..1e38391 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -14,6 +14,7 @@ }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 810f99b..522aa90 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -14,7 +14,8 @@ "maxLength": 64 } ], - "description": "Readonly, list of resource type names" + "readOnly": true, + "description": "ReadOnly, list of resource type names" } } } From ff804fc6a1245ba4c256f8b362407b7e3e0903f0 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 12 Sep 2016 22:03:29 +0200 Subject: [PATCH 27/55] Remove ReadOnly from the description. --- schemas/oic.core-schema.json | 8 +++---- schemas/oic.oic-link-schema.json | 12 +++++----- schemas/oic.rule-Update-schema.json | 4 ++-- schemas/oic.rule-schema.json | 4 ++-- schemas/oic.ruleMember-schema.json | 4 ++-- .../oic.sceneCollection-Update-schema.json | 4 ++-- schemas/oic.sceneCollection-schema.json | 4 ++-- schemas/oic.sceneMember-schema.json | 4 ++-- schemas/oic.wk.d-schema.json | 8 +++---- schemas/oic.wk.ifs-schema.json | 2 +- schemas/oic.wk.mon-schema.json | 6 ++--- schemas/oic.wk.p-schema.json | 24 +++++++++---------- schemas/oic.wk.res-schema.json | 6 ++--- schemas/oic.wk.rts-schema.json | 2 +- 14 files changed, 46 insertions(+), 46 deletions(-) diff --git a/schemas/oic.core-schema.json b/schemas/oic.core-schema.json index 125cb55..7f89b2d 100755 --- a/schemas/oic.core-schema.json +++ b/schemas/oic.core-schema.json @@ -17,7 +17,7 @@ ], "minItems" : 1, "readOnly": true, - "description": "ReadOnly, Resource Type" + "description": "Resource Type" }, "if": { "type": "array", @@ -29,19 +29,19 @@ ], "minItems": 1, "readOnly": true, - "description": "ReadOnly, The interface set supported by this resource" + "description": "The interface set supported by this resource" }, "n": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Friendly name of the resource" + "description": "Friendly name of the resource" }, "id": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Instance ID of this specific resource" + "description": "Instance ID of this specific resource" } } } diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 70842d1..9123e2f 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -28,7 +28,7 @@ ], "minItems" : 1, "readOnly": true, - "description": "ReadOnly, Resource Type" + "description": "Resource Type" }, "if": { "type": "array", @@ -40,7 +40,7 @@ ], "minItems": 1, "readOnly": true, - "description": "ReadOnly, The interface set supported by this resource" + "description": "The interface set supported by this resource" }, "di": { "type": "string", @@ -55,22 +55,22 @@ }, "p": { "readOnly": true, - "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI", + "description": "Specifies the framework policies on the Resource referenced by the target URI", "type": "object", "properties": { "bm": { "readOnly": true, - "description": "ReadOnly, Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", + "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", "type": "integer" }, "sec": { "readOnly": true, - "description": "ReadOnly, Specifies if security needs to be turned on when looking to interact with the Resource", + "description": "Specifies if security needs to be turned on when looking to interact with the Resource", "type": "boolean" }, "port": { "readOnly": true, - "description": "ReadOnly, Secure port to be used for connection", + "description": "Secure port to be used for connection", "type": "integer" } }, diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json index 073c10a..5867a39 100755 --- a/schemas/oic.rule-Update-schema.json +++ b/schemas/oic.rule-Update-schema.json @@ -15,7 +15,7 @@ "currentStatus": { "type": "string", "readOnly": true, - "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" + "description": "the current state, can be one of: enabled, disabled, error" }, "n": { "type": "string", @@ -33,7 +33,7 @@ "rts": { "type": "string", "readOnly": true, - "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" + "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" }, "links": { "type": "array", diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index ce09e35..95741d6 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -15,7 +15,7 @@ "currentStatus": { "type": "string", "readOnly": true, - "description": "ReadOnly, the current state, can be one of: enabled, disabled, error" + "description": "the current state, can be one of: enabled, disabled, error" }, "n": { "type": "string", @@ -33,7 +33,7 @@ "rts": { "type": "string", "readOnly": true, - "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" + "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" }, "links": { "type": "array", diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json index 91ca8bd..6623f35 100755 --- a/schemas/oic.ruleMember-schema.json +++ b/schemas/oic.ruleMember-schema.json @@ -19,7 +19,7 @@ "memberProperty": { "type": "string", "readOnly": true, - "description": "ReadOnly, property name that will be mapped" + "description": "property name that will be mapped" }, "memberValue": { "oneOf" : [ @@ -28,7 +28,7 @@ { "type": "boolean", "description": "if member property is an boolean" } ], "readOnly": true, - "description": "ReadOnly, value of the Member Property" + "description": "value of the Member Property" }, "link": { "type": "string", diff --git a/schemas/oic.sceneCollection-Update-schema.json b/schemas/oic.sceneCollection-Update-schema.json index eb5af4f..eb86ebd 100755 --- a/schemas/oic.sceneCollection-Update-schema.json +++ b/schemas/oic.sceneCollection-Update-schema.json @@ -15,7 +15,7 @@ "sceneValues": { "type": "string", "readOnly": true, - "description": "ReadOnly, All available scene values", + "description": "All available scene values", "format": "CSV" }, "n": { @@ -30,7 +30,7 @@ "rts": { "type": "string", "readOnly": true, - "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", + "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", "format": "UTF8" }, "links": { diff --git a/schemas/oic.sceneCollection-schema.json b/schemas/oic.sceneCollection-schema.json index bd6bc6c..0a8a7a7 100755 --- a/schemas/oic.sceneCollection-schema.json +++ b/schemas/oic.sceneCollection-schema.json @@ -15,7 +15,7 @@ "sceneValues": { "type": "string", "readOnly": true, - "description": "ReadOnly, All available scene values", + "description": "All available scene values", "format": "CSV" }, "n": { @@ -30,7 +30,7 @@ "rts": { "type": "string", "readOnly": true, - "description": "ReadOnly, Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", + "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list", "format": "UTF8" }, "links": { diff --git a/schemas/oic.sceneMember-schema.json b/schemas/oic.sceneMember-schema.json index df116b6..ae7502f 100755 --- a/schemas/oic.sceneMember-schema.json +++ b/schemas/oic.sceneMember-schema.json @@ -30,12 +30,12 @@ "memberProperty": { "type": "string", "readOnly": true, - "description": "ReadOnly, property name that will be mapped" + "description": "property name that will be mapped" }, "memberValue": { "type": "string", "readOnly": true, - "description": "ReadOnly, value of the Member Property" + "description": "value of the Member Property" } }, "required": [ "scene", "memberProperty", "memberValue" ] diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 7f8feb3..fd31c60 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -10,24 +10,24 @@ "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Human friendly name" + "description": "Human friendly name" }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", "readOnly": true, - "description": "ReadOnly, Unique identifier for device (UUID)" + "description": "Unique identifier for device (UUID)" }, "icv": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, The version of the OIC Server" + "description": "The version of the OIC Server" }, "dmv": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, The spec version of the vertical and/or resource specification" + "description": "The spec version of the vertical and/or resource specification" } } } diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index b03e361..2ab8d64 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -15,7 +15,7 @@ } ], "readOnly": true, - "description": "ReadOnly, list of interface names" + "description": "list of interface names" } } } diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json index 8b31cf7..fb9ae96 100755 --- a/schemas/oic.wk.mon-schema.json +++ b/schemas/oic.wk.mon-schema.json @@ -9,12 +9,12 @@ "av":{ "type": "boolean", "readOnly": true, - "description": "ReadOnly, Indicates if the device is available or not on the network (like ping)" + "description": "Indicates if the device is available or not on the network (like ping)" }, "lat": { "type": "integer", "readOnly": true, - "description": "ReadOnly, Indicates the elapsed time in seconds after the device was invoked or acted upon" + "description": "Indicates the elapsed time in seconds after the device was invoked or acted upon" }, "ds": { "type": "array", @@ -25,7 +25,7 @@ } ], "readOnly": true, - "description": "ReadOnly, Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)" + "description": "Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 1a70bd9..a51f384 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -9,18 +9,18 @@ "pi": { "$ref": "oic.types-schema.json#/definitions/uuid", "readOnly": true, - "description": "ReadOnly, Platform Identifier as a UUID" + "description": "Platform Identifier as a UUID" }, "mnmn": { "type": "string", "readOnly": true, - "description": "ReadOnly, Manufacturer Name", + "description": "Manufacturer Name", "maxLength": 64 }, "mnml": { "type": "string", "readOnly": true, - "description": "ReadOnly, Manufacturer's URL", + "description": "Manufacturer's URL", "maxLength": 256, "format": "uri" }, @@ -28,12 +28,12 @@ "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Model number as designated by manufacturer" + "description": "Model number as designated by manufacturer" }, "mndt": { "type": "string", "readOnly": true, - "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", + "description": "Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$", "format": "date-time" }, @@ -41,37 +41,37 @@ "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Platform Version" + "description": "Platform Version" }, "mnos": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Platform Resident OS Version" + "description": "Platform Resident OS Version" }, "mnhw": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Platform Hardware Version" + "description": "Platform Hardware Version" }, "mnfv": { "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Manufacturer's firmware version" + "description": "Manufacturer's firmware version" }, "mnsl": { "type": "string", "readOnly": true, - "description": "ReadOnly, Manufacturer's Support Information URL", + "description": "Manufacturer's Support Information URL", "maxLength": 256, "format": "uri" }, "st": { "type": "string", "readOnly": true, - "description": "ReadOnly, Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", + "description": "Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z$", "format": "date-time" }, @@ -79,7 +79,7 @@ "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Manufacturer's defined string for the platform. The string is freeform and up to the manufacturer on what text to populate it" + "description": "Manufacturer's defined string for the platform. The string is freeform and up to the manufacturer on what text to populate it" } } } diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 1e38391..b113126 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -10,16 +10,16 @@ "type": "string", "maxLength": 64, "readOnly": true, - "description": "ReadOnly, Human friendly name" + "description": "Human friendly name" }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", "readOnly": true, - "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" + "description": "Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { "readOnly": true, - "description": "ReadOnly, Supported messaging protocols", + "description": "Supported messaging protocols", "type": "string", "maxLength": 64 }, diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 522aa90..85e4d4a 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -15,7 +15,7 @@ } ], "readOnly": true, - "description": "ReadOnly, list of resource type names" + "description": "list of resource type names" } } } From 23f27a76e41ddf527d93acfbdb8202ce702cbfe4 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 12 Sep 2016 22:00:52 +0200 Subject: [PATCH 28/55] Add some missing readOnly properties. --- schemas/oic.wk.d-schema.json | 4 +++- schemas/oic.wk.ifs-schema.json | 3 ++- schemas/oic.wk.p-schema.json | 7 +++++-- schemas/oic.wk.res-schema.json | 1 + schemas/oic.wk.rts-schema.json | 3 ++- 5 files changed, 13 insertions(+), 5 deletions(-) diff --git a/schemas/oic.wk.d-schema.json b/schemas/oic.wk.d-schema.json index 5f1338f..7f8feb3 100755 --- a/schemas/oic.wk.d-schema.json +++ b/schemas/oic.wk.d-schema.json @@ -9,10 +9,12 @@ "n": { "type": "string", "maxLength": 64, - "description": "Readonly, Human friendly name" + "readOnly": true, + "description": "ReadOnly, Human friendly name" }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID)" }, "icv": { diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json index 0a0d7eb..b03e361 100755 --- a/schemas/oic.wk.ifs-schema.json +++ b/schemas/oic.wk.ifs-schema.json @@ -14,7 +14,8 @@ "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] } ], - "description": "Readonly, list of interface names" + "readOnly": true, + "description": "ReadOnly, list of interface names" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index a8a2d67..1a70bd9 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -8,6 +8,7 @@ "properties": { "pi": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Platform Identifier as a UUID" }, "mnmn": { @@ -45,12 +46,14 @@ "mnos": { "type": "string", "maxLength": 64, - "description": "Readonly, Platform Resident OS Version" + "readOnly": true, + "description": "ReadOnly, Platform Resident OS Version" }, "mnhw": { "type": "string", "maxLength": 64, - "description": "Readonly, Platform Hardware Version" + "readOnly": true, + "description": "ReadOnly, Platform Hardware Version" }, "mnfv": { "type": "string", diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 073f4ab..1e38391 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -14,6 +14,7 @@ }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", + "readOnly": true, "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, "mpro": { diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json index 810f99b..522aa90 100755 --- a/schemas/oic.wk.rts-schema.json +++ b/schemas/oic.wk.rts-schema.json @@ -14,7 +14,8 @@ "maxLength": 64 } ], - "description": "Readonly, list of resource type names" + "readOnly": true, + "description": "ReadOnly, list of resource type names" } } } From cb2c1f13680cdde664634aba0406e10bb0e83125 Mon Sep 17 00:00:00 2001 From: SiMet Date: Wed, 14 Sep 2016 12:30:07 +0200 Subject: [PATCH 29/55] Update oic.wk.p-schema.json --- schemas/oic.wk.p-schema.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 4167865..8fc4968 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -33,7 +33,7 @@ "type": "string", "readOnly": true, "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$", + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" }, "mnpv": { "type": "string", From eafd60838bdccd5ad5c5a15c9ab6d5e6299be799 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Wed, 14 Sep 2016 14:44:28 +0200 Subject: [PATCH 30/55] Move the date definition into the oic.types file. --- schemas/oic.types-schema.json | 6 ++++++ schemas/oic.wk.p-schema.json | 5 ++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/schemas/oic.types-schema.json b/schemas/oic.types-schema.json index 860410c..6456259 100644 --- a/schemas/oic.types-schema.json +++ b/schemas/oic.types-schema.json @@ -4,8 +4,14 @@ "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.types-schema.json#", "definitions" : { "uuid": { + "description": "An identifier formatted according to IETF RFC 4122.", "type":"string", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" + }, + "date": { + "description": "As defined in ISO 8601. The format is [yyyy]-[mm]-[dd].", + "type": "string", + "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" } } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index 8fc4968..22a56c8 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -30,10 +30,9 @@ "description": "ReadOnly, Model number as designated by manufacturer" }, "mndt": { - "type": "string", + "$ref": "oic.types-schema.json#/definitions/date", "readOnly": true, - "description": "ReadOnly, Manufacturing Date as defined in ISO 8601, where the format is [yyyy]-[mm]-[dd].", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" + "description": "ReadOnly, Manufacturing Date." }, "mnpv": { "type": "string", From 02346f4dc4c217ae2c32f85dd2d85a6913ca3971 Mon Sep 17 00:00:00 2001 From: SiMet Date: Tue, 27 Sep 2016 12:23:06 +0200 Subject: [PATCH 31/55] Fix for not resolved merge --- schemas/oic.wk.res-schema.json | 4 ---- 1 file changed, 4 deletions(-) diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index 719829a..b113126 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -15,11 +15,7 @@ "di": { "$ref": "oic.types-schema.json#/definitions/uuid", "readOnly": true, -<<<<<<< HEAD - "description": "ReadOnly, Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" -======= "description": "Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" ->>>>>>> ff804fc6a1245ba4c256f8b362407b7e3e0903f0 }, "mpro": { "readOnly": true, From 4f1c1b5469f5c20379f101b0183130acff549e5e Mon Sep 17 00:00:00 2001 From: rabardini Date: Thu, 29 Sep 2016 08:22:26 -0700 Subject: [PATCH 32/55] v1.1.1 --- oic.wk.mnt.raml | 11 +- scene.raml | 148 ------------------ schemas/oic.collection-schema.json | 237 +++++++++++++++-------------- schemas/oic.oic-link-schema.json | 14 +- schemas/oic.types-schema.json | 1 + schemas/oic.wk.mnt-schema.json | 4 - schemas/oic.wk.res-schema.json | 2 +- 7 files changed, 128 insertions(+), 289 deletions(-) diff --git a/oic.wk.mnt.raml b/oic.wk.mnt.raml index d2b5847..515043c 100755 --- a/oic.wk.mnt.raml +++ b/oic.wk.mnt.raml @@ -30,8 +30,6 @@ traits: rb (Reboot) is a boolean. The value 0 means No action (Default), the value 1 means Start Reboot After Reboot, this value shall be changed back to the default value - ssc (Start Stat Collection) is a boolean. - The value 0 means No collection of statistics, the value 1 means Starts collecting statistics get: description: Retrieve the maintenance action status @@ -48,8 +46,7 @@ traits: "rt": ["oic.wk.mnt"], "n": "My Maintenance Actions", "fr": false, - "rb": false, - "ssc": false + "rb": false } post: @@ -65,8 +62,7 @@ traits: { "n": "My Maintenance Actions", "fr": false, - "rb": false, - "ssc": true + "rb": false } responses: 200: @@ -77,6 +73,5 @@ traits: { "n": "My Maintenance Actions", "fr": false, - "rb": false, - "ssc": true + "rb": false } diff --git a/scene.raml b/scene.raml index f59aabd..f3fd284 100755 --- a/scene.raml +++ b/scene.raml @@ -48,65 +48,6 @@ traits: ] } - post: - description: | - Provides the action to create a new sceneCollection in the SceneList resource - The only resource type that is allowed to be created "oic.wk.sceneCollection". - The example contains 3 scene values off, Reading and TVWatching. - body: - application/json: - schema: SceneCollection - example: | - { - "scenevalue": "off", - "sceneValues": "off,Reading,TVWatching", - "lastScene": "off", - "rt": "oic.wk.sceneCollection", - "n": "my first scene", - "id": "my_scene1", - "rts": "oic.r.sceneMember" - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The created resource attributes are provided in the response, - including the server generated identifier. - body: - application/json: - schema: SceneCollection - example: | - { - "scenevalue": "off", - "sceneValues": "off,Reading,TVWatching", - "lastScene": "off", - "rt": "oic.r.sceneCollection", - "n": "mymembername", - "link": "coap://newscene", - "id": "0685B960-736F-46F7-BEC0-9E6CBD671ADC1", - "rts": "oic.r.sceneMember" - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="0685B960-736F-46F7-BEC0-9E6CBD671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - /SceneCollectionResURI: @@ -169,95 +110,6 @@ traits: } - post: - description: | - Provides the action to create a new sceneMember in the SceneCollection resource - The only resource type that is allowed to be created is "oic.wk.sceneMember". - The id of the resource will be generated by the implementation. - As example the mappings of the 3 scenes are mapped to different states of an binary switch - - body: - application/json: - schema: SceneMember - example: | - { - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "n": "my binary switch (for light bulb) mappings", - "sceneMappings": [ - { - "scene": "off", - "memberProperty": "value", - "memberValue": true - }, - { - "scene": "Reading", - "memberProperty": "value", - "memberValue": false - }, - { - "scene": "TVWatching", - "memberProperty": "value", - "memberValue": true - } - ] - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The new resource attributes are provided in the response. - body: - application/json: - schema: SceneMember - example: | - { - "id": "0685B960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "sceneMappings": [ - { - "scene": "off", - "memberProperty": "value", - "memberValue": true - }, - { - "scene": "Reading", - "memberProperty": "value", - "memberValue": false - }, - { - "scene": "TVWatching", - "memberProperty": "value", - "memberValue": true - } - ] - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="0685B960-FFFF-46F7-BEC0-9E6234671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - /SceneMemberResURI: description: | Collection that models a sceneMember. diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 3e13ce1..15b1584 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -1,138 +1,139 @@ { - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", - "title": "Collection", - "definitions": { - "oic.collection.setoflinks": { - "type": "object", - "description": "A set (array) of simple or individual OIC Links", - "properties": { - "links": { - "type": "array", - "description": "Array of OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", - "items": { - "allOf": [ - { - "$ref": "oic.oic-link-schema.json#" - } - ], - "required": ["ins"] - } - } - } - }, - "oic.collection.tagged-setoflinks": { - "type": "object", - "description": "A tagged link is a set (array) of links that are tagged with one or more key-value pairs usually either an ID or Name or both", - "allOf": [ - { - "$ref": "#/definitions/oic.collection.setoflinks" + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", + "title": "Collection", + "definitions": { + "uuid": { + "type":"string", + "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" }, - { - "properties": { - "n": { - "type": "string", - "description": "Used to name i.e. tag the set of links", - "format": "UTF8" - }, - "id": { - "oneOf": [ - { - "type": "integer", - "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + "oic.collection.setoflinks": { + "description": "A set (array) of simple or individual OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", + "type": "array", + "items": { + "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" + } + }, + "oic.collection.tags": { + "type": "object", + "description": "The tags that can be used for tagging links in a collection", + "properties": { + "n": { + "type": "string", + "description": "Used to name i.e. tag the set of links" + }, + "id": { + "description": "Id for each set of links i.e. tag. Can be an value that is unique to the use context or a UUIDv4", + "anyOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "$ref": "#/definitions/uuid", + "description": "A unique string that could be a UUIDv4" + } + ] }, + "di": { + "$ref": "#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string" + }, + "base": { + "type": "string", + "description": "The base URI to be used if the links are relative URIs (i.e. relative references); see base URI in Core spec for details", + "format": "uri" + } + }, + "minProperties": 1 + }, + "oic.collection.tagged-setoflinks": { + "type": "array", + "description": "A tagged link is a set (array) of links that are tagged with one or more key-value pairs usually either an ID or Name or both", + "items": [ { - "type": "string", - "description": "A unique string that could be a hash or similarly unique" + "$ref": "#/definitions/oic.collection.tags" }, { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "A unique string that could be a UUIDv4" + "$ref": "#/definitions/oic.collection.setoflinks" } - ], - "description": "Id for each set of links i.e. tag. Can be an value that is unique to the use context or a UUIDv4" - }, - "di": { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res" - } - } - } - ], - "required": [ "links" ] - }, - "oic.collection.setof-tagged-setoflinks": { - "type": "array", - "items": { - "$ref": "#/definitions/oic.collection.tagged-setoflinks" - } - }, - "oic.collection.alllinks": { - "description": "All forms of links in a collection", - "oneOf": [ - { - "$ref": "#/definitions/oic.collection.setof-tagged-setoflinks" + ], + "additionalItems": false }, - { - "$ref": "#/definitions/oic.collection.setoflinks" - } - ], - "required": [ "links" ] - }, - "oic.collection": { - "type": "object", - "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", - "allOf": [ - { - "$ref": "#/definitions/oic.collection.alllinks" + "oic.collection.setof-tagged-setoflinks": { + "type": "array", + "items": [ + { + "$ref": "#/definitions/oic.collection.tagged-setoflinks" + } + ], + "additionalItems": false }, - { - "properties": { - "n": { - "type": "string", - "description": "User friendly name of the collection", - "format": "UTF8" - }, - "id": { - "oneOf": [ + "oic.collection.alllinks": { + "description": "All forms of links in a collection", + "oneOf": [ { - "type": "integer", - "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + "$ref": "#/definitions/oic.collection.setof-tagged-setoflinks" }, { - "type": "string", - "description": "A unique string that could be a hash or similarly unique" + "$ref": "#/definitions/oic.collection.tagged-setoflinks" }, { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "A unique string that could be a UUIDv4" + "$ref": "#/definitions/oic.collection.setoflinks" + } + ] + }, + "oic.collection": { + "type": "object", + "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", + "properties": { + "n": { + "type": "string", + "description": "User friendly name of the collection" }, + "id": { + "anyOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "$ref": "#/definitions/uuid", + "description": "A unique string that could be a UUIDv4" + } + ], + "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" + }, + "di": { + "$ref": "#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res" + }, + "rts": { + "type": "string", + "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, + "drel": { + "type": "string", + "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" + }, + "links": { + "$ref": "#/definitions/oic.collection.alllinks" } - ], - "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" - }, - "rts": { - "type": "string", - "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list", - "format": "UTF8" - }, - "drel": { - "type": "string", - "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" } - } } - ] - } - }, - - "type": "object", - "allOf": [ - { - "$ref": "oic.core-schema.json#/definitions/oic.core" }, - { + "type": "object", + "allOf": [ + { + "$ref": "oic.core-schema.json#/definitions/oic.core", "$ref": "#/definitions/oic.collection" - } - ] + } + ] } diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 9123e2f..08d8453 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -9,12 +9,12 @@ "href": { "type": "string", "maxLength": 256, - "description": "This is the target URI – can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", + "description": "This is the target URI, it can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", "format": "uri" }, "rel": { "type": "string", - "default": "advertises", + "default": "hosts", "maxLength": 64, "description": "The relation of the target URI referenced by the link to the context URI" }, @@ -77,14 +77,8 @@ "required" : ["bm"] }, "bp": { - "type": "object", - "properties": { - "q": { - "type": "string", - "maxLength": 64, - "description": "This defines the query string to be used when batch request is forwarded through this Link" - } - } + "type": "string", + "description": " Batch Parameters: URI parameters to use with an oic.if.b batch request using this link" }, "title": { "type": "string", diff --git a/schemas/oic.types-schema.json b/schemas/oic.types-schema.json index 6456259..af495ae 100644 --- a/schemas/oic.types-schema.json +++ b/schemas/oic.types-schema.json @@ -6,6 +6,7 @@ "uuid": { "description": "An identifier formatted according to IETF RFC 4122.", "type":"string", + "format": "date-time", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" }, "date": { diff --git a/schemas/oic.wk.mnt-schema.json b/schemas/oic.wk.mnt-schema.json index 753ece5..abb9606 100755 --- a/schemas/oic.wk.mnt-schema.json +++ b/schemas/oic.wk.mnt-schema.json @@ -18,10 +18,6 @@ "rb": { "type": "boolean", "description": "Reboot Action" - }, - "ssc": { - "type": "boolean", - "description": "Start Stat Collection Action Toggle" } } } diff --git a/schemas/oic.wk.res-schema.json b/schemas/oic.wk.res-schema.json index b113126..c4b1539 100755 --- a/schemas/oic.wk.res-schema.json +++ b/schemas/oic.wk.res-schema.json @@ -13,7 +13,7 @@ "description": "Human friendly name" }, "di": { - "$ref": "oic.types-schema.json#/definitions/uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "readOnly": true, "description": "Unique identifier for device (UUID) as indicated by the /oic/d resource of the device" }, From c9e7994c0ebdef64ba9ba4829864882858c1214b Mon Sep 17 00:00:00 2001 From: rabardini Date: Thu, 29 Sep 2016 08:26:41 -0700 Subject: [PATCH 33/55] v1.1.1 --- oic.wk.col.raml | 230 ++++++++++++++++++ .../oic.collection.batch-retrieve-schema.json | 21 ++ .../oic.collection.batch-update-schema.json | 8 + schemas/oic.collection.linkslist-schema.json | 11 + 4 files changed, 270 insertions(+) create mode 100644 oic.wk.col.raml create mode 100644 schemas/oic.collection.batch-retrieve-schema.json create mode 100644 schemas/oic.collection.batch-update-schema.json create mode 100644 schemas/oic.collection.linkslist-schema.json diff --git a/oic.wk.col.raml b/oic.wk.col.raml new file mode 100644 index 0000000..9a56e75 --- /dev/null +++ b/oic.wk.col.raml @@ -0,0 +1,230 @@ +#%RAML 0.8 +#RAML for OIC Collections. +# This is an initial version; has to be converted to a RAML resource type so that it can be used when defining resource that +# are collections. Also needs to use traits to have the same query parameters recognized for all the methods. +title: Collections +version: 1.0 +documentation: + + - title: OIC Collections + content: | + Collection is an extensions of OIC Resource concept. + In addition to properties, collections also have an + array of OIC web links. + + - title: Introduction + content: | + Collections can be used to group sets of resources, + build structures like topologies, to define a + dependency relationship etc + + - title: Resource Design + content: | + The collection resource is specified as three Base URIs, one + for each interface which is supported by the collection, in addition + to the resource interfaces e.g. oic.if.s, oic.if.rw + + THese three URIs are typically the same URI path, only distinguished + by the different query parameter traits + +schemas: + - sbaseline: !include schemas/oic.collection-schema.json + - sbatch-retrieve: !include schemas/oic.collection.batch-retrieve-schema.json + - sbatch-update: !include schemas/oic.collection.batch-update-schema.json + - slinks: !include schemas/oic.collection.linkslist-schema.json + +traits: + - interface-baseline: + queryParameters: + if: + enum: ["oic.if.baseline"] + + - interface-b: + queryParameters: + if: + enum: ["oic.if.b"] + + - interface-ll: + queryParameters: + if: + enum: ["oic.if.ll"] + + +/CollectionBaselineInterfaceURI: + description: | + OCF Collection Resource Type contains properties and links. + The oic.if.baseline interface exposes a representation of + the links and the properties of the collection resource itself + + + displayName: OCF Collection + is: [ interface-baseline ] + + get: + description: | + Retrieve on Baseline Interface + + responses: + 200: + body: + application/json: + schema: sbaseline + example: | + { + "rt": ["oic.wk.col"], + "id": "unique_example_id", + "rts": [ "oic.r.switch.binary", "oic.r.airFlow" ], + "links": [ + { + "href": "switch", + "rt": "oic.r.switch.binary", + "if": "oic.if.a" + }, + { + "href": "airFlow", + "rt": "oic.r.airFlow", + "if": "oic.if.a" + } + ] + } + + + post: + description: | + Update on Baseline Interface + + body: + application/json: + schema: sbaseline + + responses: + 200: + body: + application/json: + schema: sbaseline + + +/CollectionBatchInterfaceURI: + description: | + OCF Collection Resource Type contains properties and links. + The oic.if.b interfacce exposes a composite representation of the + resources pointed to by the links + + displayName: Batch Representation of an OCF COllection + is: [ interface-b ] + + get: + description: | + Retrieve on Batch Interface + + responses: + 200: + description: "All targets returned OK status (HTTP 200 or CoAP 2.05 Content)" + body: + application/json: + schema: sbatch-retrieve + example: | + [ + { + "href": "switch", + "value": true + }, + { + "href": "airFlow", + "direction": "floor", + "speed": 3 + } + ] + 404: + description: "One or more targets did not return an OK status, return a representation containing returned properties from the targets that returned OK" + body: + application/json: + schema: sbatch-retrieve + example: | + [ + { + "href": "switch", + "value": true + } + ] + + post: + description: | + Update on Batch Interface + + body: + application/json: + schema: sbatch-update + example: | + { + "direction": "demist", + "speed": 5 + } + + responses: + 200: + description: "all targets returned OK status (HTTP 200 or CoAP 2.04 Changed) return a representation of the current state of all targets" + body: + application/json: + schema: sbatch-retrieve + example: | + [ + { + "href": "switch", + "value": true + }, + { + "href": "airFlow", + "direction": "demist", + "speed": 5 + } + ] + + 403: + description: "one or more targets did not return OK status; return a retrieve representation of the current state of all targets in the batch" + body: + application/json: + schema: sbatch-retrieve + example: | + [ + { + "href": "switch", + "value": true + }, + { + "href": "airFlow", + "direction": "floor", + "speed": 3 + } + ] + +/CollectionLinkListInterfaceURI: + description: | + OCF Collection Resource Type contains properties and links. + The oic.if.ll interface exposes a representation of the links + + displayName: Batch Representation of an OCF Collection + is: [ interface-ll ] + + get: + description: | + Retrieve on Link List Interface + + responses: + 200: + body: + application/json: + schema: slinks + example: | + [ + { + "href": "switch", + "rt": "oic.r.switch.binary", + "if": "oic.if.a" + }, + { + "href": "airFlow", + "rt": "oic.r.airFlow", + "if": "oic.if.a" + } + ] diff --git a/schemas/oic.collection.batch-retrieve-schema.json b/schemas/oic.collection.batch-retrieve-schema.json new file mode 100644 index 0000000..9e1fb25 --- /dev/null +++ b/schemas/oic.collection.batch-retrieve-schema.json @@ -0,0 +1,21 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection.batch-retrieve-schema.json#", + "title": "Collection Batch Retrieve Format", + "type": "array", + "minItems": 1, + "items": { + "type": "object", + "properties": { + "href": { + "type": "string", + "description": "URI of the target resource relative assuming the collection URI as anchor" + } + }, + "additionalProperties": true, + "required": [ + "href" + ] + } +} diff --git a/schemas/oic.collection.batch-update-schema.json b/schemas/oic.collection.batch-update-schema.json new file mode 100644 index 0000000..9d79022 --- /dev/null +++ b/schemas/oic.collection.batch-update-schema.json @@ -0,0 +1,8 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection.batch-update-schema.json#", + "title": "Collection Batch Update Format", + "type": "object", + "description": "object with keywords to identify properties to be updated in all target resources that have matching property names" +} diff --git a/schemas/oic.collection.linkslist-schema.json b/schemas/oic.collection.linkslist-schema.json new file mode 100644 index 0000000..677ce0a --- /dev/null +++ b/schemas/oic.collection.linkslist-schema.json @@ -0,0 +1,11 @@ +{ + "$schema": "http://json-schema.org/draft-v4/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection.linkslist-schema.json#", + "definitions": { + "oic.collection.alllinks": { + "$ref": "oic.collection-schema.json#/definitions/oic.collection.alllinks" + } + }, + "$ref": "#/definitions/oic.collection.alllinks" +} From 17a8ef7907a8dd26836ec0597af220e6a8a2e9e8 Mon Sep 17 00:00:00 2001 From: rabardini Date: Thu, 29 Sep 2016 20:39:48 -0700 Subject: [PATCH 34/55] Editoral fix to v1.1.1 --- schemas/oic.oic-link-schema.json | 3 ++- schemas/oic.rule-schema.json | 2 +- schemas/oic.types-schema.json | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 08d8453..71ba3ea 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -35,7 +35,7 @@ "items": [ { "type" : "string", - "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] } ], "minItems": 1, @@ -66,6 +66,7 @@ "sec": { "readOnly": true, "description": "Specifies if security needs to be turned on when looking to interact with the Resource", + "default": false, "type": "boolean" }, "port": { diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json index 95741d6..e3b5c5b 100755 --- a/schemas/oic.rule-schema.json +++ b/schemas/oic.rule-schema.json @@ -40,7 +40,7 @@ "description": "Array of OIC web links that are the rule members, this is the script", "items" : { "allOf": [ - { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link#" }, + { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, { "required" : [ "ins" ] } ] } diff --git a/schemas/oic.types-schema.json b/schemas/oic.types-schema.json index af495ae..51fa82b 100644 --- a/schemas/oic.types-schema.json +++ b/schemas/oic.types-schema.json @@ -6,12 +6,12 @@ "uuid": { "description": "An identifier formatted according to IETF RFC 4122.", "type":"string", - "format": "date-time", "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" }, "date": { "description": "As defined in ISO 8601. The format is [yyyy]-[mm]-[dd].", "type": "string", + "format": "date-time", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" } } From 88134ba178979eedcb299d86586bb04e8ec87ca9 Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Mon, 3 Oct 2016 15:06:50 +0200 Subject: [PATCH 35/55] Fix validation errors in examples of oic.wk.col.raml The rt and if attributes in the examples required an array of strings. The type rts in a collections is now streamlined with the rt type which is an array for strings. --- oic.wk.col.raml | 16 ++++++++-------- schemas/oic.collection-schema.json | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/oic.wk.col.raml b/oic.wk.col.raml index 9a56e75..19e0324 100644 --- a/oic.wk.col.raml +++ b/oic.wk.col.raml @@ -77,13 +77,13 @@ traits: "links": [ { "href": "switch", - "rt": "oic.r.switch.binary", - "if": "oic.if.a" + "rt": ["oic.r.switch.binary"], + "if": ["oic.if.a"] }, { "href": "airFlow", - "rt": "oic.r.airFlow", - "if": "oic.if.a" + "rt": ["oic.r.airFlow"], + "if": ["oic.if.a"] } ] } @@ -219,12 +219,12 @@ traits: [ { "href": "switch", - "rt": "oic.r.switch.binary", - "if": "oic.if.a" + "rt": ["oic.r.switch.binary"], + "if": ["oic.if.a"] }, { "href": "airFlow", - "rt": "oic.r.airFlow", - "if": "oic.if.a" + "rt": ["oic.r.airFlow"], + "if": ["oic.if.a"] } ] diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 15b1584..eb1470c 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -117,7 +117,7 @@ "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res" }, "rts": { - "type": "string", + "$ref": "oic.core-schema.json#/definitions/oic.core/properties/rt", "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, "drel": { "type": "string", From 7ae50fd3b1b5588c1ccb71e380a61a0bd09da28a Mon Sep 17 00:00:00 2001 From: Stephane Lejeune Date: Fri, 7 Oct 2016 13:46:12 +0200 Subject: [PATCH 36/55] Remove files that will not be part of the OIC 1.1 release. --- oic.wk.ifs.raml | 38 ----- oic.wk.mon.raml | 41 ----- oic.wk.rts.raml | 39 ----- rules.raml | 256 ---------------------------- schemas/oic.rule-Update-schema.json | 58 ------- schemas/oic.rule-schema.json | 58 ------- schemas/oic.ruleMember-schema.json | 49 ------ schemas/oic.wk.ifs-schema.json | 29 ---- schemas/oic.wk.mon-schema.json | 39 ----- schemas/oic.wk.rts-schema.json | 29 ---- 10 files changed, 636 deletions(-) delete mode 100755 oic.wk.ifs.raml delete mode 100755 oic.wk.mon.raml delete mode 100755 oic.wk.rts.raml delete mode 100755 rules.raml delete mode 100755 schemas/oic.rule-Update-schema.json delete mode 100755 schemas/oic.rule-schema.json delete mode 100755 schemas/oic.ruleMember-schema.json delete mode 100755 schemas/oic.wk.ifs-schema.json delete mode 100755 schemas/oic.wk.mon-schema.json delete mode 100755 schemas/oic.wk.rts-schema.json diff --git a/oic.wk.ifs.raml b/oic.wk.ifs.raml deleted file mode 100755 index 4daa522..0000000 --- a/oic.wk.ifs.raml +++ /dev/null @@ -1,38 +0,0 @@ -#%RAML 0.8 -title: Interface Types -version: v1-20160622 -documentation: - - - title: OCF Copyright - content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - - title: OCF License - content: !include LICENSE.md - - title: OCF Disclaimer - content: !include DISCLAIMER.md - - -schemas: - - IFS: !include schemas/oic.wk.ifs-schema.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r", "oic.if.baseline"] - -/oic/ifs: - displayName: Inteface Types - is: [ interface ] - description: | - List of resource interfaces that are supported by this Server - get: - description: Retrieve the resource interface list - responses: - 200: - body: - application/json: - schema: IFS - example: | - { - "rt": ["oic.wk.ifs"], - "il": ["oic.if.ll", "oic.if.b", "oic.if.r"] - } diff --git a/oic.wk.mon.raml b/oic.wk.mon.raml deleted file mode 100755 index d3a6efa..0000000 --- a/oic.wk.mon.raml +++ /dev/null @@ -1,41 +0,0 @@ -#%RAML 0.8 -title: Monitoring -version: v1-20160622 -documentation: - - - title: OCF Copyright - content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - - title: OCF License - content: !include LICENSE.md - - title: OCF Disclaimer - content: !include DISCLAIMER.md - - -schemas: - - MON: !include schemas/oic.wk.mon-schema.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r", "oic.if.baseline"] - -/oic/mon: - displayName: Monitoring - is: [ interface ] - description: | - The resource through which an Device is monitored. - get: - description: Retrieve the monitor information - responses: - 200: - body: - application/json: - schema: MON - example: | - { - "rt": ["oic.wk.mon"], - "name": "My Monitor Information", - "av": true, - "lat": 50, - "ds": ["1500", "2750", "0"] - } diff --git a/oic.wk.rts.raml b/oic.wk.rts.raml deleted file mode 100755 index 0af8b13..0000000 --- a/oic.wk.rts.raml +++ /dev/null @@ -1,39 +0,0 @@ -#%RAML 0.8 -title: Resource Types -version: v1-20160622 -documentation: - - - title: OCF Copyright - content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - - title: OCF License - content: !include LICENSE.md - - title: OCF Disclaimer - content: !include DISCLAIMER.md - - -schemas: - - RTS: !include schemas/oic.wk.rts-schema.json -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.r", "oic.if.baseline"] - - -/oic/rts: - displayName: Resource Types - is: [ interface ] - description: | - List of resource types that are supported by this Server - get: - description: Retrieve the resource type list - responses: - 200: - body: - application/json: - schema: RTS - example: | - { - "rt": ["oic.wk.rts"], - "tl": ["oic.r.example", "oic.r.other-example"] - } diff --git a/rules.raml b/rules.raml deleted file mode 100755 index cf04214..0000000 --- a/rules.raml +++ /dev/null @@ -1,256 +0,0 @@ -#%RAML 0.8 -title: Rules -version: v1-20160622 -documentation: - - - title: OCF Copyright - content: Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved. - - title: OCF License - content: !include LICENSE.md - - title: OCF Disclaimer - content: !include DISCLAIMER.md - - -schemas: - - Collection: !include schemas/oic.collection-schema.json - - Rule: !include schemas/oic.rule-schema.json - - RuleUpdate: !include schemas/oic.rule-Update-schema.json - - RuleMember: !include schemas/oic.ruleMember-schema.json - -traits: - - interface: - queryParameters: - if: - enum: ["oic.if.a", "oic.if.ll", "oic.if.baseline"] - - -/RuleListResURI: - description: | - Toplevel Rule resource. - This resource is a generic collection resource - The rts value shall contain oic.wk.rule resource types - displayName: Rules (Top level) - - get: - description: | - Provides the current list of web links pointing to rules - responses: - 200: - body: - application/json: - schema: Collection - example: | - { - "rt": "oic.wk.ruleList", - "n": "list of rules", - "rts": "oic.wk.rule", - "links": [ - ] - } - - post: - description: | - Provides the action to create a new rule in the ruleList resource - The only resource type that is allowed to be created "oic.wk.rule". - The example contains a condition, currentStatus and test. - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value = true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "off", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "my_rule1", - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The created resource attributes are provided in the response, - including the server generated identifier. - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "off", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" , - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - - -/RuleResURI: - description: | - Collection that models a rule. - This resource is an generic collection resource with additional parameters. - The rts value shall contain oic.wk.ruleMember resource types. - The additional parameters are - condition, this is the rule that will be evaluated - currentStatus, the current state of the rule, can be "enabled, disabled, error" - test an trigger once activation of the rule - displayName: Rule - - get: - description: | - Provides the current rule and list of web links to the rule members - responses: - 200: - body: - application/json: - schema: Rule - example: | - { - "condition": "(FFFAB960-736F-46F7-BEC0-9E6CBD671ADC1:binaryswitchid:value == true) and (FFFFB960-736F-46F7-BEC0-9E6CBD671FFFF:tempid:temperature > 30)", - "currentStatus": "disabled", - "test": false, - "rt": "oic.wk.rule", - "n": "my first rule", - "id": "FFFFB960-736F-46F7-BEC0-9E6CBD671ADC1", - "rts": "oic.r.ruleMember", - "links": [ - ] - } - - put: - description: | - Provides the action to enable/disable the rule and an test mode for the rule. - Calling this method with test = true will update of all ruleMembers to the prescribed membervalue. - - body: - application/json: - schema: RuleUpdate - example: | - { - "currentStatus": "enabled" - } - - responses: - 200: - description: | - Indicates that the value is changed. - The changed properties are provided in the response. - body: - application/json: - schema: RuleUpdate - example: | - { - "currentStatus": "enabled" - } - - - post: - description: | - Provides the action to create a new ruleMember in the rule resource - The only resource type that is allowed to be created is "oic.wk.ruleMember". - The id of the resource will be generated by the implementation. - - body: - application/json: - schema: RuleMember - example: | - { - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "id": "", - "n": "my binary switch (for light bulb) mappings", - "memberProperty": "value", - "memberValue": true - } - - responses: - 200: - description: | - Indicates that the target resource was created. - The new resource attributes are provided in the response. - body: - application/json: - schema: RuleMember - example: | - { - "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "memberProperty": "value", - "memberValue": true - } - - delete: - description: | - No change from collection. - When delete is used with the URI of the collection without and query parameters then the entire collection is deleted - When the delete uses the "ins" parameter with the value of a specific link then only that link is deleted - queryParameters: - ins: - type: string - description: | - Delete the Web link identified by the string - could be a UUID. - required: false - example: | - DELETE /mycollection?ins="FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1" - responses: - 200: - description: The web link instance or the the entire collection has been successfully deleted - 400: - description: The request is invalid - - -/RuleMemberResURI: - description: | - Rule member resource. - This resource is assignment statement of an property in a resource indicated by an URI - displayName: Rule Member - - get: - description: | - Provides the rule mappings - responses: - 200: - body: - application/json: - schema: RuleMember - example: | - { - "id": "FFFFB960-FFFF-46F7-BEC0-9E6234671ADC1", - "n": "my binary switch (for light bulb) mappings", - "link": { "href":"coap://mydevice/mybinaryswitch", - "if": "oic.if.a", - "rt": "oic.r.switch.binary" }, - "memberProperty": "value", - "memberValue": true - } diff --git a/schemas/oic.rule-Update-schema.json b/schemas/oic.rule-Update-schema.json deleted file mode 100755 index 5867a39..0000000 --- a/schemas/oic.rule-Update-schema.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rule-schema.json#", - "title" : "Rule", - "definitions": { - "oic.rule": { - "type": "object", - "properties": { - "condition": { - "type": "string", - "description": "condition of the rule", - "format": "UTF8" - }, - "currentStatus": { - "type": "string", - "readOnly": true, - "description": "the current state, can be one of: enabled, disabled, error" - }, - "n": { - "type": "string", - "description": "Used to name the Rule collection", - "format": "UTF8" - }, - "test": { - "type": "boolean", - "description": "Inidcates initiation of test mode for the rule" - }, - "id": { - "type": "string", - "description": "Can be an value that is unique to the use context or a UUIDv4" - }, - "rts": { - "type": "string", - "readOnly": true, - "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" - }, - "links": { - "type": "array", - "description": "Array of OIC web links that are the rule members, this is the script", - "items" : { - "allOf": [ - { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, - { "required" : [ "ins" ] } - ] - } - } - }, - "required": [ "currentStatus" ] - } - }, - - "type": "object", - "allOf" : [ - { "$ref": "oic.core-schema.json#/definitions/oic.core" }, - { "$ref": "#/definitions/oic.rule" } - ] -} diff --git a/schemas/oic.rule-schema.json b/schemas/oic.rule-schema.json deleted file mode 100755 index e3b5c5b..0000000 --- a/schemas/oic.rule-schema.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.rule-schema.json#", - "title" : "Rule", - "definitions": { - "oic.rule": { - "type": "object", - "properties": { - "condition": { - "type": "string", - "description": "condition of the rule", - "format": "UTF8" - }, - "currentStatus": { - "type": "string", - "readOnly": true, - "description": "the current state, can be one of: enabled, disabled, error" - }, - "n": { - "type": "string", - "description": "Used to name the Rule collection", - "format": "UTF8" - }, - "test": { - "type": "boolean", - "description": "Inidcates initiation of test mode for the rule" - }, - "id": { - "type": "string", - "description": "Can be an value that is unique to the use context or a UUIDv4" - }, - "rts": { - "type": "string", - "readOnly": true, - "description": "Defines the list of allowable resource types in links included in the collection; new links being created can only be from this list" - }, - "links": { - "type": "array", - "description": "Array of OIC web links that are the rule members, this is the script", - "items" : { - "allOf": [ - { "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" }, - { "required" : [ "ins" ] } - ] - } - } - }, - "required": [ "links", "condition", "currentStatus", "test", "id", "rts" ] - } - }, - - "type": "object", - "allOf" : [ - { "$ref": "oic.core-schema.json#/definitions/oic.core" }, - { "$ref": "#/definitions/oic.rule" } - ] -} diff --git a/schemas/oic.ruleMember-schema.json b/schemas/oic.ruleMember-schema.json deleted file mode 100755 index 6623f35..0000000 --- a/schemas/oic.ruleMember-schema.json +++ /dev/null @@ -1,49 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.ruleMember-schema.json#", - "title" : "Rule Member", - "definitions": { - "oic.ruleMember": { - "type": "object", - "properties": { - "n": { - "type": "string", - "description": "Used to name the Rule member", - "format": "UTF8" - }, - "id": { - "type": "string", - "description": "Can be an value that is unique to the use context or a UUIDv4" - }, - "memberProperty": { - "type": "string", - "readOnly": true, - "description": "property name that will be mapped" - }, - "memberValue": { - "oneOf" : [ - { "type": "number", "description": "if member property is an number" }, - { "type": "string", "description": "if member property is an number" }, - { "type": "boolean", "description": "if member property is an boolean" } - ], - "readOnly": true, - "description": "value of the Member Property" - }, - "link": { - "type": "string", - "description": "web link that points at a resource", - "$ref": "oic.oic-link-schema.json#" - } - }, - "required": [ "id", "link", "memberProperty", "memberValue" ], - "additionalProperties": false - } - }, - - "type": "object", - "allOf" : [ - { "$ref": "oic.core-schema.json#/definitions/oic.core" }, - { "$ref": "#/definitions/oic.ruleMember" } - ] -} diff --git a/schemas/oic.wk.ifs-schema.json b/schemas/oic.wk.ifs-schema.json deleted file mode 100755 index 2ab8d64..0000000 --- a/schemas/oic.wk.ifs-schema.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.ifs-schema.json#", - "definitions": { - "oic.wk.ifs": { - "type": "object", - "properties": { - "il": { - "type": "array", - "items" : [ - { - "type" : "string", - "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.lb", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] - } - ], - "readOnly": true, - "description": "list of interface names" - } - } - } - }, - "type": "object", - "allOf": [ - { "$ref": "oic.core-schema.json#/definitions/oic.core"}, - { "$ref": "#/definitions/oic.wk.ifs" } - ], - "required": ["il"] -} diff --git a/schemas/oic.wk.mon-schema.json b/schemas/oic.wk.mon-schema.json deleted file mode 100755 index fb9ae96..0000000 --- a/schemas/oic.wk.mon-schema.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.mon-schema.json#", - "definitions": { - "oic.wk.mon": { - "type": "object", - "properties": { - "av":{ - "type": "boolean", - "readOnly": true, - "description": "Indicates if the device is available or not on the network (like ping)" - }, - "lat": { - "type": "integer", - "readOnly": true, - "description": "Indicates the elapsed time in seconds after the device was invoked or acted upon" - }, - "ds": { - "type": "array", - "items" : [ - { - "type" : "string", - "maxLength": 64 - } - ], - "readOnly": true, - "description": "Contains Device Statistics Info (no. of received packets, no. of sent packets, time to respond etc.)" - } - } - } - }, - "type": "object", - "allOf": [ - {"$ref": "oic.core-schema.json#/definitions/oic.core"}, - {"$ref": "#/definitions/oic.wk.mon"} - ], - "required": ["av", "lat"] -} diff --git a/schemas/oic.wk.rts-schema.json b/schemas/oic.wk.rts-schema.json deleted file mode 100755 index 85e4d4a..0000000 --- a/schemas/oic.wk.rts-schema.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "http://json-schemas.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.wk.rts-schema.json#", - "definitions": { - "oic.wk.rts": { - "type": "object", - "properties": { - "tl": { - "type": "array", - "items" : [ - { - "type" : "string", - "maxLength": 64 - } - ], - "readOnly": true, - "description": "list of resource type names" - } - } - } - }, - "type": "object", - "allOf": [ - { "$ref": "oic.core-schema.json#/definitions/oic.core"}, - { "$ref": "#/definitions/oic.wk.rts" } - ], - "required": ["tl"] -} From cc61e7daabe2c01139795c5032983842db49c1ba Mon Sep 17 00:00:00 2001 From: marktrayer Date: Tue, 11 Oct 2016 10:16:08 -0500 Subject: [PATCH 37/55] Update oic.wk.p-schema.json Remove of pattern check from 'st' Property. The format reference is sufficient. --- schemas/oic.wk.p-schema.json | 1 - 1 file changed, 1 deletion(-) diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index fb51b98..8dc6692 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -70,7 +70,6 @@ "type": "string", "readOnly": true, "description": "Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z$", "format": "date-time" }, "vid": { From ad4cc120f616a1000d9c8714759b6eebb81c59fd Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 11 Oct 2016 15:42:14 -0700 Subject: [PATCH 38/55] Fix date format and collection syntax errrors --- oic.wk.col.raml | 18 +++++++++--------- schemas/oic.collection-schema.json | 16 ++++++---------- schemas/oic.types-schema.json | 1 - schemas/oic.wk.p-schema.json | 1 - 4 files changed, 15 insertions(+), 21 deletions(-) diff --git a/oic.wk.col.raml b/oic.wk.col.raml index 9a56e75..f246e1f 100644 --- a/oic.wk.col.raml +++ b/oic.wk.col.raml @@ -73,17 +73,17 @@ traits: { "rt": ["oic.wk.col"], "id": "unique_example_id", - "rts": [ "oic.r.switch.binary", "oic.r.airFlow" ], + "rts": [ "oic.r.switch.binary", "oic.r.airflow" ], "links": [ { "href": "switch", - "rt": "oic.r.switch.binary", - "if": "oic.if.a" + "rt": ["oic.r.switch.binary"], + "if": ["oic.if.a", "oic.if.baseline"] }, { "href": "airFlow", - "rt": "oic.r.airFlow", - "if": "oic.if.a" + "rt": ["oic.r.airflow"], + "if": ["oic.if.a", "oic.if.baseline"] } ] } @@ -219,12 +219,12 @@ traits: [ { "href": "switch", - "rt": "oic.r.switch.binary", - "if": "oic.if.a" + "rt": ["oic.r.switch.binary"], + "if": ["oic.if.a", "oic.if.baseline"] }, { "href": "airFlow", - "rt": "oic.r.airFlow", - "if": "oic.if.a" + "rt": ["oic.r.airflow"], + "if": ["oic.if.a", "oic.if.baseline"] } ] diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 15b1584..dd3d5e2 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -4,10 +4,6 @@ "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", "title": "Collection", "definitions": { - "uuid": { - "type":"string", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" - }, "oic.collection.setoflinks": { "description": "A set (array) of simple or individual OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", "type": "array", @@ -35,13 +31,13 @@ "description": "A unique string that could be a hash or similarly unique" }, { - "$ref": "#/definitions/uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "A unique string that could be a UUIDv4" } ] }, "di": { - "$ref": "#/definitions/uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "The device ID which is an UUIDv4 string" }, "base": { @@ -106,18 +102,18 @@ "description": "A unique string that could be a hash or similarly unique" }, { - "$ref": "#/definitions/uuid", + "$ref": "oic.types-schema.json#/definitions/uuid", "description": "A unique string that could be a UUIDv4" } ], "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" }, "di": { - "$ref": "#/definitions/uuid", - "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A defintion of /oic/res" + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A definition of /oic/res" }, "rts": { - "type": "string", + "$ref": "oic.core-schema.json#/definitions/oic.core/properties/rt", "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, "drel": { "type": "string", diff --git a/schemas/oic.types-schema.json b/schemas/oic.types-schema.json index 51fa82b..6456259 100644 --- a/schemas/oic.types-schema.json +++ b/schemas/oic.types-schema.json @@ -11,7 +11,6 @@ "date": { "description": "As defined in ISO 8601. The format is [yyyy]-[mm]-[dd].", "type": "string", - "format": "date-time", "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])$" } } diff --git a/schemas/oic.wk.p-schema.json b/schemas/oic.wk.p-schema.json index fb51b98..8dc6692 100755 --- a/schemas/oic.wk.p-schema.json +++ b/schemas/oic.wk.p-schema.json @@ -70,7 +70,6 @@ "type": "string", "readOnly": true, "description": "Reference time for the device as defined in ISO 8601, where concatenation of 'date' and 'time' with the 'T' as a delimiter between 'date' and 'time'. The format is [yyyy]-[mm]-[dd]T[hh]:[mm]:[ss]Z.", - "pattern": "^([0-9]{4})-(1[0-2]|0[1-9])-(3[0-1]|2[0-9]|1[0-9]|0[1-9])T(2[0-3]|1[0-9]|0[0-9]):([0-5][0-9]):([0-5][0-9])Z$", "format": "date-time" }, "vid": { From 4aaa3f7d6c650e0ea70219158f18f725412258a3 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Mon, 24 Oct 2016 09:52:20 -0700 Subject: [PATCH 39/55] Removed the link tag and added "rep" keyword As per the discussion in atg October 24, 2016, removed link tagging and added the "rep" keyword to the batch representation --- oic.wk.col.raml | 41 +++++++++--- schemas/oic.collection-schema.json | 65 ------------------- .../oic.collection.batch-retrieve-schema.json | 18 ++++- 3 files changed, 46 insertions(+), 78 deletions(-) diff --git a/oic.wk.col.raml b/oic.wk.col.raml index f246e1f..ceb4837 100644 --- a/oic.wk.col.raml +++ b/oic.wk.col.raml @@ -127,12 +127,18 @@ traits: [ { "href": "switch", - "value": true + "rep": + { + "value": true + } }, { "href": "airFlow", - "direction": "floor", - "speed": 3 + "rep": + { + "direction": "floor", + "speed": 3 + } } ] 404: @@ -144,7 +150,10 @@ traits: [ { "href": "switch", - "value": true + "rep": + { + "value": true + } } ] @@ -171,12 +180,18 @@ traits: [ { "href": "switch", - "value": true + "rep": + { + "value": true + } }, { "href": "airFlow", - "direction": "demist", - "speed": 5 + "rep": + { + "direction": "demist", + "speed": 5 + } } ] @@ -189,12 +204,18 @@ traits: [ { "href": "switch", - "value": true + "rep": + { + "value": true + } }, { "href": "airFlow", - "direction": "floor", - "speed": 3 + "rep": + { + "direction": "floor", + "speed": 3 + } } ] diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index dd3d5e2..164a1a8 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -11,74 +11,9 @@ "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" } }, - "oic.collection.tags": { - "type": "object", - "description": "The tags that can be used for tagging links in a collection", - "properties": { - "n": { - "type": "string", - "description": "Used to name i.e. tag the set of links" - }, - "id": { - "description": "Id for each set of links i.e. tag. Can be an value that is unique to the use context or a UUIDv4", - "anyOf": [ - { - "type": "integer", - "description": "A number that is unique to that collection; like an ordinal number that is not repeated" - }, - { - "type": "string", - "description": "A unique string that could be a hash or similarly unique" - }, - { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "A unique string that could be a UUIDv4" - } - ] - }, - "di": { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "The device ID which is an UUIDv4 string" - }, - "base": { - "type": "string", - "description": "The base URI to be used if the links are relative URIs (i.e. relative references); see base URI in Core spec for details", - "format": "uri" - } - }, - "minProperties": 1 - }, - "oic.collection.tagged-setoflinks": { - "type": "array", - "description": "A tagged link is a set (array) of links that are tagged with one or more key-value pairs usually either an ID or Name or both", - "items": [ - { - "$ref": "#/definitions/oic.collection.tags" - }, - { - "$ref": "#/definitions/oic.collection.setoflinks" - } - ], - "additionalItems": false - }, - "oic.collection.setof-tagged-setoflinks": { - "type": "array", - "items": [ - { - "$ref": "#/definitions/oic.collection.tagged-setoflinks" - } - ], - "additionalItems": false - }, "oic.collection.alllinks": { "description": "All forms of links in a collection", "oneOf": [ - { - "$ref": "#/definitions/oic.collection.setof-tagged-setoflinks" - }, - { - "$ref": "#/definitions/oic.collection.tagged-setoflinks" - }, { "$ref": "#/definitions/oic.collection.setoflinks" } diff --git a/schemas/oic.collection.batch-retrieve-schema.json b/schemas/oic.collection.batch-retrieve-schema.json index 9e1fb25..3c30057 100644 --- a/schemas/oic.collection.batch-retrieve-schema.json +++ b/schemas/oic.collection.batch-retrieve-schema.json @@ -11,11 +11,23 @@ "href": { "type": "string", "description": "URI of the target resource relative assuming the collection URI as anchor" - } + }, + "rep": { + "oneOf": [ + { + "type": "object", + "description": "The response payload from a single resource" + }, + { + "type": "array", + "description": " The response payload from a collection (batch) resource" + } + ] }, - "additionalProperties": true, + "additionalProperties": false, "required": [ - "href" + "href", + "rep" ] } } From 5ac587f41b36f545f08fb2a24404908893524abf Mon Sep 17 00:00:00 2001 From: mjkoster Date: Mon, 24 Oct 2016 10:01:11 -0700 Subject: [PATCH 40/55] Make "rel" an array The "rel" parameter needs to also be a multi value (repeatable) array as per RFC6690 --- schemas/oic.oic-link-schema.json | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 71ba3ea..a0fb734 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -13,9 +13,15 @@ "format": "uri" }, "rel": { - "type": "string", - "default": "hosts", - "maxLength": 64, + "type": "array", + "items": [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": ["hosts"], "description": "The relation of the target URI referenced by the link to the context URI" }, "rt": { From 80067a57ab0b4a167b2b61a5587887daa9bafd20 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Sun, 30 Oct 2016 12:35:07 -0700 Subject: [PATCH 41/55] updated di and ins UUID made "di" and "ins" use reference to UUID definition instead of pattern property --- schemas/oic.oic-link-schema.json | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index a0fb734..f2f7656 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -49,9 +49,8 @@ "description": "The interface set supported by this resource" }, "di": { - "type": "string", - "description": "The Device ID on which the Relative Reference in href is to be resolved on. Base URI should be used in preference where possible", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier for device (UUID)", }, "buri": { "type": "string", @@ -111,9 +110,8 @@ "description": "Any unique string including a URI" }, { - "type": "string", - "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$", - "description": "Use UUID for universal uniqueness - used in /oic/res to identify the device" + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier (UUID)", } ], "description": "The instance identifier for this web link in an array of web links - used in collections" From b6a0105e718f086ec39a3b78df16bc64c237bcfd Mon Sep 17 00:00:00 2001 From: mjkoster Date: Sun, 30 Oct 2016 12:45:09 -0700 Subject: [PATCH 42/55] fix typo in JSON fix typo in JSON that the editor didn't flag --- schemas/oic.oic-link-schema.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index f2f7656..f592495 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -50,7 +50,7 @@ }, "di": { "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "Unique identifier for device (UUID)", + "description": "Unique identifier for device (UUID)" }, "buri": { "type": "string", @@ -111,7 +111,7 @@ }, { "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "Unique identifier (UUID)", + "description": "Unique identifier (UUID)" } ], "description": "The instance identifier for this web link in an array of web links - used in collections" From 23470b02e5e9ea99e7c17a170a6761222ab199b2 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Mon, 31 Oct 2016 08:39:28 -0700 Subject: [PATCH 43/55] remove readonly json property from link parameter definitions readonly only applies to resource properties, not link parameter definitions. The "links" property of a collection resource is array of links with parameters. The links property is already made readonly through the oic.if.ll interface. --- schemas/oic.oic-link-schema.json | 6 ------ 1 file changed, 6 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index f592495..78d3507 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -33,7 +33,6 @@ } ], "minItems" : 1, - "readOnly": true, "description": "Resource Type" }, "if": { @@ -45,7 +44,6 @@ } ], "minItems": 1, - "readOnly": true, "description": "The interface set supported by this resource" }, "di": { @@ -59,23 +57,19 @@ "format": "uri" }, "p": { - "readOnly": true, "description": "Specifies the framework policies on the Resource referenced by the target URI", "type": "object", "properties": { "bm": { - "readOnly": true, "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", "type": "integer" }, "sec": { - "readOnly": true, "description": "Specifies if security needs to be turned on when looking to interact with the Resource", "default": false, "type": "boolean" }, "port": { - "readOnly": true, "description": "Secure port to be used for connection", "type": "integer" } From 08f9a6d22baa56f6703a093b2acd7a85b7ceb707 Mon Sep 17 00:00:00 2001 From: SiMet Date: Thu, 10 Nov 2016 10:03:32 +0100 Subject: [PATCH 44/55] Fix for invalid json schema Fix for missing closing bracket in oic.collection.batch-retrive-schema.json --- schemas/oic.collection.batch-retrieve-schema.json | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/schemas/oic.collection.batch-retrieve-schema.json b/schemas/oic.collection.batch-retrieve-schema.json index 3c30057..cc73004 100644 --- a/schemas/oic.collection.batch-retrieve-schema.json +++ b/schemas/oic.collection.batch-retrieve-schema.json @@ -23,11 +23,12 @@ "description": " The response payload from a collection (batch) resource" } ] - }, - "additionalProperties": false, - "required": [ - "href", - "rep" - ] + } + }, + "additionalProperties": false, + "required": [ + "href", + "rep" + ] } } From f69485f29fbc2234e8d4b53b5bb2b3fca71dd340 Mon Sep 17 00:00:00 2001 From: SiMet Date: Thu, 10 Nov 2016 10:06:26 +0100 Subject: [PATCH 45/55] Fix allOf section in oic.collection-schema.json --- schemas/oic.collection-schema.json | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 164a1a8..9fcf8cc 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -62,9 +62,7 @@ }, "type": "object", "allOf": [ - { - "$ref": "oic.core-schema.json#/definitions/oic.core", - "$ref": "#/definitions/oic.collection" - } + {"$ref": "oic.core-schema.json#/definitions/oic.core"}, + {"$ref": "#/definitions/oic.collection"} ] } From f9d3f3317be42cc7a61e32685dda7e30dff41f55 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Tue, 15 Nov 2016 16:23:41 +0900 Subject: [PATCH 46/55] Update oic.oic-link schema Allow the "rel" link attribute to be either string or array --- schemas/oic.oic-link-schema.json | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 78d3507..451a5ec 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -13,16 +13,25 @@ "format": "uri" }, "rel": { - "type": "array", - "items": [ + "oneOf":[ + { + "type": "array", + "items": [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": ["hosts"], + }, { "type": "string", - "maxLength": 64 + "maxLength": 64, + "default": "hosts" } ], - "minItems": 1, - "default": ["hosts"], - "description": "The relation of the target URI referenced by the link to the context URI" + "description": "The relation of the target URI referenced by the link to the context URI" }, "rt": { "type": "array", From e37baa39d3500afc5f91f12dccb32ee38f08fbd9 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Tue, 15 Nov 2016 16:53:12 +0900 Subject: [PATCH 47/55] change the batch update payload to match the batch retrieve payload as agreed in the Taipei F2F meeting --- .../oic.collection.batch-update-schema.json | 31 +++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/schemas/oic.collection.batch-update-schema.json b/schemas/oic.collection.batch-update-schema.json index 9d79022..d8f2a52 100644 --- a/schemas/oic.collection.batch-update-schema.json +++ b/schemas/oic.collection.batch-update-schema.json @@ -3,6 +3,33 @@ "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection.batch-update-schema.json#", "title": "Collection Batch Update Format", - "type": "object", - "description": "object with keywords to identify properties to be updated in all target resources that have matching property names" + "type": "array", + "minItems": 1, + "items": { + "type": "object", + "properties": { + "href": { + "type": "string", + "description": "URI of the target resource relative assuming the collection URI as anchor" + }, + "rep": { + "oneOf": [ + { + "type": "object", + "description": "The response payload from a single resource" + }, + { + "type": "array", + "description": " The response payload from a collection (batch) resource" + } + ] + } + }, + "additionalProperties": false, + "required": [ + "href", + "rep" + ] + }, + "description": "array of resource representations to apply to the batch collection, using href to indicate which resource(s) in the batch to update. If the href property is empty, effectively making the URI reference to the collection itself, the representation is to be applied to all resources in the batch" } From d87fb8b9a6fb4ffe7ff93398feea7462024760d9 Mon Sep 17 00:00:00 2001 From: mjkoster Date: Tue, 15 Nov 2016 21:47:55 +0900 Subject: [PATCH 48/55] set additionalproperties to true all resource definitions need additionalproperties to be true for validation of composite resources --- schemas/oic.collection.batch-retrieve-schema.json | 2 +- schemas/oic.collection.batch-update-schema.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/schemas/oic.collection.batch-retrieve-schema.json b/schemas/oic.collection.batch-retrieve-schema.json index cc73004..7618861 100644 --- a/schemas/oic.collection.batch-retrieve-schema.json +++ b/schemas/oic.collection.batch-retrieve-schema.json @@ -25,7 +25,7 @@ ] } }, - "additionalProperties": false, + "additionalProperties": true, "required": [ "href", "rep" diff --git a/schemas/oic.collection.batch-update-schema.json b/schemas/oic.collection.batch-update-schema.json index d8f2a52..6f373c0 100644 --- a/schemas/oic.collection.batch-update-schema.json +++ b/schemas/oic.collection.batch-update-schema.json @@ -25,7 +25,7 @@ ] } }, - "additionalProperties": false, + "additionalProperties": true, "required": [ "href", "rep" From 864f38b6052b259649ad0ad7135f366e8efc0904 Mon Sep 17 00:00:00 2001 From: SiMet Date: Thu, 17 Nov 2016 10:15:48 +0100 Subject: [PATCH 49/55] Fix for invalid json of oic.oic-link-schema.json --- schemas/oic.oic-link-schema.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 451a5ec..631b8d1 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -23,7 +23,7 @@ } ], "minItems": 1, - "default": ["hosts"], + "default": ["hosts"] }, { "type": "string", From 716ef77d0a877e000cd816cb6ee871551cd69271 Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 29 Nov 2016 14:19:29 -0800 Subject: [PATCH 50/55] Add files via upload --- schemas/oic.collection-schema.json | 132 +++++++------ schemas/oic.oic-link-schema.json | 290 +++++++++++++++-------------- 2 files changed, 212 insertions(+), 210 deletions(-) diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index 9fcf8cc..e6d5aa7 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -1,68 +1,64 @@ -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", - "title": "Collection", - "definitions": { - "oic.collection.setoflinks": { - "description": "A set (array) of simple or individual OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", - "type": "array", - "items": { - "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" - } - }, - "oic.collection.alllinks": { - "description": "All forms of links in a collection", - "oneOf": [ - { - "$ref": "#/definitions/oic.collection.setoflinks" - } - ] - }, - "oic.collection": { - "type": "object", - "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", - "properties": { - "n": { - "type": "string", - "description": "User friendly name of the collection" }, - "id": { - "anyOf": [ - { - "type": "integer", - "description": "A number that is unique to that collection; like an ordinal number that is not repeated" - }, - { - "type": "string", - "description": "A unique string that could be a hash or similarly unique" - }, - { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "A unique string that could be a UUIDv4" - } - ], - "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" - }, - "di": { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A definition of /oic/res" - }, - "rts": { - "$ref": "oic.core-schema.json#/definitions/oic.core/properties/rt", - "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, - "drel": { - "type": "string", - "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" - }, - "links": { - "$ref": "#/definitions/oic.collection.alllinks" - } - } - } - }, - "type": "object", - "allOf": [ - {"$ref": "oic.core-schema.json#/definitions/oic.core"}, - {"$ref": "#/definitions/oic.collection"} - ] -} +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", + "title": "Collection", + "definitions": { + "oic.collection.setoflinks": { + "description": "A set (array) of simple or individual OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", + "type": "array", + "items": { + "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" + } + }, + "oic.collection.alllinks": { + "description": "All forms of links in a collection", + "$ref": "#/definitions/oic.collection.setoflinks" + }, + "oic.collection": { + "type": "object", + "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", + "properties": { + "n": { + "type": "string", + "description": "User friendly name of the collection" }, + "id": { + "anyOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "A unique string that could be a UUIDv4" + } + ], + "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" + }, + "di": { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A definition of /oic/res" + }, + "rts": { + "$ref": "oic.core-schema.json#/definitions/oic.core/properties/rt", + "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, + "drel": { + "type": "string", + "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" + }, + "links": { + "$ref": "#/definitions/oic.collection.alllinks" + } + } + } + }, + "type": "object", + "allOf": [ + {"$ref": "oic.core-schema.json#/definitions/oic.core"}, + {"$ref": "#/definitions/oic.collection"} + ] +} diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 631b8d1..c3e5f59 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -1,142 +1,148 @@ -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", - "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.oic-link-schema.json#", - "definitions": { - "oic.oic-link": { - "type": "object", - "properties": { - "href": { - "type": "string", - "maxLength": 256, - "description": "This is the target URI, it can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", - "format": "uri" - }, - "rel": { - "oneOf":[ - { - "type": "array", - "items": [ - { - "type": "string", - "maxLength": 64 - } - ], - "minItems": 1, - "default": ["hosts"] - }, - { - "type": "string", - "maxLength": 64, - "default": "hosts" - } - ], - "description": "The relation of the target URI referenced by the link to the context URI" - }, - "rt": { - "type": "array", - "items" : [ - { - "type" : "string", - "maxLength": 64 - } - ], - "minItems" : 1, - "description": "Resource Type" - }, - "if": { - "type": "array", - "items": [ - { - "type" : "string", - "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] - } - ], - "minItems": 1, - "description": "The interface set supported by this resource" - }, - "di": { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "Unique identifier for device (UUID)" - }, - "buri": { - "type": "string", - "description": "The base URI used to fully qualify a Relative Reference in the href parameter. Use the OCF Schema for URI", - "maxLength": 256, - "format": "uri" - }, - "p": { - "description": "Specifies the framework policies on the Resource referenced by the target URI", - "type": "object", - "properties": { - "bm": { - "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", - "type": "integer" - }, - "sec": { - "description": "Specifies if security needs to be turned on when looking to interact with the Resource", - "default": false, - "type": "boolean" - }, - "port": { - "description": "Secure port to be used for connection", - "type": "integer" - } - }, - "required" : ["bm"] - }, - "bp": { - "type": "string", - "description": " Batch Parameters: URI parameters to use with an oic.if.b batch request using this link" - }, - "title": { - "type": "string", - "maxLength": 64, - "description": "A title for the link relation. Can be used by the UI to provide a context" - }, - "anchor": { - "type": "string", - "maxLength": 256, - "description": "This is used to override the context URI e.g. override the URI of the containing collection", - "format": "uri" - }, - "ins": { - "oneOf": [ - { - "type": "integer", - "description": "An ordinal number that is not repeated - must be unique in the collection context" - }, - { - "type": "string", - "maxLength": 256, - "format" : "uri", - "description": "Any unique string including a URI" - }, - { - "$ref": "oic.types-schema.json#/definitions/uuid", - "description": "Unique identifier (UUID)" - } - ], - "description": "The instance identifier for this web link in an array of web links - used in collections" - }, - "type": { - "type": "array", - "description": "A hint at the representation of the resource referenced by the target URI. This represents the media types that are used for both accepting and emitting", - "items" : [ - { - "type": "string", - "maxLength": 64 - } - ], - "minItems": 1, - "default": "application/cbor" - } - }, - "required": [ "href", "rt", "if" ] - } - }, - "type": "object", - "allOf": [ - { "$ref": "#/definitions/oic.oic-link" } - ] -} +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.oic-link-schema.json#", + "definitions": { + "oic.oic-link": { + "type": "object", + "properties": { + "href": { + "type": "string", + "maxLength": 256, + "description": "This is the target URI, it can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", + "format": "uri" + }, + "rel": { + "oneOf":[ + { + "type": "array", + "items": [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": ["hosts"] + }, + { + "type": "string", + "maxLength": 64, + "default": "hosts" + } + ], + "description": "The relation of the target URI referenced by the link to the context URI" + }, + "rt": { + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "minItems" : 1, + "readOnly": true, + "description": "Resource Type" + }, + "if": { + "type": "array", + "items": [ + { + "type" : "string", + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] + } + ], + "minItems": 1, + "readOnly": true, + "description": "The interface set supported by this resource" + }, + "di": { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier for device (UUID)" + }, + "buri": { + "type": "string", + "description": "The base URI used to fully qualify a Relative Reference in the href parameter. Use the OCF Schema for URI", + "maxLength": 256, + "format": "uri" + }, + "p": { + "readOnly": true, + "description": "Specifies the framework policies on the Resource referenced by the target URI", + "type": "object", + "properties": { + "bm": { + "readOnly": true, + "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", + "type": "integer" + }, + "sec": { + "readOnly": true, + "description": "Specifies if security needs to be turned on when looking to interact with the Resource", + "default": false, + "type": "boolean" + }, + "port": { + "readOnly": true, + "description": "Secure port to be used for connection", + "type": "integer" + } + }, + "required" : ["bm"] + }, + "bp": { + "type": "string", + "description": " Batch Parameters: URI parameters to use with an oic.if.b batch request using this link" + }, + "title": { + "type": "string", + "maxLength": 64, + "description": "A title for the link relation. Can be used by the UI to provide a context" + }, + "anchor": { + "type": "string", + "maxLength": 256, + "description": "This is used to override the context URI e.g. override the URI of the containing collection", + "format": "uri" + }, + "ins": { + "oneOf": [ + { + "type": "integer", + "description": "An ordinal number that is not repeated - must be unique in the collection context" + }, + { + "type": "string", + "maxLength": 256, + "format" : "uri", + "description": "Any unique string including a URI" + }, + { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier (UUID)" + } + ], + "description": "The instance identifier for this web link in an array of web links - used in collections" + }, + "type": { + "type": "array", + "description": "A hint at the representation of the resource referenced by the target URI. This represents the media types that are used for both accepting and emitting", + "items" : [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": "application/cbor" + } + }, + "required": [ "href", "rt", "if" ] + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.oic-link" } + ] +} From 4cc8c8fc2ad7c773b8bb0c3c3bac4b2edb996365 Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 29 Nov 2016 14:27:39 -0800 Subject: [PATCH 51/55] Add files via upload --- oic.collection-schema.json | 64 ++++++++++++++++ oic.oic-link-schema.json | 148 +++++++++++++++++++++++++++++++++++++ 2 files changed, 212 insertions(+) create mode 100644 oic.collection-schema.json create mode 100644 oic.oic-link-schema.json diff --git a/oic.collection-schema.json b/oic.collection-schema.json new file mode 100644 index 0000000..e6d5aa7 --- /dev/null +++ b/oic.collection-schema.json @@ -0,0 +1,64 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.collection-schema.json#", + "title": "Collection", + "definitions": { + "oic.collection.setoflinks": { + "description": "A set (array) of simple or individual OIC Links. In addition to properties required for an OIC Link, the identifier for that link in this set is also required", + "type": "array", + "items": { + "$ref": "oic.oic-link-schema.json#/definitions/oic.oic-link" + } + }, + "oic.collection.alllinks": { + "description": "All forms of links in a collection", + "$ref": "#/definitions/oic.collection.setoflinks" + }, + "oic.collection": { + "type": "object", + "description": "A collection is a set (array) of tagged-link or set (array) of simple links along with additional properties to describe the collection itself", + "properties": { + "n": { + "type": "string", + "description": "User friendly name of the collection" }, + "id": { + "anyOf": [ + { + "type": "integer", + "description": "A number that is unique to that collection; like an ordinal number that is not repeated" + }, + { + "type": "string", + "description": "A unique string that could be a hash or similarly unique" + }, + { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "A unique string that could be a UUIDv4" + } + ], + "description": "ID for the collection. Can be an value that is unique to the use context or a UUIDv4" + }, + "di": { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "The device ID which is an UUIDv4 string; used for backward compatibility with Spec A definition of /oic/res" + }, + "rts": { + "$ref": "oic.core-schema.json#/definitions/oic.core/properties/rt", + "description": "Defines the list of allowable resource types (for Target and anchors) in links included in the collection; new links being created can only be from this list" }, + "drel": { + "type": "string", + "description": "When specified this is the default relationship to use when an OIC Link does not specify an explicit relationship with *rel* parameter" + }, + "links": { + "$ref": "#/definitions/oic.collection.alllinks" + } + } + } + }, + "type": "object", + "allOf": [ + {"$ref": "oic.core-schema.json#/definitions/oic.core"}, + {"$ref": "#/definitions/oic.collection"} + ] +} diff --git a/oic.oic-link-schema.json b/oic.oic-link-schema.json new file mode 100644 index 0000000..c3e5f59 --- /dev/null +++ b/oic.oic-link-schema.json @@ -0,0 +1,148 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "description" : "Copyright (c) 2016 Open Connectivity Foundation, Inc. All rights reserved.", + "id": "https://www.openconnectivity.org/ocf-apis/core/schemas/oic.oic-link-schema.json#", + "definitions": { + "oic.oic-link": { + "type": "object", + "properties": { + "href": { + "type": "string", + "maxLength": 256, + "description": "This is the target URI, it can be specified as a Relative Reference or fully-qualified URI. Relative Reference should be used along with the di parameter to make it unique.", + "format": "uri" + }, + "rel": { + "oneOf":[ + { + "type": "array", + "items": [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": ["hosts"] + }, + { + "type": "string", + "maxLength": 64, + "default": "hosts" + } + ], + "description": "The relation of the target URI referenced by the link to the context URI" + }, + "rt": { + "type": "array", + "items" : [ + { + "type" : "string", + "maxLength": 64 + } + ], + "minItems" : 1, + "readOnly": true, + "description": "Resource Type" + }, + "if": { + "type": "array", + "items": [ + { + "type" : "string", + "enum" : ["oic.if.baseline", "oic.if.ll", "oic.if.b", "oic.if.rw", "oic.if.r", "oic.if.a", "oic.if.s" ] + } + ], + "minItems": 1, + "readOnly": true, + "description": "The interface set supported by this resource" + }, + "di": { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier for device (UUID)" + }, + "buri": { + "type": "string", + "description": "The base URI used to fully qualify a Relative Reference in the href parameter. Use the OCF Schema for URI", + "maxLength": 256, + "format": "uri" + }, + "p": { + "readOnly": true, + "description": "Specifies the framework policies on the Resource referenced by the target URI", + "type": "object", + "properties": { + "bm": { + "readOnly": true, + "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", + "type": "integer" + }, + "sec": { + "readOnly": true, + "description": "Specifies if security needs to be turned on when looking to interact with the Resource", + "default": false, + "type": "boolean" + }, + "port": { + "readOnly": true, + "description": "Secure port to be used for connection", + "type": "integer" + } + }, + "required" : ["bm"] + }, + "bp": { + "type": "string", + "description": " Batch Parameters: URI parameters to use with an oic.if.b batch request using this link" + }, + "title": { + "type": "string", + "maxLength": 64, + "description": "A title for the link relation. Can be used by the UI to provide a context" + }, + "anchor": { + "type": "string", + "maxLength": 256, + "description": "This is used to override the context URI e.g. override the URI of the containing collection", + "format": "uri" + }, + "ins": { + "oneOf": [ + { + "type": "integer", + "description": "An ordinal number that is not repeated - must be unique in the collection context" + }, + { + "type": "string", + "maxLength": 256, + "format" : "uri", + "description": "Any unique string including a URI" + }, + { + "$ref": "oic.types-schema.json#/definitions/uuid", + "description": "Unique identifier (UUID)" + } + ], + "description": "The instance identifier for this web link in an array of web links - used in collections" + }, + "type": { + "type": "array", + "description": "A hint at the representation of the resource referenced by the target URI. This represents the media types that are used for both accepting and emitting", + "items" : [ + { + "type": "string", + "maxLength": 64 + } + ], + "minItems": 1, + "default": "application/cbor" + } + }, + "required": [ "href", "rt", "if" ] + } + }, + "type": "object", + "allOf": [ + { "$ref": "#/definitions/oic.oic-link" } + ] +} From 744c93fbd1916d1ef3da913c1db9c57214c17e67 Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 29 Nov 2016 15:19:41 -0800 Subject: [PATCH 52/55] Add files via upload From fd367ac3ea7cb63696fe770799a6eaeb07f6fbcb Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 29 Nov 2016 16:36:49 -0800 Subject: [PATCH 53/55] Update oic.oic-link-schema.json --- schemas/oic.oic-link-schema.json | 4 ---- 1 file changed, 4 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index c3e5f59..681b8db 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -91,10 +91,6 @@ }, "required" : ["bm"] }, - "bp": { - "type": "string", - "description": " Batch Parameters: URI parameters to use with an oic.if.b batch request using this link" - }, "title": { "type": "string", "maxLength": 64, From d9a9dd59d773c9fb48f185ea19291960fff3a01b Mon Sep 17 00:00:00 2001 From: rabardini Date: Tue, 29 Nov 2016 16:49:21 -0800 Subject: [PATCH 54/55] Update oic.oic-link-schema.json --- schemas/oic.oic-link-schema.json | 6 ------ 1 file changed, 6 deletions(-) diff --git a/schemas/oic.oic-link-schema.json b/schemas/oic.oic-link-schema.json index 681b8db..598f9c9 100755 --- a/schemas/oic.oic-link-schema.json +++ b/schemas/oic.oic-link-schema.json @@ -42,7 +42,6 @@ } ], "minItems" : 1, - "readOnly": true, "description": "Resource Type" }, "if": { @@ -54,7 +53,6 @@ } ], "minItems": 1, - "readOnly": true, "description": "The interface set supported by this resource" }, "di": { @@ -68,23 +66,19 @@ "format": "uri" }, "p": { - "readOnly": true, "description": "Specifies the framework policies on the Resource referenced by the target URI", "type": "object", "properties": { "bm": { - "readOnly": true, "description": "Specifies the framework policies on the Resource referenced by the target URI for e.g. observable and discoverable", "type": "integer" }, "sec": { - "readOnly": true, "description": "Specifies if security needs to be turned on when looking to interact with the Resource", "default": false, "type": "boolean" }, "port": { - "readOnly": true, "description": "Secure port to be used for connection", "type": "integer" } From 7e3b1b40e557adf5fa959a9fcf4c971ee56ae682 Mon Sep 17 00:00:00 2001 From: rabardini Date: Wed, 30 Nov 2016 06:58:46 -0800 Subject: [PATCH 55/55] Update oic.collection-schema.json --- schemas/oic.collection-schema.json | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/schemas/oic.collection-schema.json b/schemas/oic.collection-schema.json index e6d5aa7..9f37c29 100755 --- a/schemas/oic.collection-schema.json +++ b/schemas/oic.collection-schema.json @@ -13,7 +13,11 @@ }, "oic.collection.alllinks": { "description": "All forms of links in a collection", - "$ref": "#/definitions/oic.collection.setoflinks" + "oneOf": [ + { + "$ref": "#/definitions/oic.collection.setoflinks" + } + ] }, "oic.collection": { "type": "object",