> ## Documentation Index
> Fetch the complete documentation index at: https://fastmcp-ts.docs.prefect.io/llms.txt
> Use this file to discover all available pages before exploring further.

# ListChangedHandler

```ts theme={null}
type ListChangedHandler<T> = {
  autoRefresh?: boolean;
  debounceMs?: number;
  onChanged: (error, items) => void | Promise<void>;
};
```

Defined in: [client/handlers.ts:32](https://github.com/PrefectHQ/fastmcp-ts/blob/e4b6038f642b529f601463a576229747afebe9a4/src/client/handlers.ts#L32)

Config for receiving server-initiated list-change notifications.
Set debounceMs: 0 in tests for instant delivery.

## Type Parameters

### T

`T`

## Properties

### autoRefresh?

```ts theme={null}
optional autoRefresh?: boolean;
```

Defined in: [client/handlers.ts:35](https://github.com/PrefectHQ/fastmcp-ts/blob/e4b6038f642b529f601463a576229747afebe9a4/src/client/handlers.ts#L35)

Whether to auto-fetch the updated list before calling onChanged. Default: true.

***

### debounceMs?

```ts theme={null}
optional debounceMs?: number;
```

Defined in: [client/handlers.ts:37](https://github.com/PrefectHQ/fastmcp-ts/blob/e4b6038f642b529f601463a576229747afebe9a4/src/client/handlers.ts#L37)

Debounce window in ms. Default: 300. Set to 0 to disable.

***

### onChanged

```ts theme={null}
onChanged: (error, items) => void | Promise<void>;
```

Defined in: [client/handlers.ts:33](https://github.com/PrefectHQ/fastmcp-ts/blob/e4b6038f642b529f601463a576229747afebe9a4/src/client/handlers.ts#L33)

#### Parameters

##### error

`Error` | `null`

##### items

`T`\[] | `null`

#### Returns

`void` | `Promise`\<`void`>
