---
name: "unbindRule"
mode: "api"
versionRequirements:
  - { name: "@ray-js/ray", version: "1.5.15" }
title: "unbindRule - 解绑联动"
---

## unbindRule

> [VERSION] @ray-js/ray >= 1.5.15

### Description

Unbind linkage and delete the binding between button conditions and scene rules

### Parameters

`Params`

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `params` | `IUnbindRule` | Yes | Parameters for unbinding rules |

### Return Value

Type: `Promise<boolean>`

Whether unbinding succeeded

### Referenced Types

##### `interface` IUnbindRule

| Property | Type | Description |
| --- | --- | --- |
| `bindId` | `string` | Binding ID |
| `gid` | `string` | Home ID |


### Examples

```typescript
import { unbindRule } from '@ray-js/ray';

const unbindSceneRule = async () => {
  try {
    const success = await unbindRule({
      bindId: '123456',
      gid: '12345678',
    });
    console.log('Unbind result:', success);
  } catch (err) {
    console.error('Unbind failed:', err);
  }
};
```
