Contacts Service

  • This Contacts service is deprecated; use the People API advanced service instead.

  • The Contacts service previously allowed scripts to access and modify Google Contacts data, including individual contacts and groups.

  • The ContactsApp class was the primary interface for creating, removing, and updating contacts within Google Contacts.

  • Various classes like Contact, ContactGroup, and field-specific classes like AddressField, EmailField were used to represent and manipulate contact data.

  • Although deprecated, the documentation details the available classes and methods for interacting with Google Contacts through this older service.

Contacts

Deprecated. Instead, use the People API advanced service

This service allows scripts to access and modify Google Contacts, both for individual contacts and for groups.

Classes

NameBrief description
(削除) AddressField (削除ここまで)Address field in a contact.
(削除) CompanyField (削除ここまで)Company field in a Contact.
(削除) Contact (削除ここまで)A Contact contains the name, address, and various contact details of a contact.
(削除) ContactGroup (削除ここまで)A ContactGroup is is a group of contacts.
(削除) ContactsApp (削除ここまで)This class allows users to access their own Google Contacts and create, remove, and update contacts listed therein.
(削除) CustomField (削除ここまで)A custom field in a Contact.
(削除) DateField (削除ここまで)A date field in a Contact.
(削除) EmailField (削除ここまで)An email field in a Contact.
(削除) ExtendedField (削除ここまで)An enum for extended contacts fields.
(削除) Field (削除ここまで)An enum for contacts fields.
(削除) Gender (削除ここまで)An enum for contact gender.
(削除) IMField (削除ここまで)An instant messaging field in a Contact.
(削除) PhoneField (削除ここまで)A phone number field in a Contact.
(削除) Priority (削除ここまで)An enum for contact priority.
(削除) Sensitivity (削除ここまで)An enum for contact sensitivity.
(削除) UrlField (削除ここまで)A URL field in a Contact.

(削除) AddressField (削除ここまで)

Methods

MethodReturn typeBrief description
getAddress() StringGet the address for this field.
getLabel() ObjectGets the label for this field.
isPrimary() BooleanGets whether this is the primary field value.
setAddress(address) (削除) AddressField (削除ここまで)Sets the address of this field.
setAsPrimary() (削除) AddressField (削除ここまで)Sets this field to primary.
setLabel(field) (削除) AddressField (削除ここまで)Sets the label of this field.
setLabel(label) (削除) AddressField (削除ここまで)Sets the label of this field.

(削除) CompanyField (削除ここまで)

(削除) Contact (削除ここまで)

(削除) ContactGroup (削除ここまで)

(削除) ContactsApp (削除ここまで)

(削除) CustomField (削除ここまで)

Methods

MethodReturn typeBrief description
getLabel() ObjectGets the label for this field.
setLabel(label) (削除) CustomField (削除ここまで)Sets the label of this field.

(削除) DateField (削除ここまで)

Methods

MethodReturn typeBrief description
getLabel() ObjectGets the label for this field.
setLabel(label) (削除) DateField (削除ここまで)Sets the label of this field.

(削除) EmailField (削除ここまで)

Methods

MethodReturn typeBrief description
getAddress() StringGet the address for this field.
getLabel() ObjectGets the label for this field.
isPrimary() BooleanGets whether this is the primary field value.
setAddress(address) (削除) EmailField (削除ここまで)Sets the address of this field.
setAsPrimary() (削除) EmailField (削除ここまで)Sets this field to primary.
setLabel(field) (削除) EmailField (削除ここまで)Sets the label of this field.
setLabel(label) (削除) EmailField (削除ここまで)Sets the label of this field.

(削除) ExtendedField (削除ここまで)

(削除) Field (削除ここまで)

(削除) Gender (削除ここまで)

(削除) IMField (削除ここまで)

Methods

MethodReturn typeBrief description
getAddress() StringGet the address for this field.
getLabel() ObjectGets the label for this field.
isPrimary() BooleanGets whether this is the primary field value.
setAddress(address) (削除) IMField (削除ここまで)Sets the address of this field.
setAsPrimary() (削除) IMField (削除ここまで)Sets this field to primary.
setLabel(field) (削除) IMField (削除ここまで)Sets the label of this field.
setLabel(label) (削除) IMField (削除ここまで)Sets the label of this field.

(削除) PhoneField (削除ここまで)

Methods

MethodReturn typeBrief description
getLabel() ObjectGets the label for this field.
isPrimary() BooleanGets whether this is the primary field value.
setAsPrimary() (削除) PhoneField (削除ここまで)Sets this field to primary.
setLabel(field) (削除) PhoneField (削除ここまで)Sets the label of this field.
setLabel(label) (削除) PhoneField (削除ここまで)Sets the label of this field.

(削除) Priority (削除ここまで)

(削除) Sensitivity (削除ここまで)

(削除) UrlField (削除ここまで)

Methods

MethodReturn typeBrief description
getAddress() StringGet the address for this field.
getLabel() ObjectGets the label for this field.
isPrimary() BooleanGets whether this is the primary field value.
setAddress(address) (削除) UrlField (削除ここまで)Sets the address of this field.
setAsPrimary() (削除) UrlField (削除ここまで)Sets this field to primary.
setLabel(field) (削除) UrlField (削除ここまで)Sets the label of this field.
setLabel(label) (削除) UrlField (削除ここまで)Sets the label of this field.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2024年12月02日 UTC.