Make your speaker speak.
homecast
is a Go package to enable text-to-speech on Google Home in local network.
This is Go version of noelportugal/google-home-notifier
$ go get -u github.com/ikasamah/homecast
ctx := context.Background()
devices := homecast.LookupAndConnect(ctx)
for _, device := range devices {
err := device.Speak(ctx, "Hello World", "en")
}
$ go run $GOPATH/src/github.com/ikasamah/homecast/example/main.go
$ go run $GOPATH/src/github.com/ikasamah/homecast/example/server.go
Then, access following URL in your browser.