How to get contact’s details back from Google’s Contacts (People) API using the Google Contacts node?
i.e., I’d like to send a request via an AI agent "fetch me John Doe's email address".
What I figured so far is that using the Get Operation requires knowing the Contact ID.
If I understand correctly, finding the Contact’s ID requires finding the contact, so I figure using Get Many operation is the one to go with.
What is the proper node config (something with query maybe?) to get a contact by name and not by ID?
If you dont know the contact ID , you can first call Get Many to fetch all the contacts. Then have a filter like name to fetch that record. you now have the contact id and all other details
you can first call Get Many to fetch all the contacts
@Saikalyan_Akunuri Yes, I saw people doing it but it feels very “expensive”. Getting hundres or thousands of contacts and then filter down. I’m hoping there’s some magic syntax I could put into the Query field.
you can select that it’s the agent who should generate the input.
@NLSolutions I did try Defined automatically by the model but I got the same results. I wonder if I should add a prior processing that prepares the input, but it would still be looking for IDs, won’t it?
Thats true. it would be very expensive. I am guessing for some reason your MCP Server Payload doesnt get the contact Id for you to use and query. I am now thinking what if you use the Google People API via http node and search by name/email .
instead using google contact tools, how about create sub workflow . then use google contact node with input name. you can customize your own query in the workflow
Here’s an HTTP Request node that performs the right query, using Google Contacts account from my Credentials.
It needs to accept a search query under query . body should remain empty.
Now I need to figure out how to get my AI to run a smart search (e.g., search separately for first and last name, separate several names…)