Google-cloud-dotnet: Speech service alternate authentication method

Created on 23 Jul 2017  路  1Comment  路  Source: googleapis/google-cloud-dotnet

The documentation mentioned using the env var GOOGLE_APPLICATION_CREDENTIALS for authenticating the API. Is there some other way where we can manually pass in this credential into the SpeechClient.Create() or similar instantiation?

Most helpful comment

Yes, you can pass in a channel which is authenticated with the right credentials.

See https://googlecloudplatform.github.io/google-cloud-dotnet/docs/faq.html#how-can-i-use-non-default-credentials-for-grpc-based-apis for an example of this. You can't pass in just the credentials, as then we'd be creating a channel for you without making it easy for you to clean the channel up later if you want to do so manually.

>All comments

Yes, you can pass in a channel which is authenticated with the right credentials.

See https://googlecloudplatform.github.io/google-cloud-dotnet/docs/faq.html#how-can-i-use-non-default-credentials-for-grpc-based-apis for an example of this. You can't pass in just the credentials, as then we'd be creating a channel for you without making it easy for you to clean the channel up later if you want to do so manually.

Was this page helpful?
0 / 5 - 0 ratings