Skip to content

Commit 0c07852

Browse files
committed
docs: Add JSDoc links to People API definitions and clarify partial type definitions.
1 parent 2ddf01e commit 0c07852

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

people/quickstart/quickstart.gs

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,33 +16,40 @@
1616
// [START people_quickstart]
1717
/**
1818
* @typedef {Object} EmailAddress
19+
* @see https://developers.google.com/people/api/rest/v1/people#Person
1920
* @property {string} value
21+
* Note: This is a partial definition.
2022
*/
2123

2224
/**
2325
* @typedef {Object} Name
26+
* @see https://developers.google.com/people/api/rest/v1/people#Person
2427
* @property {string} displayName
28+
* Note: This is a partial definition.
2529
*/
2630

2731
/**
2832
* @typedef {Object} Person
33+
* @see https://developers.google.com/people/api/rest/v1/people#Person
2934
* @property {Name[]} names
3035
* @property {EmailAddress[]} [emailAddresses]
36+
* Note: This is a partial definition.
3137
*/
3238

3339
/**
3440
* @typedef {Object} Connection
41+
* @see https://developers.google.com/people/api/rest/v1/people.connections/list
3542
* @property {Person[]} connections
43+
* Note: This is a partial definition.
3644
*/
3745

3846
/**
3947
* Print the display name if available for 10 connections.
4048
*/
4149
function listConnectionNames() {
42-
// Poll the People API to list the connections of the logged in user.
50+
// Use the People API to list the connections of the logged in user.
4351
// See: https://developers.google.com/people/api/rest/v1/people.connections/list
4452
if (!People || !People.People || !People.People.Connections) {
45-
// See: https://developers.google.com/apps-script/guides/services/advanced#enable_advanced_services
4653
throw new Error('People service not enabled.');
4754
}
4855
const connections = People.People.Connections.list('people/me', {

0 commit comments

Comments
 (0)