Connecting ChatGPT to Google Home via n8n: Possible?

Hey everyone! I’m trying to set up a cool project where I can talk to ChatGPT through my Google Home devices using n8n. But I’m stuck.

I want to say “Hey Google, ask GPT” and have my question sent to my n8n setup, which then talks to ChatGPT and sends the answer back through Google Home. Sounds awesome, right?

Problem is, I can’t get it to work. I’ve got n8n running with a certificate, opened the right ports, and set up stuff in Google’s console. But when I try to add the OAuth2 ID and secret from n8n to Google, it asks for a scope and I’m lost.

Can anyone help me figure out:

  1. What scope I should use?
  2. How to make n8n answer voice queries from Google Home?

Is this even doable now that DiagFlow is gone? I can’t find any up-to-date guides. If you know of one, please share!

Thanks for any help you can give!

yo, I tried somethin similar. its tricky but not impossible. for the scope, try ‘https://www.googleapis.com/auth/homegraph’. thats what worked 4 me.

for n8n to handle voice stuff, u gotta set up a webhook node that can process requests from google home. then use text-to-speech api to turn chatgpt’s text into voice.

goodluck man, its a cool project!

I’ve been working on a similar setup, and it’s definitely a challenge without Dialogflow. One thing that helped me was using the Actions on Google platform. It lets you create custom actions for Google Assistant, which might be what you need.

For the OAuth2 scope, try ‘https://www.googleapis.com/auth/actions.fulfillment.conversation’. This should give you the necessary permissions for custom actions.

As for n8n responding to voice queries, I set up a webhook node that listens for incoming requests from Google Assistant. Then, I used a Function node to process the request, call the ChatGPT API, and format the response.

To get the voice output, I integrated Google’s Text-to-Speech API directly in n8n. It converts ChatGPT’s text response to audio before sending it back to Google Home.

It took some trial and error, but I eventually got it working. Keep at it, and don’t hesitate to dive into Google’s documentation for Actions on Google and the Assistant SDK. They were lifesavers for me.

I’ve actually attempted a similar project recently, and it’s definitely challenging without Dialogflow. While I couldn’t get it working perfectly, I made some progress using IFTTT as an intermediary. It can handle voice commands from Google Home and trigger webhooks, which you could potentially use to communicate with your n8n setup.

For the OAuth2 scope, try using ‘https://www.googleapis.com/auth/assistant-sdk-prototype’ if you haven’t already. It’s meant for custom Assistant actions.

As for making n8n respond to voice queries, you might need to set up a custom webhook node in n8n that can accept and process the incoming requests from Google Home/IFTTT. Then, use Google’s Text-to-Speech API to convert ChatGPT’s response back into audio.

It’s a complex setup, and I’m still working on perfecting it myself. Good luck with your project!