Method: otherContacts.copyOtherContactToMyContactsGroup

Copies an "Other contact" to a new contact in the user's "myContacts" group

Mutate requests for the same user should be sent sequentially to avoid increased latency and failures.

HTTP request

POST https://people.googleapis.com/v1/{resourceName=otherContacts/*}:copyOtherContactToMyContactsGroup

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
resourceName

string

Required. The resource name of the "Other contact" to copy.

Request body

The request body contains data with the following structure:

JSON representation
{
  "copyMask": string,
  "readMask": string,
  "sources": [
    enum (ReadSourceType)
  ]
}
Fields
copyMask

string (FieldMask format)

Required. A field mask to restrict which fields are copied into the new contact. Valid values are:

  • emailAddresses
  • names
  • phoneNumbers
readMask

string (FieldMask format)

Optional. A field mask to restrict which fields on the person are returned. Multiple fields can be specified by separating them with commas. Defaults to the copy mask with metadata and membership fields if not set. 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 (ReadSourceType)

Optional. A mask of what source types to return. Defaults to READ_SOURCE_TYPE_CONTACT and READ_SOURCE_TYPE_PROFILE if not set.

Response body

If successful, the response body contains an instance of Person.

Authorization scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/contacts.other.readonly
  • https://www.googleapis.com/auth/contacts

For more information, see the Authorization guide.