Contents

authorization(forAccessory:)

Checks whether someone permits the system to forward Live Activities to the given accessory.

Declaration

static func authorization(forAccessory accessory: ASAccessory) async throws -> AccessoryAuthorizationResult

Parameters

  • accessory:

    The accessory for which to check authorization to forward Live Activities.

Mentioned in

Return Value

The person’s authorization decision for the accessory.

Overview

To determine whether someone permits forwarding Live Activities, call authorization(forAccessory:) before configuring your accessory or presenting an interface that relates to Live Activity forwarding.

If you want to ask someone to update their authorization – if they denied or limited Live Activity forwarding – present the system UI that allows people to manage their permission to forward Live Activities by calling presentAuthorizationSheet(forAccessory:).

If the result of the query is AccessoryAuthorizationResult.undetermined, the system hasn’t presented the authorization UI to the person. For more information about asking for permission for the first time, see Receiving Live Activity updates and alerts on an accessory.

See Also

Requesting Live Activity forwarding