You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+35-7Lines changed: 35 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,15 +18,15 @@ This native Node.js module allows you to manage an app's access to:
18
18
19
19
*`type` String - The type of system component to which you are requesting access. Can be one of 'contacts', 'full-disk-access', 'photos', 'reminders', or 'calendar'.
20
20
21
-
Returns `String` - Can be one of 'Not Determined', 'Denied', 'Authorized', or 'Restricted'.
21
+
Returns `String` - Can be one of 'not determined', 'denied', 'authorized', or 'restricted'.
22
22
23
23
Checks the authorization status of the application to access `type` on macOS.
24
24
25
25
Return Value Descriptions:
26
-
* 'Not Determined' - The user has not yet made a choice regarding whether the application may access `type` data.
27
-
* 'Not Authorized' - The application is not authorized to access `type` data. The user cannot change this application’s status, possibly due to active restrictions such as parental controls being in place.
28
-
* 'Denied' - The user explicitly denied access to `type` data for the application.
29
-
* 'Authorized' - The application is authorized to access `type` data.
26
+
* 'not determined' - The user has not yet made a choice regarding whether the application may access `type` data.
27
+
* 'restricted' - The application is not authorized to access `type` data. The user cannot change this application’s status, possibly due to active restrictions such as parental controls being in place.
28
+
* 'denied' - The user explicitly denied access to `type` data for the application.
29
+
* 'authorized' - The application is authorized to access `type` data.
30
30
31
31
**Note:** Access to 'contacts' will always return a status of 'Authorized' prior to macOS 10.13 High Sierra, as access to contacts was unilaterally allowed until that version.
32
32
@@ -36,7 +36,7 @@ Return Value Descriptions:
36
36
*`error` String | null - An error in performing the request, if one occurred.
37
37
*`status` String - Whether or not the request succeeded or failed; can be 'authorized' or 'denied'.
38
38
39
-
In your app, you should put the reason you're requesting to manipulate user's contacts database in your `Info.plist` like so:
39
+
Your app’s `Info.plist` file must provide a value for the `NSContactsUsageDescription` key that explains to the user why your app is requesting Contacts access.
40
40
41
41
```
42
42
<key>NSContactsUsageDescription</key>
@@ -47,6 +47,34 @@ In your app, you should put the reason you're requesting to manipulate user's co
0 commit comments