subscription(for:)
Fetches a specific subscription and returns it to an awaiting caller.
Declaration
func subscription(for subscriptionID: CKSubscription.ID) async throws -> CKSubscriptionParameters
- subscriptionID:
The identifier of the subscription to fetch.
Return Value
The fetched subscription.
Discussion
This method throws an error if the request fails, such as when the network is unavailable or the device doesn’t have an active iCloud account.