Recognize
speech_to_text.recognize
ActionGoogle Cloudconnection required
Calls the Speech-to-Text API POST /v1/speech:recognize.
Transcribe a short audio file (under 1 minute) into text.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- OAuth 2.0
- Providers
- Google Speech-to-Text
- Secret shape
- {"client_id", "client_secret", "refresh_token"}
- Config it needs
- project_id
- Resolved by
- config.connection_id, else node.connection_id
Configuration
5 fields, none required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
file_content Audio as base64. Leave empty to use the upstream file envelope. | string | No | — | — | — |
encoding Audio encoding (leave unspecified for FLAC/WAV headers). | string | No | ENCODING_UNSPECIFIED | one of "ENCODING_UNSPECIFIED", "LINEAR16", "FLAC", "MP3", "OGG_OPUS", "WEBM_OPUS" | — |
sample_rate_hertz Sample rate in Hz (e.g. 16000). Required for raw LINEAR16. | number | No | — | ≥ 1 | — |
language_code BCP-47 language code. | string | No | en-US | — | — |
enable_automatic_punctuation Add punctuation to the transcript. | boolean | No | false | — | — |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"enable_automatic_punctuation": false,
"encoding": "ENCODING_UNSPECIFIED",
"language_code": "en-US"
}Input
| Field | Type | Example |
|---|---|---|
file_content The file, base64-encoded. | string | — |
content_encoding | string | base64 |
filename | string | app-main.zip |
content_type | string | application/zip |
size Raw size in bytes (before base64). | number | — |
Output
One shape.
result
| Field | Type | Example |
|---|---|---|
ok | boolean | — |
transcript All top alternatives joined with spaces. | string | — |
confidence Mean confidence of the top alternatives. | number | — |
alternatives[].transcript | string | — |
alternatives[].confidence | number | — |
{
"alternatives": [
{
"confidence": 0,
"transcript": ""
}
],
"confidence": 0,
"ok": false,
"transcript": ""
}Notes
- Audio longer than ~1 minute must use Long Running Recognize with a gs:// URI.
Related Google Speech-to-Text nodes
See Recognize run in a workflow.
In a technical demo we add the Google Speech-to-Text connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.