TokenLab

Video & Materials

Get Visual Validation Result

Gets the real-person material group produced by visual validation.

POST
/api/v3

Poll this Action after the H5 visual validation flow. A successful result returns the TokenLab material group ID for the verified person.

Use the same authenticated organization, user, and case-sensitive ProjectName that created the session.

Endpoint And Authentication

POST https://api.tokenlab.sh/api/v3?Action=GetVisualValidateResult&Version=2024-01-01
Authorization: Bearer <TOKENLAB_API_KEY>
Content-Type: application/json

Send the BytedToken returned by Create Visual Validation Session. If you set ProjectName during creation, send the same case-sensitive value here; otherwise omit it or use default.

The result may not be ready immediately after the browser callback. Retry the same request until Result.GroupId is returned or the 30-minute BytedToken expires. Repeating a successful request with the same token returns the same mapped GroupId.

Use the returned GroupId as the group_id when creating liveness_face material assets.

Example Request

curl 'https://api.tokenlab.sh/api/v3?Action=GetVisualValidateResult&Version=2024-01-01' \
  -H "Authorization: Bearer $TOKENLAB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"BytedToken":"ZXhhbXBsZS10b2tlbg","ProjectName":"default"}'

Example Response

{
  "ResponseMetadata": {
    "RequestId": "req_def456",
    "Action": "GetVisualValidateResult",
    "Version": "2024-01-01",
    "Service": "ark",
    "Region": "cn-beijing"
  },
  "Result": {
    "GroupId": "group-20260720123456-real1"
  }
}

Errors use ResponseMetadata.Error.Code and ResponseMetadata.Error.Message. A success response contains ResponseMetadata and Result; it does not use the response envelope from TokenLab's other /v1 APIs.

curl -X POST "https://example.com/api/v3" \  -H "Content-Type: application/json" \  -d '{    "CallbackURL": "http://example.com"  }'
{  "id": "string"}

Authorization

BearerAuth
AuthorizationBearer <token>

API Key authentication. Create or manage API keys in Dashboard > API > API Keys.

In: header

Query Parameters

Action?string

Value in

  • "CreateContentsGenerationsTasks"
  • "GetContentsGenerationsTask"
  • "ListContentsGenerationsTasks"
  • "DeleteContentsGenerationsTasks"
  • "CreateVisualValidateSession"
  • "GetVisualValidateResult"
  • "CreateAssetGroup"
  • "ListAssetGroups"
  • "GetAssetGroup"
  • "UpdateAssetGroup"
  • "DeleteAssetGroup"
  • "CreateAsset"
  • "ListAssets"
  • "GetAsset"
  • "UpdateAsset"
  • "DeleteAsset"
Version?string
default"2024-01-01"

Headers

X-TokenLab-Delivery-Policy?string

Per-request Delivery policy. Overrides the API key and Workspace defaults. Auto tries TokenLab Verified first and may switch once to Official only before output, request acceptance, or persistent resource creation.

Value in

  • "auto"
  • "verified"
  • "official"

Request Body

application/json

Response

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json