Skip to content

Check Whether User Set Password

After the user logs in successfully and calls the change personal password API, call this API first to obtain whether the current user has set a password.

This is a post-login API. You need to add authorization information in the header: Authorization.

Request Description

Request Headers

Parameter NameNameRequiredTypeExample
X-operating-sys-versionCaller client operating system versionYesStringwindows10.1.1
X-device-fingerprintCaller client device fingerprintYesString156aysdna213sc50
X-device-ipCaller client IPNoString192.168.1.2
X-agentUser-Agent informationYesStringMozilla/5.0 (iPhone; CPU iPhone OS 13_3 like Mac OS X)
X-LUsed for internationalization language settingNoStringzh
X-client-idApplication authorization IDYesStringnTo1eRIub60vPb54WeE6aojPwYwImtl4
AuthorizationAuthorization informationYesStringBearer {id_token}
content-typeContent format typeYesStringapplication/json

Request Example

None

Request Parameters

None

Response Example

Success Example

HTTP/1.1 200 OK

json
{
    "is_set_pwd": true
}

Error Example

HTTP/1.1 400 Bad Request

json
{
    "error_code": "IDAAS.SDK.PARAM.0016",
    "error_msg": "IdToken is invalid or expired"
}

Response Parameters

Parameter NameNameTypeDescription
is_set_pwdWhether password existsStringReturns true if a password exists, false otherwise

Error Codes

Status CodeError CodeChinese Error MessageEnglish Error MessageResolution
400IDAAS.SDK.PARAM.0001设备信息不完整Device information is incompletePlease check whether the input device information is complete
400IDAAS.SDK.PARAM.0002clientId不能为空clientId cannot be emptyPlease check whether the input clientId is empty
400IDAAS.SDK.PARAM.0003应用未注册,请先注册应用The app is not registered, please register the app firstPlease check whether the input clientId is correct
400IDAAS.SDK.PARAM.0015IdToken不能为空IdToken cannot be emptyPlease check whether the input IdToken is empty
400IDAAS.SDK.PARAM.0016IdToken无效或已过期IdToken is invalid or expiredPlease re-acquire the IdToken and try again
400IDAAS.SDK.USER.0001用户未找到User not foundPlease register first and try again

BambooCloud IDaaS Open Platform