This topic describes the result codes for Mobile Gateway Service to help you troubleshoot issues.
Gateway-side result codes
A result code of 1000 indicates a successful API call. All other codes indicate errors.
Result codes from 1001 to 5999 and in the 7XXX range indicate gateway errors.
Codes in the 7XXX range indicate Security Guard signature verification or decryption errors. For more information, see Security Guard result code reference.
In addition to the result code, you can check the
Memoandtipsfields in the response header for more error information.Apsara Stack users can also view detailed error information in the
~/logs/gateway/gateway-error.logfile on the gateway server.
If an exception occurs, troubleshoot it using the gateway exception troubleshooting guide. For more information, see Gateway exception troubleshooting.
Result code | Description | Explanation |
1000 | Success | The gateway API call was processed successfully. |
1001 | Access denied | The mock format is incorrect, the |
1002 | API call limit exceeded | This exception occurs when the request rate limit is triggered after you enable throttling. |
1005 | Unauthorized | This exception occurs when API authorization fails after you enable API authorization. |
2000 | Logon timeout | This exception is triggered in a non-logged-on state when the authorization feature is enabled. |
3000 | RPC interface does not exist or is closed | In the environment that corresponds to the current workspaceId, the API service for the specified operationType is not configured for the mobile application that corresponds to the appId, or the API service is not in the Active state. |
3001 | Request data is empty | The |
3002 | Incorrect data format | The RPC request format is incorrect. Apsara Stack users can view details in the server-side |
3003 | Data decryption failed | Data decryption failed. |
4001 | Service request timeout | The Mobile Gateway Service (MGS) timed out when calling the business system service. This is caused by high load on the backend business system. Check the operational status of the backend system. If the timeout setting is unreasonable, adjust it as needed. Note: The default timeout is 3 s. |
4002 | Exception in remote call to business system | An exception occurred when MGS called the business system service. Apsara Stack users can view details in the server-side |
4003 | API group HOST exception | An |
5000 | Unknown exception | Other critical errors. Apsara Stack users can view details in the server-side |
7000 | Public key not set | The key corresponding to the appId does not exist in Security Guard for the mobile app, or the gateway cannot get the signature key for the appId. |
7001 | Insufficient parameters for signature verification | Server-side signature verification by the gateway failed. |
7002 | Signature verification failed | Server-side signature verification by the gateway failed. |
7003 | Signature verification - timeliness failed | The ts timestamp in the API request parameters has expired based on the system's validity period. Check if the client time is synchronized with the system time. |
7007 | Signature verification - missing ts parameter | The ts parameter for signature verification is missing from the API request. |
7014 | Signature verification - missing sign parameter | The sign parameter for signature verification is missing from the API request. This is usually because the client failed to sign the data. Check if the client's Security Guard image is correct. |
8002 | Cross-domain preflight request (CORS preflight) | Cross-domain preflight request. |
Service-side result codes
You can view error information for the following result codes on the business system server.
You can determine the specific exception details by viewing the ~/logs/mobileservice/monitor.log log on each business system.
Result code | Applicable protocol | Description | Explanation |
6000 | MPC, DUBBO | RPC - Target service not found | The published service cannot be found. The server is inaccessible or the service has been migrated. |
6001 | MPC, DUBBO | RPC - Target method not found | The method within the published service cannot be found. |
6002 | MPC, DUBBO | RPC - Incorrect number of parameters | The number of input parameters does not match the number of declared parameters. |
6003 | MPC, DUBBO | RPC - Target method is not accessible | The target method cannot be invoked. |
6004 | HTTP, MPC, DUBBO | RPC - JSON parsing exception | HTTP: An exception occurred when converting RPC parameters to backend HTTP request parameters. MPC/DUBBO: Failed to deserialize RPC JSON-formatted data into business parameter objects. |
6005 | MPC, DUBBO | RPC - Invalid parameters when calling the target method | The parameters are invalid for reflection-based calls. |
6007 | MPC, DUBBO | RPC - Logon authentication service is unavailable | The logon authentication interface in the Service Provider Interface (SPI) package is not implemented, or the interface is configured incorrectly. |
6666 | HTTP, MPC, DUBBO | RPC - Exception thrown by business | HTTP: The backend system returned an HTTP status code other than 200. MPC/DUBBO: An exception was thrown by the business. The RPC cannot handle it and treats it as a business exception. |
Android client result codes
Result code | Description | Prompt text |
0 | Unknown error | Unknown error. Please try again later. |
1 | The client cannot find the communication object because no transport is set. | Network error. Please try again later. |
2 | The client has no network connectivity, such as when the user turns off the network or disables network permissions for the application. | Cannot connect to the network. |
3 | SSL-related errors, including SSL handshake errors and SSL certificate errors. | The client certificate is incorrect. Check if the phone's time setting is accurate. |
4 | The client network connection timed out. This error occurs when the TCP connection exceeds the 10 s timeout period. | Poor network connection. |
5 | A data read/write operation timed out. This error typically occurs when the client network speed is too slow (socketTimeout scenario). | Poor network connection. |
6 | The client sent a request to the server but did not receive a response (NoHttpResponseException). | Network error. Please try again later. |
7 | A client network I/O error occurred (IOException). | Network error. Please try again later. |
8 | A client network request scheduling error occurred because the execution thread was interrupted. | Network error. Please try again later. |
9 | Client processing error, including serialization errors, annotation processing errors, and thread execution errors. | Network error. Please try again later. |
10 | A client data deserialization error occurred because the data format from the server is incorrect. | Network error. Please try again later. |
13 | Request interruption error, such as when a network request is interrupted because its thread is interrupted. | Network error. Please try again later. |
15 | A client network authorization error occurred (HttpHostConnectException: "Connection to xxx refused"). This error indicates that there is no network connectivity or the server rejected the connection. | Cannot connect to the network. |
16 | DNS parsing error | Cannot connect to the network. Please try again later. |
18 | Network throttling. This error is triggered when the client's request traffic exceeds the client-side throttling threshold. | Network access is throttled. Please try again later. |
code ≥ 400 and code < 500 | An HTTP status code in the 4xx range. | Cannot connect to the network. |
400 > code ≥ 100 and 500 < code < 600 | An unsuccessful HTTP status code was returned. | Cannot connect to the network. Please try again later. |
iOS RPC request error codes
Value | Status code | Meaning |
0 | kDTRpcNetworkError | Cannot connect to the network. Important All network failures are classified under this code. The specific error is passed through using userinfo. The key to get the corresponding error from the userinfo dictionary is kDTRpcErrorCauseError. |
1 | kDTRpcEmptyResponse | The data returned by the server is empty. |
2 | kDTRpcInvalidJSONString | The JSON string returned by the server is not in the correct format and cannot be converted into a JSON object. |
3 | kDTRpcDecodeObjectError | Error deserializing the JSON object. |
4 | kDTRpcNetworkCancelled | The network request was canceled. |
5 | kDTRpcEncodeObjectError | Error serializing the JSON object. |
6 | kDTRpcProtocolBuffersDecodeError | Error deserializing the Protocol Buffers (PB) object. |
9 | KDTRpcSizeControlError | An exception is thrown directly if the RPC payload is too large. This error is delegated to the caller:
|
24 | KDTRpcAbandonError | After a logon RPC is returned during an account switch, the RPC is discarded and an exception is thrown directly. |
3003 | / | Decryption error. |