Mobile SDK quickstart
The prerequisites and required configuration to properly set up your development environment for the Optimizely Configured Commerce Mobile SDK.
Prerequisites
Ensure you have the following prerequisites before developing the Optimizely Configured Commerce Mobile SDK:
Configure
The following configuration is required.
Update the following files with your specifications:
lib/core/colors/app_colors.dart
– Controls colors used in the app. The Admin Console settingAppConfigurationService
overrides the primary color.assets/config/base_config.json
– SetDomain
to your Configured Commerce instance and setshouldUseStaticDomain
to true:If"domain": "www.example.com", "shouldUseStaticDomain": true,
shouldUseStaticDomain
is false, the app behaves like a testing app where you can change between domains from the settings screen. This can be helpful during testing or partner builds.
Warning
When submitting the application to the Apple App Store or Google Play, do not submit it with
shouldUseStaticDomain
set asfalse
.
The app verifies that the domain
string is set in the base_config.json
file upon launch. The app uses that value as the host for all requests if it is set. Otherwise, you must enter a domain URL for the app to use.
Important
Do not add any properties or tamper with
base_config.json
except for altering its existing property values. If you wish to implement custom logic based on a new property, usecustom_config.json
.
If you are interested in configuring the Mobile SDK further, refer to Mobile SDK Reference.
Updated 2 months ago
After configuring the Core project, you will need to set up the Android and iOS projects: