API reference
API reference
Select your platform
No SDKs available
No versions available

ApplicationLifecycle

Updated: Jul 24, 2025

ApplicationLifecycle

class ApplicationLifecycle
This ApplicationLifecycle API provides methods for managing the lifecycle of an application, including retrieving information about how the application was started, such as the type of intent horizon.platform.application_lifecycle.models.LaunchDetails.launchType, logging the results of deeplinking attempts, whether it was horizon.platform.application_lifecycle.enums.LaunchResult.success or not, and handling changes to the launch intent.

Constructors

NameSummary
ApplicationLifecycle
constructor()

Types

NameSummary
Companion
object Companion

Functions

NameSummary
getLaunchDetails
suspend fun getLaunchDetails(): LaunchDetails
Returns information about how the application was started. This function provides details about the launch intent, such as the type of intent horizon.platform.application_lifecycle.models.LaunchDetails.launchType and any additional data that was passed along with it. By calling this function, you can gain insight into how your application was launched and take appropriate action based on that information.
launchIntentChanged
fun launchIntentChanged(): Flow<String>
This event is triggered when a launch intent is received, whether it’s a cold or warm start. The payload contains the type of intent that was received. To obtain additional details, you should call the horizon.platform.application_lifecycle.ApplicationLifecycle.getLaunchDetails function.
logDeeplinkResult
suspend fun logDeeplinkResult(trackingId: String, result: LaunchResult)
Logs if the user successfully deeplinked to a destination. This function takes two parameters: a string tracking ID and a launch result. The tracking ID is used to identify the specific deeplink attempt, while the launch result indicates whether the deeplink was horizon.platform.application_lifecycle.enums.LaunchResult.success or not. By logging this information, you can track the effectiveness of your deeplinking efforts and make adjustments as needed.

Companion

object Companion
Did you find this page helpful?
Thumbs up icon
Thumbs down icon