Unbind Assigned Unlocking Method

Last Updated on : 2023-12-07 03:33:55

The administrator unbinds an assigned unlocking method from a user. After the unbinding operation is successful, the unlocking method can be bound with other users. This API applies to Wi-Fi and Zigbee door locks.

API address

POST: /v1.0/smart-lock/devices/{device_id}/opmodes/actions/cancel-allocate

Request parameter

Parameter nameTypeINRequiredDescription
device_idStringuritrueThe device ID.

Description of body

Parameter nameTypeINRequiredDescription
user_idString trueThe user ID.
unlock_listList trueThe list of unlocking methods.

Description of unlock_list

Parameter nameTypeINRequiredDescription
codeString trueThe code of a specified unlocking method. Valid values:
  • unlock_fingerprint: Unlock with fingerprint.
  • unlock_password: Unlock with password.
  • unlock_card: Unlock with card.
  • unlock_face: Unlock with face recognition.
  • unlock_hand: Unlock with palm print.
  • unlock_finger_vein: Unlock with finger vein.
  • unlock_eye: Unlock with iris recognition.
unlock_snInteger trueThe number of a specified unlocking method.

Return parameter

Parameter nameTypeDescription
resultBooleanThe returned result. Valid values:
  • true: success.
  • false: failure.

Request example

POST: /v1.0/smart-lock/devices/vdevo12454656****/opmodes/actions/cancel-allocate
{
  "user_id": "00****pdo",
  "unlock_list": [
    {
      "code": "unlock_fingerprint",
      "unlock_sn": 2
    },
    {
      "code": "unlock_password",
      "unlock_sn": 1
    },
    {
      "code": "unlock_card",
      "unlock_sn": 3
    }
  ]
}

Return example

{
    "tid": "573a2a1eac0111ecb10bc61f0b5f39c2",
    "result": true,
    "t": 1648188230193,
    "success": true
}

Error code

For more information, see error code.