# Cloud Speech-to-Text API

Converts audio to text by applying powerful neural network models.

- [REST Resource: v2.projects.locations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations)
- [REST Resource: v2.projects.locations.config](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations.config)
- [REST Resource: v2.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations.customClasses)
- [REST Resource: v2.projects.locations.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations.operations)
- [REST Resource: v2.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations.phraseSets)
- [REST Resource: v2.projects.locations.recognizers](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v2.projects.locations.recognizers)
- [REST Resource: v1p1beta1.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1p1beta1.operations)
- [REST Resource: v1p1beta1.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1p1beta1.projects.locations.customClasses)
- [REST Resource: v1p1beta1.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1p1beta1.projects.locations.phraseSets)
- [REST Resource: v1p1beta1.speech](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1p1beta1.speech)
- [REST Resource: v1.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1.operations)
- [REST Resource: v1.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1.projects.locations.customClasses)
- [REST Resource: v1.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1.projects.locations.phraseSets)
- [REST Resource: v1.speech](https://docs.cloud.google.com/speech-to-text/docs/reference/rest#v1.speech)

## Service: speech.googleapis.com

To call this service, we recommend that you use the Google-provided [client libraries](https://cloud.google.com/apis/docs/client-libraries-explained). If your application needs to use your own libraries to call this service, use the following information when you make the API requests.

### Discovery document

A [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) is a machine-readable specification for describing and consuming REST APIs. It is used to build client libraries, IDE plugins, and other tools that interact with Google APIs. One service may provide multiple discovery documents. This service provides the following discovery documents:

- <https://speech.googleapis.com/$discovery/rest?version=v2>
- <https://speech.googleapis.com/$discovery/rest?version=v1>
- <https://speech.googleapis.com/$discovery/rest?version=v1p1beta1>

### Service endpoint

A [service endpoint](https://cloud.google.com/apis/design/glossary#api_service_endpoint) is a base URL that specifies the network address of an API service. One service might have multiple service endpoints. This service has the following service endpoint and all URIs below are relative to this service endpoint:

- `https://speech.googleapis.com`

## REST Resource: [v2.projects.locations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations/get` | `GET /v2/{name=projects/*/locations/*}` Gets information about a location. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations/list` | `GET /v2/{name=projects/*}/locations` Lists information about the supported locations for this service. |

## REST Resource: [v2.projects.locations.config](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.config)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.config/get` | `GET /v2/{name=projects/*/locations/*/config}` Returns the requested `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.config#Config`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.config/update` | `PATCH /v2/{config.name=projects/*/locations/*/config}` Updates the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.config#Config`. |

## REST Resource: [v2.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/create` | `POST /v2/{parent=projects/*/locations/*}/customClasses` Creates a `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses#CustomClass`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/delete` | `DELETE /v2/{name=projects/*/locations/*/customClasses/*}` Deletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses#CustomClass`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/get` | `GET /v2/{name=projects/*/locations/*/customClasses/*}` Returns the requested `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses#CustomClass`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/list` | `GET /v2/{parent=projects/*/locations/*}/customClasses` Lists CustomClasses. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/patch` | `PATCH /v2/{customClass.name=projects/*/locations/*/customClasses/*}` Updates the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses#CustomClass`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses/undelete` | `POST /v2/{name=projects/*/locations/*/customClasses/*}:undelete` Undeletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.customClasses#CustomClass`. |

## REST Resource: [v2.projects.locations.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.operations)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.operations/cancel` | `POST /v2/{name=projects/*/locations/*/operations/*}:cancel` Starts asynchronous cancellation on a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.operations/delete` | `DELETE /v2/{name=projects/*/locations/*/operations/*}` Deletes a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.operations/get` | `GET /v2/{name=projects/*/locations/*/operations/*}` Gets the latest state of a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.operations/list` | `GET /v2/{name=projects/*/locations/*}/operations` Lists operations that match the specified filter in the request. |

## REST Resource: [v2.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/create` | `POST /v2/{parent=projects/*/locations/*}/phraseSets` Creates a `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets#PhraseSet`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/delete` | `DELETE /v2/{name=projects/*/locations/*/phraseSets/*}` Deletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets#PhraseSet`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/get` | `GET /v2/{name=projects/*/locations/*/phraseSets/*}` Returns the requested `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets#PhraseSet`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/list` | `GET /v2/{parent=projects/*/locations/*}/phraseSets` Lists PhraseSets. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/patch` | `PATCH /v2/{phraseSet.name=projects/*/locations/*/phraseSets/*}` Updates the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets#PhraseSet`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets/undelete` | `POST /v2/{name=projects/*/locations/*/phraseSets/*}:undelete` Undeletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.phraseSets#PhraseSet`. |

## REST Resource: [v2.projects.locations.recognizers](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/batchRecognize` | `POST /v2/{recognizer=projects/*/locations/*/recognizers/*}:batchRecognize` Performs batch asynchronous speech recognition: send a request with N audio files and receive a long running operation that can be polled to see when the transcriptions are finished. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/create` | `POST /v2/{parent=projects/*/locations/*}/recognizers` Creates a `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers#Recognizer`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/delete` | `DELETE /v2/{name=projects/*/locations/*/recognizers/*}` Deletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers#Recognizer`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/get` | `GET /v2/{name=projects/*/locations/*/recognizers/*}` Returns the requested `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers#Recognizer`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/list` | `GET /v2/{parent=projects/*/locations/*}/recognizers` Lists Recognizers. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/patch` | `PATCH /v2/{recognizer.name=projects/*/locations/*/recognizers/*}` Updates the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers#Recognizer`. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/recognize` | `POST /v2/{recognizer=projects/*/locations/*/recognizers/*}:recognize` Performs synchronous Speech recognition: receive results after all audio has been sent and processed. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers/undelete` | `POST /v2/{name=projects/*/locations/*/recognizers/*}:undelete` Undeletes the `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v2/projects.locations.recognizers#Recognizer`. |

## REST Resource: [v1p1beta1.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/operations)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/operations/cancel` | `POST /v1p1beta1/operations/{name=**}:cancel` Starts asynchronous cancellation on a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/operations/delete` | `DELETE /v1p1beta1/operations/{name=**}` Deletes a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/operations/get` | `GET /v1p1beta1/operations/{name=**}` Gets the latest state of a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/operations/list` | `GET /v1p1beta1/operations` Lists operations that match the specified filter in the request. |

## REST Resource: [v1p1beta1.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses/create` | `POST /v1p1beta1/{parent=projects/*/locations/*}/customClasses` Create a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses/delete` | `DELETE /v1p1beta1/{name=projects/*/locations/*/customClasses/*}` Delete a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses/get` | `GET /v1p1beta1/{name=projects/*/locations/*/customClasses/*}` Get a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses/list` | `GET /v1p1beta1/{parent=projects/*/locations/*}/customClasses` List custom classes. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.customClasses/patch` | `PATCH /v1p1beta1/{customClass.name=projects/*/locations/*/customClasses/*}` Update a custom class. |

## REST Resource: [v1p1beta1.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets/create` | `POST /v1p1beta1/{parent=projects/*/locations/*}/phraseSets` Create a set of phrase hints. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets/delete` | `DELETE /v1p1beta1/{name=projects/*/locations/*/phraseSets/*}` Delete a phrase set. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets/get` | `GET /v1p1beta1/{name=projects/*/locations/*/phraseSets/*}` Get a phrase set. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets/list` | `GET /v1p1beta1/{parent=projects/*/locations/*}/phraseSets` List phrase sets. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/projects.locations.phraseSets/patch` | `PATCH /v1p1beta1/{phraseSet.name=projects/*/locations/*/phraseSets/*}` Update a phrase set. |

## REST Resource: [v1p1beta1.speech](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/speech)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/speech/longrunningrecognize` | `POST /v1p1beta1/speech:longrunningrecognize` Performs asynchronous speech recognition: receive results via the google.longrunning.Operations interface. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1p1beta1/speech/recognize` | `POST /v1p1beta1/speech:recognize` Performs synchronous speech recognition: receive results after all audio has been sent and processed. |

## REST Resource: [v1.operations](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/operations)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/operations/cancel` | `POST /v1/operations/{name=**}:cancel` Starts asynchronous cancellation on a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/operations/delete` | `DELETE /v1/operations/{name=**}` Deletes a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/operations/get` | `GET /v1/operations/{name=**}` Gets the latest state of a long-running operation. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/operations/list` | `GET /v1/operations` Lists operations that match the specified filter in the request. |

## REST Resource: [v1.projects.locations.customClasses](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses/create` | `POST /v1/{parent=projects/*/locations/*}/customClasses` Create a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses/delete` | `DELETE /v1/{name=projects/*/locations/*/customClasses/*}` Delete a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses/get` | `GET /v1/{name=projects/*/locations/*/customClasses/*}` Get a custom class. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses/list` | `GET /v1/{parent=projects/*/locations/*}/customClasses` List custom classes. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.customClasses/patch` | `PATCH /v1/{customClass.name=projects/*/locations/*/customClasses/*}` Update a custom class. |

## REST Resource: [v1.projects.locations.phraseSets](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets/create` | `POST /v1/{parent=projects/*/locations/*}/phraseSets` Create a set of phrase hints. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets/delete` | `DELETE /v1/{name=projects/*/locations/*/phraseSets/*}` Delete a phrase set. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets/get` | `GET /v1/{name=projects/*/locations/*/phraseSets/*}` Get a phrase set. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets/list` | `GET /v1/{parent=projects/*/locations/*}/phraseSets` List phrase sets. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/projects.locations.phraseSets/patch` | `PATCH /v1/{phraseSet.name=projects/*/locations/*/phraseSets/*}` Update a phrase set. |

## REST Resource: [v1.speech](https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/speech)

| Methods ||
|---|---|
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/speech/longrunningrecognize` | `POST /v1/speech:longrunningrecognize` Performs asynchronous speech recognition: receive results via the google.longrunning.Operations interface. |
| `https://docs.cloud.google.com/speech-to-text/docs/reference/rest/v1/speech/recognize` | `POST /v1/speech:recognize` Performs synchronous speech recognition: receive results after all audio has been sent and processed. |