confirm(intent:completion:)
Validates that your app is able to start the workout.
Declaration
optional func confirm(intent: INStartWorkoutIntent, completion: @escaping @Sendable (INStartWorkoutIntentResponse) -> Void)optional func confirm(intent: INStartWorkoutIntent) async -> INStartWorkoutIntentResponseParameters
- intent:
The intent object that contains details about the user’s request. This object’s information has already been resolved by the user.
- completion:
The handler block to execute with your response. You must execute this handler while implementing this method. This handler has no return value and takes the following parameter:
- response
The Instartworkoutintentresponse object contains the status of whether your app is able to start the workout. This parameter must not be
nil.
Discussion
This method validates that your app is able to start the workout. For example, checking that a workout isn’t already in progress or that data you need for the workout is available.