diff --git a/api/part2/openapi/examples/controlstreams/controlStream-ptz-create.json b/api/part2/openapi/examples/controlstreams/controlStream-ptz-create.json deleted file mode 100644 index 35aff8da..00000000 --- a/api/part2/openapi/examples/controlstreams/controlStream-ptz-create.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "name": "PTZ Control", - "inputName": "ptz", - "controlledProperties": [ - { - "definition": "http://sensorml.com/ont/swe/property/PanAngle", - "label": "Pan Angle" - }, - { - "definition": "http://sensorml.com/ont/swe/property/TiltAngle", - "label": "Tilt Angle" - }, - { - "definition": "http://sensorml.com/ont/swe/property/ZoomFactor", - "label": "Zoom Factor" - } - ] -} \ No newline at end of file diff --git a/api/part2/openapi/examples/controlstreams/controlstream-ptz-create.json b/api/part2/openapi/examples/controlstreams/controlstream-ptz-create.json new file mode 100644 index 00000000..58f3e929 --- /dev/null +++ b/api/part2/openapi/examples/controlstreams/controlstream-ptz-create.json @@ -0,0 +1,43 @@ +{ + "name": "Garage Video Camera 001 - PTZ Control", + "inputName": "ptz", + "async": false, + "schema": { + "commandFormat": "application/json", + "parametersSchema": { + "type": "DataRecord", + "fields": [ + { + "name": "pan", + "type": "Quantity", + "definition": "http://sensorml.com/ont/swe/property/PanAngle", + "label": "Pan Angle", + "description": "Rotation of the camera around its vertical axis (i.e. causing the image to translate along its horizontal axis)", + "uom": { + "code": "deg" + } + }, + { + "name": "tilt", + "type": "Quantity", + "definition": "http://sensorml.com/ont/swe/property/PanAngle", + "label": "Pan Angle", + "description": "Rotation of the camera around its horizontal axis (i.e. causing the image to translate along its vertical axis)", + "uom": { + "code": "deg" + } + }, + { + "name": "zoom", + "type": "Quantity", + "definition": "http://sensorml.com/ont/swe/property/ZoomFactor", + "label": "Zoom Factor", + "description": "Amount of zoom, 0 being the highest FOV and 100 being the lowest", + "uom": { + "code": "%" + } + } + ] + } + } +} \ No newline at end of file diff --git a/api/part2/openapi/examples/controlstreams/controlStream-ptz.json b/api/part2/openapi/examples/controlstreams/controlstream-ptz.json similarity index 100% rename from api/part2/openapi/examples/controlstreams/controlStream-ptz.json rename to api/part2/openapi/examples/controlstreams/controlstream-ptz.json diff --git a/api/part2/openapi/examples/datastreams/datastream-simple.json b/api/part2/openapi/examples/datastreams/datastream-simple.json index 9c70d075..1c3c24c5 100644 --- a/api/part2/openapi/examples/datastreams/datastream-simple.json +++ b/api/part2/openapi/examples/datastreams/datastream-simple.json @@ -38,8 +38,8 @@ "live": true, "links": [ { - "rel" : "self", - "href" : "https://data.example.org/api/datastreams/958tf25kjm2f6", + "rel" : "observations", + "href" : "https://data.example.org/api/datastreams/958tf25kjm2f6/observations", "type" : "application/json" } ] diff --git a/api/part2/openapi/examples/schemas/commandSchema-ptz-json.json b/api/part2/openapi/examples/schemas/commandSchema-ptz-json.json index 7d129e4e..99f297a5 100644 --- a/api/part2/openapi/examples/schemas/commandSchema-ptz-json.json +++ b/api/part2/openapi/examples/schemas/commandSchema-ptz-json.json @@ -1,6 +1,6 @@ { "commandFormat": "application/json", - "paramsSchema": { + "parametersSchema": { "type": "DataRecord", "fields": [ { diff --git a/api/part2/openapi/examples/schemas/commandSchema-ptz-jsonschema-byref.json b/api/part2/openapi/examples/schemas/commandSchema-ptz-jsonschema-byref.json index a0e5d51f..fcdc8863 100644 --- a/api/part2/openapi/examples/schemas/commandSchema-ptz-jsonschema-byref.json +++ b/api/part2/openapi/examples/schemas/commandSchema-ptz-jsonschema-byref.json @@ -4,7 +4,7 @@ { "$ref": "https://raw.githubusercontent.com/opengeospatial/ogcapi-connected-systems/master/api/part2/openapi/schemas/json/command_view.json" }, { "properties": { - "params": { + "parameters": { "type": "object", "properties": { "pan": { diff --git a/api/part2/openapi/requests/commandSchema.yaml b/api/part2/openapi/requests/commandSchema.yaml index 14b98a16..51270204 100644 --- a/api/part2/openapi/requests/commandSchema.yaml +++ b/api/part2/openapi/requests/commandSchema.yaml @@ -4,10 +4,10 @@ content: schema: $ref: ../schemas/json/commandSchema.json examples: - ptz-cmdjson: + ptz-json: summary: PTZ Control - Command JSON value: - $ref: ../examples/schemas/commandSchema-ptz-cmdjson.json + $ref: ../examples/schemas/commandSchema-ptz-json.json ptz-swejson: summary: PTZ Control - SWE JSON value: diff --git a/api/part2/openapi/requests/controlStream.yaml b/api/part2/openapi/requests/controlStream.yaml index 86625cd2..ee176b9d 100644 --- a/api/part2/openapi/requests/controlStream.yaml +++ b/api/part2/openapi/requests/controlStream.yaml @@ -2,4 +2,9 @@ description: A single `ControlStream` resource content: application/json: schema: - $ref: ../schemas/json/controlStream.json \ No newline at end of file + $ref: ../schemas/json/controlStream.json + examples: + simple: + summary: PTZ Control + value: + $ref: ../examples/controlstreams/controlstream-ptz-create.json \ No newline at end of file diff --git a/api/part2/openapi/requests/dataStream.yaml b/api/part2/openapi/requests/dataStream.yaml index 44daf431..e91f43b5 100644 --- a/api/part2/openapi/requests/dataStream.yaml +++ b/api/part2/openapi/requests/dataStream.yaml @@ -2,4 +2,9 @@ description: A single `DataStream` resource content: application/json: schema: - $ref: ../schemas/json/dataStream.json \ No newline at end of file + $ref: ../schemas/json/dataStream.json + examples: + simple: + summary: Simple Datastream (1 observed property) + value: + $ref: ../examples/datastreams/datastream-simple-create.json \ No newline at end of file diff --git a/api/part2/openapi/responses/commandSchema.yaml b/api/part2/openapi/responses/commandSchema.yaml index 61f661e7..ed8005df 100644 --- a/api/part2/openapi/responses/commandSchema.yaml +++ b/api/part2/openapi/responses/commandSchema.yaml @@ -4,10 +4,10 @@ content: schema: $ref: ../schemas/json/commandSchema.json examples: - ptz-cmdjson: + ptz-json: summary: PTZ Control - JSON value: - $ref: ../examples/schemas/commandSchema-ptz-cmdjson.json + $ref: ../examples/schemas/commandSchema-ptz-json.json ptz-swejson: summary: PTZ Control - SWE JSON value: diff --git a/api/part2/openapi/responses/controlStream.yaml b/api/part2/openapi/responses/controlStream.yaml index 8289975b..a8fd8720 100644 --- a/api/part2/openapi/responses/controlStream.yaml +++ b/api/part2/openapi/responses/controlStream.yaml @@ -2,4 +2,9 @@ description: OK. Successful request content: application/json: schema: - $ref: ../schemas/json/controlStream.json \ No newline at end of file + $ref: ../schemas/json/controlStream.json + examples: + simple: + summary: PTZ Control + value: + $ref: ../examples/controlstreams/controlstream-ptz.json \ No newline at end of file diff --git a/api/part2/standard/sections/clause_20_requirements_class_json_encoding.adoc b/api/part2/standard/sections/clause_20_requirements_class_json_encoding.adoc index e5cf9b14..c8d71d12 100644 --- a/api/part2/standard/sections/clause_20_requirements_class_json_encoding.adoc +++ b/api/part2/standard/sections/clause_20_requirements_class_json_encoding.adoc @@ -165,7 +165,7 @@ This is a simple control stream for a camera accepting PTZ commands in JSON form [source%autofit,json] ---- -include::../openapi/examples/controlstreams/controlStream-ptz.json[] +include::../openapi/examples/controlstreams/controlstream-ptz.json[] ---- =================