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

# Functions

## addCalculatedMeasure

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given calculated measure was added. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
addCalculatedMeasure(
  mdx,
  {
    calculatedMeasureName,
    expression,
    measureIndex,
    properties,
  },
  cube,
);
```

| Argument                                                                                                | Type                                                                                                                                                                                                                                 | Description |
| :------------------------------------------------------------------------------------------------------ | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                                     | [MdxSelect](types#mdxselect)                                                                                                                                                                                                         |             |
| \{<br />   calculatedMeasureName,<br />   expression,<br />   measureIndex,<br />   properties, <br />} | \{<br />   calculatedMeasureName: string;<br />   expression: [MdxExpression](types#mdxexpression);<br />   measureIndex?: number;<br />   properties?: [MdxMemberPropertyDefinition](types#mdxmemberpropertydefinition)\[]; <br />} |             |
| cube                                                                                                    | [Cube](types#cube)                                                                                                                                                                                                                   |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## addLevel

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given level was added.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
addLevel(mdx, {
  cube,
  dimensionName,
  hierarchyName,
  levelName,
  axisName,
  indexOnAxis,
  shouldCreateNonEmptyAxis,
  doesIncludeCalculatedMembers,
});
```

| Argument                                                                                                                                                                                                 | Type                                                                                                                                                                                                                                                                                                                                                                                             | Description |
| :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                                                                                                                                      | [MdxSelect](types#mdxselect)                                                                                                                                                                                                                                                                                                                                                                     |             |
| \{<br />   cube,<br />   dimensionName,<br />   hierarchyName,<br />   levelName,<br />   axisName,<br />   indexOnAxis,<br />   shouldCreateNonEmptyAxis,<br />   doesIncludeCalculatedMembers, <br />} | \{<br />   cube: [Cube](types#cube);<br />   dimensionName: [DimensionName](types#dimensionname);<br />   hierarchyName: [HierarchyName](types#hierarchyname);<br />   levelName: [LevelName](types#levelname);<br />   axisName?: [AxisName](types#axisname);<br />   indexOnAxis?: number;<br />   shouldCreateNonEmptyAxis?: boolean;<br />   doesIncludeCalculatedMembers?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## addMeasure

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given measure was added. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
addMeasure(mdx, {
  cube,
  measureName,
  measureIndex,
  shouldCreateNonEmptyAxis,
  axisName,
});
```

| Argument                                                                                                                | Type                                                                                                                                                                                                                          | Description |
| :---------------------------------------------------------------------------------------------------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                                                     | [MdxSelect](types#mdxselect)                                                                                                                                                                                                  |             |
| \{<br />   cube,<br />   measureName,<br />   measureIndex,<br />   shouldCreateNonEmptyAxis,<br />   axisName, <br />} | \{<br />   cube: [Cube](types#cube);<br />   measureName: [MeasureName](types#measurename);<br />   measureIndex?: number;<br />   shouldCreateNonEmptyAxis?: boolean;<br />   axisName?: [AxisName](types#axisname); <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## addPage

Adds a page to a dashboard and returns the updated dashboard state with the new page key. Does not mutate the dashboard state.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
addPage(dashboardState, options);
```

| Argument       | Type                                                                                                                   | Description |
| :------------- | :--------------------------------------------------------------------------------------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate)                                                                                 |             |
| options        | \{<br />   page: [DashboardPageState](types#dashboardpagestate);<br />   key?: string;<br />   index?: number; <br />} |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## addWidget

Returns a new dashboard with the given widget added at the specified location. Does not mutate dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
addWidget({
  dashboardState,
  initialWidgetState,
  layoutPath,
  pageKey,
  side,
});
```

| Argument                                                                                                          | Type                                                                                                                                                                                                                                 | Description |
| :---------------------------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   dashboardState,<br />   initialWidgetState,<br />   layoutPath,<br />   pageKey,<br />   side, <br />} | \{<br />   dashboardState: [DashboardState](types#dashboardstate);<br />   initialWidgetState: [AWidgetState](types#awidgetstate);<br />   layoutPath: number\[];<br />   pageKey: string;<br />   side: [Side](types#side); <br />} |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## areHierarchiesEqual

Returns whether `hierarchyCoordinatesA` and `hierarchyCoordinatesB` represent the same hierarchy.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
areHierarchiesEqual(hierarchyCoordinatesA, hierarchyCoordinatesB);
```

| Argument              | Type                                                            | Description |
| :-------------------- | :-------------------------------------------------------------- | :---------- |
| hierarchyCoordinatesA | [HierarchyCoordinates](types#hierarchycoordinates) \| undefined |             |
| hierarchyCoordinatesB | [HierarchyCoordinates](types#hierarchycoordinates) \| undefined |             |

<b>Returns:</b>

boolean

## areLevelsEqual

Returns whether `levelCoordinatesA` and `levelCoordinatesB` represent the same level.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
areLevelsEqual(levelCoordinatesA, levelCoordinatesB);
```

| Argument          | Type                                                    | Description |
| :---------------- | :------------------------------------------------------ | :---------- |
| levelCoordinatesA | [LevelCoordinates](types#levelcoordinates) \| undefined |             |
| levelCoordinatesB | [LevelCoordinates](types#levelcoordinates) \| undefined |             |

<b>Returns:</b>

boolean

## areTuplesEqual

Returns whether `tupleCoordinatesA` and `tupleCoordinatesB` represent the same tuple

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
areTuplesEqual(tupleCoordinatesA, tupleCoordinatesB);
```

| Argument          | Type                                                    | Description |
| :---------------- | :------------------------------------------------------ | :---------- |
| tupleCoordinatesA | [TupleCoordinates](types#tuplecoordinates) \| undefined |             |
| tupleCoordinatesB | [TupleCoordinates](types#tuplecoordinates) \| undefined |             |

<b>Returns:</b>

boolean

## collapse

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given tuple was collapsed. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
collapse(mdx, {
  cube,
  tupleCoordinates,
});
```

| Argument                                           | Type                                                                                                               | Description |
| :------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                | [MdxSelect](types#mdxselect)                                                                                       |             |
| \{<br />   cube,<br />   tupleCoordinates, <br />} | \{<br />   cube: [Cube](types#cube);<br />   tupleCoordinates: [TupleCoordinates](types#tuplecoordinates); <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## createAtotiClient

Returns a new [AtotiClient](types#atoticlient) instance.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
createAtotiClient(constructorArgs);
```

| Argument        | Type                                                           | Description |
| :-------------- | :------------------------------------------------------------- | :---------- |
| constructorArgs | [AtotiClientConstructorArgs](types#atoticlientconstructorargs) |             |

<b>Returns:</b>

[AtotiClient](types#atoticlient)

## createContentClient

Returns a new [ContentClient](types#contentclient) instance.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
createContentClient(constructorArguments);
```

| Argument             | Type                                                                          | Description |
| :------------------- | :---------------------------------------------------------------------------- | :---------- |
| constructorArguments | [ContentClientConstructorArgs](types#contentclientconstructorargs)\<Settings> |             |

<b>Returns:</b>

[ContentClient](types#contentclient)\<Settings>

## createFilter

Returns the [Filter](types#filter) represented by `mdx` (assuming that it represents a filter).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
createFilter(mdx, {
  cube,
  nonVisualTotals,
});
```

| Argument                                         | Type                                                                            | Description |
| :----------------------------------------------- | :------------------------------------------------------------------------------ | :---------- |
| mdx                                              | [MdxExpression](types#mdxexpression)                                            |             |
| \{<br />   cube,<br />   nonVisualTotals <br />} | \{<br />   cube: [Cube](types#cube);<br />   nonVisualTotals?: boolean; <br />} |             |

<b>Returns:</b>

[Filter](types#filter)

## createLevelCompoundIdentifier

Returns the [MdxLevelCompoundIdentifier](types#mdxlevelcompoundidentifier) corresponding to the given level coordinates.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
createLevelCompoundIdentifier({
  dimensionName,
  hierarchyName,
  levelName,
});
```

| Argument                                                                    | Type                                       | Description |
| :-------------------------------------------------------------------------- | :----------------------------------------- | :---------- |
| \{<br />   dimensionName,<br />   hierarchyName,<br />   levelName, <br />} | [LevelCoordinates](types#levelcoordinates) |             |

<b>Returns:</b>

[MdxLevelCompoundIdentifier](types#mdxlevelcompoundidentifier)

## createMdxForFilter

Returns a new [MdxExpression](types#mdxexpression) representing `filter`. Returns `undefined` for a filter on members where there are no members selected.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
createMdxForFilter(filter, cube, options);
```

| Argument | Type                                           | Description |
| :------- | :--------------------------------------------- | :---------- |
| filter   | [Filter](types#filter)                         |             |
| cube     | [Cube](types#cube)                             |             |
| options  | \{<br />   atotiServerVersion: string; <br />} |             |

<b>Returns:</b>

[MdxExpression](types#mdxexpression) | undefined

## deserializeDashboardState

Returns a new dashboard state where: - all MDX strings representing queries and filters are parsed and replaced by AST. - all data visualization widget mappings are deserialized. Does not mutate the passed dashboard state.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
deserializeDashboardState(dashboardState);
```

| Argument       | Type                                                  | Description |
| :------------- | :---------------------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate)\<"serialized"> |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)\<"deserialized">

## deserializeFilter

Deserializes a [Filter](types#filter), making it usable in Atoti UI.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
deserializeFilter(filter);
```

| Argument | Type                                  | Description |
| :------- | :------------------------------------ | :---------- |
| filter   | [Filter](types#filter)\<"serialized"> |             |

<b>Returns:</b>

[Filter](types#filter)\<"deserialized">

## deserializeWidgetState

Accepts a serialized `widgetState`, as it is saved on a content server and returns its deserialized version, ready to live in the state of [Dashboard](components#dashboard).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
deserializeWidgetState(widgetState);
```

| Argument    | Type                                              | Description |
| :---------- | :------------------------------------------------ | :---------- |
| widgetState | [AWidgetState](types#awidgetstate)\<"serialized"> |             |

<b>Returns:</b>

R

## expand

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given tuple was expanded. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
expand(mdx, {
  cube,
  tupleCoordinates,
  toLevel,
  doesIncludeCalculatedMembers,
});
```

| Argument                                                                                                  | Type                                                                                                                                                                                                                            | Description |
| :-------------------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | :---------- |
| mdx                                                                                                       | [MdxSelect](types#mdxselect)                                                                                                                                                                                                    |             |
| \{<br />   cube,<br />   tupleCoordinates,<br />   toLevel,<br />   doesIncludeCalculatedMembers, <br />} | \{<br />   cube: [Cube](types#cube);<br />   tupleCoordinates: [TupleCoordinates](types#tuplecoordinates);<br />   toLevel: [LevelCoordinates](types#levelcoordinates);<br />   doesIncludeCalculatedMembers?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## fetchTranslations

Asynchronously returns the Atoti UI translations for `locale`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
fetchTranslations(locale);
```

| Argument | Type   | Description |
| :------- | :----- | :---------- |
| locale   | string |             |

<b>Returns:</b>

Promise\<\{ \[key in string]: string; }>

## findContentRecords

Returns the nodes in `tree` with the given ids, indexed by id.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
findContentRecords(tree, ids, pathOrOptions);
```

| Argument      | Type                                                     | Description |
| :------------ | :------------------------------------------------------- | :---------- |
| tree          | [ContentRecord](types#contentrecord)\<T>                 |             |
| ids           | string\[]                                                |             |
| pathOrOptions | string\[] \| \{<br />   includeFolders: boolean; <br />} |             |

<b>Returns:</b>

\{ \[id: string]: \{ node: [ContentRecord](types#contentrecord)\<T>; pathToParentFolder: string\[]; }; }

## findMappingFieldForHierarchy

Returns the coordinates of the [DataVisualizationMappingField](types#datavisualizationmappingfield) in `mapping` that corresponds to the given hierarchy. Returns `undefined` if the hierarchy is not expressed in the mapping.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
findMappingFieldForHierarchy(mapping, {
  dimensionName,
  hierarchyName,
});
```

| Argument                                                | Type                                                                   | Description |
| :------------------------------------------------------ | :--------------------------------------------------------------------- | :---------- |
| mapping                                                 | [DataVisualizationWidgetMapping](types#datavisualizationwidgetmapping) |             |
| \{<br />   dimensionName,<br />   hierarchyName <br />} | [HierarchyCoordinates](types#hierarchycoordinates)                     |             |

<b>Returns:</b>

\{ attributeName: string; fieldIndex: number; type: "hierarchy"; } | \{ attributeName: string; fieldIndex: number; hierarchyIndex: number; type: "compositeHierarchy"; } | undefined

## getActiveToolKey

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the key of the active tool tab. See `activeToolKey` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getActiveToolKey(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

string | undefined

## getAntdTheme

Returns the Ant Desgin ThemeConfig based on the provided \$[Theme](types#theme).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getAntdTheme(atotiTheme);
```

| Argument   | Type                 | Description |
| :--------- | :------------------- | :---------- |
| atotiTheme | [Theme](types#theme) |             |

<b>Returns:</b>

ThemeConfig

## getCalculatedMeasures

Returns the expression of each calculated measure defined in `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getCalculatedMeasures(mdx);
```

| Argument | Type                                                                     | Description |
| :------- | :----------------------------------------------------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect) \| [MdxDrillthrough](types#mdxdrillthrough) |             |

<b>Returns:</b>

\{ \[measureName: string]: [MdxFormula](types#mdxformula); }

## getContentNodes

Returns the nodes useful to display a `ContentTree`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getContentNodes(structure, options);
```

| Argument  | Type                                                                                                  | Description |
| :-------- | :---------------------------------------------------------------------------------------------------- | :---------- |
| structure | [ContentRecord](types#contentrecord)\<T>                                                              |             |
| options   | \{<br />   areFilesVisible: boolean;<br />   getDragItem?: (id: string, metaData: T) => void; <br />} |             |

<b>Returns:</b>

[TreeObject](types#treeobject)\<[ContentNode](types#contentnode)\<T>>\[]

## getContentRecordAtPath

Returns the [ContentRecord](types#contentrecord) at `path` in `tree`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getContentRecordAtPath({
  tree,
  path,
});
```

| Argument                               | Type                                                                                                            | Description |
| :------------------------------------- | :-------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   tree,<br />   path, <br />} | \{<br />   tree?: [ContentRecord](types#contentrecord)\<MetaData, T> \| null;<br />   path?: string\[]; <br />} |             |

<b>Returns:</b>

[ContentRecord](types#contentrecord)\<MetaData, T> | undefined

## getCube

Returns the cube identified by `cubeName` in `dataModel`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getCube(dataModel, cubeName);
```

| Argument  | Type                         | Description |
| :-------- | :--------------------------- | :---------- |
| dataModel | [DataModel](types#datamodel) |             |
| cubeName  | [CubeName](types#cubename)   |             |

<b>Returns:</b>

[Cube](types#cube)

## getCubeName

Returns the name of the cube used in `mdx`, if any.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getCubeName(mdx);
```

| Argument | Type                                                                                                                                                   | Description |
| :------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect) \| [MdxSubSelect](types#mdxsubselect) \| [MdxDrillthrough](types#mdxdrillthrough) \| [MdxFromClause](types#mdxfromclause) |             |

<b>Returns:</b>

[CubeName](types#cubename)

## getDashboardState

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the state of the dashboard. See `dashboard` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getDashboardState(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate) | undefined

## getDimension

Returns the dimension identified by `dimensionName` in `cube`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getDimension(dimensionName, cube);
```

| Argument      | Type                                 | Description |
| :------------ | :----------------------------------- | :---------- |
| dimensionName | [DimensionName](types#dimensionname) |             |
| cube          | [Cube](types#cube)                   |             |

<b>Returns:</b>

[Dimension](types#dimension)

## getDrillthroughColumns

Returns the [DrillthroughColumnUniqueName](types#drillthroughcolumnuniquename) of each drillthrough column in `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getDrillthroughColumns(mdx);
```

| Argument | Type                                     | Description |
| :------- | :--------------------------------------- | :---------- |
| mdx      | [MdxDrillthrough](types#mdxdrillthrough) |             |

<b>Returns:</b>

[DrillthroughColumnUniqueName](types#drillthroughcolumnuniquename)\[]

## getExpandedFolderPathsInHomePage

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the expanded folder paths of the homepage. See `expandedFolderPathsInHomePage` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getExpandedFolderPathsInHomePage(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

string\[]\[]

## getExpandedTuples

Returns the drilled down tuples in `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getExpandedTuples(mdx, cube);
```

| Argument | Type                                                     | Description |
| :------- | :------------------------------------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect) \| [MdxAxis](types#mdxaxis) |             |
| cube     | [Cube](types#cube)                                       |             |

<b>Returns:</b>

\{ tupleCoordinates: [TupleCoordinates](types#tuplecoordinates); toLevel: [LevelCoordinates](types#levelcoordinates); }\[]

## getFilters

Returns the filters expressed in `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getFilters(mdx, {
  cube,
});
```

| Argument                | Type                                                                                                           | Description |
| :---------------------- | :------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                     | [MdxSelect](types#mdxselect) \| [MdxSubSelect](types#mdxsubselect) \| [MdxDrillthrough](types#mdxdrillthrough) |             |
| \{<br />   cube <br />} | \{<br />   cube: [Cube](types#cube); <br />}                                                                   |             |

<b>Returns:</b>

\{ mdx: [MdxExpression](types#mdxexpression); paths: (string | number)\[]\[]; nonVisualTotals?: boolean; }\[]

## getHasUnsavedChanges

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether the dashboard has unsaved changes. See `dashboard` and `lastSavedDashboardHash` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getHasUnsavedChanges(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getHierarchy

Returns the hierarchy identified by `hierarchyCoordinates` in `cube`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getHierarchy(hierarchyCoordinates, cube);
```

| Argument             | Type                                               | Description |
| :------------------- | :------------------------------------------------- | :---------- |
| hierarchyCoordinates | [HierarchyCoordinates](types#hierarchycoordinates) |             |
| cube                 | [Cube](types#cube)                                 |             |

<b>Returns:</b>

[Hierarchy](types#hierarchy)

## getIndexedDataModel

Transforms a dataModel into an indexed format where properties can be accessed by keys.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIndexedDataModel(dataModel);
```

| Argument  | Type                                 | Description |
| :-------- | :----------------------------------- | :---------- |
| dataModel | [DataModel](types#datamodel)\<"raw"> |             |

<b>Returns:</b>

[DataModel](types#datamodel)\<"indexed">

## getIsDeferred

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether deferred updates are enabled. See `isDeferred` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIsDeferred(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getIsOpenDashboardPopupVisible

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether the 'Open Dashboard' popup is visible. See `isOpenDashboardPopupVisible` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIsOpenDashboardPopupVisible(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getIsPresenting

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether the application is displayed in "Present" mode. See `isPresenting` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIsPresenting(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getIsSettingsPopupVisible

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether the 'Settings' popup is visible. See `isSettingsPopupVisible` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIsSettingsPopupVisible(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getIsWidgetsPanelVisible

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning whether the widgets panel is visible. See `isWidgetsPanelVisible` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getIsWidgetsPanelVisible(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

boolean

## getLayoutPath

Returns the layoutPath of the widget identified by `leafKey` in `layout`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getLayoutPath(layout, leafKey);
```

| Argument | Type                   | Description |
| :------- | :--------------------- | :---------- |
| layout   | [Layout](types#layout) |             |
| leafKey  | string                 |             |

<b>Returns:</b>

number\[]

## getLevel

Returns the level identified by `levelCoordinates` in `cube`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getLevel(levelCoordinates, cube);
```

| Argument         | Type                                       | Description |
| :--------------- | :----------------------------------------- | :---------- |
| levelCoordinates | [LevelCoordinates](types#levelcoordinates) |             |
| cube             | [Cube](types#cube)                         |             |

<b>Returns:</b>

[Level](types#level)

## getLevels

Returns the coordinates of every level used in `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getLevels(mdx, {
  cube,
});
```

| Argument                | Type                                         | Description |
| :---------------------- | :------------------------------------------- | :---------- |
| mdx                     | [Mdx](types#mdx)                             |             |
| \{<br />   cube <br />} | \{<br />   cube: [Cube](types#cube); <br />} |             |

<b>Returns:</b>

[LevelCoordinates](types#levelcoordinates)\[]

## getMeasure

Returns the measure identified by `measureName` in `cube`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getMeasure(measureName, cube);
```

| Argument    | Type               | Description |
| :---------- | :----------------- | :---------- |
| measureName | string             |             |
| cube        | [Cube](types#cube) |             |

<b>Returns:</b>

[Measure](types#measure)

## getMeasureNames

Returns the names of the measures used in the axes of `mdx`. Does not return duplicate measures.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getMeasureNames(mdx);
```

| Argument | Type                                                                     | Description |
| :------- | :----------------------------------------------------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect) \| [MdxDrillthrough](types#mdxdrillthrough) |             |

<b>Returns:</b>

[MeasureName](types#measurename)\[]

## getMetaData

Returns a file's metadata content, useful to display its corresponding node in a ContentTree. Throws a `MissingMetaDataError` if the record is missing for the given id. Throws an `InvalidMetaDataError` if the `name` attribute is missing.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getMetaData(node, id);
```

| Argument | Type                                            | Description |
| :------- | :---------------------------------------------- | :---------- |
| node     | [ContentRecord](types#contentrecord)\<MetaData> |             |
| id       | string                                          |             |

<b>Returns:</b>

MetaData

## getMetaDataRecord

Returns a file's metadata record, containing information about when and by whom this file was saved and who can access it.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getMetaDataRecord(node, id);
```

| Argument | Type                                               | Description |
| :------- | :------------------------------------------------- | :---------- |
| node     | [ContentRecord](types#contentrecord)\<MetaData, T> |             |
| id       | string                                             |             |

<b>Returns:</b>

[ContentRecord](types#contentrecord)\<MetaData, T>

## getNode

Returns a reference to the node at the given path

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getNode(tree, path);
```

| Argument | Type                                                                        | Description |
| :------- | :-------------------------------------------------------------------------- | :---------- |
| tree     | [TreeObject](types#treeobject)\<T> \| [TreeObject](types#treeobject)\<T>\[] |             |
| path     | number\[]                                                                   |             |

<b>Returns:</b>

[TreeObject](types#treeobject)\<T>

## getOwnersAndReaders

Returns the [ContentEntry](types#contententry) owners and readers corresponding to the given `permissions`. - Permissions of type "editor" are converted to "owners". - Permissions of type "reader" are converted both to "owners" and "readers". - The current user is added both as "owner" and "reader".

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getOwnersAndReaders(permissions, currentUserName);
```

| Argument        | Type                              | Description |
| :-------------- | :-------------------------------- | :---------- |
| permissions     | [Permission](types#permission)\[] |             |
| currentUserName | string                            |             |

<b>Returns:</b>

\{ owners: string\[]; readers: string\[]; }

## getOwnersAndReadersForNewFile

Returns the [ContentEntry](types#contententry) owners and readers for a new file or folder.

The reasoning is as follows: - if the user is not allowed to share, then she is the only owner/reader for the file being created and is not allowed to edit those permissions. - if the user is allowed to share.. - ..and is saving at the root, then she is initially the only owner/reader for the file being created, but is allowed to edit those permissions. - ..and is saving under a folder with `doesInheritParentFolderPermissions` set to `true`, then the file being created initially inherits the permissions of that folder, and its permissions are editable.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getOwnersAndReadersForNewFile({
  currentUserName,
  canShare,
  parentFolderOwners,
  parentFolderReaders,
  isParentFolderRoot,
  doesInheritParentFolderPermissions,
});
```

| Argument                                                                                                                                                                               | Type                                                                                                                                                                                                                                             | Description |
| :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   currentUserName,<br />   canShare,<br />   parentFolderOwners,<br />   parentFolderReaders,<br />   isParentFolderRoot,<br />   doesInheritParentFolderPermissions, <br />} | \{<br />   currentUserName: string;<br />   canShare: boolean;<br />   parentFolderOwners: string\[];<br />   parentFolderReaders: string\[];<br />   isParentFolderRoot: boolean;<br />   doesInheritParentFolderPermissions?: boolean; <br />} |             |

<b>Returns:</b>

\{ owners: string\[]; readers: string\[]; }

## getPage

Returns the page with the specified key in the dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getPage(dashboardState, pageKey);
```

| Argument       | Type                                                        | Description |
| :------------- | :---------------------------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate) \| null \| undefined |             |
| pageKey        | string \| null                                              |             |

<b>Returns:</b>

[DashboardPageState](types#dashboardpagestate) | undefined

## getParentPaths

Returns the paths to the parents of the nodes identified by the given paths

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getParentPaths(paths);
```

| Argument | Type    | Description |
| :------- | :------ | :---------- |
| paths    | T\[]\[] |             |

<b>Returns:</b>

T\[]\[]

## getPluginsTranslations

Returns the translations of all plugins for the given locale

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getPluginsTranslations(plugins, locale);
```

| Argument | Type                                                                                                                                   | Description |
| :------- | :------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| plugins  | \{<br />   \[key in [PluginType](types#plugintype)]?: [PluginsOfType](types#pluginsoftype)\<[APlugin](types#aplugin)>; <br />} \| null |             |
| locale   | string                                                                                                                                 |             |

<b>Returns:</b>

\{ \[key in string]: string; }

## getPrefixedLocalStorageKey

Returns `key`, prefixed with the application's name, in order to avoid conflicts on the domain where it is deployed.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getPrefixedLocalStorageKey(key);
```

| Argument | Type   | Description |
| :------- | :----- | :---------- |
| key      | string |             |

<b>Returns:</b>

string

## getResourcesPanelKey

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the key of the currently open resources panel. See `resourcesPanelKey` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getResourcesPanelKey(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

"data-model" | "widgets" | "filters"

## getSelectedLeafKey

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the key of the selected widget, identifying it in its parent dashboard page. See `widgetSelection` in [State](types#state). It is useful to retrieve the selected widget state.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getSelectedLeafKey(state, activePageKey);
```

| Argument      | Type                 | Description |
| :------------ | :------------------- | :---------- |
| state         | [State](types#state) |             |
| activePageKey | string \| undefined  |             |

<b>Returns:</b>

string | undefined

<b>For example:</b>

```
import { useSelector } from "react-redux";
import { getWidget } from "@activeviam/atoti-ui-sdk"

const dashboardState = useSelector(getDashboardState);
const activePageKey = useActivePageKeyFromUrl();
const selectedLeafKey = useSelector((state) =>
 getSelectedLeafKey(state, activePageKey),
);
const selectedWidgetState = getWidget(dashboardState, activePageKey, selectedLeafKey);
```

## getSelectionWithinWidgets

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) returning the selected elements within each widget in the dashboard. See `selectionWithinWidget` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getSelectionWithinWidgets(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

[SelectionWithinWidgets](types#selectionwithinwidgets)

## getSort

Returns the [OrderMode](types#ordermode) defining the sort and the [LevelCoordinates](types#levelcoordinates) if it is alphabetical or the [TupleCoordinates](types#tuplecoordinates) if it is numerical. Returns `undefined` if `mdx` is not sorted.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getSort(mdx, {
  cube,
});
```

| Argument                | Type                                         | Description |
| :---------------------- | :------------------------------------------- | :---------- |
| mdx                     | [MdxSelect](types#mdxselect)                 |             |
| \{<br />   cube <br />} | \{<br />   cube: [Cube](types#cube); <br />} |             |

<b>Returns:</b>

(\{ orderMode: [OrderMode](types#ordermode); } & (\{ tupleCoordinates: [TupleCoordinates](types#tuplecoordinates); } | \{ levelCoordinates: [LevelCoordinates](types#levelcoordinates); })) | undefined

## getStatusNotifications

[Redux selector](https://redux.js.org/tutorials/fundamentals/part-2-concepts-data-flow#selectors) return the state corresponding to the status notifications of the current asynchronous actions. See `statusNotifications` in [State](types#state).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getStatusNotifications(state);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| state    | [State](types#state) |             |

<b>Returns:</b>

[StatusNotification](types#statusnotification)\[]

## getTargetCube

Returns the serverKey, dataModel and cube targeted by the given `cubeName` and/or `serverKey`. If neither `serverKey` nor `cubeName` are defined, defaults to the last cube the user used if it is still valid, and the first cube of the first provided server otherwise. If only `cubeName` is defined, uses the `serverKey` from `lastUsedCube` if it is still valid. Else defaults to the first server containing a cube with that name. If only `serverKey` is defined, uses the `cubeName` from `lastUsedCube` if it is still valid. Else defaults to the first cube from that server.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getTargetCube({
  dataModels,
  serverKey,
  cubeName,
  lastUsedCube,
});
```

| Argument                                                                                  | Type                                                                                                                                                                                                                                                                                                            | Description |
| :---------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   dataModels,<br />   serverKey,<br />   cubeName,<br />   lastUsedCube, <br />} | \{<br />   dataModels: \{<br />     \[serverKey: string]: [DataModel](types#datamodel); <br />  };<br />   serverKey?: string;<br />   cubeName?: [CubeName](types#cubename);<br />   lastUsedCube?: \{<br />     cubeName: [CubeName](types#cubename);<br />     serverKey: string; <br />  } \| null; <br />} |             |

<b>Returns:</b>

\{ cube: [Cube](types#cube); dataModel: [DataModel](types#datamodel); serverKey: string; }

## getToolsTranslations

Returns the translations of all tools for the given locale.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getToolsTranslations(tools, locale);
```

| Argument | Type                          | Description |
| :------- | :---------------------------- | :---------- |
| tools    | [Tool](types#tool)\[] \| null |             |
| locale   | string                        |             |

<b>Returns:</b>

\{ \[key in string]: string; }

## getUserFromJwt

Extracts the user name and roles from an Atoti server sandbox authentication token.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getUserFromJwt(jwt);
```

| Argument | Type   | Description |
| :------- | :----- | :---------- |
| jwt      | string |             |

<b>Returns:</b>

[User](types#user)

## getUserRoles

<Warning>
  **Deprecated**

  Use [getUserFromJwt](functions#getuserfromjwt) instead.
</Warning>

Decodes the user roles from the authentication token.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getUserRoles(token);
```

| Argument | Type   | Description |
| :------- | :----- | :---------- |
| token    | string |             |

<b>Returns:</b>

string\[]

## getWidget

Returns the widget with the specified key in the page at the specified index of the dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getWidget(dashboardState, pageKey, leafKey);
```

| Argument       | Type                                                        | Description |
| :------------- | :---------------------------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate) \| null \| undefined |             |
| pageKey        | string \| null                                              |             |
| leafKey        | string \| null                                              |             |

<b>Returns:</b>

[AWidgetState](types#awidgetstate) | undefined

## getWidgetQuery

A function returning the widget's [Query](types#query) impacted by the user, dashboard, page and widget filters and query contexts.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
getWidgetQuery(widgetState, {
  dashboardState,
  pageKey,
  queryRanges,
  userFilters,
  userQueryContext,
  dataModels,
  lastUsedCube,
  filtersFromFoldersBySection,
  atotiServerVersion,
});
```

| Argument                                                                                                                                                                                                                           | Type                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Description |
| :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| widgetState                                                                                                                                                                                                                        | [WidgetWithQueryState](types#widgetwithquerystate)\<MdxType>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |             |
| \{<br />   dashboardState,<br />   pageKey,<br />   queryRanges,<br />   userFilters,<br />   userQueryContext,<br />   dataModels,<br />   lastUsedCube,<br />   filtersFromFoldersBySection,<br />   atotiServerVersion, <br />} | \{<br />   dashboardState?: [DashboardState](types#dashboardstate);<br />   pageKey?: string;<br />   queryRanges?: Partial\<\{<br />     \[axisId in [AxisId](types#axisid)]: [QueryRange](types#queryrange); <br />  }>;<br />   userFilters?: [Filter](types#filter)\[];<br />   userQueryContext?: [QueryContextEntry](types#querycontextentry)\[];<br />   dataModels: \{<br />     \[serverKey: string]: [DataModel](types#datamodel); <br />  };<br />   lastUsedCube?: \{<br />     cubeName: [CubeName](types#cubename);<br />     serverKey: string; <br />  } \| null;<br />   filtersFromFoldersBySection?: \{<br />     \[sectionName: string]: [Filter](types#filter)\[]; <br />  };<br />   atotiServerVersion?: string; <br />} |             |

<b>Returns:</b>

[Query](types#query)\<[MdxString](types#mdxstring)> | undefined

## isActionInDashboard

An action can be used in or outside a dashboard. Some actions make sense in any context (e.g. "sort the current widget"). Some others only make sense in a dashboard (e.g. "remove widget"). This function returns whether the action is being used in a dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isActionInDashboard(props);
```

| Argument | Type                                                                                 | Description |
| :------- | :----------------------------------------------------------------------------------- | :---------- |
| props    | [ActionProps](types#actionprops)\<WidgetState, SelectionType, LowLevelSelectionType> |             |

<b>Returns:</b>

props is [WidgetInDashboardActionProps](types#widgetindashboardactionprops)\<WidgetState, SelectionType, LowLevelSelectionType>

## isBodyCell

Returns whether `props` represent a body cell in a cellset table.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isBodyCell(props);
```

| Argument | Type                                                 | Description |
| :------- | :--------------------------------------------------- | :---------- |
| props    | [CellSetTableCellProps](types#cellsettablecellprops) |             |

<b>Returns:</b>

props is [CellSetTableBodyCellProps](types#cellsettablebodycellprops)

## isHeaderCell

Returns whether `props` represent a header cell in a cellset table.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isHeaderCell(props);
```

| Argument | Type                                                 | Description |
| :------- | :--------------------------------------------------- | :---------- |
| props    | [CellSetTableCellProps](types#cellsettablecellprops) |             |

<b>Returns:</b>

props is [CellSetTableHeaderCellProps](types#cellsettableheadercellprops)

## isLevelNode

Returns whether `node` is a [LevelNode](types#levelnode). If `hierarchyCoordinates` is provided, returns whether `node` is a \$[LevelNode](types#levelnode) representing a level of this hierarchy.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isLevelNode(node, hierarchyCoordinates);
```

| Argument             | Type                                               | Description |
| :------------------- | :------------------------------------------------- | :---------- |
| node                 | [DataModelNode](types#datamodelnode)               |             |
| hierarchyCoordinates | [HierarchyCoordinates](types#hierarchycoordinates) |             |

<b>Returns:</b>

node is [LevelNode](types#levelnode)

## isStaticHeaderCell

Returns whether `props` represent a static header cell in a cellset table.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isStaticHeaderCell(props);
```

| Argument | Type                                                 | Description |
| :------- | :--------------------------------------------------- | :---------- |
| props    | [CellSetTableCellProps](types#cellsettablecellprops) |             |

<b>Returns:</b>

props is [CellSetTableStaticHeaderCellProps](types#cellsettablestaticheadercellprops)

## isTotal

Determines whether the member is a total given its hierarchy

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isTotal(hierarchy, member);
```

| Argument  | Type                                                                   | Description |
| :-------- | :--------------------------------------------------------------------- | :---------- |
| hierarchy | [Hierarchy](types#hierarchy)                                           |             |
| member    | [MemberCoordinates](types#membercoordinates) \| [Member](types#member) |             |

<b>Returns:</b>

boolean

## isWidgetInDashboard

Returns whether `props` are the properties of a widget in a dashboard. In this case, it contains a "dashboardState" and a "pageKey" attribute.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isWidgetInDashboard(props);
```

| Argument | Type                                                                                             | Description |
| :------- | :----------------------------------------------------------------------------------------------- | :---------- |
| props    | [WidgetPluginProps](types#widgetpluginprops)\<T, SelectionType, Elements, LowLevelSelectionType> |             |

<b>Returns:</b>

props is [WidgetPluginInDashboardProps](types#widgetpluginindashboardprops)\<T, SelectionType, Elements, LowLevelSelectionType>

## isWidgetWithQueryState

Returns whether `widgetState` is a [WidgetWithQueryState](types#widgetwithquerystate).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
isWidgetWithQueryState(widgetState);
```

| Argument    | Type                                   | Description |
| :---------- | :------------------------------------- | :---------- |
| widgetState | [AWidgetState](types#awidgetstate)\<T> |             |

<b>Returns:</b>

widgetState is [WidgetWithQueryState](types#widgetwithquerystate)\<MdxType, T>

## moveAllMeasures

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where all measures were moved to `indexOnAxis` on the axis with `axisName`. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
moveAllMeasures(mdx, {
  axisName,
  cube,
  indexOnAxis,
  shouldCreateNonEmptyAxis,
});
```

| Argument                                                                                          | Type                                                                                                                                                                  | Description |
| :------------------------------------------------------------------------------------------------ | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                               | [MdxSelect](types#mdxselect)                                                                                                                                          |             |
| \{<br />   axisName,<br />   cube,<br />   indexOnAxis,<br />   shouldCreateNonEmptyAxis, <br />} | \{<br />   axisName?: [AxisName](types#axisname);<br />   cube: [Cube](types#cube);<br />   indexOnAxis?: number;<br />   shouldCreateNonEmptyAxis?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## moveLevel

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given level is moved at `indexOnAxis` on the axis with `axisName`. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
moveLevel(mdx, {
  cube,
  dimensionName,
  hierarchyName,
  levelName,
  axisName,
  indexOnAxis,
  shouldCreateNonEmptyAxis,
});
```

| Argument                                                                                                                                                           | Type                                                                                                                                                                                                                                                                                                                                            | Description |
| :----------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                                                                                                | [MdxSelect](types#mdxselect)                                                                                                                                                                                                                                                                                                                    |             |
| \{<br />   cube,<br />   dimensionName,<br />   hierarchyName,<br />   levelName,<br />   axisName,<br />   indexOnAxis,<br />   shouldCreateNonEmptyAxis, <br />} | \{<br />   cube: [Cube](types#cube);<br />   dimensionName: [DimensionName](types#dimensionname);<br />   hierarchyName: [HierarchyName](types#hierarchyname);<br />   levelName: [LevelName](types#levelname);<br />   axisName?: [AxisName](types#axisname);<br />   indexOnAxis: number;<br />   shouldCreateNonEmptyAxis?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## moveMeasure

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given measure was moved to `measureIndex`. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
moveMeasure(mdx, options);
```

| Argument | Type                                                                                                                                                                          | Description |
| :------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect)                                                                                                                                                  |             |
| options  | \{<br />   cube: [Cube](types#cube);<br />   measureName: [MeasureName](types#measurename);<br />   measureIndex: number;<br />   shouldCreateNonEmptyAxis?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## moveWidget

Returns a new dashboard with the given widget moved from the specified origin to the specified target. When the moved widget was the last one on its origin page (i.e. moving across pages empties the origin page), the origin page is reset to `emptyPageState` so that it remains usable. Does not mutate dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
moveWidget({
  dashboardState,
  originLayoutPath,
  pageKey,
  originPageKey: _originPageKey,
  targetPageKey: _targetPageKey,
  side,
  targetLayoutPath,
  emptyPageState,
});
```

| Argument                                                                                                                                                                                                                      | Type                                                                                                                                                                                                                                                                                                                                                                     | Description |
| :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   dashboardState,<br />   originLayoutPath,<br />   pageKey,<br />   originPageKey: \_originPageKey,<br />   targetPageKey: \_targetPageKey,<br />   side,<br />   targetLayoutPath,<br />   emptyPageState, <br />} | \{<br />   dashboardState: [DashboardState](types#dashboardstate);<br />   originLayoutPath: number\[];<br />   pageKey?: string;<br />   originPageKey?: string;<br />   targetPageKey?: string;<br />   side: [Side](types#side);<br />   targetLayoutPath: number\[];<br />   emptyPageState?: Omit\<[DashboardPageState](types#dashboardpagestate), "name">; <br />} |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## opacitize

Returns the rgba color corresponding to the given color with the given opacity.

CSS custom property references (e.g. `var(--atoti-color-0)`) are returned as-is, since their actual value is resolved by the browser at render time.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
opacitize(color, opacity);
```

| Argument | Type                 | Description |
| :------- | :------------------- | :---------- |
| color    | [Color](types#color) |             |
| opacity  | number               |             |

<b>Returns:</b>

[Color](types#color)

## parse

Returns the Mdx abstract syntax tree corresponding to `mdxString`

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
parse(mdxString);
```

| Argument  | Type                         | Description |
| :-------- | :--------------------------- | :---------- |
| mdxString | [MdxString](types#mdxstring) |             |

<b>Returns:</b>

T

<b>Throws:</b>

[MdxError](errors#mdxerror) when `mdxString` does not represent a valid Mdx query.

## ping

Pings the server at the given URL.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
ping(serverUrl, serviceVersion, options);
```

| Argument       | Type                                   | Description |
| :------------- | :------------------------------------- | :---------- |
| serverUrl      | string                                 |             |
| serviceVersion | [ServiceVersion](types#serviceversion) |             |
| options        | RequestInit                            |             |

<b>Returns:</b>

Promise\<void>

## quote

Converts an array of strings into the corresponding stringified Mdx compound identifier.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
quote(path);
```

| Argument | Type      | Description |
| :------- | :-------- | :---------- |
| path     | string\[] |             |

<b>Returns:</b>

[MdxString](types#mdxstring)

<b>For example:</b>

```tsx theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
quote("a", "b"); // === '[a].[b]'
```

## removeAllMeasures

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where all measures were removed. Does not mutate `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removeAllMeasures(mdx, {
  cube,
  shouldRemoveCalculatedMeasureExpression,
});
```

| Argument                                                                  | Type                                                                                                    | Description |
| :------------------------------------------------------------------------ | :------------------------------------------------------------------------------------------------------ | :---------- |
| mdx                                                                       | [MdxSelect](types#mdxselect)                                                                            |             |
| \{<br />   cube,<br />   shouldRemoveCalculatedMeasureExpression, <br />} | \{<br />   cube: [Cube](types#cube);<br />   shouldRemoveCalculatedMeasureExpression?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## removeLevel

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given level was removed. Does not mutate mdx

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removeLevel(mdx, {
  cube,
  dimensionName,
  hierarchyName,
  levelName,
});
```

| Argument                                                                                  | Type                                                                                                                                  | Description |
| :---------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------ | :---------- |
| mdx                                                                                       | [MdxSelect](types#mdxselect)                                                                                                          |             |
| \{<br />   cube,<br />   dimensionName,<br />   hierarchyName,<br />   levelName, <br />} | \{<br />   cube: [Cube](types#cube);<br />   dimensionName: string;<br />   hierarchyName: string;<br />   levelName: string; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## removeMeasure

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx` where the given measure was removed. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removeMeasure(mdx, {
  cube,
  measureName,
  shouldRemoveCalculatedMeasureExpression,
});
```

| Argument                                                                                       | Type                                                                                                                                 | Description |
| :--------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                            | [MdxSelect](types#mdxselect)                                                                                                         |             |
| \{<br />   cube,<br />   measureName,<br />   shouldRemoveCalculatedMeasureExpression, <br />} | \{<br />   cube: [Cube](types#cube);<br />   measureName: string;<br />   shouldRemoveCalculatedMeasureExpression?: boolean; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## removePage

Returns a new [DashboardState](types#dashboardstate) corresponding to `dashboardState` from which the page identified by `pageKey` was removed. Does not mutate `dashboardState`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removePage(dashboardState, pageKey);
```

| Argument       | Type                                   | Description |
| :------------- | :------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate) |             |
| pageKey        | string                                 |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## removeSort

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx`, unsorted. Does not mutate `mdx`.

This function removes both `Order` functions and `ReverseHierarchize` functions (sorting for Atoti Server >= 6.0.28 or >= 6.1.15). When removing `ReverseHierarchize`, the expression is wrapped with `Hierarchize` to restore the hierarchical ordering.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removeSort(mdx);
```

| Argument | Type                         | Description |
| :------- | :--------------------------- | :---------- |
| mdx      | [MdxSelect](types#mdxselect) |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## removeWidget

Returns a new dashboard with the widget at the specified location removed. When the removed widget was the last one on its page, the page is reset to `emptyPageState` so that it remains usable. `emptyPageState` defaults to a blank page with no widgets. Does not mutate dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
removeWidget({
  dashboardState,
  layoutPath,
  pageKey,
  leafKey,
  emptyPageState,
});
```

| Argument                                                                                                         | Type                                                                                                                                                                                                                                                | Description |
| :--------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| \{<br />   dashboardState,<br />   layoutPath,<br />   pageKey,<br />   leafKey,<br />   emptyPageState, <br />} | \{<br />   dashboardState: [DashboardState](types#dashboardstate);<br />   layoutPath: number\[];<br />   pageKey: string;<br />   leafKey: string;<br />   emptyPageState?: Omit\<[DashboardPageState](types#dashboardpagestate), "name">; <br />} |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## search

Returns the matches corresponding to `searchValue` within `list`. Uses a fuzzy search algorithm. See [https://fusejs.io/](https://fusejs.io/).

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
search(list, searchValue, options);
```

| Argument    | Type                                                           | Description |
| :---------- | :------------------------------------------------------------- | :---------- |
| list        | T\[]                                                           |             |
| searchValue | string                                                         |             |
| options     | Partial\<FuseOptions\<T>> & \{<br />   limit?: number; <br />} |             |

<b>Returns:</b>

((T & \{ score: number; }) | T)\[]

## serializeDashboardState

Returns a new dashboard state where: - all MDX AST objects of filters and queries are replaced by their stringified versions - all data visualization widget mappings are serialized. Does not mutate the passed dashboard state.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
serializeDashboardState(dashboardState);
```

| Argument       | Type                                                    | Description |
| :------------- | :------------------------------------------------------ | :---------- |
| dashboardState | [DashboardState](types#dashboardstate)\<"deserialized"> |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)\<"serialized">

## serializeFilter

Serializes a [Filter](types#filter), making it lighter to store on the Content Server.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
serializeFilter(filter);
```

| Argument | Type                                    | Description |
| :------- | :-------------------------------------- | :---------- |
| filter   | [Filter](types#filter)\<"deserialized"> |             |

<b>Returns:</b>

[Filter](types#filter)\<"serialized">

## serializeWidgetState

Accepts a deserialized `widgetState`, as it lives in the state of [Dashboard](components#dashboard) and returns its serialized version, ready to be saved on a content server.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
serializeWidgetState(widgetState, options);
```

| Argument    | Type                                                | Description |
| :---------- | :-------------------------------------------------- | :---------- |
| widgetState | [AWidgetState](types#awidgetstate)\<"deserialized"> |             |
| options     | \{<br />   indent?: boolean; <br />}                |             |

<b>Returns:</b>

[AWidgetState](types#awidgetstate)\<"serialized">

## setCubeName

Returns a new [MdxSelect](types#mdxselect) or [MdxDrillthrough](types#mdxdrillthrough) corresponding to `mdx` with `cubeName` updated as required. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
setCubeName(mdx, {
  cubeName,
});
```

| Argument                    | Type                                                                     | Description |
| :-------------------------- | :----------------------------------------------------------------------- | :---------- |
| mdx                         | [MdxSelect](types#mdxselect) \| [MdxDrillthrough](types#mdxdrillthrough) |             |
| \{<br />   cubeName <br />} | \{<br />   cubeName: string; <br />}                                     |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect) | [MdxDrillthrough](types#mdxdrillthrough)

## setDrillthroughColumns

Returns a new [MdxDrillthrough](types#mdxdrillthrough) corresponding to `mdx`. The columns in the returned MDX are set to the drillthrough columns corresponding to `drillthroughColumnUniqueNames`. Does not mutate `mdx`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
setDrillthroughColumns(mdx, {
  drillthroughColumnUniqueNames,
});
```

| Argument                                          | Type                                                                                                                     | Description |
| :------------------------------------------------ | :----------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                               | [MdxDrillthrough](types#mdxdrillthrough)                                                                                 |             |
| \{<br />   drillthroughColumnUniqueNames, <br />} | \{<br />   drillthroughColumnUniqueNames: [DrillthroughColumnUniqueName](types#drillthroughcolumnuniquename)\[]; <br />} |             |

<b>Returns:</b>

[MdxDrillthrough](types#mdxdrillthrough)

## setFilters

Returns a new [MdxSelect](types#mdxselect) or [MdxDrillthrough](types#mdxdrillthrough) corresponding to `mdx` where the filters were set to `filters`. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
setFilters(mdx, {
  filters,
  cube,
});
```

| Argument                                  | Type                                                                                                                                                                                                               | Description |
| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                       | [MdxSelect](types#mdxselect) \| [MdxDrillthrough](types#mdxdrillthrough)                                                                                                                                           |             |
| \{<br />   filters,<br />   cube, <br />} | \{<br />   filters: ([MdxExpression](types#mdxexpression) \| \{<br />     mdx: [MdxExpression](types#mdxexpression);<br />     nonVisualTotals?: boolean; <br />  })\[];<br />   cube: [Cube](types#cube); <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect) | [MdxDrillthrough](types#mdxdrillthrough)

## setSort

Returns a new [MdxSelect](types#mdxselect) corresponding to `mdx`, sorted as specified. Does not mutate mdx.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
setSort(mdx, {
  cube,
  levelCoordinates,
  orderMode,
  tupleCoordinates,
  serverVersion,
});
```

| Argument                                                                                                               | Type                                                                                                                                                                                                                                                                        | Description |
| :--------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| mdx                                                                                                                    | [MdxSelect](types#mdxselect)                                                                                                                                                                                                                                                |             |
| \{<br />   cube,<br />   levelCoordinates,<br />   orderMode,<br />   tupleCoordinates,<br />   serverVersion, <br />} | \{<br />   cube: [Cube](types#cube);<br />   levelCoordinates?: [LevelCoordinates](types#levelcoordinates);<br />   orderMode: [OrderMode](types#ordermode);<br />   tupleCoordinates?: [TupleCoordinates](types#tuplecoordinates);<br />   serverVersion?: string; <br />} |             |

<b>Returns:</b>

[MdxSelect](types#mdxselect)

## sortTree

Returns a new tree, corresponding to `tree` recursively sorted using `comparator`. Does not mutate `tree`.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
sortTree(tree, comparator);
```

| Argument   | Type                                         | Description |
| :--------- | :------------------------------------------- | :---------- |
| tree       | [TreeObject](types#treeobject)\<NodeType>\[] |             |
| comparator | (nodeA: NodeType, nodeB: NodeType) => number |             |

<b>Returns:</b>

[TreeObject](types#treeobject)\<NodeType>\[]

## stringify

Returns the Mdx string corresponding to `mdx`

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
stringify(mdx, options, indenter);
```

| Argument | Type                                     | Description |
| :------- | :--------------------------------------- | :---------- |
| mdx      | [Mdx](types#mdx)                         |             |
| options  | \{<br />   indent?: boolean; <br />}     |             |
| indenter | [GenericIndenter](types#genericindenter) |             |

<b>Returns:</b>

[MdxString](types#mdxstring)

## traverseMdx

Walks through `mdx` recursively and calls `callback` on each node. If `callback` explicitly returns `false` when evaluated on a node, the function execution is stopped, and `false` is returned.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
traverseMdx(mdx, callback, path);
```

| Argument | Type                                                                    | Description |
| :------- | :---------------------------------------------------------------------- | :---------- |
| mdx      | [Mdx](types#mdx) \| null \| undefined \| [Mdx](types#mdx)\[]            |             |
| callback | (mdx: [Mdx](types#mdx), path: (string \| number)\[]) => boolean \| void |             |
| path     | (string \| number)\[]                                                   |             |

<b>Returns:</b>

boolean | void

## unquote

Converts a stringified Mdx compound identifier into the corresponding array of strings.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
unquote(str);
```

| Argument | Type                         | Description |
| :------- | :--------------------------- | :---------- |
| str      | [MdxString](types#mdxstring) |             |

<b>Returns:</b>

string\[]

<b>For example:</b>

```tsx theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
unquote("[a].[b]"); // === ['a', 'b']
```

## updatePage

Updates the page with the specified key in the dashboard. Does not mutate dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
updatePage(dashboardState, pageKey, updater);
```

| Argument       | Type                                                           | Description |
| :------------- | :------------------------------------------------------------- | :---------- |
| dashboardState | [DashboardState](types#dashboardstate)                         |             |
| pageKey        | string                                                         |             |
| updater        | (page: [DashboardPageState](types#dashboardpagestate)) => void |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## updateWidget

Updates the widget with the specified key in the specified page in the dashboard. Does not mutate dashboard.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
updateWidget(
  dashboardState,
  {
    pageKey,
    leafKey,
  },
  updater,
);
```

| Argument                                     | Type                                                         | Description |
| :------------------------------------------- | :----------------------------------------------------------- | :---------- |
| dashboardState                               | [DashboardState](types#dashboardstate)                       |             |
| \{<br />   pageKey,<br />   leafKey, <br />} | \{<br />   pageKey: string;<br />   leafKey: string; <br />} |             |
| updater                                      | (widget: WidgetState) => WidgetState                         |             |

<b>Returns:</b>

[DashboardState](types#dashboardstate)

## withDefaultCellStyle

Provides `style` to the underlying table cell Component.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
withDefaultCellStyle(CellComponent);
```

| Argument      | Type                                                           | Description |
| :------------ | :------------------------------------------------------------- | :---------- |
| CellComponent | ForwardRefExoticComponent\<T & RefAttributes\<HTMLDivElement>> |             |

<b>Returns:</b>

ForwardRefExoticComponent\<PropsWithoutRef\<T> & RefAttributes\<HTMLDivElement>>

## withLazyLoadedQueryResult

Runs the widget's query and provides its result to the underlying component. Also provides the query's lazy loading ranges and a callback to change them. Requires the underlying widget plugin to have a `widgetPlugin.lazyLoading` attribute, containing the chunkSizes it should load.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
withLazyLoadedQueryResult(WrappedComponent);
```

| Argument         | Type                                                                                                                                               | Description |
| :--------------- | :------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| WrappedComponent | ComponentType\<[WidgetWithQueryProps](types#widgetwithqueryprops)\<WidgetState, [CellSet](types#cellset), Selection, Elements, LowLevelSelection>> |             |

<b>Returns:</b>

ComponentType\<[WidgetPluginProps](types#widgetpluginprops)\<WidgetState, Selection, Elements, LowLevelSelection>>

## withQueryResult

Runs the widget's query and provides its result to the underlying component.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
withQueryResult(WrappedComponent);
```

| Argument         | Type                                                                                                                                               | Description |
| :--------------- | :------------------------------------------------------------------------------------------------------------------------------------------------- | :---------- |
| WrappedComponent | ComponentType\<[WidgetWithQueryProps](types#widgetwithqueryprops)\<WidgetState, [CellSet](types#cellset), Selection, Elements, LowLevelSelection>> |             |

<b>Returns:</b>

ComponentType\<[WidgetPluginProps](types#widgetpluginprops)\<WidgetState, Selection, Elements, LowLevelSelection> & \{ queryRanges?: Partial\<\{ \[axisId in [AxisId](types#axisid)]: [QueryRange](types#queryrange); }>; onQueryRangesChanged?: (newQueryRanges: Partial\<\{ \[axisId in [AxisId](types#axisid)]: [QueryRange](types#queryrange); }>) => void; }>

## withWidgetLoadingBar

Displays a loading bar above a widget if a query is taking a while to load.

```typescript theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
withWidgetLoadingBar(WrappedComponent);
```

| Argument         | Type                                                           | Description |
| :--------------- | :------------------------------------------------------------- | :---------- |
| WrappedComponent | ForwardRefExoticComponent\<T & RefAttributes\<HTMLDivElement>> |             |

<b>Returns:</b>

ForwardRefExoticComponent\<PropsWithoutRef\<T> & RefAttributes\<HTMLDivElement>>
