# Adaptable State Technical Reference

Canonical page: https://www.adaptabletools.com/docs/technical-reference-adaptable-state

## State Options

| Property | Type | Description | Default |
| --- | --- | --- | --- |
| [applyState](https://www.adaptabletools.com/docs/reference/stateoptions.md#applystate) | [`AdaptableApplyStateFunction`](https://www.adaptabletools.com/docs/reference/adaptableapplystatefunction.md) | Transforms state before applying it to the application. Called after `loadState()` (and after merging with `initialState`) but before the state is used. |   |
| [autoMigrateState](https://www.adaptabletools.com/docs/reference/stateoptions.md#automigratestate) | `boolean` | Automatically migrate State from previous AdapTable version to current one | true |
| [clearState](https://www.adaptabletools.com/docs/reference/stateoptions.md#clearstate) | [`AdaptableClearStateFunction`](https://www.adaptabletools.com/docs/reference/adaptableclearstatefunction.md) | Allows clearing of remote Adaptable State. Only invoked during `StateApi.reloadInitialState()` operations. | undefined |
| [debounceStateDelay](https://www.adaptabletools.com/docs/reference/stateoptions.md#debouncestatedelay) | `number` | Delay (in ms) to debounce `saveState` / `persistState` calls enabling grouping multiple sequential calls in single one (e.g. elevator doors)<br/><br/>**Defaults to: 400**. Also, the wait will be max 1000ms, at which point the save/persist calls will happen anyway. | 400 |
| [loadState](https://www.adaptabletools.com/docs/reference/stateoptions.md#loadstate) | [`AdaptableLoadStateFunction`](https://www.adaptabletools.com/docs/reference/adaptableloadstatefunction.md) | Retrieves saved Adaptable State from storage or external source |   |
| [persistState](https://www.adaptabletools.com/docs/reference/stateoptions.md#persiststate) | [`AdaptablePersistStateFunction`](https://www.adaptabletools.com/docs/reference/adaptablepersiststatefunction.md) | Handles the actual storage of state to localStorage, server, etc. Called after `saveState()` to store the prepared state. |   |
| [saveState](https://www.adaptabletools.com/docs/reference/stateoptions.md#savestate) | [`AdaptableSaveStateFunction`](https://www.adaptabletools.com/docs/reference/adaptablesavestatefunction.md) | Transforms state before saving to storage. Called before `persistState()`. |   |

---

## State API

| Method | Returns | Description |
| --- | --- | --- |
| [applyInitialState(newInitialState)](https://www.adaptabletools.com/docs/reference/stateapi.md#applyinitialstate) | `Promise<void>` | Merges Initial State into the **current** user state (Revision / Override / KeepUserDefined),<br/>without clearing persistence. Same merge as startup, applied at runtime.<br/><br/>When `newInitialState` is provided it also updates `AdaptableOptions.initialState`.<br/>Omitting it re-applies the current Initial State onto current user state. |
| [copyAllStateToClipboard()](https://www.adaptabletools.com/docs/reference/stateapi.md#copyallstatetoclipboard) | `void` | Copies all Adaptable state to clipboard |
| [copyUserStateToClipboard()](https://www.adaptabletools.com/docs/reference/stateapi.md#copyuserstatetoclipboard) | `void` | Copies User State sections of Adaptable State to clipboard |
| [dispatchStateReadyAction(module)](https://www.adaptabletools.com/docs/reference/stateapi.md#dispatchstatereadyaction) | `void` | Sent by each Module when it is Ready |
| [getAdaptableFilterState()](https://www.adaptabletools.com/docs/reference/stateapi.md#getadaptablefilterstate) | [`AdaptableFilterState`](https://www.adaptabletools.com/docs/reference/adaptablefilterstate.md) | Gets filter-related sections of Adaptable State |
| [getAdaptableSortState()](https://www.adaptabletools.com/docs/reference/stateapi.md#getadaptablesortstate) | [`AdaptableSortState`](https://www.adaptabletools.com/docs/reference/adaptablesortstate.md) | Gets sort-related sections of Adaptable State |
| [getAlertState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getalertstate) | [`AlertState`](https://www.adaptabletools.com/docs/reference/alertstate.md) | Returns Alert section of Adaptable State |
| [getAllState()](https://www.adaptabletools.com/docs/reference/stateapi.md#getallstate) | [`AdaptableState`](https://www.adaptabletools.com/docs/reference/adaptablestate.md) | Retrieves ALL state which is currently stored by Adaptable (both persistent and transient/internal) |
| [getApplicationState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getapplicationstate) | [`ApplicationState`](https://www.adaptabletools.com/docs/reference/applicationstate.md) | Returns Application section of Adaptable State |
| [getCalculatedColumnState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getcalculatedcolumnstate) | [`CalculatedColumnState`](https://www.adaptabletools.com/docs/reference/calculatedcolumnstate.md) | Returns Calculated Column section of Adaptable State |
| [getChartingState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getchartingstate) | [`ChartingState`](https://www.adaptabletools.com/docs/reference/chartingstate.md) | Returns Charting section of Adaptable State |
| [getCustomSortState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getcustomsortstate) | [`CustomSortState`](https://www.adaptabletools.com/docs/reference/customsortstate.md) | Returns Custom Sort section of Adaptable State |
| [getDashboardState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getdashboardstate) | [`DashboardState`](https://www.adaptabletools.com/docs/reference/dashboardstate.md) | Returns Dashboard section of Adaptable State |
| [getDescriptionForModule(adaptableModule)](https://www.adaptabletools.com/docs/reference/stateapi.md#getdescriptionformodule) | `string` | Retrieves a brief description of an AdapTable Module |
| [getExportState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getexportstate) | [`ExportState`](https://www.adaptabletools.com/docs/reference/exportstate.md) | Returns Export section of Adaptable State |
| [getFlashingCellState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getflashingcellstate) | [`FlashingCellState`](https://www.adaptabletools.com/docs/reference/flashingcellstate.md) | Returns Flashing Cell section of Adaptable State |
| [getFormatColumnState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getformatcolumnstate) | [`FormatColumnState`](https://www.adaptabletools.com/docs/reference/formatcolumnstate.md) | Returns Format Column section of Adaptable State |
| [getFreeTextColumnState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getfreetextcolumnstate) | [`FreeTextColumnState`](https://www.adaptabletools.com/docs/reference/freetextcolumnstate.md) | Returns FreeText Column section of Adaptable State |
| [getHelpPageForModule(adaptableModule)](https://www.adaptabletools.com/docs/reference/stateapi.md#gethelppageformodule) | `string` | Retrieves the help page for an AdapTable Module |
| [getInitialState()](https://www.adaptabletools.com/docs/reference/stateapi.md#getinitialstate) | [`InitialState`](https://www.adaptabletools.com/docs/reference/initialstate.md)` \| any` | Returns the Initial Adaptable State |
| [getLayoutState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getlayoutstate) | [`LayoutState`](https://www.adaptabletools.com/docs/reference/layoutstate.md) | Returns Layout section of Adaptable State |
| [getNamedQueryState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getnamedquerystate) | [`NamedQueryState`](https://www.adaptabletools.com/docs/reference/namedquerystate.md) | Returns Query section of Adaptable State |
| [getNoteState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getnotestate) | [`NoteState`](https://www.adaptabletools.com/docs/reference/notestate.md) | Returns Note section of Adaptable State |
| [getPersistentState()](https://www.adaptabletools.com/docs/reference/stateapi.md#getpersistentstate) | [`AdaptablePersistentState`](https://www.adaptabletools.com/docs/reference/adaptablepersistentstate.md) | Retrieves the persistent state in Adaptable, i.e. state that is passed to the `StateOptions.persistState()` function. |
| [getPlusMinusState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getplusminusstate) | [`PlusMinusState`](https://www.adaptabletools.com/docs/reference/plusminusstate.md) | Returns Plus Minus section of Adaptable State |
| [getQuickSearchState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getquicksearchstate) | [`QuickSearchState`](https://www.adaptabletools.com/docs/reference/quicksearchstate.md) | Returns Quick Search section of Adaptable State |
| [getShortcutState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getshortcutstate) | [`ShortcutState`](https://www.adaptabletools.com/docs/reference/shortcutstate.md) | Returns Shortcut section of Adaptable State |
| [getStatusBarState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getstatusbarstate) | [`StatusBarState`](https://www.adaptabletools.com/docs/reference/statusbarstate.md) | Returns StatusBar section of Adaptable State |
| [getStyledColumnState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getstyledcolumnstate) | [`StyledColumnState`](https://www.adaptabletools.com/docs/reference/styledcolumnstate.md) | Returns StyledColumn section of Adaptable State |
| [getThemeState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getthemestate) | [`ThemeState`](https://www.adaptabletools.com/docs/reference/themestate.md) | Returns Theme section of Adaptable State |
| [getToolPanelState(returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#gettoolpanelstate) | [`ToolPanelState`](https://www.adaptabletools.com/docs/reference/toolpanelstate.md) | Returns Tool Panel section of Adaptable State |
| [getUserStateByStateKey(stateKey, returnJson)](https://www.adaptabletools.com/docs/reference/stateapi.md#getuserstatebystatekey) | [`BaseState`](https://www.adaptabletools.com/docs/reference/basestate.md)` \| string` | Returns given section of Adaptable State (as JSON or object) |
| [incrementUserStateRevision(stateKey)](https://www.adaptabletools.com/docs/reference/stateapi.md#incrementuserstaterevision) | `void` | Adds &#39;1&#39; to current revision number of State element |
| [loadUserState(state)](https://www.adaptabletools.com/docs/reference/stateapi.md#loaduserstate) | `Promise<void>` | Loads supplied user state, replacing (NOT merging) existing User(persisted) State. |
| [persistAdaptableState()](https://www.adaptabletools.com/docs/reference/stateapi.md#persistadaptablestate) | `Promise<`[`AdaptablePersistentState`](https://www.adaptabletools.com/docs/reference/adaptablepersistentstate.md)`>` | Persists the current Adaptable State to storage.<br/><br/>This method first calls StateOption.saveState() to prepare the state<br/>and then StateOptions.persistState() to save it to the configured storage. |
| [reloadInitialState(newInitialState)](https://www.adaptabletools.com/docs/reference/stateapi.md#reloadinitialstate) | `Promise<void>` | Reloads existing (or supplied) Initial State; clears persistent state by calling `StateOptions.clearState` |
| [remergePersistedState()](https://www.adaptabletools.com/docs/reference/stateapi.md#remergepersistedstate) | `Promise<void>` | Re-runs the startup merge using **persisted** user state from `StateOptions.loadState`<br/>and the current `AdaptableOptions.initialState`. Does not clear persistence.<br/><br/>Use when remote/local storage may have changed (or Initial State in options was updated)<br/>and you want to re-sync without a full wipe (`reloadInitialState`).<br/><br/>Unsaved in-memory-only changes are discarded in favour of what `loadState` returns. |
| [setAdaptableStateKey(adaptableStateKey, config)](https://www.adaptabletools.com/docs/reference/stateapi.md#setadaptablestatekey) | `Promise<void>` | Changes key used for persisting AdaptableState into localStorage; optionally provides an initialState to load |

---

## Application State

Application section of AdapTable State stores custom data as a collection of `ApplicationDataEntries`:

| Property | Type | Description |
| --- | --- | --- |
| [ApplicationDataEntries](https://www.adaptabletools.com/docs/reference/applicationstate.md#applicationdataentries) | [`ApplicationDataEntry`](https://www.adaptabletools.com/docs/reference/applicationdataentry.md)`[]` | Array of Key / Value pairs enabling custom data to be stored in Adaptable State. |

### ApplicationDataEntry

Each [`ApplicationDataEntry`](https://www.adaptabletools.com/docs/reference/applicationdataentry.md) is a key / value pair:

| Property | Type | Description |
| --- | --- | --- |
| [Key](https://www.adaptabletools.com/docs/reference/applicationdataentry.md#key) | `string` | Key of Key / Value pair - always stored as a string |
| [Value](https://www.adaptabletools.com/docs/reference/applicationdataentry.md#value) | `any` | Value stored for `Key`. It must be stringifiable, because it is saved with the rest of AdapTable State. |

---

## Application API

| Method | Returns | Description |
| --- | --- | --- |
| [addApplicationDataEntry(applicationDataEntry)](https://www.adaptabletools.com/docs/reference/applicationapi.md#addapplicationdataentry) | `void` | Adds new Application Data Entry |
| [createApplicationDataEntry(key, value)](https://www.adaptabletools.com/docs/reference/applicationapi.md#createapplicationdataentry) | `void` | Creates new Application Data Entry with given Key and Value |
| [deleteApplicationDataEntry(applicationDataEntry)](https://www.adaptabletools.com/docs/reference/applicationapi.md#deleteapplicationdataentry) | `void` | Deletes given Application Data Entry |
| [editApplicationDataEntry(applicationDataEntry)](https://www.adaptabletools.com/docs/reference/applicationapi.md#editapplicationdataentry) | `void` | Edits given Application Data Entry |
| [getApplicationDataEntries()](https://www.adaptabletools.com/docs/reference/applicationapi.md#getapplicationdataentries) | [`ApplicationDataEntry`](https://www.adaptabletools.com/docs/reference/applicationdataentry.md)`[]` | Every key/value entry in Application State. |
| [getApplicationDataEntriesByValue(value)](https://www.adaptabletools.com/docs/reference/applicationapi.md#getapplicationdataentriesbyvalue) | [`ApplicationDataEntry`](https://www.adaptabletools.com/docs/reference/applicationdataentry.md)`[]` | Gets Application Data Entry with given value |
| [getApplicationDataEntryByKey(key)](https://www.adaptabletools.com/docs/reference/applicationapi.md#getapplicationdataentrybykey) | [`ApplicationDataEntry`](https://www.adaptabletools.com/docs/reference/applicationdataentry.md)` \| undefined` | Gets Application Data Entry with given key |
| [getApplicationState()](https://www.adaptabletools.com/docs/reference/applicationapi.md#getapplicationstate) | [`ApplicationState`](https://www.adaptabletools.com/docs/reference/applicationstate.md) | The Application section of Adaptable State. |

See [Customising AdapTable State](https://www.adaptabletools.com/docs/dev-guide-adaptable-state-custom/index.md) for how Application State is supplied and persisted

---

## Initial State

Initial State is the Adaptable State provided at design time for **first-time** use.

The full definition of the object is:

| Property | Type | Description |
| --- | --- | --- |
| [Alert](https://www.adaptabletools.com/docs/reference/initialstate.md#alert) | [`AlertState`](https://www.adaptabletools.com/docs/reference/alertstate.md) | Collection of `AlertDefinitions` which will fire Alerts when the rule is met |
| [Application](https://www.adaptabletools.com/docs/reference/initialstate.md#application) | [`ApplicationState`](https://www.adaptabletools.com/docs/reference/applicationstate.md) | Empty state section (only populated at Design Time) available for User to store their own data with the rest of AdapTable state. |
| [CalculatedColumn](https://www.adaptabletools.com/docs/reference/initialstate.md#calculatedcolumn) | [`CalculatedColumnState`](https://www.adaptabletools.com/docs/reference/calculatedcolumnstate.md) | Collection of *CalculatedColumn* objects that will display a value based on other cells in the row (using a Calculated Column Expression) |
| [Charting](https://www.adaptabletools.com/docs/reference/initialstate.md#charting) | [`ChartingState`](https://www.adaptabletools.com/docs/reference/chartingstate.md) | Saved charts. AG Grid charts are `ChartDefinitions` (`Name` and `Model`). Application charts are `ExternalChartDefinitions` (`Name` and `Data`). |
| [CustomSort](https://www.adaptabletools.com/docs/reference/initialstate.md#customsort) | [`CustomSortState`](https://www.adaptabletools.com/docs/reference/customsortstate.md) | Collection of *Custom Sort* objects to allow some columns to be sorted in non-standard (e.g. non alphabetical) ways |
| [Dashboard](https://www.adaptabletools.com/docs/reference/initialstate.md#dashboard) | [`DashboardState`](https://www.adaptabletools.com/docs/reference/dashboardstate.md) | Large series of properties to give users full control over the look and feel of the *Dashboard* - the section above the grid with toolbars and buttons |
| [Export](https://www.adaptabletools.com/docs/reference/initialstate.md#export) | [`ExportState`](https://www.adaptabletools.com/docs/reference/exportstate.md) | Collection of *Report* objects, together with name of the Current Report, as part of AdapTable export Module |
| [FlashingCell](https://www.adaptabletools.com/docs/reference/initialstate.md#flashingcell) | [`FlashingCellState`](https://www.adaptabletools.com/docs/reference/flashingcellstate.md) | Flashing Cell definitions. Each one names a column scope and a boolean rule, and flashes a cell, a row, or an aggregated cell. |
| [FormatColumn](https://www.adaptabletools.com/docs/reference/initialstate.md#formatcolumn) | [`FormatColumnState`](https://www.adaptabletools.com/docs/reference/formatcolumnstate.md) | Format Columns. Each one colours cells, changes how values are displayed, or both, for a column scope. Omit `Rule` to apply it on every row. |
| [FreeTextColumn](https://www.adaptabletools.com/docs/reference/initialstate.md#freetextcolumn) | [`FreeTextColumnState`](https://www.adaptabletools.com/docs/reference/freetextcolumnstate.md) | Collection of *FreeText* objects that define user-owned columns whose cell values are stored in Adaptable State (not the grid DataSource). Use for editable per-row fields such as ops notes, flags, or codes — distinct from cell-level Notes and Comments. |
| [Layout](https://www.adaptabletools.com/docs/reference/initialstate.md#layout) | [`LayoutState`](https://www.adaptabletools.com/docs/reference/layoutstate.md) | Collection of *Layouts* to name (and manage) sets of column visibility, order, grouping, sorts, aggregations, filters etc.<br/>Required unless `layoutOptions.autoCreateLayout` is set. |
| [NamedQuery](https://www.adaptabletools.com/docs/reference/initialstate.md#namedquery) | [`NamedQueryState`](https://www.adaptabletools.com/docs/reference/namedquerystate.md) | Named Queries other expressions can call with `QUERY('Name')`. A boolean query can be a Grid Filter or an Alert rule. |
| [Note](https://www.adaptabletools.com/docs/reference/initialstate.md#note) | [`NoteState`](https://www.adaptabletools.com/docs/reference/notestate.md) | Notes. One piece of text on one cell, located by primary key and column id. |
| [PlusMinus](https://www.adaptabletools.com/docs/reference/initialstate.md#plusminus) | [`PlusMinusState`](https://www.adaptabletools.com/docs/reference/plusminusstate.md) | Plus Minus module: nudge rules. Optional `IncrementKey` / `DecrementKey` on each nudge<br/>accept either a single key or a keyboard shortcut combination (e.g. `shift+Enter`); when<br/>omitted, `AdaptableOptions.plusMinusOptions` applies, then `+` / `-`. |
| [QuickSearch](https://www.adaptabletools.com/docs/reference/initialstate.md#quicksearch) | [`QuickSearchState`](https://www.adaptabletools.com/docs/reference/quicksearchstate.md) | Quick Search text restored at startup, and the styles used to highlight matches. |
| [Shortcut](https://www.adaptabletools.com/docs/reference/initialstate.md#shortcut) | [`ShortcutState`](https://www.adaptabletools.com/docs/reference/shortcutstate.md) | Collection of *Shortcut* objects to aid data entry and prevent &#39;fat finger&#39; issues |
| [StatusBar](https://www.adaptabletools.com/docs/reference/initialstate.md#statusbar) | [`StatusBarState`](https://www.adaptabletools.com/docs/reference/statusbarstate.md) | Status bars. Each `Key` matches an AG Grid `statusPanels` entry whose component is `AdaptableStatusPanel`. |
| [StyledColumn](https://www.adaptabletools.com/docs/reference/initialstate.md#styledcolumn) | [`StyledColumnState`](https://www.adaptabletools.com/docs/reference/styledcolumnstate.md) | Styled Columns. Each entry draws one column with a single visual style. |
| [Theme](https://www.adaptabletools.com/docs/reference/initialstate.md#theme) | [`ThemeState`](https://www.adaptabletools.com/docs/reference/themestate.md) | Active theme (`light`, `dark` or `os`) and which shipped themes are offered. |
| [ToolPanel](https://www.adaptabletools.com/docs/reference/initialstate.md#toolpanel) | [`ToolPanelState`](https://www.adaptabletools.com/docs/reference/toolpanelstate.md) | Sets order &amp; visibility of Tool Panel controls in AdapTable ToolPanel (on right of grid) |
| [UserInterface](https://www.adaptabletools.com/docs/reference/initialstate.md#userinterface) | [`UserInterfaceState`](https://www.adaptabletools.com/docs/reference/userinterfacestate.md) | Controls the visibility of AdapTable UI elements (Dashboard, Tool Panel, Status Bar, Menus etc.) |

Every item in the object, inherits from [`BaseState`](https://www.adaptabletools.com/docs/reference/basestate.md) which contains just one property:

| Property | Type | Description |
| --- | --- | --- |
| [Revision](https://www.adaptabletools.com/docs/reference/basestate.md#revision) | `number \| \{ Key: number; UpdateStrategy: 'Override' \| 'KeepUserDefined'; \}` | Version of this section.<br/><br/>A number, or `{ Key, UpdateStrategy }`. AdapTable compares `Key` (or the number) with the Revision already persisted for this section. When the Initial State key is higher, the section is updated:<br/><br/>- `Override` (the default) replaces the persisted section with the Initial State section.<br/>- `KeepUserDefined` applies the Initial State section, then appends objects the user added (their `Source` is not `InitialState`) back onto each array. |

---

## AdapTable State Events

AdapTable provides 3 State-related Events:

- `BeforeAdaptableStateChange` — fired before something changes in AdapTable State
- `AdaptableStateChanged` — fired after anything changes in AdapTable State
- `AdaptableStateReloaded` — fired whenever the State reloads

See [Listening to Adaptable State](https://www.adaptabletools.com/docs/dev-guide-adaptable-state-events/index.md) for full details

### Adaptable State Changed

The full definition of the [`AdaptableStateChangedInfo`](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md) object is:

| Property | Type | Description |
| --- | --- | --- |
| [action](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md#action) | `Redux.Action` | Redux action that was applied. |
| [actionName](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md#actionname) | `string` | Redux action type that was applied (`action.type`). |
| [newState](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md#newstate) | [`AdaptableState`](https://www.adaptabletools.com/docs/reference/adaptablestate.md) | Full Adaptable State after the action. |
| [oldState](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md#oldstate) | [`AdaptableState`](https://www.adaptabletools.com/docs/reference/adaptablestate.md) | Full Adaptable State before the action. |
| [adaptableContext](https://www.adaptabletools.com/docs/reference/adaptablestatechangedinfo.md#adaptablecontext) | `any` | Custom application Context provided in `AdaptableOptions.adaptableContext` |

### Before Adaptable State Change

The full definition of the [`BeforeAdaptableStateChangeInfo`](https://www.adaptabletools.com/docs/reference/beforeadaptablestatechangeinfo.md) object is:

| Property | Type | Description |
| --- | --- | --- |
| [action](https://www.adaptabletools.com/docs/reference/beforeadaptablestatechangeinfo.md#action) | `Redux.Action` | The Redux Action that is about to be invoked |
| [actionName](https://www.adaptabletools.com/docs/reference/beforeadaptablestatechangeinfo.md#actionname) | `string` | Redux action type about to be applied (`action.type`). |
| [state](https://www.adaptabletools.com/docs/reference/beforeadaptablestatechangeinfo.md#state) | [`AdaptableState`](https://www.adaptabletools.com/docs/reference/adaptablestate.md) | Current Adaptable State (before the Action is applied) |
| [adaptableContext](https://www.adaptabletools.com/docs/reference/beforeadaptablestatechangeinfo.md#adaptablecontext) | `any` | Custom application Context provided in `AdaptableOptions.adaptableContext` |

### Adaptable State Reloaded

The full definition of the [`AdaptableStateReloadedInfo`](https://www.adaptabletools.com/docs/reference/adaptablestatereloadedinfo.md) object is:

| Property | Type | Description |
| --- | --- | --- |
| [newState](https://www.adaptabletools.com/docs/reference/adaptablestatereloadedinfo.md#newstate) | [`AdaptablePersistentState`](https://www.adaptabletools.com/docs/reference/adaptablepersistentstate.md) | Persisted Adaptable State after the reload. |
| [oldState](https://www.adaptabletools.com/docs/reference/adaptablestatereloadedinfo.md#oldstate) | [`AdaptablePersistentState`](https://www.adaptabletools.com/docs/reference/adaptablepersistentstate.md) | Persisted Adaptable State before the reload. |
| [adaptableContext](https://www.adaptabletools.com/docs/reference/adaptablestatereloadedinfo.md#adaptablecontext) | `any` | Custom application Context provided in `AdaptableOptions.adaptableContext` |

### Base Event Info

The Event Info objects extend [`BaseContext`](https://www.adaptabletools.com/docs/reference/basecontext.md):

| Property | Type | Description |
| --- | --- | --- |
| [adaptableApi](https://www.adaptabletools.com/docs/reference/basecontext.md#adaptableapi) | [`AdaptableApi`](https://www.adaptabletools.com/docs/reference/adaptableapi.md) | Adaptable Api object |
| [adaptableContext](https://www.adaptabletools.com/docs/reference/basecontext.md#adaptablecontext) | `any` | Custom application Context provided in `AdaptableOptions.adaptableContext` |
| [adaptableId](https://www.adaptabletools.com/docs/reference/basecontext.md#adaptableid) | `string` | Id of current AdapTable instance |
| [adaptableStateKey](https://www.adaptabletools.com/docs/reference/basecontext.md#adaptablestatekey) | `string` | Current Adaptable State Key |
| [clientTimestamp](https://www.adaptabletools.com/docs/reference/basecontext.md#clienttimestamp) | `Date` | Time on user&#39;s computer |
| [userName](https://www.adaptabletools.com/docs/reference/basecontext.md#username) | `string` | Name of Current User |

### Event Subscription

Subscribing to the Events is done the same as with all [Adaptable Events](https://www.adaptabletools.com/docs/technical-reference-adaptable-events/index.md):

```ts
api.eventApi.on(
  'BeforeAdaptableStateChange',
  (eventInfo: BeforeAdaptableStateChangeInfo) => {
    // do something with the info
  }
);
api.eventApi.on(
  'AdaptableStateChanged',
  (eventInfo: AdaptableStateChangedInfo) => {
    // do something with the info
  }
);
api.eventApi.on(
  'AdaptableStateReloaded',
  (eventInfo: AdaptableStateReloadedInfo) => {
    // do something with the info
  }
);
```
