ContactsUI updates
Learn about important changes to ContactsUI.
Overview
Browse notable changes in ContactsUI.
June 2024
Limited access to contacts
Check your app’s authorization status for a new value,
CNAuthorizationStatus.limited. This represents a new status in which a person can grant your app access to a limited subset of their contacts, rather than make an all-or-nothing choice. When your app first callsCNContactStore.requestAccess(for:completionHandler:), an alert asks the person using the app whether to allow contacts access at all. If they allow access, they can choose either full access or choose which contacts to allow, which appears to your app as the.limitedauthorization status. They can revise their choices later in the Settings app.Allow someone to quickly add more contacts to this limited-access group by displaying a
ContactAccessButtonin your app’s contact search UI. You initialize this SwiftUI view with a search substring and sets of ignored emails and phone numbers. If a single person matches this query, the button shows the contact and offers to add them to the contacts your app can access. If there are multiple matches, tapping the button shows a separate view to select contacts.Use the SwiftUI view modifier
contactAccessPicker(isPresented:completionHandler:)if you want to conditionally show a full-screen picker that adds contacts to your limited-access app. TheisPresentedparameter binds to aBoolvalue, and shows the picker when the bound value becomestrue.
See Also
Technology and frameworks
Accelerate updatesAccessibility updatesActivityKit updatesAdAttributionKit UpdatesApp Clips updatesApp Intents updatesAppKit updatesApple Intelligence updatesAppleMapsServerAPI UpdatesApple Pencil updatesARKit updatesAudio Toolbox updatesAuthenticationServices updatesAVFAudio updatesAVFoundation updates