---
name: "SmartGroupModel.onGroupInfoChange"
mode: "api"
versionRequirements:
  - { name: "@ray-js/panel-sdk", version: "1.5.0" }
title: "onGroupInfoChange"
---

## SmartGroupModel.onGroupInfoChange

> [VERSION] @ray-js/panel-sdk >= 1.5.0

### Description

Listen for smart group info change events

### Parameters

`(listener: Function)`

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `listener` | `(data: GroupInfoChanged) => number` | Yes | Event callback that receives parameters with group info change data including groupId |

### Return Value

None


### Referenced Types

##### `type` GroupInfoChanged

Group info change event callback parameters

| Property | Type | Description |
| --- | --- | --- |
| `groupId` | `string` | Group ID |


### Examples

#### Example

```typescript
const id = group.onGroupInfoChange((data) => {
  console.log('Group info changed:', data.groupId);
});
// Unregister when needed
group.offGroupInfoChange(id);
```
