---
url: https://docs.ridgedata.ai/reference/embed-api/Interface.StateError.md
---
# Interface: StateError

An error for one rejected component update. Other updates in the same batch may succeed.

Iframe embeds report these errors through `ridge:error` messages. The JavaScript embed
reports them through `stateerror` events and the result of `setState` or `setFilters`.

## Properties

| Property | Type | Description |
| ------ | ------ | ------ |
|  `code` | [`StateErrorCode`](TypeAlias.StateErrorCode.md) | Stable error identifier. Use this field to choose how to handle the rejection. |
|  `id` | `string` | The component id whose write was rejected. |
|  `message` | `string` | An error message prefixed with `[Ridge AI]`, for logs and developer tools. |
