With Leanplum variables, you can update your app's data and files remotely without having to resubmit your app to the App Store or Google Play. Any data type (floats, booleans, strings, arrays, dictionaries, etc.) or file in your app can be a variable.
Variables will appear automatically in the Variables tab once they are detected by our SDK and synced to our servers on
You can sync your app's resources as well as your files and assets using File Variables, which allow you to define individual files, assets, or resources as Leanplum variables using our SDK. If you have many resources, you can improve performance by reducing the set of synced resources to just those that you'll need to swap out. Like variables, File Variables will show up on the Variables tab of the dashboard.
Variables are retrieved asynchronously
After your app starts, the Leanplum SDK retrieves the Variable values asynchronously. When using Variables, your application should wait until the Variable values are retrieved from the server.
File variables are currently only supported on iOS and Android.
For a guide on a technical implementation of Variables via the Leanplum SDK visit our technical guide.
- You must have a registered test device. For information, see Register your test device.
To set up your app to work with Leanplum Variables:
Define the Variables in your application.
Variables can be of different types — Integer, Boolean, String, Dictionary, File. To define a variable on a specific platform, see the platform-specific documentation below.
Run the app in development mode on your test device
Verify that the variables defined on the client are visible on the Variables page as shown below.
Learn more about Variables in our user guide here
Updated over 2 years ago