Trusted Web Activity - Android
A Trusted Web Activity (TWA) ↗ (https://developer.chrome.com/docs/android/trusted-web-activity) enables Android apps to display web content in full-screen mode using Chrome, without any browser UI elements. Unlike WebView, TWAs run in the user's browser context, allowing better performance, access to browser features (like push notifications and background sync), and shared cookies, permissions, and storage between the app and the browser.
To enable Trusted Web Activity, contact your integration manager with the app’s package name and certificate hash.
Trusted Web Activity support is project-independent and applies at the app level — based on the package name and signing certificate only.
Configuring for Trusted Web Activity in the SDK
When configuring the SDK, supply an activity setting to the config like this:
final Config.Payments configPayments = Config.Payments.getDefault()
.withActivity(Config.Payments.Activity.forTrustedWebActivity());
This ensures that the Trusted Web Activity will be used by the payment flow.
Trusted Web Activity availability depends on the device's system configuration, i.e. a compatible browser needs to be installed. If TWA support is not available, then the SDK falls back to one of the default activity types for payments (e.g. Custom Tabs or WebView, depending on the environment).
An example of the TWA in action:

(Optional) Orientation locking
Trusted Web Activity natively supports orientation locking when it's shown on the screen. This can be setup during the configuration step with these lines:
final Config.Payments configPayments = Config.Payments.getDefault()
.withActivityOrientationLock(
// orientation setting
);
Orientation setting is one of the following values:
Config.Payments.ACTIVITY_ORIENTATION_LOCK_PORTRAIT
- forces the TWA to be displayed in portrait mode.Config.Payments.ACTIVITY_ORIENTATION_LOCK_LANDSCAPE
- forces the TWA to be displayed in landscape mode.null
- disables the orientation locking.