Last Updated on : 2023-12-07 03:33:56download
Modify a scene under a specified home.
PUT: /v1.0/homes/{home_id}/scenes/{scene_id}
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
home_id | String | uri | true | The home ID. |
scene_id | String | uri | true | The scene ID. |
Description of body
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
background | String | body | true | The background image. |
name | String | body | true | Scene name. |
actions | List | body | true | The list of actions. |
Description of actions
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
entity_id | String | body | false | The device ID. The value is required when the API involves a device. |
executor_property | object | body | true | The property of a specified execution action. |
action_executor | String | body | true | The category of a specified execution action. For example, dpIssue and delay . |
Parameter name | Type | Description |
---|---|---|
result | Boolean | The returned result. true is returned when the operation is successful. |
PUT: /v1.0/homes/242****/scenes/53IYSXI3gEn2****
{
"name": "Test of Adding a Scene",
"background": "https://images.tuyacn.com/smart/rule/cover/****.png",
"actions": [
{
"executor_property": {
"hours": "0",
"minutes": "0",
"seconds": "5"
},
"action_executor": "delay"
},
{
"executor_property": {
"work_mode": "scene_2"
},
"action_executor": "dpIssue",
"entity_id": "0120090568c63a89****"
}
]
}
{
"tid": "2c1fc5cf7f4511ee82774ab24801****",
"result": true,
"t": 1540799929837,
"success": true
}
For more information, see error code.
Is this page helpful?
YesFeedbackIs this page helpful?
YesFeedback