Verify Image Captcha API
After sliding the image captcha slider, call the verify image captcha API.
Request Description
Request Headers
| Parameter Name | Name | Required | Type | Description |
|---|---|---|---|---|
| X-operating-sys-version | Caller operating system version | Yes | String | windows10.1.1 |
| X-device-fingerprint | Caller device fingerprint | Yes | String | 156aysdna213sc50 |
| X-device-ip | Caller IP | No | String | 192.168.1.2 |
| X-agent | User-Agent information | Yes | String | Mozilla/5.0 (iPhone; CPU iPhone OS 13_3 like Mac OS X) AppleWebKit/605.1.15(KHTML, like Gecko) Mobile/15E148/HuaWei-AnyOffice/2.6.1802.0010/com.huawei.cloudlink.workplace |
| X-L | Used for internationalization language setting | No | String | zh |
| X-client-id | Application authorization ID | Yes | String | nTo1eRIub60vPb54WeE6aojPwYwImtl4 |
Request Example
json
# For SMS verification code scenario
{
"point_json": "{\"x\":237.0,\"y\":5.0}",
"token": "71dd26999e314f9abb0c635336976635",
"sender":"15201657315"
}
# For email verification code scenario
{
"point_json": "{\"x\":237.0,\"y\":5.0}",
"token": "71dd26999e314f9abb0c635336976635",
"sender":"zhangsan@qq.com"
}Request Parameters
| Parameter Name | Name | Required | Type | Description |
|---|---|---|---|---|
| point_json | Coordinate info | Yes | String | Coordinate info; the y-axis fixed value is 5.0. For how to obtain coordinate info, see JS, VUE Puzzle Captcha DEMO. |
| token | Token returned by Get Image Captcha | Yes | String | Token returned by Get Image Captcha |
| sender | Sender | Yes | String | Sender (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": "SDK.COMMON.1001",
"error_msg": "Parameter X-client-id cannot be left blank."
}Response Parameters
| Parameter Name | Name | Type | Description |
|---|---|---|---|
| captcha_token | Token after successful image captcha verification | String | Token after successful image captcha verification |