This topic explains how to create, edit, and delete application versions.
LaunchDarkly automatically creates application versions when a LaunchDarkly SDK evaluates a feature flag that contains application version information. You can edit and delete application versions from the Versions page of an existing application in the LaunchDarkly UI.
For a list of SDKs that support application versions, read the SDK configuration topic.
Similar to creating an application, LaunchDarkly automatically creates new application versions when it establishes a connection with a LaunchDarkly SDK that supports Application metadata configuration.
We strongly recommend also enabling automatic environment attribute collection as part of your SDK configuration. When this configuration is enabled, the SDK provides data on the mobile environment where an application is running, including the application version name and id. The SDK includes this data in the ld_application and ld_device contexts. To learn more, read Automatic environment attributes.
After the SDK has evaluated at least one feature flag using an ld_application context, you can create mobile targeting rules based on application and application version information in that context. To learn more, read Mobile targeting.
You can only create a “Mobile” targeting rule, and target mobile apps and devices based on automatically collected application version information, if you have completed the following:
ld_application and ld_device context kinds. LaunchDarkly must receive these context kinds before it enables the option to create a mobile targeting rule. To learn more, read Automatic environment attributes.You can only edit an application version’s support status. Only application versions for “mobile” application kinds include a support status.
To edit an application version’s support status:
You cannot modify an application version name or key.
Before you mark an application version as unsupported, make sure that the application key is unique for each separately distributed software binary.
For example, suppose you have a mobile app, “Example app,” that you distribute on both iOS and Android. Initially you create one application, with application key “example-app” and application version “1.0”. However, if you set the “1.0” application version to unsupported, then if you create a flag targeting rule based only on the supported status, the flag will target both iOS and Android. This may not be what you intend.
We recommend that you create different applications for each separately distributed software binary, and set the application key to a different value for each. To learn more, read Application metadata configuration.
To delete an existing application version:
You can also use the REST API: Delete application version