Navigating Your Google Contacts: A Guide to Updates and the People API Shift

Remember the days when managing your contacts felt like a chore? Well, Google has been quietly evolving how we handle that, and it's worth catching up on. If you've been trying to update your Google Contacts recently, you might have noticed things feel a little different. That's because back in January 2022, the old Contacts API was retired, making way for the more robust People API.

Think of it as an upgrade. The People API essentially offers all the functionality of the old Contacts API, but with some key distinctions, especially when it comes to those 'Other Contacts' – the ones Google automatically saves for you. Now, administrators have read-only access to these, and if you want to make changes to them, you'll need to actively add them to your 'My Contacts' first. The API can still pull basic info like names and emails from 'Other Contacts,' but for any real editing, they need to be part of your main contact list.

This shift also means a change in how we authorize access. The old scope, https://www.google.com/m8/feeds, which gave access to personal contacts and directory information, has been replaced. For personal contacts, you'll now use https://www.googleapis.com/auth/contacts. If you need to access directory information, the scope is https://www.googleapis.com/auth/directory.readonly.

Let's dive into what this means for actually updating your contacts. For your personal contacts, the People API offers clear endpoints. You can read individual contacts with people.get or multiple with people.getBatchGet. Listing all your connections is done via people.connections.list. When it comes to making changes – creating, updating, or deleting contacts – you'll use people.createContact, people.updateContact, and people.deleteContact respectively, all requiring the https://www.googleapis.com/auth/contacts scope. Even updating contact photos has its own dedicated methods: people.updateContactPhoto and people.deleteContactPhoto.

What about those 'Other Contacts' we mentioned? As read-only entities, you can list them using otherContacts.list with the https://www.googleapis.com/auth/contacts.other.readonly scope. If you decide you want to edit one of these, the process involves copying it to your 'My Contacts' group using otherContacts.copyOtherContactToMyContactsGroup.

And for those who need to access company-wide directories, the https://www.googleapis.com/auth/directory.readonly scope allows you to list and search directory people using people.listDirectoryPeople and people.searchDirectoryPeople.

Managing contact groups has also seen an update. You can get specific groups with people.contactGroups.get or list them all with people.contactGroups.list, both under the https://www.googleapis.com/auth/contacts or https://www.googleapis.com/auth/contacts.readonly scopes. Creating, updating, and deleting groups are handled by people.contactGroups.create, people.contactGroups.update, and people.contactGroups.delete. You can even modify group memberships directly with people.contactGroups.members.modify, or by updating a contact's memberships field.

It's a bit of a learning curve, for sure, but understanding these changes ensures your contact management stays smooth and efficient. The People API is designed to be more comprehensive, and with a little adjustment, you'll find it a powerful tool for keeping your connections organized.

Leave a Reply

Your email address will not be published. Required fields are marked *