From f2e8d4810885e1ac24efa30b1a5770a82abdd364 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 12:16:12 -0400 Subject: [PATCH 01/13] Added error response color temperature controller specific not supported in current color mode --- .../alexa_smart_home_message_schema.json | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 969ea29..4eda630 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -3171,6 +3171,28 @@ "$ref": "#/definitions/common.properties/temperature" } } + }, + "payload.ColorTemperatureController.NOT_SUPPORTED_IN_CURRENT_MODE": { + "type": "object", + "required": [ + "type" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "NOT_SUPPORTED_IN_CURRENT_MODE" + ] + }, + "message": { + "$ref": "#/definitions/common.properties/message" + }, + "currentDeviceMode": { + "enum": [ + "COLOR" + ] + } + } } }, "ResponseOrStateReport.properties": { @@ -3401,6 +3423,20 @@ } } }, + { + "additionalProperties": false, + "properties": { + "header": { + "$ref": "#/definitions/ErrorResponse.properties/header.ColorTemperatureController" + }, + "endpoint": { + "$ref": "#/definitions/common.properties/endpoint" + }, + "payload": { + "$ref": "#/definitions/ErrorResponse.properties/payload.ColorTemperatureController.NOT_SUPPORTED_IN_CURRENT_MODE" + } + } + }, { "additionalProperties": false, "properties": { From bd3483c8b36ece0b9b68fc752c413b53c1163889 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 12:18:10 -0400 Subject: [PATCH 02/13] Added motion/contact sensors schema properties --- .../alexa_smart_home_message_schema.json | 154 +++++++++++++++++- 1 file changed, 152 insertions(+), 2 deletions(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 4eda630..ac9d809 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -2484,6 +2484,43 @@ } }, "MotionSensor": { + "detectionState": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.MotionSensor" + ] + }, + "name": { + "enum": [ + "detectionState" + ] + }, + "value": { + "enum": [ + "DETECTED", + "NOT_DETECTED" + ] + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, "capabilities": { "type": "object", "required": [ @@ -2491,7 +2528,7 @@ "interface", "version" ], - "additionalProperties": true, + "additionalProperties": false, "properties": { "type": { "enum": [ @@ -2505,11 +2542,83 @@ }, "version": { "$ref": "#/definitions/common.properties/version" + }, + "properties": { + "type": "object", + "required": [ + "supported", + "proactivelyReported", + "retrievable" + ], + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "detectionState" + ] + } + } + } + }, + "proactivelyReported": { + "type": "boolean" + }, + "retrievable": { + "type": "boolean" + } + } } } } }, "ContactSensor": { + "detectionState": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.ContactSensor" + ] + }, + "name": { + "enum": [ + "detectionState" + ] + }, + "value": { + "enum": [ + "DETECTED", + "NOT_DETECTED" + ] + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, "capabilities": { "type": "object", "required": [ @@ -2517,7 +2626,7 @@ "interface", "version" ], - "additionalProperties": true, + "additionalProperties": false, "properties": { "type": { "enum": [ @@ -2531,6 +2640,41 @@ }, "version": { "$ref": "#/definitions/common.properties/version" + }, + "properties": { + "type": "object", + "required": [ + "supported", + "proactivelyReported", + "retrievable" + ], + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "detectionState" + ] + } + } + } + }, + "proactivelyReported": { + "type": "boolean" + }, + "retrievable": { + "type": "boolean" + } + } } } } @@ -2595,6 +2739,12 @@ }, { "$ref": "#/definitions/common.properties/interfaces/ModeController/mode/property" + }, + { + "$ref": "#/definitions/common.properties/interfaces/MotionSensor/detectionState/property" + }, + { + "$ref": "#/definitions/common.properties/interfaces/ContactSensor/detectionState/property" } ] } From 1429c73468ca3dafa3662e7a4da01d71abfdd4cb Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 14:54:50 -0400 Subject: [PATCH 03/13] Added equalizer controller schema capabilities and properties --- .../alexa_smart_home_message_schema.json | 214 +++++++++++++++++- 1 file changed, 212 insertions(+), 2 deletions(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index ac9d809..0c518f9 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -66,6 +66,22 @@ }, "minProperties": 1 }, + "equalizerBands": { + "enum": [ + "BASS", + "MIDRANGE", + "TREBLE" + ] + }, + "equalizerMode": { + "enum": [ + "MOVIE", + "MUSIC", + "NIGHT", + "SPORT", + "TV" + ] + }, "input": { "type": "string", "minLength": 1 @@ -2458,14 +2474,100 @@ } }, "EqualizerController": { + "bands": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.EqualizerController" + ] + }, + "name": { + "enum": [ + "bands" + ] + }, + "value": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name", + "value" + ], + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/definitions/common.properties/equalizerBands" + }, + "value": { + "type": "number" + } + } + } + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, + "mode": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.EqualizerController" + ] + }, + "name": { + "enum": [ + "mode" + ] + }, + "value": { + "$ref": "#/definitions/common.properties/equalizerMode" + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, "capabilities": { "type": "object", "required": [ "type", "interface", - "version" + "version", + "configurations" ], - "additionalProperties": true, + "additionalProperties": false, "properties": { "type": { "enum": [ @@ -2479,6 +2581,108 @@ }, "version": { "$ref": "#/definitions/common.properties/version" + }, + "configurations": { + "type": "object", + "additionalProperties": false, + "properties": { + "bands": { + "type": "object", + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/definitions/common.properties/equalizerBands" + } + } + } + }, + "range": { + "type": "object", + "required": [ + "minimum", + "maximum" + ], + "additionalProperties": false, + "properties": { + "minimum": { + "type": "number" + }, + "maximum": { + "type": "number" + } + } + } + } + }, + "modes": { + "type": "object", + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/definitions/common.properties/equalizerMode" + } + } + } + } + } + } + } + }, + "properties": { + "type": "object", + "required": [ + "supported", + "proactivelyReported", + "retrievable" + ], + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "bands", + "modes" + ] + } + } + } + }, + "proactivelyReported": { + "type": "boolean" + }, + "retrievable": { + "type": "boolean" + } + } } } } @@ -2740,6 +2944,12 @@ { "$ref": "#/definitions/common.properties/interfaces/ModeController/mode/property" }, + { + "$ref": "#/definitions/common.properties/interfaces/EqualizerController/bands/property" + }, + { + "$ref": "#/definitions/common.properties/interfaces/EqualizerController/mode/property" + }, { "$ref": "#/definitions/common.properties/interfaces/MotionSensor/detectionState/property" }, From 76229f4487e45360267e55b8c4aa97088e9b7d00 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 15:04:41 -0400 Subject: [PATCH 04/13] Added playback controller schema capabilities --- .../alexa_smart_home_message_schema.json | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 0c518f9..edebc40 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -2687,6 +2687,48 @@ } } }, + "PlaybackController": { + "capabilities": { + "type": "object", + "required": [ + "type", + "interface", + "version" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "AlexaInterface" + ] + }, + "interface": { + "enum": [ + "Alexa.PlaybackController" + ] + }, + "version": { + "$ref": "#/definitions/common.properties/version" + }, + "supportedOperations": { + "type": "array", + "uniqueItems": true, + "items": { + "enum": [ + "Play", + "Pause", + "Stop", + "StartOver", + "Previous", + "Next", + "Rewind", + "FastForward" + ] + } + } + } + } + }, "MotionSensor": { "detectionState": { "property": { @@ -3148,6 +3190,9 @@ { "$ref": "#/definitions/common.properties/interfaces/EqualizerController/capabilities" }, + { + "$ref": "#/definitions/common.properties/interfaces/PlaybackController/capabilities" + }, { "$ref": "#/definitions/common.properties/interfaces/ContactSensor/capabilities" }, From 2e733fef9a8c2ac68812d1c889f6c7c493ad7656 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 15:31:46 -0400 Subject: [PATCH 05/13] Added step speaker controller schema capabilities --- .../alexa_smart_home_message_schema.json | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index edebc40..3ce9900 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -1897,6 +1897,32 @@ } } }, + "StepSpeaker": { + "capabilities": { + "type": "object", + "required": [ + "type", + "interface", + "version" + ], + "additionalProperties": true, + "properties": { + "type": { + "enum": [ + "AlexaInterface" + ] + }, + "interface": { + "enum": [ + "Alexa.StepSpeaker" + ] + }, + "version": { + "$ref": "#/definitions/common.properties/version" + } + } + } + }, "SceneController": { "capabilities": { "type": "object", @@ -3163,6 +3189,9 @@ { "$ref": "#/definitions/common.properties/interfaces/Speaker/capabilities" }, + { + "$ref": "#/definitions/common.properties/interfaces/StepSpeaker/capabilities" + }, { "$ref": "#/definitions/common.properties/interfaces/SceneController/capabilities" }, From e8e026fa9d7ad04c84bf2ad27089779ee018aa74 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 15:48:25 -0400 Subject: [PATCH 06/13] Updated thermostat controller schema capabilities --- .../alexa_smart_home_message_schema.json | 27 ++++++++----------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 3ce9900..2ea0467 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -50,6 +50,15 @@ } } }, + "thermostatMode": { + "enum": [ + "AUTO", + "COOL", + "HEAT", + "ECO", + "OFF" + ] + }, "channel": { "type": "object", "additionalProperties": false, @@ -1380,14 +1389,7 @@ ] }, "value": { - "enum": [ - "HEAT", - "COOL", - "AUTO", - "ECO", - "OFF", - "CUSTOM" - ] + "$ref": "#/definitions/common.properties/thermostatMode" }, "timeOfSample": { "$ref": "#/definitions/common.properties/timestamp" @@ -1469,14 +1471,7 @@ "type": "array", "uniqueItems": true, "items": { - "type": "string", - "enum": [ - "HEAT", - "COOL", - "AUTO", - "ECO", - "OFF" - ] + "$ref": "#/definitions/common.properties/thermostatMode" } } } From 3555ba9a4973ec488605860c210126627c697d91 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 15:56:33 -0400 Subject: [PATCH 07/13] Updated input controller schema capabilities and properties --- .../alexa_smart_home_message_schema.json | 111 ++++++++++++------ 1 file changed, 77 insertions(+), 34 deletions(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 2ea0467..e8271a4 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -92,8 +92,69 @@ ] }, "input": { - "type": "string", - "minLength": 1 + "enum": [ + "AUX 1", + "AUX 2", + "AUX 3", + "AUX 4", + "AUX 5", + "AUX 6", + "AUX 7", + "BLURAY", + "CABLE", + "CD", + "COAX 1", + "COAX 2", + "COMPOSITE 1", + "DVD", + "GAME", + "HD RADIO", + "HDMI 1", + "HDMI 2", + "HDMI 3", + "HDMI 4", + "HDMI 5", + "HDMI 6", + "HDMI 7", + "HDMI 8", + "HDMI 9", + "HDMI 10", + "HDMI ARC", + "INPUT 1", + "INPUT 2", + "INPUT 3", + "INPUT 4", + "INPUT 5", + "INPUT 6", + "INPUT 7", + "INPUT 8", + "INPUT 9", + "INPUT 10", + "IPOD", + "LINE 1", + "LINE 2", + "LINE 3", + "LINE 4", + "LINE 5", + "LINE 6", + "LINE 7", + "MEDIA PLAYER", + "OPTICAL 1", + "OPTICAL 2", + "PHONO", + "PLAYSTATION", + "PLAYSTATION 3", + "PLAYSTATION 4", + "SATELLITE", + "SMARTCAST", + "TUNER", + "TV", + "USB DAC", + "VIDEO 1", + "VIDEO 2", + "VIDEO 3", + "XBOX" + ] }, "volume": { "type": "integer", @@ -1709,7 +1770,8 @@ "required": [ "type", "interface", - "version" + "version", + "inputs" ], "additionalProperties": false, "properties": { @@ -1726,38 +1788,19 @@ "version": { "$ref": "#/definitions/common.properties/version" }, - "properties": { - "type": "object", - "required": [ - "supported", - "proactivelyReported", - "retrievable" - ], - "additionalProperties": false, - "properties": { - "supported": { - "type": "array", - "uniqueItems": true, - "items": { - "type": "object", - "required": [ - "name" - ], - "additionalProperties": false, - "properties": { - "name": { - "enum": [ - "input" - ] - } - } + "inputs": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/definitions/common.properties/input" } - }, - "proactivelyReported": { - "type": "boolean" - }, - "retrievable": { - "type": "boolean" } } } From 48ec6a6a2205292b46cc5ddf19a713096f574f62 Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 11 Mar 2019 17:12:52 -0400 Subject: [PATCH 08/13] Added security panel controller schema capabilities and properties --- .../alexa_smart_home_message_schema.json | 286 +++++++++++++++++- 1 file changed, 283 insertions(+), 3 deletions(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index e8271a4..1dd7546 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -30,6 +30,14 @@ "type": "string", "minLength": 1 }, + "armState": { + "enum": [ + "ARMED_AWAY", + "ARMED_STAY", + "ARMED_NIGHT", + "DISARMED" + ] + }, "temperature": { "type": "object", "required": [ @@ -2988,6 +2996,186 @@ } } } + }, + "SecurityPanelController": { + "alarmState": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.SecurityPanelController" + ] + }, + "name": { + "enum": [ + "burglaryAlarm", + "fireAlarm", + "carbonMonoxideAlarm", + "waterAlarm" + ] + }, + "value": { + "enum": [ + "OK", + "ALARM" + ] + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, + "armState": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.SecurityPanelController" + ] + }, + "name": { + "enum": [ + "armState" + ] + }, + "value": { + "$ref": "#/definitions/common.properties/armState" + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, + "capabilities": { + "type": "object", + "required": [ + "type", + "interface", + "version", + "configuration" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "AlexaInterface" + ] + }, + "interface": { + "enum": [ + "Alexa.SecurityPanelController" + ] + }, + "version": { + "$ref": "#/definitions/common.properties/version" + }, + "properties": { + "type": "object", + "required": [ + "supported", + "proactivelyReported", + "retrievable" + ], + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "armState", + "burglaryAlarm", + "fireAlarm", + "carbonMonoxideAlarm", + "waterAlarm" + ] + } + } + } + }, + "proactivelyReported": { + "type": "boolean" + }, + "retrievable": { + "type": "boolean" + } + } + }, + "configuration": { + "type": "object", + "additionalProperties": false, + "properties": { + "supportedAuthorizationTypes": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "type" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "FOUR_DIGIT_PIN" + ] + } + } + } + }, + "supportedArmStates": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "value" + ], + "additionalProperties": false, + "properties": { + "value": { + "$ref": "#/definitions/common.properties/armState" + } + } + } + } + } + } + } + } } }, "state.properties": { @@ -3061,6 +3249,12 @@ }, { "$ref": "#/definitions/common.properties/interfaces/ContactSensor/detectionState/property" + }, + { + "$ref": "#/definitions/common.properties/interfaces/SecurityPanelController/alarmState/property" + }, + { + "$ref": "#/definitions/common.properties/interfaces/SecurityPanelController/armState/property" } ] } @@ -3108,6 +3302,17 @@ "$ref": "#/definitions/common.properties/timestamp" } } + }, + "securityPanelArm": { + "type": "object", + "additionalProperties": false, + "properties": { + "exitDelayInSeconds": { + "type": "integer", + "minimum": 0, + "maximum": 255 + } + } } }, "discoveredEndpointArray": { @@ -3165,6 +3370,7 @@ "SMARTLOCK", "SCENE_TRIGGER", "ACTIVITY_TRIGGER", + "SECURITY_PANEL", "OTHER" ] } @@ -3265,6 +3471,9 @@ }, { "$ref": "#/definitions/common.properties/interfaces/MotionSensor/capabilities" + }, + { + "$ref": "#/definitions/common.properties/interfaces/SecurityPanelController/capabilities" } ] } @@ -3417,6 +3626,35 @@ } } }, + "header.SecurityPanelController": { + "type": "object", + "required": [ + "namespace", + "name", + "payloadVersion", + "messageId" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.SecurityPanelController" + ] + }, + "name": { + "$ref": "#/definitions/ErrorResponse.properties/name" + }, + "payloadVersion": { + "$ref": "#/definitions/common.properties/payloadVersion" + }, + "messageId": { + "$ref": "#/definitions/common.properties/messageId" + }, + "correlationToken": { + "$ref": "#/definitions/common.properties/correlationToken" + } + } + }, "header.ColorTemperatureController": { "type": "object", "required": [ @@ -3644,6 +3882,28 @@ } } }, + "payload.SecurityPanelController.general": { + "type": "object", + "required": [ + "type" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "AUTHORIZATION_REQUIRED", + "BYPASS_NEEDED", + "NOT_READY", + "UNAUTHORIZED", + "UNCLEARED_ALARM", + "UNCLEARED_TROUBLE" + ] + }, + "message": { + "$ref": "#/definitions/common.properties/message" + } + } + }, "payload.ColorTemperatureController.NOT_SUPPORTED_IN_CURRENT_MODE": { "type": "object", "required": [ @@ -3674,7 +3934,8 @@ "StateReport", "ActivationStarted", "DeactivationStarted", - "AcceptGrant.Response" + "AcceptGrant.Response", + "Arm.Response" ] }, "with.payload": { @@ -3708,7 +3969,8 @@ "namespace": { "enum": [ "Alexa.CameraStreamController", - "Alexa.SceneController" + "Alexa.SceneController", + "Alexa.SecurityPanelController" ] }, "name": { @@ -3735,6 +3997,9 @@ }, { "$ref": "#/definitions/common.properties/payload/sceneActivationDeactivation" + }, + { + "$ref": "#/definitions/common.properties/payload/securityPanelArm" } ], "minProperties": 1 @@ -3774,7 +4039,8 @@ "namespace": { "enum": [ "Alexa", - "Alexa.Authorization" + "Alexa.Authorization", + "Alexa.SecurityPanelController" ] }, "name": { @@ -3895,6 +4161,20 @@ } } }, + { + "additionalProperties": false, + "properties": { + "header": { + "$ref": "#/definitions/ErrorResponse.properties/header.SecurityPanelController" + }, + "endpoint": { + "$ref": "#/definitions/common.properties/endpoint" + }, + "payload": { + "$ref": "#/definitions/ErrorResponse.properties/payload.SecurityPanelController.general" + } + } + }, { "additionalProperties": false, "properties": { From 0c57fc6721c656317ab5e209b6157ae45ac16e0e Mon Sep 17 00:00:00 2001 From: jsetton Date: Thu, 30 May 2019 21:36:33 -0400 Subject: [PATCH 09/13] Added playback state reporter schema capabilities and properties --- .../alexa_smart_home_message_schema.json | 114 ++++++++++++++++++ 1 file changed, 114 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 1dd7546..b3574ba 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -2801,6 +2801,114 @@ } } }, + "PlaybackStateReporter": { + "playbackState": { + "property": { + "type": "object", + "required": [ + "namespace", + "name", + "value", + "timeOfSample", + "uncertaintyInMilliseconds" + ], + "additionalProperties": false, + "properties": { + "namespace": { + "enum": [ + "Alexa.PlaybackStateReporter" + ] + }, + "name": { + "enum": [ + "playbackState" + ] + }, + "value": { + "type": "object", + "required": [ + "state" + ], + "additionalProperties": false, + "properties": { + "state": { + "enum": [ + "PLAYING", + "PAUSED", + "STOPPED" + ] + } + } + }, + "timeOfSample": { + "$ref": "#/definitions/common.properties/timestamp" + }, + "uncertaintyInMilliseconds": { + "$ref": "#/definitions/common.properties/uncertaintyInMilliseconds" + } + } + } + }, + "capabilities": { + "type": "object", + "required": [ + "type", + "interface", + "version" + ], + "additionalProperties": false, + "properties": { + "type": { + "enum": [ + "AlexaInterface" + ] + }, + "interface": { + "enum": [ + "Alexa.PlaybackStateReporter" + ] + }, + "version": { + "$ref": "#/definitions/common.properties/version" + }, + "properties": { + "type": "object", + "required": [ + "supported", + "proactivelyReported", + "retrievable" + ], + "additionalProperties": false, + "properties": { + "supported": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "name" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "playbackState" + ] + } + } + } + }, + "proactivelyReported": { + "type": "boolean" + }, + "retrievable": { + "type": "boolean" + } + } + } + } + } + }, "MotionSensor": { "detectionState": { "property": { @@ -3244,6 +3352,9 @@ { "$ref": "#/definitions/common.properties/interfaces/EqualizerController/mode/property" }, + { + "$ref": "#/definitions/common.properties/interfaces/PlaybackStateReporter/playbackState/property" + }, { "$ref": "#/definitions/common.properties/interfaces/MotionSensor/detectionState/property" }, @@ -3466,6 +3577,9 @@ { "$ref": "#/definitions/common.properties/interfaces/PlaybackController/capabilities" }, + { + "$ref": "#/definitions/common.properties/interfaces/PlaybackStateReporter/capabilities" + }, { "$ref": "#/definitions/common.properties/interfaces/ContactSensor/capabilities" }, From 99b64802dfb6d9a80052e6840998bee71903c9cd Mon Sep 17 00:00:00 2001 From: jsetton Date: Mon, 7 Oct 2019 19:42:25 -0400 Subject: [PATCH 10/13] Added non-controllable mode range toggle property --- validation_schemas/alexa_smart_home_message_schema.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index b3574ba..8279043 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -2122,6 +2122,9 @@ { "type": "boolean" }, + "nonControllable": { + "type": "boolean" + }, "readOnly":{ "type": "boolean" } @@ -2236,6 +2239,9 @@ "retrievable": { "type": "boolean" }, + "nonControllable": { + "type": "boolean" + }, "readOnly":{ "type": "boolean" } @@ -2395,6 +2401,9 @@ "retrievable": { "type": "boolean" }, + "nonControllable": { + "type": "boolean" + }, "readOnly":{ "type": "boolean" } From c63cc1b55bb679fa0a109d0cacb4b7387938d6dc Mon Sep 17 00:00:00 2001 From: jsetton Date: Thu, 5 Dec 2019 19:09:37 -0500 Subject: [PATCH 11/13] Added latest text label locales --- validation_schemas/alexa_smart_home_message_schema.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 8279043..6edaed6 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -332,8 +332,10 @@ "es-MX", "fr-CA", "fr-FR", + "hi-IN", "it-IT", - "ja-JP" + "ja-JP", + "pt-BR" ] }, "text": { From f13ce315d02fd9cb55f5fef19aac63b29880eba4 Mon Sep 17 00:00:00 2001 From: jsetton Date: Fri, 6 Dec 2019 23:21:42 -0500 Subject: [PATCH 12/13] Added semantic extensions --- .../alexa_smart_home_message_schema.json | 429 ++++++++++++++++++ 1 file changed, 429 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 6edaed6..1a09fbc 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -430,6 +430,22 @@ } } }, + "semantics": { + "actions": { + "enum": [ + "Alexa.Actions.Close", + "Alexa.Actions.Open", + "Alexa.Actions.Lower", + "Alexa.Actions.Raise" + ] + }, + "states": { + "enum": [ + "Alexa.States.Closed", + "Alexa.States.Open" + ] + } + }, "interfaces": { "Alexa": { "capabilities": { @@ -2131,6 +2147,89 @@ "type": "boolean" } } + }, + "semantics": { + "type": "object", + "anyOf": [ + { + "required": [ + "actionMappings" + ] + }, + { + "required": [ + "stateMappings" + ] + } + ], + "additionalProperties": false, + "properties": { + "actionMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "@type", + "actions", + "directive" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "ActionsToDirective" + ] + }, + "actions": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/actions" + } + }, + "directive": { + "$ref": "#/definitions/common.properties/directives/toggleState" + } + } + } + }, + "stateMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "@type", + "states", + "value" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "StatesToValue" + ] + }, + "states": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/states" + } + }, + "value": { + "enum": [ + "ON", + "OFF" + ] + } + } + } + } + } } } } @@ -2295,6 +2394,86 @@ } } } + }, + "semantics": { + "type": "object", + "anyOf": [ + { + "required": [ + "actionMappings" + ] + }, + { + "required": [ + "stateMappings" + ] + } + ], + "additionalProperties": false, + "properties": { + "actionMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "@type", + "actions", + "directive" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "ActionsToDirective" + ] + }, + "actions": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/actions" + } + }, + "directive": { + "$ref": "#/definitions/common.properties/directives/mode" + } + } + } + }, + "stateMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "@type", + "states", + "value" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "StatesToValue" + ] + }, + "states": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/states" + } + }, + "value": { + "type": "string" + } + } + } + } + } } } } @@ -2474,6 +2653,128 @@ } } } + }, + "semantics": { + "type": "object", + "anyOf": [ + { + "required": [ + "actionMappings" + ] + }, + { + "required": [ + "stateMappings" + ] + } + ], + "additionalProperties": false, + "properties": { + "actionMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "required": [ + "@type", + "actions", + "directive" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "ActionsToDirective" + ] + }, + "actions": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/actions" + } + }, + "directive": { + "$ref": "#/definitions/common.properties/directives/rangeValue" + } + } + } + }, + "stateMappings": { + "type": "array", + "minItems": 1, + "uniqueItems": true, + "items": { + "type": "object", + "oneOf": [ + { + "required": [ + "@type", + "states", + "range" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "StatesToRange" + ] + }, + "states": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/states" + } + }, + "range": { + "type": "object", + "required": [ + "minimumValue", + "maximumValue" + ], + "additionalProperties": false, + "properties": { + "minimumValue": { + "type": "number" + }, + "maximumValue": { + "type": "number" + } + } + } + } + }, + { + "required": [ + "@type", + "states", + "value" + ], + "additionalProperties": false, + "properties": { + "@type": { + "enum": [ + "StatesToValue" + ] + }, + "states": { + "type": "array", + "uniqueItems": true, + "items": { + "$ref": "#/definitions/common.properties/semantics/states" + } + }, + "value": { + "type": "number" + } + } + } + ] + } + } + } } } } @@ -3390,6 +3691,82 @@ } } }, + "directives": { + "mode": { + "type": "object", + "required": [ + "name", + "payload" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "SetMode", + "AdjustMode" + ] + }, + "payload": { + "oneOf": [ + { + "$ref": "#/definitions/common.properties/payload/mode" + }, + { + "$ref": "#/definitions/common.properties/payload/modeDelta" + } + ] + } + } + }, + "rangeValue": { + "type": "object", + "required": [ + "name", + "payload" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "SetRangeValue", + "AdjustRangeValue" + ] + }, + "payload": { + "oneOf": [ + { + "$ref": "#/definitions/common.properties/payload/rangeValue" + }, + { + "$ref": "#/definitions/common.properties/payload/rangeValueDelta" + } + ] + } + } + }, + "toggleState": { + "type": "object", + "required": [ + "name", + "payload" + ], + "additionalProperties": false, + "properties": { + "name": { + "enum": [ + "TurnOn", + "TurnOff" + ] + }, + "payload": { + "type": "object", + "additionalProperties": false, + "properties": {}, + "maxProperties": 0 + } + } + } + }, "payload": { "cameraStreams": { "type": "object", @@ -3409,6 +3786,58 @@ } } }, + "mode": { + "type": "object", + "required": [ + "mode" + ], + "additionalProperties": false, + "properties": { + "mode": { + "type": "string" + } + } + }, + "modeDelta": { + "type": "object", + "required": [ + "modeDelta" + ], + "additionalProperties": false, + "properties": { + "modeDelta": { + "type": "integer" + } + } + }, + "rangeValue": { + "type": "object", + "required": [ + "rangeValue" + ], + "additionalProperties": false, + "properties": { + "rangeValue": { + "type": "number" + } + } + }, + "rangeValueDelta": { + "type": "object", + "required": [ + "rangeValueDelta", + "rangeValueDeltaDefault" + ], + "additionalProperties": false, + "properties": { + "rangeValueDelta": { + "type": "number" + }, + "rangeValueDeltaDefault": { + "type": "boolean" + } + } + }, "sceneActivationDeactivation": { "type": "object", "required": [ From 6629289b2d77f866a6cb35a7a5a82582d7e849ca Mon Sep 17 00:00:00 2001 From: jsetton Date: Sat, 21 Dec 2019 00:13:08 -0500 Subject: [PATCH 13/13] Added latest display categories --- .../alexa_smart_home_message_schema.json | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/validation_schemas/alexa_smart_home_message_schema.json b/validation_schemas/alexa_smart_home_message_schema.json index 1a09fbc..ed2435d 100644 --- a/validation_schemas/alexa_smart_home_message_schema.json +++ b/validation_schemas/alexa_smart_home_message_schema.json @@ -3922,6 +3922,22 @@ "SCENE_TRIGGER", "ACTIVITY_TRIGGER", "SECURITY_PANEL", + "COMPUTER", + "EXTERIOR_BLIND", + "FAN", + "GAME_CONSOLE", + "GARAGE_DOOR", + "INTERIOR_BLIND", + "LAPTOP", + "MOBILE_PHONE", + "MUSIC_SYSTEM", + "NETWORK_HARDWARE", + "OVEN", + "PHONE", + "SCREEN", + "STREAMING_DEVICE", + "TABLET", + "WEARABLE", "OTHER" ] }