Error codes
Updated at:
Use this reference to diagnose errors returned by the Intelligent Speech Interaction SDK and server during short sentence recognition and real-time speech recognition.
How errors are reported
Errors come from two sources:
SDK errors — generated during SDK use and returned in a callback.
Server errors — returned when the SDK raises a
DEFAULT_NLS_ERRORorHTTP_SERVER_ERRORevent. Thestatusfield in the event'sheaderobject contains the server-side error code. For details, see Error codes returned by the server.
SDK error codes
Successful requests
| Error code | Error message | Description |
|---|---|---|
| 0 | SUCCESS | The request succeeded. |
Configuration and parameter errors
| Error code | Error message | Description |
|---|---|---|
| 240999 | DEFAULT_ERROR | An internal error occurred. |
| 240001 | NUI_CONFIG_INVALID | The configuration file is invalid. |
| 240002 | ILLEGAL_PARAM | A parameter value is invalid. |
| 240003 | ILLEGAL_INIT_PARAM | An initialization parameter is invalid. |
| 240004 | NECESSARY_PARAM_LACK | A required parameter is missing. |
| 240005 | NULL_PARAM_ERROR | A parameter is empty. |
| 240006 | NULL_LISTENER_ERROR | No listener callback is registered. |
| 240007 | NULL_DIALOG_ERROR | No valid dialog instance exists. This is typically an internal status error. |
| 240008 | NULL_ENGINE_ERROR | No valid engine instance exists. Check whether engine initialization succeeded. |
| 240009 | ILLEGAL_DATA | The audio data URL is invalid, or the audio data exceeds the size limit. |
SDK status errors
| Error code | Error message | Description |
|---|---|---|
| 240010 | ILLEGAL_REENTRANT | The SDK was called after the client exited. |
| 240011 | SDK_NOT_INIT | The SDK is not initialized. |
| 240012 | SDK_ALREADY_INIT | The SDK is initialized more than once. |
| 240013 | DIALOG_INVALID_STATE | The internal dialog instance is in an abnormal state. |
| 240014 | STATE_INVALID | The SDK is in an abnormal state. |
| 240015 | ILLEGAL_FUNC_CALL | The SDK is called in an invalid mode. |
System errors
| Error code | Error message | Description |
|---|---|---|
| 240020 | MEM_ALLOC_ERROR | Memory allocation failed. |
| 240021 | FILE_ACCESS_FAIL | File access failed. |
| 240022 | CREATE_DIR_ERROR | The storage directory could not be created. |
Internal SDK call errors
| Error code | Error message | Description |
|---|---|---|
| 240030 | CREATE_NUI_ERROR | The engine could not be created. |
| 240031 | TEXT_DIALOG_START_FAIL | The text comprehension task could not be started. |
| 240032 | TEXT_CANCEL_START_FAIL | The text comprehension task could not be canceled. |
| 240033 | WUW_DUPLICATE | Duplicate dynamic wake-up words were specified. |
Client engine errors
| Error code | Error message | Description |
|---|---|---|
| 240040 | CEI_INIT_FAIL | The client engine failed to initialize. |
| 240041 | CEI_SET_PARAM_FAIL | An engine parameter could not be set. |
| 240042 | CEI_COMPILE_GRAMMER_FAIL | Grammar compilation failed. |
| 240043 | CEI_STOP_FAIL | The client engine could not stop the recognition task. |
| 240044 | CEI_CANCEL_FAIL | The client engine could not cancel the recognition task. |
| 240045 | CEI_UNLOAD_KWS_FAIL | The client engine could not unload the specified wake-up words. |
| 240046 | GET_WUW_ERROR | The client engine could not retrieve the specified wake-up words. |
Audio data errors
| Error code | Error message | Description |
|---|---|---|
| 240050 | SELECT_RECORDER_ERROR | The recording device was not selected properly. |
| 240051 | UPDATE_AUDIO_ERROR | Audio data could not be pushed to the server. This is typically caused by audio data that exceeds the size limit. |
| 240052 | MIC_ERROR | The microphone captured no audio for 2 consecutive seconds. |
Request timeout errors
| Error code | Error message | Description |
|---|---|---|
| 240080 | ENGINE_INIT_TIMEOUT | The engine initialization request timed out. |
| 240081 | SET_PARAM_TIMEOUT | The parameter configuration request timed out. |
| 240082 | SET_WUW_TIMEOUT | The wake-up word configuration request timed out. |
| 240083 | SELECT_RECORDER_TIMEOUT | The recording device selection request timed out. |
| 240084 | STOP_TIMEOUT | The dialog termination request timed out. |
| 240085 | ASR_ENGINE_STOP_TIMEOUT | The engine stop request timed out. |
| 240086 | UNLOAD_DYNAMIC_WUW_TIMEOUT | The dynamic wake-up word removal request timed out. |
| 240087 | ADD_DYNAMIC_WUW_TIMEOUT | The dynamic wake-up word addition request timed out. |
| 240100 | WAIT_TIMEOUT | The engine request timed out. |
| 240101 | HANDLE_API_TIMEOUT | The API request timed out. |
Network errors
| Error code | Error message | Description |
|---|---|---|
| 240060 | CREATE_DA_REQUEST_ERROR | The dialog assistant could not be created. |
| 240061 | START_DA_REQUEST_ERROR | The dialog assistant could not be started. |
| 240062 | DEFAULT_NLS_ERROR | A server-side error occurred. This error also generates a server error code. See Error codes returned by the server. |
| 240063 | SSL_ERROR | The Secure Sockets Layer (SSL) certificate could not be created. |
| 240064 | SSL_CONNECT_FAILED | The SSL connection failed. |
| 240065 | HTTP_CONNECT_FAILED | The HTTP connection failed. |
| 240066 | DNS_FAILED | Domain Name System (DNS) resolution failed. |
| 240067 | CONNECT_FAILED | The socket connection failed. |
| 240068 | SERVER_NOT_ACCESS | The server is unreachable. |
| 240069 | SOCKET_CLOSED | The socket connection was closed. |
| 240070 | AUTH_FAILED | Authentication failed. |
| 240071 | HTTPDNS_FAILED | The connection to the server using the specified IP address failed. |
Network timeout errors
| Error code | Error message | Description |
|---|---|---|
| 240090 | UPDATE_CONTEXT_TIMEOUT | The client update request timed out. |
| 240091 | CONNECTION_TIMEOUT | The network connection timed out. |
| 240092 | PARTIAL_ASR_TIMEOUT | The request to get the intermediate automatic speech recognition (ASR) result timed out. |
| 240093 | ASR_TIMEOUT | The request to get the final ASR result timed out. |
| 240094 | DIALOG_TIMEOUT | The request to get the dialog processing result timed out. |
| 240095 | WWV_TIMEOUT | The request to get the server-side wake-up result timed out. |
Error codes returned by the server
When the SDK raises an EVENT_ASR_ERROR event with error code 240062 (DEFAULT_NLS_ERROR), the status field in the event's header object contains the server-side error code listed here.
For server errors50000000,50000001, and52010001— if the error occurs occasionally, no action is required. If the error recurs repeatedly, submit a ticket.
| Error code | Cause | Solution |
|---|---|---|
| 40000001 | Authentication failed. | Check whether the token has expired or is invalid. |
| 40000002 | The request message is invalid. | Check whether the message format meets the service requirements. |
| 403 | The token has expired or is invalid. | Check whether the token has expired. If it is still within its validity period, verify that it is correct. |
| 40000004 | The idle connection timed out because no data was sent for 10 consecutive seconds. | Check whether the client is sending data at the expected rate. |
| 40000005 | The number of requests exceeds the limit. | Check whether the number of concurrent connections or queries per second (QPS) exceeds the limit. To increase the concurrency limit, upgrade Intelligent Speech Interaction from the trial edition to Commercial Edition. If you are already on Commercial Edition, purchase additional resources. |
| 40000000 | A client error occurred (default client error). | Check the error message for details. If the issue persists, submit a ticket. |
| 41010120 | The client timed out because no audio data was sent for 10 or more consecutive seconds. | Check whether the client is sending audio data at the expected rate. |
| 50000000 | A server error occurred (default server error). | If occasional: no action needed. If recurring: submit a ticket. |
| 50000001 | An internal call error occurred on the server. | If occasional: no action needed. If recurring: submit a ticket. |
| 52010001 | An internal call error occurred on the server. | If occasional: no action needed. If recurring: submit a ticket. |
| 40010001 | The method is not supported. | Submit a ticket. |
| 40010002 | The instruction is not supported. | Submit a ticket. |
| 40010003 | The instruction is invalid. | Submit a ticket. |
| 40010004 | The client disconnected before the server completed the task. | Check whether the client disconnected prematurely and ensure the connection stays open until the task finishes. |
| 40010005 | The task is in an abnormal state. | Check whether the instruction is valid for the current task state. |
| 40020105 | The appkey is invalid. | Resolve the route to check whether the application exists. |
| 40020106 | The appkey and token do not match. | Check that the appkey belongs to the same Alibaba Cloud account as the token. |
| 40020503 | Resource Access Management (RAM) user authentication failed. | Use your Alibaba Cloud account to grant the RAM user access to the POP API. |
| 41040201 | No data was received from the client for 10 consecutive seconds. | Check the network connection or whether no business data needs to be sent. |
| 41040202 | The client is sending data too fast, consuming all server resources. | Check whether the client sends data at an appropriate transmission rate, for example, at the real-time factor of 1:1. |
| 41040203 | The audio coding format is not supported. | Convert the audio to a format supported by the SDK. |
| 41040204 | Methods were called in the wrong order. | Check that the client calls the request method before calling other methods. |
| 41040205 | The MAXSILENCE_PARAM value is out of range. | Check whether the value of the MAXSILENCE_PARAM parameter is in the range of 200 to 2000. |
| 41050008 | The audio sampling rate does not match the ASR model. | Check that the audio sampling rate in the service call matches the sampling rate of the ASR model bound to the application in the console. |
| 51040101 | An internal server error occurred. | Check the error message and resolve the issue accordingly. |
| 51040102 | Reserved. | N/A |
| 51040103 | The real-time speech recognition service is unavailable. | Check whether the number of concurrent real-time speech recognition tasks exceeds the limit. |
| 51040104 | The real-time speech recognition request timed out. | Check the real-time speech recognition service logs. |
| 51040105 | The real-time speech recognition service call failed. | Check whether the service is enabled and whether the port is reachable. |
| 51040106 | Load balancing failed and the service IP address could not be resolved. | Check whether the real-time speech recognition server in the configured virtual private cloud (VPC) is running properly. |
Is this page helpful?