---
name: "bindUnlockMethod"
mode: "api"
versionRequirements:
  - { name: "@ray-js/lock-sdk", version: "1.0.0" }
title: "bindUnlockMethod - Bind unassociated unlock method to user."
summary: "Bind unassociated unlock method to user."
---

## bindUnlockMethod

> [VERSION] @ray-js/lock-sdk >= 1.0.0

### Description

Bind unbound unlocking methods to a user

### Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `userId` | `string` | Yes | User ID |
| `unlockList` | `Object[]` | Yes | List of unlocking methods to associate |

##### bindUnlockMethod.unlockList[] properties

| Property | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `type` | `UnlockMethodType` | Yes | - | Unlocking method type |
| `unlockId` | `number` | Yes | - | Hardware ID of the unlocking method |


### Return Value

Type: `Promise<boolean>`

None (resolve after successful binding)

### Referenced Types

##### `type` UnlockMethodType

Unlock method business type literal

```typescript
export type UnlockMethodType =
  | "finger"
  | "face"
  | "password"
  | "card"
  | "fingerVein"
  | "hand"
  | "eye";
```


### Examples

#### Example

```ts
import { bindUnlockMethod } from '@ray-js/lock-sdk';
await bindUnlockMethod({ userId: 'user_001', unlockList: [{ id: 'method_001' }] });
```
