Skip to main content

# App SDK API

## Classes​

Class | Description
--- | ---
Analytics | Analytics scripting object
CMicroAppGuest | Micro-frontend guest application class (singleton). Manages communication between a guest micro-app and its host application. Supports both SSF (Shared Service Framework) and App Bridge communication methods.
CMicroAppHost | Micro-frontend host application class (singleton). Manages hosting and coordination of multiple micro-frontend guest applications. Provides shared services like navigation, theming, analytics, and state management.
ErrorBoundary | React error boundary component that catches JavaScript errors in child components. Logs errors and displays a fallback UI instead of crashing the app.

## Interfaces​

Interface | Description
--- | ---
AppConfig | -
UseStateSelectorOptions | -

## Functions​

Function | Description
--- | ---
AppRoot | Root component for SDK-based applications. Provides Redux store, routing, theming, error boundaries, and session management.
authorize | Handles the OAuth authorization callback after redirect from IDP. Exchanges authorization code for access token and initializes user session.
authSaga | -
Autocomplete | -
CheckBox | -
cleanup | Unmounts React trees that were mounted with render.
ComboBox | Dropdown/select field component with React Hook Form integration. Wraps the Dimsum ComboBox component with form state management and validation.
ComboBoxV3 | -
configureStore | Creates and configures the Redux store with SDK middleware and enhancers. Includes saga middleware, listener middleware, RTK Query support, and hot reloading.
ConnectForm | -
createManager | Creates a "manager" component that will inject the provided reducer and saga when mounted. It only renders its children after both the reducer and saga have been injected. This is the recommended way to use redux-injectors.
DateInput | -
DatePicker | Date picker field component with React Hook Form integration. Wraps the Dimsum DatePicker component with form state management and validation.
DateRangePicker | -
DateTimePicker | -
enableReactAppForHostIntegration | -
fetchHostAppData | -
fetchUserSettings | -
Form | Form component with integrated React Hook Form state management and validation. Provides form context to all child form fields and handles submission.
FormItemLayout | -
FormLayoutBlockItem | -
FormSubmitButton | -
getApiActionCreator | -
getAppConfigValue | Gets a value from the application configuration using dot notation. Returns a deep clone to prevent accidental mutations.
getAuthHTTPClient | Creates an authenticated HTTP client instance with authorization headers. Automatically includes the current user's authorization token in all requests.
getAuthorizationHeader | Gets the current authorization header value from session storage.
getHostAppDataByKey | -
getHTTPClient | Creates a basic HTTP client instance using Axios. The client includes request/response interceptors and automatic retry logic.
getLogger | -
getMicroFrontEndAppConfig | -
getNavigationLinks | -
getRedirectUrl | -
getSelectField | Why use this? It will prevent unnecessary rerenders hence improving performance, it also reduces the amount of code needed to select data from the store hence making it easier and keeping your codebase smaller and easier to maintain.
getStore | Gets the global Redux store instance.
initServiceWorker | -
InputMask | -
InputText | -
isCIBuild | -
isProd | -
isUserAuthorized | Checks if the user is currently authorized/authenticated.
LargeTextBox | -
listenStorageEvents | -
loadable | Creates a lazily-loaded React component for code splitting. Wraps the component in Suspense with a customizable fallback.
loadAppConfig | Loads the application configuration from a JSON file. Attempts to fetch from versioned path first, then falls back to unversioned path. Merges environment-specific configuration with base configuration.
login | Initiates the login flow using OAuth/OIDC authorization code flow. If authorization code is present in URL, completes the authorization. Otherwise, redirects to the identity provider's login page.
MaskedInputText | -
notifyGuestUnloadComplete | -
onAuthorizationFailure | Registers a callback to handle authorization failures (401 errors). The callback should refresh the authentication token and return the new authorization header. The SDK will automatically retry the failed request with the new token.
onGuestUnloadStart | -
Page | -
Radio | -
RadioGroup | -
redactPii | Redacts personally identifiable information (PII) from data objects. Removes sensitive data like credit cards, SSNs, emails, passwords, addresses, etc.
RegisterService | -
removeDoubleSlash | -
removeStorageEvents | -
render | -
renderHook | Allows you to render a hook within a test React component without having to create that component yourself.
renderWithHostData | -
renderWithRedux | -
renderWithRouter | -
renderWithRouterRedux | -
RenderWithStateAddOns | -
RequireAuth | A React component that ensures authentication for its children.
sdkBaseQuery | Base query function for RTK Query integration. Provides automatic error handling, authentication, and token refresh capabilities. Use this as the baseQuery for RTK Query API slices.
sendBAEvent | Sends a business analytics event to Google Tag Manager data layer. Can send events to the host app or handle locally.
sendMessageToHost | -
SessionTimeout | -
setAppConfig | Sets the entire application configuration. Replaces the current configuration with the provided config object.
setAppConfigValue | Sets a value in the application configuration using dot notation. Creates nested objects if they don't exist.
setHostAppData | -
setLoginParams | Sets login parameters for the authentication flow. Stores parameters in the global window object for use across the application.
subscribeToResetSession | Subscribes to session reset events. The callback is invoked when the session idle time is reset.
subscribeToSessionExpiry | Subscribes to session expiry events. The callback is invoked when the session has expired.
subscribeToSessionExpiryWarning | Subscribes to session expiry warning events. The callback is invoked when the session is about to expire (based on warning interval).
TextBox | Text input field component with React Hook Form integration. Wraps the Dimsum TextBox component with form state management and validation.
Toggle | -
trackActivity | Starts tracking user activity for session management. Monitors user interactions on the specified element and invokes callback.
useAppDispatch | React hook to get the typed dispatch function. Provides type-safe dispatching of Redux actions.
useAppMiddleware | -
useInjectQuery | React hook to dynamically inject RTK Query API slice into the Redux store. Registers the reducer and middleware for the API slice at runtime.
useInjectReducer | A react hook that dynamically injects a reducer when the hook is run
useInjectSaga | A react hook that dynamically injects a saga when the hook is run
useInjectSideEffect | -
useMediaQueryList | -
useStateSelector | Generic selector that receives a field selector function returned from getSelectField
useStateSelectorShallow | Generic selector that receives a field selector function returned from getSelectField.
waitFor | -
waitForElementToBeRemoved | -
withAppDecorator | -

## Modules​

Module | Description
--- | ---
@elliemae/ds-form | -

## References​

### CMicroApp​

Renames and re-exports CMicroAppGuest

### MASK_PIPES​

Renames and re-exports @elliemae/ds-form

## Type Aliases​

Type Alias | Description
--- | ---
AppDispatch | -
AppStore | -
Await | -
EMUI | -
OnHostInitCallback | -
OnInitCallback | -
OnMountCallback | -
OnUnMountCallback | -
RootState | -
SelectStateFieldFunction | -

## Variables​

Variable | Description
--- | ---
act | Simply calls ReactDOMTestUtils.act(cb) If that's not available (older version of react) then it simply calls the given callback immediately
ariaLive | -
auth | -
authReducer | -
clearSideEffects | Clears all registered side effect listeners. Useful for cleanup or resetting the app state.
createSideEffect | Creates a new side effect listener. Alternative API for adding listeners.
decorators | -
endSession | Ends the current user session and redirects to logout page. Revokes tokens and clears session storage.
error | -
errorMiddleware | -
ErrorToast | -
fireEvent | -
globalConstants | -
GuestMicroApp | Component to load a guest microapp
history | -
httpClientProps | -
logout | -
memoryHistory | -
MicroApp | Component to render a guest microapp
MicroIFrameApp | Component to render a guest microapp in an iframe.
NavigationPrompt | -
NavigationPromptActions | -
removeSideEffect | Removes a side effect listener.
resetUserIdleTime | Resets the user idle time counter. Call this when user performs an action to extend their session.
screen | -
startSideEffect | Starts a side effect listener. Used to listen for specific actions and execute side effects.
Themes | -
updateBAEventParameters | Updates the business analytics event parameters with new values
useAppSelector | React hook to select data from Redux store with type safety. Automatically typed to the app's RootState.
VisuallyHidden | -
WaitMessage | -
waitMessageAction | -
within | -