Home > @uniformdev/mesh-sdk

mesh-sdk package

Classes

Class

Description

IntegrationDefinitionClient

API Client to manage the registration of custom Mesh applications and their identity-delegation credentials.

IntegrationInstallationClient

API Client to manage the registration of custom Mesh applications

Functions

Function

Description

hasPermissions(permissions, user)

hasRole(role, user)

Check if user has a role by both name and id

initializeUniformMeshSDK({ autoResizingDisabled, }, input)

Initializes the Uniform Mesh SDK. Intended to be called (and awaited) prior to any attempted interaction with the Uniform Mesh SDK.

parseFunctionCall(request)

Interfaces

Interface

Description

DialogContext

DialogOptions

DialogResponseData

DialogResponseHandler

DialogResponseHandlers

EditorStateApi

Imperative API for interacting with the composition/entry editor state. Available on canvasEditorTools, and dataResourceSelector locations.

All methods use object parameters for consistency across client, wire format, and server.

LocationDialogResponse

MeshContextData

MeshLocationCore

Core shared generic for a mesh location context

MeshParentConnection

Methods the parent frame exposes to the Mesh SDK over the iframe bridge (connectToParent().parent). The dashboard implements the same shape when wiring setupIframeListeners / mesh location hosts.

SdkWindow

SetPropertyLocalizabilityCommonParams

Common fields for EditorStateApi.setPropertyLocalizability().

UniformMeshSDK

Variables

Variable

Description

CSRF_HEADER_NAME

Default custom-header name partners attach on every state-changing call to the BFF. Any fixed, non-CORS-safelisted header name works — the value is irrelevant to the security argument; only its presence matters.

The browser will not attach a non-safelisted header on a cross-origin request without a CORS preflight, so any request that arrives with the header must have originated from same-origin JavaScript.

The constant is exported so the BFF and the consumer's browser fetch helper share one source of truth.

CSRF_HEADER_VALUE

Default expected value for the custom CSRF header. Constant; the security argument is presence-of-header, not value-secrecy. Kept as '1' so the value is trivial to recognise in logs and developer tooling.

DELEGATION_EXPIRED_CODE

BFF 401 body code when the delegation session is missing or the access token is expired. Clients re-exchange the Mesh session token and retry once. Do not use for other 401s.

DELEGATION_SESSION_EXPIRED_MESSAGE

Human-readable message to pair with DELEGATION_EXPIRED_CODE.

functionCallSystemParameters

Type Aliases

Type Alias

Description

AIGenerateLocation

AIGenerateLocationMetadata

AIPromptMetadataLocation

AssetLibraryLocation

AssetLibraryLocationMetadata

AssetParameterLocation

AssetParameterLocationMetadata

BindableTypes

Primitive data types that a parameter type accepts to be bound to composition data

CanvasEditorContextMetadata

Serializable metadata fields available in Canvas/Entry editor context. EditorStateApi is not part of metadata; it is provided on the location object via mesh-sdk comms.

CanvasEditorEntityType

CanvasEditorToolsData

CanvasEditorToolsLocation

CanvasEditorToolsLocationMetadata

CloseDialogMessage

CloseLocationDialogOptions

CommonMetadata

Common metadata for all mesh locations

ConnectToParentResult

CSSHeight

DashboardToolLocation

DashboardToolLocationMetadata

DataConnectorInfo

DataResourceLocation

DataResourceLocationMetadata

DataResourceSelectorLocation

Location for custom data resource selector UI. Replaces the default JSON tree viewer when selecting dynamic tokens from a data resource.

Value: The selected JSON pointer string (e.g., "/moves/0/move/name") setValue: Call with a valid JSON pointer to select that path getDataResource: Fetch data from the data connector using the current data source editorState: Imperative API for inspecting/mutating the underlying composition / entry tree

DataResourceSelectorLocationMetadata

Metadata for the dataResourceSelector location. This location type allows custom UI for selecting JSON pointers within a data resource, replacing the default JSON tree viewer in the dynamic token picker.

DataSourceLocation

DataSourceLocationMetadata

DataSourceLocationValue

DataTypeLocation

DataTypeLocationMetadata

DataTypeLocationValue

DeleteNodeOptions

Options for deleteNode

DialogParams

DialogParamValue

DialogType

DynamicInput

Dynamic inputs come from project map and represent path or query based dynamic values These can be connected to from within a Mesh location by setting a data resource variable to contain ex: $} expression(s).

Dynamic inputs only work at runtime when using the route endpoint to fetch data.

DynamicInputs

Record of dynamic inputs keyed by the input name

EditConnectedDataMessage

Message to parent to create a data connection expression to insert in a param type

EditConnectedDataResponse

Response from parent when creating a dynamic token expression

EditConnectedDataResponseCancellationContext

EditorComponentInstance

A component instance without slots/params (indexed separately)

EditorComponentParameter

A component parameter value

EditorExportOptions

Options for exporting the tree

EditorNode

An indexed node within the editor state

EditorNodeChildren

Child node IDs indexed by slot name

EditorNodeParentInfo

Parent info for a node

EditorRootMetadata

Metadata about the composition (description, category, workflow, etc.)

EditorRootNodeMetadata

Root node metadata (name and slug)

EmbeddedEditorLocation

EmbeddedEditorLocationMetadata

EmbeddedEditorLocationSetValue

EmbeddedEditorLocationValue

FunctionCallResponse

FunctionCallSystemParameter

GetDataResourceLocation

GetDataResourceMessage

GetEditorStateLocation

GetEditorStateLocationMaybe

InsertNodeOptions

Options for insertNode

InsertPatternOptions

Options for insertPattern

IntegrationCredentialRevokeParameters

The DELETE body for /api/v1/integration-credentials (revoke)

IntegrationCredentialRotateParameters

The POST body for /api/v1/integration-credentials (rotate or mint)

IntegrationCredentialRotateResponse

The POST response for /api/v1/integration-credentials (returns the plaintext secret once)

IntegrationDefinitionDeleteParameters

The DELETE body for /api/v1/integration-definitions

IntegrationDefinitionGetParameters

Query parameter options for GET /api/v1/integration-definitions

IntegrationDefinitionGetResponse

The GET response from /api/v1/integration-definitions

IntegrationDefinitionPutParameters

The PUT body for /api/v1/integration-definitions

IntegrationDefinitionPutResponse

The PUT response body for /api/v1/integration-definitions (has team-specific integration type)

IntegrationInstallationDeleteParameters

The DELETE body for /api/v1/integration-installations

IntegrationInstallationGetParameters

Query parameter options for GET /api/v1/integration-installations

IntegrationInstallationGetResponse

The GET response from /api/v1/integration-installations

IntegrationInstallationPutParameters

The PUT body for /api/v1/integration-installations

MeshLocation

Defines methods used for interacting with a Mesh location To receive useful typings, check the type property of the location to narrow the typing.

MeshLocationTypes

Known location types that can be passed to a mesh location

MeshLocationUserPermissions

MeshRouter

MeshSDKEventInterface

Shape of the handler object the mesh parent iframe must provide (includes initialize for the host side).

MoveNodeOptions

Options for moveNode

NavigateMessage

OpenConfirmationDialogOptions

OpenConfirmationDialogResult

OpenDialogMessage

OpenDialogResult

OpenLocationDialogOptions

ParamTypeConfigLocation

ParamTypeConfigLocationMetadata

ParamTypeLocation

ParamTypeLocationMetadata

PersonalizationCriteriaLocation

PersonalizationCriteriaLocationMetadata

ProjectToolLocation

ProjectToolLocationMetadata

PromptSettingsLocationMetadata

SetLocationFunction

SetPropertyLocalizabilityParams

Discriminated-union params for EditorStateApi.setPropertyLocalizability().

  • isLocalized: true (toggle ON): per-locale values are written to every enabled locale of the composition. - isLocalized: false (toggle OFF): per-locale values are collapsed back into a single invariant value, copying from copyFromLocale (or the first defined locale).

SettingsLocation

SettingsLocationMetadata

SetValueMessage

SetValueOptions

UniformMeshSDKEvents

Events that can be emitted from the Mesh SDK

UniformUser

UpdateNodePropertyOptions

Options for updateNodeProperty

UpdateRootNodeOptions

Options for updateRootNode

ValidationResult