This topic describes the error codes for the speech recognition service to help you troubleshoot issues.
Error codes
Successful recognition
Error code | Error message | Description |
0 | SUCCESS | Success. |
Configuration or parameter errors
Error code | Error message | Description | Solution |
240999 | DEFAULT_ERROR | Default internal error. | Internal error. Retry the operation. |
240001 | NUI_CONFIG_INVALID | Configuration file error. | Configuration file error. Confirm that the resource file exists in the specified resource path. For Android, see the code sample and use the copyAssets interface. |
240002 | ILLEGAL_PARAM | Invalid parameter. | Confirm that the input format is correct, including the field type and value range limits. |
240003 | ILLEGAL_INIT_PARAM | Invalid initialization parameter. | Confirm if the initialization parameter format is incorrect or if a required field is missing. |
240004 | NECESSARY_PARAM_LACK | A required parameter is missing. | Confirm the required parameters for the interface call. |
240005 | NULL_PARAM_ERROR | The parameter is empty. | Confirm that the parameter is not empty. |
240006 | NULL_LISTENER_ERROR | The event callback is not defined. | Confirm that the callback event is assigned correctly. |
240007 | NULL_DIALOG_ERROR | No valid dialog instance exists. This usually occurs during an internal state error. | Confirm that the state is correct before calling the interface. Use the cancel interface to restore the idle state. |
240008 | NULL_ENGINE_ERROR | No valid engine instance exists. Check if the initialization was successful. | Confirm that the initialization was successful. |
240009 | ILLEGAL_DATA | The input audio data address or length is invalid. | Confirm the value of the input data length. |
SDK status errors
Error code | Error message | Description | Solution |
240010 | ILLEGAL_REENTRANT | An SDK interface was called after exiting. | You can ignore this error if it does not affect functionality. |
240011 | SDK_NOT_INIT | The SDK was not initialized correctly. | Confirm that the initialization returns a correct value before using other interfaces. |
240012 | SDK_ALREADY_INIT | The SDK initialization interface was called repeatedly. | Confirm the initialization call logic. |
240013 | DIALOG_INVALID_STATE | Internal dialog state error. | Read the SDK flowchart to confirm if the interface was called in an incorrect state. |
240014 | STATE_INVALID | SDK internal state error. | Same as DIALOG_INVALID_STATE. |
240015 | ILLEGAL_FUNC_CALL | The interface cannot be called in this mode. | Confirm that the interface call is valid. |
System call errors
Error code | Error message | Description | Solution |
240020 | MEM_ALLOC_ERROR | Memory allocation error. | Check for insufficient memory. |
240021 | FILE_ACCESS_FAIL | File access error. | Check if file read and write permissions are granted. |
240022 | CREATE_DIR_ERROR | Error creating directory. | Check for write permissions. |
SDK internal call errors
Error code | Error message | Description | Solution |
240030 | CREATE_NUI_ERROR | Failed to create the engine. | Failed to create the instance. This is usually due to insufficient system resources. |
240031 | TEXT_DIALOG_START_FAIL | Failed to start text understanding. | Failed to convert text to semantic understanding. Check if the network connection, URL, and token are valid. |
240032 | TEXT_CANCEL_START_FAIL | Failed to cancel text understanding. | You can safely ignore this. |
240033 | WUW_DUPLICATE | Duplicate dynamic wake-up word. | You can ignore this error. |
Local engine call errors
Error code | Error message | Description | Solution |
240040 | CEI_INIT_FAIL | Failed to initialize the local engine. | Confirm that the local engine model is valid and that the directory is readable and writable. |
240041 | CEI_SET_PARAM_FAIL | Failed to set engine parameters. | You can safely ignore this. |
240042 | CEI_COMPILE_GRAMMER_FAIL | Failed to compile grammar. | You can safely ignore this. |
240043 | CEI_STOP_FAIL | Failed to stop recognition. | You can disregard this. |
240044 | CEI_CANCEL_FAIL | Failed to cancel recognition. | You can ignore this. |
240045 | CEI_UNLOAD_KWS_FAIL | Failed to cancel the wake-up word. | You can ignore this error. |
240046 | GET_WUW_ERROR | Failed to get the wake-up word. | You can safely ignore this. |
Audio errors
Error code | Error message | Description | Solution |
240050 | SELECT_RECORDER_ERROR | Error selecting audio device. | Internal error. Retry the operation. |
240051 | UPDATE_AUDIO_ERROR | Error pushing audio. This usually occurs when the input audio length is greater than the required length. | You can check if the length of the pushed audio is invalid. |
240052 | MIC_ERROR | Failed to get audio for 2 consecutive seconds. | Confirm that audio of the required length is provided in the audio data callback. |
Call timeout errors
Error code | Error message | Description | Solution |
240080 | ENGINE_INIT_TIMEOUT | Engine initialization timed out. | Internal service error. The client must retry the operation. |
240081 | SET_PARAM_TIMEOUT | Setting parameters timed out. | Internal service error. The client must retry the operation. |
240082 | SET_WUW_TIMEOUT | You can set the wake word timeout. | Internal service error. The client must retry the operation. |
240083 | SELECT_RECORDER_TIMEOUT | Selecting the recording device timed out. | Internal service error. The client must retry the operation. |
240084 | STOP_TIMEOUT | Ending the dialog timed out. | Internal service error. The client must retry the operation. |
240085 | ASR_ENGINE_STOP_TIMEOUT | Stopping the engine timed out. | Internal service error. The client must retry the operation. |
240086 | UNLOAD_DYNAMIC_WUW_TIMEOUT | You can cancel the dynamic wake-up word timeout. | Internal service error. The client must retry the operation. |
240087 | ADD_DYNAMIC_WUW_TIMEOUT | You can increase the dynamic wake word timeout. | Internal service error. The client must retry the operation. |
240100 | WAIT_TIMEOUT | Engine interface call timed out. | Internal service error. The client must retry the operation. |
240101 | HANDLE_API_TIMEOUT | API layer interface call timed out. | Internal service error. The client must retry the operation. |
Network errors
Error code | Error message | Description | Solution |
240060 | CREATE_DA_REQUEST_ERROR | Failed to create a dialog assistant instance. | You can ignore this. |
240061 | START_DA_REQUEST_ERROR | Failed to start a dialog assistant request. | You can safely ignore this. |
240062 | DEFAULT_NLS_ERROR | A server-side error occurred. This error includes the error content returned by the server. For more information, see the server-side error codes. | See the server-side return code for further troubleshooting. |
240063 | SSL_ERROR | Error creating SSL instance. | Internal service error. The client must retry the operation. |
240064 | SSL_CONNECT_FAILED | SSL connection failed. | Connection is abnormal. Check if the service URL or the on-premises network connectivity is normal. |
240065 | HTTP_CONNECT_FAILED | HTTP connection failed. | Service connection error. View the HTTP return value in the log file to identify the cause. |
240066 | DNS_FAILED | DNS parsing failed. | Check if the on-premises network and DNS service are normal. |
240067 | CONNECT_FAILED | Socket connection failed. | Check the network connection. |
240068 | SERVER_NOT_ACCESS | The server cannot be accessed. | Check if the token has expired or if the URL is correct. |
240069 | SOCKET_CLOSED | The socket is closed. | Internal service error. The client must retry the operation. |
240070 | AUTH_FAILED | Authentication failed. | Check if the correct ak_secret, ak_id, app_key, sdk_code, and device_id are provided. Also, confirm that a sufficient quota is enabled. |
240071 | HTTPDNS_FAILED | Failed to connect using the IP address provided by the client. | If you directly use an IP address for access, confirm that the IP address is accessible. |
240072 | HTTP_SEND_FAILED | Failed to send HTTP request for file transcription. | Confirm that the network connection is normal. |
240073 | HTTP_RECEIVE_FAILED | Failed to receive HTTP response for file transcription. | Confirm that the network connection is normal. |
240074 | HTTP_RESPONSE_ERROR | Failed to parse the received content for file transcription. | Internal error. Retry the operation. |
240075 | HTTP_SERVER_ERROR | File transcription service error. For more information, see the service error codes. | See the server-side error code to identify the cause. |
Network timeout errors
Error code | Error message | Description | Solution |
240090 | UPDATE_CONTEXT_TIMEOUT | Updating client information timed out. | Internal service error. The client must retry the operation. |
240091 | CONNECTION_TIMEOUT | Network connection timed out. | Internal service error. The client must retry the operation. |
240092 | PARTIAL_ASR_TIMEOUT | Getting intermediate recognition results timed out. | Internal service error. The client must retry the operation. |
240093 | ASR_TIMEOUT | Getting final recognition results timed out. | Internal service error. The client must retry the operation. |
240094 | DIALOG_TIMEOUT | Getting dialog understanding results timed out. | Internal service error. The client must retry the operation. |
240095 | WWV_TIMEOUT | Getting cloud-side wake-up confirmation results timed out. | Internal service error. The client must retry the operation. |
Server-side error codes
If you receive an EVENT_ASR_ERROR event with the error code DEFAULT_NLS_ERROR (240062) or HTTP_SERVER_ERROR (240075), retrieve the server-side error code from the status field in the event header to troubleshoot the issue.
Error code | Cause | Solution |
40000001 | Identity authentication failed. | Check if the token is correct and has not expired. |
40000002 | Invalid message. | Check if the sent message meets the requirements. |
403 | The token has expired or a parameter is invalid. |
|
40000004 | Idle timeout. | Confirm that no data has been sent to the server-side for 10 seconds. |
40000005 | Too many requests. | Check whether the number of concurrent connections or requests per second is exceeded. If the concurrency limit is exceeded, you can upgrade from the Free Edition to the Commercial Edition, or scale out the concurrent resources for the Commercial Edition. |
40000000 | Default client error code. | Check the corresponding error message. |
40000010 | The trial period has ended and the Commercial Edition is not activated, or the account has an overdue payment. | Log on to the console to confirm the service activation status and your account balance. |
41010120 | Client timeout error. | The client did not send data for 10 or more consecutive seconds, which caused a client timeout error. |
50000000 | Default server-side error. | Internal service error. The client must retry the operation. |
50000001 | Internal call error. | Internal service error. The client must retry the operation. |
52010001 | Internal call error. | Internal service error. The client must retry the operation. |
40010001 | Unsupported interface. | Upgrade to the latest SDK. |
40010002 | Unsupported instruction. | Upgrade to the latest SDK. |
40010003 | Invalid instruction. | Upgrade to the latest SDK. |
40010004 | The client disconnected prematurely. | Check if the connection was closed before the request was completed. |
40010005 | Task status error. | An instruction was sent that cannot be processed in the current task state. |
40020105 | The application does not exist. | The application could not be found during route parsing. |
40020106 | The appkey and token do not match. | Check if the appkey is correct and if it belongs to the same account as the token. |
40020503 | Sub-account authentication failed. | Use the primary account to grant the sub-account access permissions to the POP API. |
41040201 | The client stops sending data within 10 s. | Check for network issues, or verify that your service is sending data. |
41040202 | The client sent data too quickly, and server resources are exhausted. | Check whether the client is sending packets too quickly. Packets must be sent at a 1:1 real-time factor. |
41040203 | The client sent audio in an unsupported format. | Convert the audio data to a format that the SDK supports. |
41040204 | An abnormal client method call occurred. | The client must call the send request interface before calling other interfaces. |
41040205 | The client set an invalid value for the MAXSILENCE_PARAM parameter. | The valid value range for the MAXSILENCE_PARAM parameter is 200 to 2000. |
41050008 | Sample rate mismatch. | Check whether the sample rate set during the call matches the sample rate of the ASR model that is bound to the appkey in the console. |
51040101 | Internal server error. | Unknown error. |
51040103 | The real-time speech recognition service is unavailable. | Check whether tasks are stacked in the real-time speech recognition service. This can cause task submission to fail. |
51040104 | The request to the real-time speech recognition service timed out. | Check the real-time speech recognition service logs. |
51040105 | Failed to call the real-time speech recognition service. | Check whether the real-time speech recognition service is running and whether the port is open. |
51040106 | Load balancing for the real-time speech recognition service failed. The IP address of the service was not retrieved. | Check for issues with the real-time speech recognition service instance in the VPC. |