Last Updated on : 2023-06-20 14:54:11download
Send an update command to a specified access control device to update the information about a specified person.
PUT: /v1.0/access-control/{device_id}/persons/{person_id}
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
device_id | String | uri | true | The ID of a Tuya device. |
person_id | String | uri | true | The ID of a specified person. |
Description of body
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
name | String | false | The name of a specified person. | |
id_card | String | false | The identity card number of a specified person. | |
phone | String | false | The mobile phone number. | |
person_floor | Integer | false | The floor on which the person resides. | |
secret_key | String | false | The secret key of the person. | |
refresh_time | Long | false | The time interval when a QR code is refreshed. Unit: milliseconds. | |
begin_time | Long | false | The start time of a specified validity period. Unit: milliseconds. | |
end_time | Long | false | The end time of a specified validity period. Unit: milliseconds. | |
door_time_rule_list | List | false | The time rules of a specified schedule. | |
extend | String | false | The extension information. |
Description of door_time_rule_list
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
rule_name | String | false | The name of a specified time rule. | |
period | String | false | The time cycle when access is allowed, in the JSON string format. For example, [{"weekDay":1,"weekTime":[{"start":"32400000","end":"64800000"}]},{"weekDay":2,"weekTime":[{"start":"68400000","end":"75600000"}]}]. | |
allowed_date | String | false | The time period when access is allowed, in the JSON string format. For example, [{"start":"1571587200000","end":"1864569600000"},{"start":"1573022801885","end":"1864569600000"}]. | |
denied_date | String | false | The time period when access is not allowed, in the JSON string format. For example, [{"start":"1571587200000","end":"1864569600000"},{"start":"1573022801885","end":"1864569600000"}]. |
Parameter name | Type | Description |
---|---|---|
result | CmdIssueResultResponse | The returned result. |
Description of result
Parameter name | Type | Description |
---|---|---|
sn | String | The ID of a specified command record. |
PUT: /v1.0/access-control/6ce****/persons/123****
{
"begin_time": 1582959882104,
"end_time": 1661666512292,
"id_card": "330****",
"name": "James",
"phone": "135****",
"person_floor": 5,
"secret_key": "abc123***",
"refresh_time": 300000
}
{
"result": {
"sn": "133****"
},
"t": 1561456817168,
"success": true
}
For more information, see error code.
Is this page helpful?
YesFeedbackIs this page helpful?
YesFeedback