Does anyone have any work arounds for google voice sms notifications when your account has 2 factor authentication enabled?
I think you can just go into your google account and create application specific passwords. Then use that as the password.
support.google.com/accounts/answer/185833?hl=en
That said, I have not gotten the Google Voice integration working yet, but I havenât tried too much.
Good luck! Let us know if it works.
I tried the approach of creating an application specific password and entered it into the config file however it didnât work for me. Has anyone been able to get the google voice sms notification to work? If so can you share how you did it?
Thanks!
Ok, I tried this again and couldnât get it to work. I donât know if I was not triggering the message correctly, or if my Google Voice setup was wrong. I was able to send Google emails, but not Google Voice.
My config looked like this:
notify myGV: platform: googlevoice name: gv username: [email protected] password: xxxxxxxxxxxxxxxxx
Then I tried sending a message/notification kinda like this from the web interface:
{ "message": "The sun is {% if is_state('sun.sun', 'above_horizon') %}up{% else %}down{% endif %}!" }
But no go.
My config file is very similar and I do see it being triggered in HA. I have an automation trigger setup at a specific time to send a test message. I have no idea why I am not receiving the message in GV or where that triggered message is going.
When I use my regular google voice password, I get a sms from google with my verification code everytime a notification is triggered. When I use an app password, I get absolutely nothing. On my google app patssword dashboard, it doesnât ever register a âlast usedâ timestamp. Tomorrow when I have some time ill dive into the code and play with the library to see if I can get it to work.
89vision - I assume your config file is setup similar to the examples provided or what is shown above by HADad? I unfortunately do not receive anything. This is my setup in the config file (see below). I see it firing in HA but where it goes is anyoneâs guess : )
notify:
platform: googlevoice
username: [email protected]
password: (Tried my regular password and also the google app password for a two step verification)
automation:
- alias: Test Message
trigger:
platform: time
hours: 21
minutes: 00
seconds: 0
action:
service: notify.googlevoice
data:
title: "Another test"
message: "Sending this test message"
target:
- xxxxxxxxxx (my cell phone #)
- xxxxxxxxxx (my google #)
Yes, similar to that. I donât receive the notification from home assistant, I receive the sms from google with my 2fa code.
I did some digging, and the google voice python library being used by home assistant doesnât support app passwords due to the endpoint url that is used to login to google. Iâm going to refactor it this week and submit a pull request.
@89vision - was just curious if had an opportunity to look into google voice and getting it to work on HA. I would love to see that working.
Thanks!
Iâm also checking in, @89vision to see if youâve had a chance to make some headway on this. Thanks for your time and contributions
Not sure if this is the same issue everyone else is having. In the logbook it looks like the SMS notifications are being generated but Iâm not getting it on my google voice number.
I donât get an update within the logbook. Mine doesnât seem to be sending out at all. I also tried using the dev tools and it says it called the service but I never receive anything through googlevoice.
I was able to get mine to work over the weekend. When I did the notify component I left the notifier name as NOTIFIER_NAME and then the number that was receiving the notification wasnât the actual google voice number. I used my cell phone number and it started to work.
Hopefully that will help somebody else.
Just so I am clear this is what your config looks like?
notify:
platform: googlevoice
username: YOUR_GOOGLE_EMAIL
password: YOUR_GOOGLE_PASSWORD
name: NOTIFIER_NAME <<<âLeave this as Notifier_Name
Your automation would be similar to the example provided except that you are using your cell phone number as the target and not your gv number
automation:
- alias: The sun has set
trigger:
platform: sun
event: sunset
action:
service: notify.googlevoice
data:
message: âThe sun has setâ
target:
- 5555555555
The only other question I have is are you using the 2-step password verification with your google account?
I donât have the 2 step password verification turned on but you should be able to allow access through google.
The only change I see is on automation the service should be notify.NOTIFIER_NAME. Then make sure your target number is not your google voice number.
Iâll give this a try to see if it works. My suspicion is the s-step verification may be causing some issues though. Thanks for the info.
Sorry all, I havenât had time to look at this. The problem is definitely 2 factor authentication. The login endpoints that the underlying library is using doesnât support application specific passwords