Configuration
This is the consumer WolletteConfig reference. Merchant apps use WollettePosConfig in the POS API reference.
Pass WolletteConfig when creating the SDK. Invalid API-origin or timeout settings throw VALIDATION. Obtain environment URLs from Wollette; the example URLs below are placeholders.
| Field | Type | Default | Notes |
|---|---|---|---|
apiBaseUrl | String | required | HTTPS origin. The SDK appends /api/v1 |
requestTimeoutMillis | Int | 60000 | Must be positive |
loginBaseUrl | String? | none | HTTPS origin of the hosted login service. Required for login and refresh |
redirectUri | String? | none | App callback URI for hosted login, for example myapp://wollette-callback. Android: intent filter on LoginRedirectActivity. iOS: scheme in CFBundleURLTypes |
registrationToken | String? | none | Firebase token the SDK uses for device association once a session exists. Required for push/payment-device features, not a basic wallet read. Passing it here does not associate the device by itself; call setRegistrationToken after sign-in before those features and on token rotation. On Android, pay also uses it |
appType | WolletteAppType | THIRD_PARTY / .thirdParty | Controls only whether createUser requires an address |
WolletteAppType
| Value | Rule |
|---|---|
THIRD_PARTY / .thirdParty | Default. createUser requires an address |
NATIVE_WOLLETTE / .nativeWollette | createUser may omit an address. This is not a credential or authorisation grant |
Constructors
val sdk = WolletteSdk(
context = applicationContext,
config = WolletteConfig(
apiBaseUrl = "https://api.example.com",
loginBaseUrl = "https://login.example.com", // omit for applySession
redirectUri = "myapp://wollette-callback", // omit for applySession
registrationToken = fcmToken,
),
)let sdk = try WolletteSDK(
config: WolletteConfig(
apiBaseUrl: "https://api.example.com",
loginBaseUrl: "https://login.example.com", // omit for applySession
redirectUri: "myapp://wollette-callback", // omit for applySession
registrationToken: fcmToken
)
)Android requires a Context so the SDK can persist a local device id; only the application context is retained.
Environments
Use separate API/login configurations and developer key pairs for development and production. In the reviewed source, both platforms fix wallet forms to https://devsdk.wollette.com. WolletteConfig has no form-origin option. Changing apiBaseUrl or loginBaseUrl does not switch the hosted forms.
Configuration and service ownership
| Input | Source | Persistence rule |
|---|---|---|
| API origin | Matched access pack, HTTPS without /api/v1 | Keep the environment consistent with stored state |
| Hosted login origin/callback | Wollette login service and approved app URI | Match SDK, app declarations and server registration |
| Developer identity and alias/tag | Enrolment plus the chosen provisioner/importer | Keep the installed key identifier consistent with the signer |
| Request timeout | App policy; default 60 seconds | A timeout does not establish a financial outcome |
| FCM token | Your Firebase integration | Update on rotation; not required for basic wallet reading |
| POS storage/terminal | Your stable namespace and original provisioning record | Restore before inspecting retained operations |
| Token lifetime | Your authentication service | Supply actual remaining seconds; POS token is memory-only |
The minimal repository apps, original complete starters and copyable components have separate READMEs. Use one retained SDK owner; a wrapper that constructs its own SDK replaces that direct service. Host order/receipt state must survive native acknowledgement and restart.
Backend contracts
These task pages cover the existing backend services:
- BFF grant and renewal, separate from the core API origin.
- Registration reference data, obtained by the host.
- Developer key enrolment, with route/encoding still requiring confirmation.
- Money representation, qualified by each operation's approved contract.
- POS host recovery and Bluetooth deployment limits.
These are source contracts and implementation records. Obtain the deployed origins, permissions and approved inputs from the matching access pack.