---
name: "offBLEConnectStatusChange"
mode: "kit"
versionRequirements:
  - { name: "DeviceKit", version: "3.0.0" }
  - { name: "@ray-js/ray", version: "0.6.23" }
platform:
  - "iOS"
  - "Android"
async: true
---

## offBLEConnectStatusChange

> [VERSION] DeviceKit >= 3.0.0 | @ray-js/ray >= 0.6.23

> [PLATFORM] iOS, Android

> ⚡ **Supports Promise** — Returns a Promise when success / fail / complete callbacks are omitted.

### Description

BLE (thing) connection state change notification event

### Parameters

`(listener: Function)`

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `listener` | `(params: ThingBLEConnectStatusEvent) => void` | Yes | - |  |

### Referenced Types

##### `interface` ThingBLEConnectStatusEvent

| Property | Type | Since | Description |
| --- | --- | --- | --- |
| `deviceId` | `string` | `3.0.0` | BLE (thing) connection state deviceId: Device ID |
| `status` | `string` | `3.0.0` | status values  CONNECTED: connected  CONNECTING: connecting  CONNECT_BREAK: connection failed |


### Examples

#### Basic usage

```tsx
import { device } from '@ray-js/ray'

const { offBLEConnectStatusChange } = device;

offBLEConnectStatusChange((res) => {
  console.log('offBLEConnectStatusChange', res);
});
```
