Contains your app’s response to a start workout intent.


class INStartWorkoutIntentResponse : INIntentResponse


Use an INStartWorkoutIntentResponse object to specify whether your app is able to start a workout. The response object contains only the response code that indicates whether your app should be launched or whether there was a problem.

You create an INStartWorkoutIntentResponse object in the confirm(intent:completion:) and handle(intent:completion:) methods of your start workout handler object. For more information about implementing your handler object, see INStartWorkoutIntentHandling.


Initializing the Response Object

init(code: INStartWorkoutIntentResponseCode, userActivity: NSUserActivity?)

Initializes the response object with the specified code and user activity object.

Getting the Response Code

var code: INStartWorkoutIntentResponseCode

The code indicating whether you successfully handled the intent.

enum INStartWorkoutIntentResponseCode

Constants indicating the state of the response.


Inherits From

Conforms To

See Also

Start a Workout

protocol INStartWorkoutIntentHandling

The handler interface for starting a workout.

class INStartWorkoutIntent

A request to start a workout for the user.