Manage contacts on android

I’ve running android emulator. I need somehow to add/remove contacts from phone book to make 3-rd party apps interact with them.

I’ve managed to do it via ADB and shell scripts. But it’s hard to manage and resource consuming process for hardware. So, I’ve registered google account and registered service account for People API and wrote cloud functions to add them, but they didn’t get added to contacts app, despite the fact that emulator linked to google account and have synchronization turned on.

Is there a way to make it work with People API or anything else?

Source: Ask Javascript Questions