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
+22-10Lines changed: 22 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -46,7 +46,9 @@ console.log(`Authorization access to contacts is: ${authStatus}`)
46
46
*/
47
47
```
48
48
49
-
### contacts.getAllContacts()
49
+
### contacts.getAllContacts([extraProperties])
50
+
51
+
*`extraProperties` string[] (optional) - an array of extra contact properties to fetch that can be any of: `jobTitle`, `departmentName`, `organizationName`, `middleName`, `note`, `contactImage`, or `contactThumbnailImage`.
50
52
51
53
Returns `Array<Object>` - Returns an array of contact objects.
52
54
@@ -59,7 +61,13 @@ The returned objects will take the following format:
59
61
*`phoneNumbers` String[] - An array of phone numbers as strings in [E.164 format](https://en.wikipedia.org/wiki/E.164).
60
62
*`emailAddresses` String[] - An array of email addresses as strings.
61
63
*`postalAddresses` String[] - An array of postal as strings.
62
-
*`contactImage` Buffer (optional) - a Buffer representation of the contact's image, if one has been set.
64
+
*`jobTitle` String (optional) - The contact's job title.
65
+
*`departmentName` String (optional) - The name of the department associated with the contact.
66
+
*`organizationName` String (optional) - The name of the organization associated with the contact.
67
+
*`middleName` String (optional) - The contact's middle name.
68
+
*`note` String (optional) - The note associated with the contact.
69
+
*`contactImage` Buffer (optional) - a Buffer representation of the contact's profile picture.
70
+
*`contactThumbnailImage` Buffer (optional) - a Buffer representation of The thumbnail version of the contact’s profile picture.
63
71
64
72
This method will return an empty array (`[]`) if access to Contacts has not been granted.
65
73
@@ -77,17 +85,16 @@ console.log(allContacts[0])
77
85
nickname: 'Johnny',
78
86
birthday: '1970-01-01',
79
87
phoneNumbers: [ +11234566789' ],
80
-
emailAddresses: [ 'johnny@appleseed.com' ]
81
-
postalAddresses: [ '123 Pine Tree Way\nBlack Oak, Arkansas 72414\nUnited States' ],
*`name` String (required) - The first, last, or full name of a contact.
97
+
*`extraProperties` string[] (optional) - an array of extra contact properties to fetch that can be any of: `jobTitle`, `departmentName`, `organizationName`, `middleName`, `note`, `contactImage`, or `contactThumbnailImage`.
91
98
92
99
Returns `Array<Object>` - Returns an array of contact objects where either the first or last name of the contact matches `name`.
93
100
@@ -102,7 +109,13 @@ The returned object will take the following format:
102
109
*`phoneNumbers` String[] - An array of phone numbers as strings in [E.164 format](https://en.wikipedia.org/wiki/E.164).
103
110
*`emailAddresses` String[] - An array of email addresses as strings.
104
111
*`postalAddresses` String[] - An array of postal as strings.
105
-
*`contactImage` Buffer (optional) - a Buffer representation of the contact's image, if one has been set.
112
+
*`jobTitle` String (optional) - The contact's job title.
113
+
*`departmentName` String (optional) - The name of the department associated with the contact.
114
+
*`organizationName` String (optional) - The name of the organization associated with the contact.
115
+
*`middleName` String (optional) - The contact's middle name.
116
+
*`note` String (optional) - The note associated with the contact.
117
+
*`contactImage` Buffer (optional) - a Buffer representation of the contact's profile picture.
118
+
*`contactThumbnailImage` Buffer (optional) - a Buffer representation of The thumbnail version of the contact’s profile picture.
106
119
107
120
This method will return an empty array (`[]`) if access to Contacts has not been granted.
108
121
@@ -120,9 +133,8 @@ console.log(contacts)
120
133
nickname: 'Johnny',
121
134
birthday: '1970-01-01',
122
135
phoneNumbers: [ +11234566789' ],
123
-
emailAddresses: [ 'johnny@appleseed.com' ]
136
+
emailAddresses: [ 'johnny@appleseed.com' ],
124
137
postalAddresses: [ '123 Pine Tree Way\nBlack Oak, Arkansas 72414\nUnited States' ]
0 commit comments