SpeechToTextV2.viaToken constructor
SpeechToTextV2.viaToken(})
Creates a SpeechToTextV2 interface using a token. You are responsible for updating the token when it expires.
Implementation
factory SpeechToTextV2.viaToken(
String typeToken,
String token, {
required String projectId,
String? cloudSpeechEndpoint,
Map<String, String>? metadata,
}) =>
SpeechToTextV2._(
CallOptions(metadata: {
'authorization': '$typeToken $token',
...?metadata,
}),
projectId: projectId,
cloudSpeechEndpoint: cloudSpeechEndpoint);