Skip to content

integrations/voice/google-speech/dist

Interfaces

GoogleSpeechClient

Methods

getRawClients()
getRawClients(): GoogleSpeechRawClients;
Returns

GoogleSpeechRawClients

synthesizeSpeech()
synthesizeSpeech(input): Promise<ArrayBuffer>;
Parameters
Parameter Type
input GoogleTextToSpeechInput
Returns

Promise\<ArrayBuffer>

transcribeSpeech()
transcribeSpeech(input): Promise<GoogleSpeechToTextResult>;
Parameters
Parameter Type
input GoogleSpeechToTextInput
Returns

Promise\<GoogleSpeechToTextResult>


GoogleSpeechClientOptions

Properties

accessToken?
optional accessToken?: string;
clientOptions?
optional clientOptions?: object;
getAccessToken?
optional getAccessToken?: GoogleSpeechAccessTokenProvider;
quotaProjectId?
optional quotaProjectId?: string;
speechClient?
optional speechClient?: SpeechClient;
textToSpeechClient?
optional textToSpeechClient?: TextToSpeechClient;

GoogleSpeechCredentialStatusInput

Properties

accessToken?
optional accessToken?: string;
hasAccessTokenProvider?
optional hasAccessTokenProvider?: boolean;

GoogleSpeechJsonObject

Indexable

[key: string]: GoogleSpeechJsonValue

GoogleSpeechOperationRequestInput

Properties

body?
optional body?: GoogleSpeechJsonValue;
contentType?
optional contentType?: string;
headers?
optional headers?: Record<string, string>;
pathParams?
optional pathParams?: Record<string, string | number>;
query?
optional query?: Record<string, GoogleSpeechJsonValue | undefined>;
responseType?
optional responseType?: "response" | "json" | "arrayBuffer" | "stream";

GoogleSpeechRawClients

Properties

speechClient
speechClient: SpeechClient;
textToSpeechClient
textToSpeechClient: TextToSpeechClient;

GoogleSpeechToTextInput

Properties

audio
audio: Uint8Array;
enableAutomaticPunctuation?
optional enableAutomaticPunctuation?: boolean;
encoding?
optional encoding?: string;
languageCode?
optional languageCode?: string;
maxAlternatives?
optional maxAlternatives?: number;
model?
optional model?: string;
profanityFilter?
optional profanityFilter?: boolean;
sampleRate?
optional sampleRate?: number;
signal?
optional signal?: AbortSignal;
useEnhanced?
optional useEnhanced?: boolean;

GoogleSpeechToTextResult

Properties

confidence?
optional confidence?: number;
languageCode?
optional languageCode?: string;
raw?
optional raw?: GoogleSpeechJsonObject;
requestId?
optional requestId?: string;
text
text: string;
totalBilledTime?
optional totalBilledTime?: string;

GoogleSpeechVoiceProviderOptions

Extends

  • Omit\<Partial\<SpeechPipelineVoiceProviderOptions>, "provider" | "transcriptionSource" | "transcribe" | "synthesize">

Properties

accessToken?
optional accessToken?: string;
audioEncoding?
optional audioEncoding?: string;
client?
optional client?: GoogleSpeechClient;
clientOptions?
optional clientOptions?: object;
effectsProfileId?
optional effectsProfileId?: readonly string[];
enableAutomaticPunctuation?
optional enableAutomaticPunctuation?: boolean;
endSilenceMs?
optional endSilenceMs?: number;
Inherited from
Omit.endSilenceMs
getAccessToken?
optional getAccessToken?: GoogleSpeechAccessTokenProvider;
id?
optional id?: string;
Inherited from
Omit.id
languageCode?
optional languageCode?: string;
maxAlternatives?
optional maxAlternatives?: number;
maxSpeechMs?
optional maxSpeechMs?: number;
Inherited from
Omit.maxSpeechMs
minSpeechMs?
optional minSpeechMs?: number;
Inherited from
Omit.minSpeechMs
model?
optional model?: string;
Inherited from
Omit.model
outputSampleRate?
optional outputSampleRate?: number;
pitch?
optional pitch?: number;
profanityFilter?
optional profanityFilter?: boolean;
quotaProjectId?
optional quotaProjectId?: string;
recognitionEncoding?
optional recognitionEncoding?: string;
recognitionModel?
optional recognitionModel?: string;
sampleRate?
optional sampleRate?: number;
Inherited from
Omit.sampleRate
silenceThreshold?
optional silenceThreshold?: number;
Inherited from
Omit.silenceThreshold
speakingRate?
optional speakingRate?: number;
speechClient?
optional speechClient?: SpeechClient;
ssmlGender?
optional ssmlGender?: string;
stripLinear16WavHeader?
optional stripLinear16WavHeader?: boolean;
textToSpeechClient?
optional textToSpeechClient?: TextToSpeechClient;
useEnhanced?
optional useEnhanced?: boolean;
voiceLanguageCode?
optional voiceLanguageCode?: string;
voiceName
voiceName: string;
volumeGainDb?
optional volumeGainDb?: number;

GoogleTextToSpeechInput

Properties

audioEncoding?
optional audioEncoding?: string;
effectsProfileId?
optional effectsProfileId?: readonly string[];
languageCode?
optional languageCode?: string;
pitch?
optional pitch?: number;
sampleRateHertz?
optional sampleRateHertz?: number;
signal?
optional signal?: AbortSignal;
speakingRate?
optional speakingRate?: number;
ssmlGender?
optional ssmlGender?: string;
text
text: string;
voiceName?
optional voiceName?: string;
volumeGainDb?
optional volumeGainDb?: number;

Type Aliases

GoogleSpeechAccessTokenProvider

type GoogleSpeechAccessTokenProvider = (input) => string | Promise<string>;

Parameters

Parameter Type
input { signal?: AbortSignal; }
input.signal? AbortSignal

Returns

string | Promise\<string>


GoogleSpeechJsonPrimitive

type GoogleSpeechJsonPrimitive = string | number | boolean | null;

GoogleSpeechJsonValue

type GoogleSpeechJsonValue =
  | GoogleSpeechJsonPrimitive
  | GoogleSpeechJsonObject
  | readonly GoogleSpeechJsonValue[];

GoogleSpeechRecognitionEncoding

type GoogleSpeechRecognitionEncoding =
  | "ENCODING_UNSPECIFIED"
  | "LINEAR16"
  | "FLAC"
  | "MULAW"
  | "AMR"
  | "AMR_WB"
  | "OGG_OPUS"
  | "SPEEX_WITH_HEADER_BYTE"
  | "MP3"
  | "WEBM_OPUS"
  | "ALAW"
  | string;

GoogleSpeechResource

type GoogleSpeechResource = GoogleSpeechJsonValue;

GoogleTextToSpeechAudioEncoding

type GoogleTextToSpeechAudioEncoding =
  | "AUDIO_ENCODING_UNSPECIFIED"
  | "LINEAR16"
  | "MP3"
  | "OGG_OPUS"
  | "MULAW"
  | "ALAW"
  | string;

GoogleTextToSpeechSsmlGender

type GoogleTextToSpeechSsmlGender = "SSML_VOICE_GENDER_UNSPECIFIED" | "MALE" | "FEMALE" | "NEUTRAL" | string;

Variables

googleSpeechIntegration

const googleSpeechIntegration: DefinedIntegration<{
  capabilities: (
     | {
     audiences: "customer-facing"[];
     capability: string;
     description: string;
     exposesSensitiveData: true;
     label: string;
     providerObjects: {
        kind: string;
        label: string;
     }[];
     requiresCredential: true;
     sideEffect: true;
   }
     | {
     audiences: ("customer-facing" | "internal-support")[];
     capability: string;
     description: string;
     exposesSensitiveData: true;
     label: string;
     providerObjects: {
        kind: string;
        label: string;
     }[];
     requiresCredential: true;
     sideEffect?: never;
  })[];
  category: string;
  channelAudiences: ("customer-facing" | "mixed")[];
  coverage: {
     evidence: {
        label: string;
        url: string;
     }[];
     notes: string[];
     scope: "provider-api-subset";
  };
  credentialRequirements: {
     description: string;
     id: string;
     label: string;
     required: true;
  }[];
  directions: ("receive-only" | "send-only" | "bidirectional")[];
  id: string;
  limitations: string[];
  maintainers: {
     name: string;
     type: "official";
  }[];
  metadata: {
     channelCoverage: {
        backgroundModelProvider: string;
        browserVoiceProtocol: string;
        fullGoogleCloudSpeechSdk: string;
        longAudioSynthesis: string;
        longRunningRecognize: string;
        speechToText: string;
        streamingRecognize: string;
        textToSpeech: string;
     };
     implementation: {
        adapterCoverage: string[];
        rawClientEscapeHatch: boolean;
        sdkPackages: string[];
        strategy: string;
     };
     integrationEntryPoints: {
        manifest: string;
        runtime: string;
     };
     integrationName: string;
     integrationPackageName: string;
  };
  name: string;
  operations: (
     | {
     alias: string;
     capability: string;
     exposesSensitiveData: true;
     externallyVisible?: never;
     providerObject: string;
     providerOperation: string;
     requiresCredential: true;
     sideEffect?: never;
   }
     | {
     alias: string;
     capability: string;
     exposesSensitiveData?: never;
     externallyVisible: true;
     providerObject: string;
     providerOperation: string;
     requiresCredential: true;
     sideEffect: true;
  })[];
  packageName: string;
  privacyNotes: string[];
  provider: string;
  trustLevel: "official";
}, unknown, {
  voice.session.start: (input, context) => Promise<GoogleSpeechToTextResult>;
  voice.speak: (input, context) => Promise<ArrayBuffer>;
  voice.turn.finalize: (input, context) => Promise<GoogleSpeechToTextResult>;
}>;

googleSpeechProviderManifest

const googleSpeechProviderManifest: {
  capabilities: {
     audiences?: ("customer-facing" | "internal-support" | "mixed")[];
     capability: string;
     changesWorkflow?: boolean;
     description?: string;
     exposesSensitiveData?: boolean;
     extension?: boolean;
     label?: string;
     metadata?: Record<string, unknown>;
     providerObjects?: {
        description?: string;
        kind: string;
        label?: string;
        metadata?: Record<string, unknown>;
        schemaName?: string;
     }[];
     requiresCredential?: boolean;
     sideEffect?: boolean;
  }[];
  category: string;
  channelAudiences: ("customer-facing" | "internal-support" | "mixed")[];
  coverage: {
     evidence: {
        label: string;
        url?: string;
     }[];
     notes: string[];
     scope:   | "support-workflow-subset"
        | "provider-api-subset"
        | "connector-required"
        | "local-protocol"
        | "full-provider-api";
  };
  credentialRequirements: {
     description?: string;
     id: string;
     label?: string;
     metadata?: Record<string, unknown>;
     required: boolean;
     scopes: string[];
  }[];
  directions: (
     | "receive-only"
     | "send-only"
     | "inbound-only"
     | "outbound-only"
    | "bidirectional")[];
  id: string;
  limitations: string[];
  maintainers: {
     name: string;
     type: "community" | "official" | "unknown" | "partner";
     url?: string;
  }[];
  metadata?: Record<string, unknown>;
  name: string;
  operations: {
     alias: string;
     audience?: "customer-facing" | "internal-support" | "mixed";
     audiences?: ("customer-facing" | "internal-support" | "mixed")[];
     capability: string;
     changesWorkflow?: boolean;
     description?: string;
     exposesSensitiveData?: boolean;
     extension: boolean;
     externallyVisible?: boolean;
     inputSchema?: unknown;
     inputSchemaName?: string;
     inputSchemaRef?: string;
     label?: string;
     metadata?: Record<string, unknown>;
     outputSchema?: unknown;
     outputSchemaName?: string;
     outputSchemaRef?: string;
     providerObject?: string;
     providerObjects?: {
        description?: string;
        kind: string;
        label?: string;
        metadata?: Record<string, unknown>;
        schemaName?: string;
     }[];
     providerOperation?: string;
     requiredPolicyIds?: string[];
     requiresApproval?: boolean;
     requiresCredential?: boolean;
     sideEffect?: boolean;
  }[];
  packageName: string;
  privacyNotes: string[];
  provider: string;
  trustLevel: "community" | "official" | "verified" | "experimental";
} & {
  capabilities: (
     | {
     audiences: "customer-facing"[];
     capability: string;
     description: string;
     exposesSensitiveData: true;
     label: string;
     providerObjects: {
        kind: string;
        label: string;
     }[];
     requiresCredential: true;
     sideEffect: true;
   }
     | {
     audiences: ("customer-facing" | "internal-support")[];
     capability: string;
     description: string;
     exposesSensitiveData: true;
     label: string;
     providerObjects: {
        kind: string;
        label: string;
     }[];
     requiresCredential: true;
     sideEffect?: never;
  })[];
  category: string;
  channelAudiences: ("customer-facing" | "mixed")[];
  coverage: {
     evidence: {
        label: string;
        url: string;
     }[];
     notes: string[];
     scope: "provider-api-subset";
  };
  credentialRequirements: {
     description: string;
     id: string;
     label: string;
     required: true;
  }[];
  directions: ("receive-only" | "send-only" | "bidirectional")[];
  id: string;
  limitations: string[];
  maintainers: {
     name: string;
     type: "official";
  }[];
  metadata: {
     channelCoverage: {
        backgroundModelProvider: string;
        browserVoiceProtocol: string;
        fullGoogleCloudSpeechSdk: string;
        longAudioSynthesis: string;
        longRunningRecognize: string;
        speechToText: string;
        streamingRecognize: string;
        textToSpeech: string;
     };
     implementation: {
        adapterCoverage: string[];
        rawClientEscapeHatch: boolean;
        sdkPackages: string[];
        strategy: string;
     };
     integrationEntryPoints: {
        manifest: string;
        runtime: string;
     };
     integrationName: string;
     integrationPackageName: string;
  };
  name: string;
  operations: (
     | {
     alias: string;
     capability: string;
     exposesSensitiveData: true;
     externallyVisible?: never;
     providerObject: string;
     providerOperation: string;
     requiresCredential: true;
     sideEffect?: never;
   }
     | {
     alias: string;
     capability: string;
     exposesSensitiveData?: never;
     externallyVisible: true;
     providerObject: string;
     providerOperation: string;
     requiresCredential: true;
     sideEffect: true;
  })[];
  packageName: string;
  privacyNotes: string[];
  provider: string;
  trustLevel: "official";
};

Type Declaration

Name Type
capabilities { audiences?: ("customer-facing" | "internal-support" | "mixed")[]; capability: string; changesWorkflow?: boolean; description?: string; exposesSensitiveData?: boolean; extension?: boolean; label?: string; metadata?: Record\<string, unknown>; providerObjects?: { description?: string; kind: string; label?: string; metadata?: Record\<string, unknown>; schemaName?: string; }[]; requiresCredential?: boolean; sideEffect?: boolean; }[]
category string
channelAudiences ("customer-facing" | "internal-support" | "mixed")[]
coverage { evidence: { label: string; url?: string; }[]; notes: string[]; scope: | "support-workflow-subset" | "provider-api-subset" | "connector-required" | "local-protocol" | "full-provider-api"; }
coverage.evidence { label: string; url?: string; }[]
coverage.notes string[]
coverage.scope | "support-workflow-subset" | "provider-api-subset" | "connector-required" | "local-protocol" | "full-provider-api"
credentialRequirements { description?: string; id: string; label?: string; metadata?: Record\<string, unknown>; required: boolean; scopes: string[]; }[]
directions ( | "receive-only" | "send-only" | "inbound-only" | "outbound-only" | "bidirectional")[]
id string
limitations string[]
maintainers { name: string; type: "community" | "official" | "unknown" | "partner"; url?: string; }[]
metadata? Record\<string, unknown>
name string
operations { alias: string; audience?: "customer-facing" | "internal-support" | "mixed"; audiences?: ("customer-facing" | "internal-support" | "mixed")[]; capability: string; changesWorkflow?: boolean; description?: string; exposesSensitiveData?: boolean; extension: boolean; externallyVisible?: boolean; inputSchema?: unknown; inputSchemaName?: string; inputSchemaRef?: string; label?: string; metadata?: Record\<string, unknown>; outputSchema?: unknown; outputSchemaName?: string; outputSchemaRef?: string; providerObject?: string; providerObjects?: { description?: string; kind: string; label?: string; metadata?: Record\<string, unknown>; schemaName?: string; }[]; providerOperation?: string; requiredPolicyIds?: string[]; requiresApproval?: boolean; requiresCredential?: boolean; sideEffect?: boolean; }[]
packageName string
privacyNotes string[]
provider string
trustLevel "community" | "official" | "verified" | "experimental"

Type Declaration

Name Type
capabilities ( | { audiences: "customer-facing"[]; capability: string; description: string; exposesSensitiveData: true; label: string; providerObjects: { kind: string; label: string; }[]; requiresCredential: true; sideEffect: true; } | { audiences: ("customer-facing" | "internal-support")[]; capability: string; description: string; exposesSensitiveData: true; label: string; providerObjects: { kind: string; label: string; }[]; requiresCredential: true; sideEffect?: never; })[]
category string
channelAudiences ("customer-facing" | "mixed")[]
coverage { evidence: { label: string; url: string; }[]; notes: string[]; scope: "provider-api-subset"; }
coverage.evidence { label: string; url: string; }[]
coverage.notes string[]
coverage.scope "provider-api-subset"
credentialRequirements { description: string; id: string; label: string; required: true; }[]
directions ("receive-only" | "send-only" | "bidirectional")[]
id string
limitations string[]
maintainers { name: string; type: "official"; }[]
metadata { channelCoverage: { backgroundModelProvider: string; browserVoiceProtocol: string; fullGoogleCloudSpeechSdk: string; longAudioSynthesis: string; longRunningRecognize: string; speechToText: string; streamingRecognize: string; textToSpeech: string; }; implementation: { adapterCoverage: string[]; rawClientEscapeHatch: boolean; sdkPackages: string[]; strategy: string; }; integrationEntryPoints: { manifest: string; runtime: string; }; integrationName: string; integrationPackageName: string; }
metadata.channelCoverage { backgroundModelProvider: string; browserVoiceProtocol: string; fullGoogleCloudSpeechSdk: string; longAudioSynthesis: string; longRunningRecognize: string; speechToText: string; streamingRecognize: string; textToSpeech: string; }
metadata.channelCoverage.backgroundModelProvider string
metadata.channelCoverage.browserVoiceProtocol string
metadata.channelCoverage.fullGoogleCloudSpeechSdk string
metadata.channelCoverage.longAudioSynthesis string
metadata.channelCoverage.longRunningRecognize string
metadata.channelCoverage.speechToText string
metadata.channelCoverage.streamingRecognize string
metadata.channelCoverage.textToSpeech string
metadata.implementation { adapterCoverage: string[]; rawClientEscapeHatch: boolean; sdkPackages: string[]; strategy: string; }
metadata.implementation.adapterCoverage string[]
metadata.implementation.rawClientEscapeHatch boolean
metadata.implementation.sdkPackages string[]
metadata.implementation.strategy string
metadata.integrationEntryPoints { manifest: string; runtime: string; }
metadata.integrationEntryPoints.manifest string
metadata.integrationEntryPoints.runtime string
metadata.integrationName string
metadata.integrationPackageName string
name string
operations ( | { alias: string; capability: string; exposesSensitiveData: true; externallyVisible?: never; providerObject: string; providerOperation: string; requiresCredential: true; sideEffect?: never; } | { alias: string; capability: string; exposesSensitiveData?: never; externallyVisible: true; providerObject: string; providerOperation: string; requiresCredential: true; sideEffect: true; })[]
packageName string
privacyNotes string[]
provider string
trustLevel "official"

Functions

createGoogleSpeechClient()

function createGoogleSpeechClient(options): GoogleSpeechClient;

Parameters

Parameter Type
options GoogleSpeechClientOptions

Returns

GoogleSpeechClient


createGoogleSpeechRawClients()

function createGoogleSpeechRawClients(options): GoogleSpeechRawClients;

Parameters

Parameter Type
options GoogleSpeechClientOptions

Returns

GoogleSpeechRawClients


createGoogleSpeechVoiceProvider()

function createGoogleSpeechVoiceProvider(options): VoiceProvider;

Parameters

Parameter Type
options GoogleSpeechVoiceProviderOptions

Returns

VoiceProvider


googleSpeechCredentialStatuses()

function googleSpeechCredentialStatuses(input): {
  expiresAt?: string;
  message?: string;
  providerPackageId?: string;
  requirementId: string;
  scopes?: string[];
  state:   | "required"
     | "configured"
     | "permission-blocked"
     | "not-required"
     | "missing"
     | "expired"
     | "insufficient-scope"
     | "unavailable";
}[];

Parameters

Parameter Type
input GoogleSpeechCredentialStatusInput

Returns

{ expiresAt?: string; message?: string; providerPackageId?: string; requirementId: string; scopes?: string[]; state: | "required" | "configured" | "permission-blocked" | "not-required" | "missing" | "expired" | "insufficient-scope" | "unavailable"; }[]