Class PeopleResource.UpdateContactRequest
Update contact data for an existing contact person. Any non-contact data will not be modified.
The request throws a 400 error if updatePersonFields is not specified.
The request throws a 400 error if person.metadata.sources is not specified for the contact to be updated.
The request throws a 400 error with an error with reason "failedPrecondition" if
person.metadata.sources.etag is different than the contact's etag, which indicates the contact has changed
since its data was read. Clients should get the latest person and re-apply their updates to the latest
person.
Inheritance
Implements
Inherited Members
Namespace: Google.Apis.PeopleService.v1
Assembly: Google.Apis.PeopleService.v1.dll
Syntax
public class UpdateContactRequest : PeopleServiceBaseServiceRequest<Person>, IClientServiceRequest<Person>, IClientServiceRequest
Constructors
UpdateContactRequest(IClientService, Person, String)
Constructs a new UpdateContact request.
Declaration
public UpdateContactRequest(IClientService service, Person body, string resourceName)
Parameters
| Type | Name | Description |
|---|---|---|
| Google.Apis.Services.IClientService | service | |
| Person | body | |
| System.String | resourceName |
Properties
HttpMethod
Gets the HTTP method.
Declaration
public override string HttpMethod { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
Overrides
MethodName
Gets the method name.
Declaration
public override string MethodName { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
Overrides
ResourceName
The resource name for the person, assigned by the server. An ASCII string with a max length of
27 characters, in the form of people/{person_id}.
Declaration
[RequestParameter("resourceName", RequestParameterType.Path)]
public virtual string ResourceName { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
RestPath
Gets the REST path.
Declaration
public override string RestPath { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
Overrides
UpdatePersonFields
Required. A field mask to restrict which fields on the person are updated. Multiple fields can be specified by separating them with commas. All updated fields will be replaced. Valid values are:
- addresses * biographies * birthdays * emailAddresses * events * genders * imClients * interests * locales * memberships * names * nicknames * occupations * organizations * phoneNumbers * relations * residences * sipAddresses * urls * userDefined
Declaration
[RequestParameter("updatePersonFields", RequestParameterType.Query)]
public virtual object UpdatePersonFields { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Object |
Methods
GetBody()
Returns the body of the request.
Declaration
protected override object GetBody()
Returns
| Type | Description |
|---|---|
| System.Object |
Overrides
InitParameters()
Initializes UpdateContact parameter list.
Declaration
protected override void InitParameters()