Method: people.listDirectoryPeople

Provides a list of domain profiles and domain contacts in the authenticated user's domain directory.

HTTP request

GET https://people.googleapis.com/v1/people:listDirectoryPeople

The URL uses gRPC Transcoding syntax.

Query parameters

Parameters
readMask

string (FieldMask format)

Required. A field mask to restrict which fields on each person are returned. Multiple fields can be specified by separating them with commas. Valid values are:

  • addresses
  • ageRanges
  • biographies
  • birthdays
  • calendarUrls
  • clientData
  • coverPhotos
  • emailAddresses
  • events
  • externalIds
  • genders
  • imClients
  • interests
  • locales
  • locations
  • memberships
  • metadata
  • miscKeywords
  • names
  • nicknames
  • occupations
  • organizations
  • phoneNumbers
  • photos
  • relations
  • sipAddresses
  • skills
  • urls
  • userDefined
sources

enum (DirectorySourceType)

Required. Directory sources to return.

mergeSources

enum (DirectoryMergeSourceType)

Optional. Additional data to merge into the directory sources if they are connected through verified join keys such as email addresses or phone numbers.

pageSize

integer

Optional. The number of people to include in the response. Valid values are between 1 and 1000, inclusive. Defaults to 100 if not set or set to 0.

pageToken

string

Optional. A page token, received from a previous people.listDirectoryPeople call. Provide this to retrieve the subsequent page.

When paginating, all other parameters provided to people.listDirectoryPeople must match the call that provided the page token.

requestSyncToken

boolean

Optional. Whether the response should include nextSyncToken, which can be used to get all changes since the last request. For subsequent sync requests use the syncToken param instead.

syncToken

string

Optional. A sync token, received from a previous people.listDirectoryPeople call. Provide this to retrieve only the resources changed since the last request.

When syncing, all other parameters provided to people.listDirectoryPeople must match the call that provided the sync token.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

The response to a request for the authenticated user's domain directory.

JSON representation
{
  "people": [
    {
      object (Person)
    }
  ],
  "nextPageToken": string,
  "nextSyncToken": string
}
Fields
people[]

object (Person)

The list of people in the domain directory.

nextPageToken

string

A token, which can be sent as pageToken to retrieve the next page. If this field is omitted, there are no subsequent pages.

nextSyncToken

string

A token, which can be sent as syncToken to retrieve changes since the last request. Request must set requestSyncToken to return the sync token.

Authorization Scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/directory.readonly

For more information, see the Authorization guide.