Skip to content

agentio/translate-io

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

translate-io

This repo contains a small example CLI that calls the Google Cloud Translate API with Sidecar and IO.

You'll need a Google Cloud project and service credentials, but once you have that, the rest is easy:

$ make
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
mkdir -p genproto
protoc proto/google/cloud/translate/v3/translation_service.proto \
--proto_path='proto' \
--go_opt='module=github.com/agentio/translate-io/genproto' \
--go_opt=Mgoogle/cloud/translate/v3/translation_service.proto=github.com/agentio/translate-io/genproto/translatepb \
--go_out='genproto'
go install ./...

$ translate-io --parent projects/agentio "I just called a Google gRPC API"
{
  "translations":  [
    {
      "translatedText":  "Acabo de llamar a una API gRPC de Google"
    }
  ]
}

In the example above, my project is agentio.

IO configuration is in the io directory.

About

Call a Google API with Sidecar using IO as an authenticating proxy.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published