Skip to content

Verify Captcha

This document introduces the API for verifying the graphic captcha after sliding the slider.

Request Description

Request Headers

Parameter NameChinese NameRequiredTypeExample
X-operating-sys-versionCaller client OS 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
content-typeContent format typeYesStringapplication/json

Request Example

Used for sending SMS verification code scenario

json
{
	"point_json": "{\"x\":237.0,\"y\":5.0}",
	"token": "71dd26999e314f9abb0c635336976635",
	"sender": "15200000000"
}

Used for sending email verification code scenario

json
{
	"point_json": "{\"x\":237.0,\"y\":5.0}",
	"token": "71dd26999e314f9abb0c635336976635",
	"sender": "15200000000@163.com"
}

Request Parameters

Parameter NameChinese NameRequiredTypeDescription
point_jsonCoordinate informationYesStringCoordinate information, y-axis fixed value 5.0
For coordinate information, seeJS, VUE Puzzle Captcha Demo
tokenCaptcha identity tokenYesStringToken returned by Get Captcha
senderSenderYesStringSender (mobile number, email)

Response Example

Success Example

HTTP/1.1 200 OK

json
{
    "captcha_token":"71dd26999e314f9abb0c635336976635---{\"x\":237.0,\"y\":5.0}"
}

Error Example

HTTP/1.1 400 Bad Request

json
{
    "error_code": "IDAAS.SDK.CAPTCHA.0002",
    "error_msg": "Graphic verification code verification failed"
}

Response Parameters

Parameter NameChinese NameTypeDescription
captcha_tokenCaptcha verification pass tokenStringToken after successful captcha verification

Error Codes

Status CodeError CodesChinese 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.0004坐标信息不能为空Point json cannot be emptyPlease check whether the input coordinate information is empty
400IDAAS.SDK.PARAM.0005图形验证码身份令牌不能为空Token cannot be emptyPlease check whether the input captcha identity token is empty
400IDAAS.SDK.PARAM.0006发送方不能为空Sender cannot be emptyPlease check whether the input sender is empty
400IDAAS.SDK.CAPTCHA.0002图形验证码校验失败Graphic verification code verification failedPlease check whether the input items are correct and call again

BambooCloud IDaaS Open Platform