目录

Error Codes

Error Code

Value

Description

Solution

NSP_STATUS

500

Failed to call the API.

Rectify the fault based on the error description.

NSP_STATUS

6

The access token has expired.

Obtain a new access token.

NSP_STATUS

102

Invalid access token. For example, the access token has an incorrect format or is blocklisted due to the password change.

Obtain a new access token.

NSP_STATUS

1

Unknown error.

-

Error Code

Sub-error Code

Description

Solution

1101

12304

The client_secret parameter has an incorrect value.

Check the settings of the input parameters.

20002

The value of client_id is in an incorrect format.

20022

The value of redirect_uri is in an incorrect format.

20023

The value of redirect_uri in code does not match the redirection URL set in AppGallery Connect.

20086

Invalid need_code parameter.

20024

The value of redirect_uri in code is different from that of the input parameter.

20152

The value of code is in an incorrect format.

20154

The value of client_id in code or refresh_token is different from that of the input parameter.

20172

The value of client_secret is in an incorrect format.

20182

The grant_type parameter has an incorrect value.

20192

The value of refresh_token is in an incorrect format.

22023

If the value of redirect_uri does not start with hms, the redirection URL specified by the value is not that registered with AppGallery Connect.

1102

20001

The client_id parameter is left empty.

20021

The redirect_uri parameter is left empty.

20151

The code parameter is left empty.

20181

The grant_type parameter is left empty.

20191

The refresh_token parameter is left empty.

1103

20153

Invalid code parameter.

1203

31202

The refresh token matches the regular expression but cannot be parsed.

Example: The original refresh token is truncated or transcoded.

12303

The client_id parameter does not exist in the system.

31218

The refresh_token parameter does not meet the regular expression requirements.

1101

20155

The code has expired. The validity period of the code is 5 minutes.

A new authorization code needs to be obtained.

20156

The code has been used.

1203

11205

The refresh_token parameter has expired.

A new refresh token needs to be obtained.

31204

The refresh_token parameter has expired. (If a user changes the password or signs out, the previous refresh_token parameter becomes invalid.)

Other error codes

Other error codes

Internal system error.

  1. Network flapping or system errors may occur. You are advised to try again.
  2. It is recommended that you record the sub-error codes to help locate faults.

If the error persists, submit a ticket online. Huawei will get back to you as soon as possible.