TTS Error with Google - configuration is not valid

I don’t think you really read or comprehended the replies here. It’s clear it has been working perfectly fine for many of us until suddenly it wasn’t.

You can also see from config examples above where the base_url has needed to be commented out, the url used is https.

And you haven’t tested it yet yourself :wink: Sorry bud but that was triggering in the same way that someone will post on a Microsoft forum “my PC is on fire and now my cat has 3rd degree burns” and someone will reply “try sfc /scannow”

1 Like

Recently upgraded to version 2023.7.3, and problem still seems to be there? Strange?

Ok, here’s what fixed it for me.

System → Network → Home Assistant URL. My WAN URL was no longer listed here.
For both the Internet and Local Network options I had to set these to my https://xxxx.duckdns.org address (didn’t accept my actual local IP in the local network field).

Leave external_url commented out in the TTS section of your configuration.yaml

1 Like

Putting an external URL in your local network means all HA requests now go via the internet… even when on your loca network…

Any idea if this is fixed in 2023.8?

Putting an external URL in your local network does not mean all HA requests will go via the internet, it goes as far as your home router and back inside again.

Can you post a traceroute and show us? :open_mouth:

Do you realise it would have been less characters for you to type to tracert your own hostname than it would have been to ask me to do it for you?

oh mate… nice fake news with the internal DNS entries…

Here is what happens when you using proper Nabu Casa…

Who said anything about Nabu casa? Not me. I don’t even know why you assumed I was using nabu?

And it’s not an “internal dns entry” you muppet, you can clearly see it resolves to a public ip.

But what would I know, I’ve only been a network engineer since 2002…and help desk for a dialup ISP before that.

mate don’t be like that… we are all friends here, and kids love muppets.

why would a network engineer use a free DNS service, scary stuff

I am having this same problem (I think). When I went to 2023.7.3, my Announcements using Google TTS to my chromecast devices stopped working. I replaced them with this service: Text-to-speech (TTS): Say a TTS message with cloud

I am a nabu casa subscriber, and wne I do a text to speech test using the option in the home assitant cloud menu under settings, everything works just fine, but not when I call the service to say something.

I have removed my google tts entries from my configurational.yaml (nothing is there now), and if I use automatic or I use the nabu case URL in the network internal network URL announcements still aren’t working.

What am I doing wrong?

@fresnoboy did you remove the “tts” config from configuration.yaml?

This worked for me with the local integration, thanks.

1 Like

9/17/2023 - RESPONSE TO BEST ANSWER YET
This was the most useful piece of information to me in this entire thread (and all of Google, for that matter). I hope others find this.

I needed to replace the URL that was in the Local network field with my local IP address (see attached image). I don’t have duckdns or other such things created, I just wanted a simple way for HA to do what I needed it to do and remain local and secure. I’m not a network guy, that stuff confuses me for the most part (hence my use of Nabu Casa). Meanwhile, I changed it to what you see in the image, rebooted, and BOOM! – it works as it was before.

ALSO NOTWORTHY:
I didn’t realize we only needed to comment-out the one line in the configuration.yaml for the google_translate entry. If anyone is still researching, all you need to comment out is the one line – I didn’t realize this during my research, an oversight on my part for sure, nevertheless, if you’re wondering, just comment-out/remove the base_url line only.

# Text to speech configuration
tts:
  - platform: google_translate
    cache: true
    cache_dir: /tmp/tts
    time_memory: 300
    service_name: google_say
#    base_url: !secret tts_address

This now works perfectly, as expected.

1 Like

Another option is to configure TTS through the UI and delete it from the configuration file.

Once that is done, you’ll need to use this new service syntax. Tested in 2023.9.2. I’m not sure when tts became configurable in the UI

service: tts.speak
data:
  message: Type message here
  media_player_entity_id: media_player.bedroom
target:
  entity_id: tts.google_en_com

entity_id is the tts configured through the integration page