[Deprecated] Google Assistant Relay V2.0 - Google Home Audio Notifications!

Every time that i use the notification assistant now google tell everytime “Broadast From” username.
It’s horrible, we need disable this. :frowning:

How do we add a time stamp to the npm console? I have lots of google assistant-relay event that are working fine, but I can’t tell when they ran.

Thanks,
-S1930

Agreed this just started the other day. Must be a change google made on there end. I hope there is away to disable it.

Same - annoying (and is happening w/V1 which I still use) so must be affecting everyone. Hopefully they will provide a way to turn it off if you don’t want it…

Broadcast from Eric - It is driving me crazy as well. :wink:

Worked my way to this point, but need some help!

I successfully retrieved oauth code, but I am unable to get it to pause so that I can enter it. Thanks in advance!

pi@raspi:~/assistant-relay $ npm run start
assistant-relay@2.1.1 start /home/pi/assistant-relay
node server/app.js
Attempted to automatically open the URL, but if it failed, copy/paste this in your browser:
https://accounts.google.com/o/oauth2/auth?access_type=offline&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fassistant-sdk-prototype&response_type=code&client_id=1--------------------------apps.googleusercontent.com&redirect_uri=urn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob
Paste your code: (node:720) UnhandledPromiseRejectionWarning: Error: Exited with code 3
at ChildProcess.cp.once.code (/home/pi/node_modules/opn/index.js:84:13)
at Object.onceWrapper (events.js:317:30)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:915:16)
at Socket.stream.socket.on (internal/child_process.js:336:11)
at emitOne (events.js:116:13)
at Socket.emit (events.js:211:7)
at Pipe._handle.close [as _onclose] (net.js:561:12)
(node:720) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:720) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

npm ERR! code ELIFECYCLE
npm ERR! errno 255
npm ERR! assistant-relay@2.1.1 start: `node server/app.js`
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the assistant-relay@2.1.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/pi/.npm/_logs/2018-12-10T00_16_22_436Z-debug.log
pi@raspi:~/assistant-relay $ node -v
v8.12.0
pi@raspi:~/assistant-relay $

@jcthomas Did you follow this to place the file in the proper directory?

Note: When creating an Oauth Client ID, make sure you use the “Other” application type

Once you have downloaded your client secret file, rename the file to your chosen user name. For example: greg.json . Once renamed, copy your OAuth file to the folder server\configurations\secrets

When Assistant Relay is ran, it will automatically configure itself to according to the files in the secrets folder. These are also the usernames you can now pass with your queries. For example, the username for greg.json is greg

@joetlawson It took me a few tries, but I did follow the prescribed procedure and downloaded the ‘Other’ type client secret file, renamed it to ‘joseph.json’ and put the file in the ‘secrets’ directory. I was able to paste the supplied URL into a browser and retrieve the code. The app doesn’t pause to allow me to paste the retrieved code.

I believe that I did, but how can I confirm that I used the correct secrets file?

I changed the config.json to specify the IP address of the device ( “baseUrl”: “http://192.168.1.127:3000”,) and the key path:

“users”: {
“joseph”: {
“keyFilePath”: “/home/pi/assistant-relay/server/configurations/secrets/joseph.json”,
“savedTokensPath”: “/home/pi/assistant-relay/server/configurations/tokens/joseph-tokens.json”
}
},
“assistants”: {}
}

I presume the app create the ‘joseph-tokens.json’ file as I saw no instructions on creating this file.

UPDATE!!!

Fixed by rolling back to v8

@ghesp You might want to put something in the instructions that say that you can only use v8, not the current version of 10.

I had to go traipsing back several months in this thread to get that info.

3 Likes

It has also been giving out crap with it.

“If you want me to set an alarm, let me know”

Edit: Setting “converse” to “true” doesn’t give the extra crap at the end

if i set up all right, am i expected to see the relay in smartthings app as device? or google home app ?
i think i set up the relay all right, but i couldn’t get the sound notification. thanks

You won’t see in in smartthings unless you set up the device handler. You also will not see it in the Google home app.
The most common fix (that I’ve seen at least) for not receiving the sound notification is to disable ipv6 on your router, if everything is indeed set up correctly. Also check the config file to see if the start up sound is muted or not.

`

1 Like

thank you for the response. if hit the ip address at web browser, i could get “Cannot GET /” or “Dude, chill, quiet time” while quiet time mode, so i guess the server is working all right.
only thing bothering me is “No user specified, using jacob yoo
Assistant Relay is now setup and running for jacob yoo” message.

i have credential file name as
assistant-relay-master\server\configurations\secrets\jacob yoo.json

i have config file as
assistant-relay-master\server\configurations\config.json
in the file i have right path and right name as ‘jacob yoo.json’ and ‘jacob yoo-token.json’

is this talking about my google home device name? or my google account username ? or email?

Look at the post since i had the same downtime message always and i had to comment out the time check.

1 Like

ok. but in my case, the server is not stuck into quiet mode. it sometimes returns “Cannot GET /” which is warning for requesting GET method from web browser.
anyway, i have tried your recommendation, but no luck.
i still think the problem is user setting.

I had the same message when i try to access it from the browser. Just use command line message using curl to test the notification.

Edit:

The full request would be:

curl -d '{"command":"hello world", "user":"greg", "broadcast":"true"}' -H "Content-Type: application/json" -X POST http://<ip_address>:<port>/assistant

The Google Home device will now play an audio alert, and say Hello World

1 Like

i tried that this is the output

Guys the same thing is happening to me.
Google announces ’ broadcast by… It says ’
Is there any way to disable this… Highly annoying!

hello and ty for this. i am trying to get it setup and when i get to the point of npm run start i get errors, not locating google assistant

pi@raspberrypi:~/assistant-relay-master $ npm run start

assistant-relay@2.1.1 start /home/pi/assistant-relay-master
node server/app.js

internal/modules/cjs/loader.js:605
throw err;
^

Error: Cannot find module ‘google-assistant’
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:603:15)
at Function.Module._load (internal/modules/cjs/loader.js:529:25)
at Module.require (internal/modules/cjs/loader.js:659:17)
at require (internal/modules/cjs/helpers.js:22:18)
at Object. (/home/pi/assistant-relay-master/server/app.js:1:87)
at Module._compile (internal/modules/cjs/loader.js:723:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:734:10)
at Module.load (internal/modules/cjs/loader.js:620:32)
at tryModuleLoad (internal/modules/cjs/loader.js:560:12)
at Function.Module._load (internal/modules/cjs/loader.js:552:3)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! assistant-relay@2.1.1 start: node server/app.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the assistant-relay@2.1.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2018-12-15T19_14_32_154Z-debug.log

@joetlawson (or anyone else that can help me!)

I tried regenerating the json OAuth file from here: https://console.developers.google.com/apis/api/embeddedassistant.googleapis.com/overview

Here are the options I selected:

Select project from drop down at top left
Select Overview on left, click Create Credentials button
Under item 1 Find out what kind of credentials you need,
for Which API are you using, select: Google Assistant API
For Where will you be calling the API from, select: Other UI
For What data will you be accessing, select: User data
Click button: What credentials do I need?

This generated the json file I downloaded, renamed (joseph.json), and placed in: server\configurations\secrets

I tried the Application data option (For What data will you be accessing) and this generated a much larger file.txt file. Since this doesn’t have the json filename extension, this doesn’t seem like the correct file.

I’m stuck. What am I missing?