SDK Layer#

The SDK Layer is the mid-level of the HAAPI SDK stack. It offers structured flow stepping (start → submit → followLink), OAuth token management, and platform-aware configuration. It is the natural entry point for React Native apps (RN’s only public surface lives here) and a good fit for iOS and Android applications that want to build their own UI on top of a typed HAAPI flow.

Reading order. Start with the SDK Layer Overview, then jump to your platform’s entry page. The shared topic pages (HAAPI Flow, OAuthTokenManager, Token Binding, …) use platform tabs and can be read in any order once the platform entry is familiar.

Foundational#

Layer overview and per-platform entry points.

PageTopic
SDK Layer Overview What the SDK Layer is, when to choose it over the UI or Driver Layer
iOS SDK Install IdsvrHaapiSdk, build HaapiAccessor, link to the autodoc
Android SDK Install the Maven artifact, build HaapiAccessor, link to the autodoc
React Native SDK Install the npm package, build the configuration, the accessor factory pattern

Per-Platform Representations#

Narrative references for the HAAPI response model on each platform — the same 14 step types, action shapes, and problem variants, expressed in each platform’s type system.

PageTopic
iOS Representations The HaapiResult enum and HaapiRepresentation protocol hierarchy; switching with Swift pattern matching
Android Representations The HaapiResponse sealed interface and concrete step classes; branching with Kotlin when
React Native Representations The HaapiResponse discriminated union and 14 step types; switching on stepType from React

React Native Specifics#

Pages that exist only for React Native because the iOS and Android SDKs cover the same ground natively.

PageTopic
Native Resolvers (React Native) The host-app extension mechanism — registering custom URLSession / KeyStore / Storage in native Swift / Kotlin

Configuration and Topics#

Cross-platform topics shown with iOS / Android / React Native tabs. Each page covers configuration parameters, runtime behaviour, and per-platform notes.

PageTopic
Creating a HaapiAccessor HaapiAccessorBuilder (iOS), HaapiAccessorFactory (Android), initializeForHaapi (React Native)
HAAPI Flow start → submitForm → followLink stepping and step-type dispatch
OAuthTokenManager Fetching, refreshing, and revoking tokens after the HAAPI flow completes
Client Authentication (SDK Layer) Secret, MTLS, and Signed JWT — required for DCR fallback
Token Binding (SDK Layer) DPoP-bound authorization codes and refresh tokens
Dynamic Client Registration (SDK Layer) Per-device dynamic OAuth client for attestation-incapable devices
Risk Assessment (SDK Layer) Device-context fields for BankID-style risk integrations

Operational#

Cross-cutting operational concerns that apply to every SDK Layer integration.

PageTopic
Token Endpoint Response Listener Capture raw HTTP headers and JSON from the OAuth token endpoint
Error Handling (SDK Layer) Retryable / unrecoverable / OAuth-protocol error dispatch
Logging (SDK Layer) HaapiLogger configuration, sensitive-value masking, custom sinks

Was this helpful?