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

# Container app authentication

> Configure authentication flows, landing pages, and session management for container applications that embed FlowX UI Flows.

## Overview

A **container app** is any web or mobile application that embeds FlowX UI Flows using the FlowX renderers (Angular, React, React Native, iOS, or Android SDKs). Container apps are responsible for authenticating end users before rendering FlowX content.

The container app authentication flow provides built-in support for OAuth2/OIDC authentication, custom landing pages, and session management.

***

## Key features

> [card] Authentication providers
>
> Support for multiple OAuth2/OIDC authentication providers via Keycloak integration

> [card] Custom landing page
>
> Configure a landing page for unauthenticated users with organization branding

> [card] Session management
>
> Automatic token refresh, silent refresh support, and redirect URI persistence

> [card] SSO integration
>
> Single sign-on across container apps within the same organization

***

## How it works

The container app authentication flow handles the following:

**1. Organization resolution**

The container app resolves the organization context using the hostname or an organization code. This determines which Keycloak realm and authentication configuration to use.

**2. Authentication redirect**

Unauthenticated users are redirected to the configured identity provider (Keycloak) for login. The redirect URI is persisted in local storage to restore the user's navigation state after authentication.

**3. Token management**

After successful authentication, the container app manages access tokens with automatic refresh. Silent refresh keeps the session alive without requiring user interaction.

**4. UI Flow rendering**

Once authenticated, the container app renders FlowX UI Flows with the user's identity and permissions.

***

## Configuration

### Authentication setup

Container apps authenticate using OAuth2/OIDC with the following configuration:

| Parameter | Description |
| - | - |
| **Organization code** | Identifies the organization for multi-tenant environments. Can be derived from the hostname or provided explicitly. |
| **Keycloak realm** | The Keycloak realm associated with the organization |
| **Client ID** | The OAuth2 client ID registered in Keycloak for the container app |
| **Redirect URI** | The URI to redirect to after authentication. Persisted across browser sessions. |

> [!TIP]
>
> For multi-tenant SaaS deployments, the organization code is typically extracted from the subdomain (e.g., `acme.flowx.ai` resolves to organization `acme`).

### Landing page

You can configure a custom landing page that appears for unauthenticated users. This page can include:

* Organization branding and logo
* Login button that initiates the authentication flow
* Links to support or documentation

> [card] [Container app branding](https://docs.flowx.ai/6.x/docs/saas/container-app-branding.md)
>
> Customize colors, logo, and header appearance for the container app

### Session behavior

| Behavior | Description |
| - | - |
| **Token refresh** | Access tokens are refreshed automatically before expiration |
| **Silent refresh** | Background token renewal without user interaction |
| **Redirect persistence** | The user's intended destination is stored and restored after login |
| **Session timeout** | Configurable session duration based on Keycloak realm settings |

***

## SDK integration

Each FlowX renderer SDK handles container app authentication:

> [tab] Angular
>
> The Angular SDK integrates with `angular-oauth2-oidc` for authentication handling. Configure the OAuth2 module in your app with the Keycloak endpoints for your organization.
>
> For setup details, see the [Angular SDK documentation](https://docs.flowx.ai/6.x/sdks/angular-renderer.md).

> [tab] React
>
> The React SDK provides authentication hooks that connect to your Keycloak instance.
>
> For setup details, see the [React SDK documentation](https://docs.flowx.ai/6.x/sdks/react-renderer.md).

> [tab] React Native
>
> For setup details, see the [React Native SDK documentation](https://docs.flowx.ai/6.x/sdks/react-native-renderer.md).

> [tab] iOS
>
> The iOS renderer handles OAuth2 authentication natively with secure token storage in the keychain.
>
> For setup details, see the [iOS SDK documentation](https://docs.flowx.ai/6.x/sdks/ios-renderer.md).

> [tab] Android
>
> The Android renderer integrates with AppAuth for secure OAuth2 authentication.
>
> For setup details, see the [Android SDK documentation](https://docs.flowx.ai/6.x/sdks/android-renderer.md).

***

## Related resources

> [card] [IAM Configuration](https://docs.flowx.ai/6.x/setup-guides/access-management/configuring-an-iam-solution.md)
>
> Set up Keycloak realms, clients, and service accounts

> [card] [UI Flows](https://docs.flowx.ai/6.x/docs/building-blocks/ui-flows.md)
>
> Learn about UI Flows and how they render in container apps

> [card] [FlowX SaaS Overview](https://docs.flowx.ai/6.x/docs/saas/saas-overview.md)
>
> Understand the FlowX SaaS deployment model

> [card] [Workspaces & Access Rights](https://docs.flowx.ai/6.x/setup-guides/access-management/workspaces-access-rights.md)
>
> Configure workspace-level access control


## Related topics

- [FlowX.AI 5.5.0 Release Notes](https://docs.flowx.ai/release-notes/v5.x/v5.5.0-february-2026/v5.5.0-february-2026.md)
- [Container app branding](https://docs.flowx.ai/6.x/docs/saas/container-app-branding.md)
- [FlowX.AI 5.6.0 Release Notes](https://docs.flowx.ai/release-notes/v5.x/v5.6.0-march-2026/v5.6.0-march-2026.md)
- [Anonymous runtime access](https://docs.flowx.ai/6.x/docs/platform-deep-dive/user-roles-management/anonymous-runtime-access.md)
- [UI Flows](https://docs.flowx.ai/6.x/docs/building-blocks/ui-flows.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.