Checking Job Status, Retrieving Results
GET/v2/recognitions/:session_id
Retrieves the status and result of the specified speech recognition job.
Request
Responses
- 200
- 401
- 404
- 500
Returns the status of the speech recognition request and associated information. The status takes one of the following 5 values:
| status | Description |
|---|---|
| queued | The job is registered in the queue. |
| started | The job has been taken out of the queue and is preparing the execution environment. |
| processing | The job is being executed. |
| completed | Results have been obtained from the speech recognition process. If code is an empty string, meaning the speech recognition was successful, the results are included in segments. |
| error | An error occurred when trying to execute the job or during job execution. The error details are stored in error_message. |
The following table summarizes the information included in each state: queued, started, processing, completed, and error. In the columns for each state's initial letter (q, s, p, c, e), A indicates always included. O indicates included if that information is available.
| Key | q | s | p | c | e | Description |
|---|---|---|---|---|---|---|
| status | A | A | A | A | A | Job status. Takes the states: queued, started, processing, completed, error. |
| audio_md5 | A | A | O | MD5 checksum value of the received audio file. | ||
| audio_size | A | A | O | Size of the received audio file. | ||
| content_id | O | O | O | O | O | Value of contentId set by the user at the time of request. |
| service_id | A | A | A | A | Service ID. | |
| segments | A | Speech recognition results per utterance. | ||||
| utteranceid | A | Recognition result information ID. | ||||
| text | A | Overall recognition result text combining all "recognition results for speech segments". | ||||
| code | A | Single character code representing the result. | ||||
| message | A | String describing the error content. | ||||
| error_message | A | String describing the error content |
When the status is completed, it returns the speech recognition results in JSON format. Unlike the synchronous HTTP interface, the recognition results are placed under segments on a per-utterance basis.
Returned when authentication fails.
| Error Message | Error Situation |
|---|---|
| No authorization header | Authorization header is not set |
| Invalid authorization header format | Authorization header format is invalid |
| Failed to authorize for the API key | Authentication with the specified API key failed |
Returned when the job with the specified session_id is not found.
| Error Message | Error Situation |
|---|---|
| Specified session_id is not found | The job with the specified session_id is not found |
If this error occurs even when specifying the correct session_id, the following cases may be possible:
- When the data retention period has passed
- When a user different from the one at the time of request tries to retrieve the job status or results
Returned in case of an internal error.
| Error Message | Error Situation |
|---|---|
| - | Internal error. Please contact us here. |