Asset library Volcengine-compatible endpoint
Volcengine Ark Open API format compatible entry point for the asset
library. Point the base URL at XRToken and the request path, parameters,
and response stay identical to the official Volcengine API. Authenticate
with an XRToken API key (Authorization: Bearer tr-xxx or
x-api-key: tr-xxx) — no AK/SK required.
The Action query parameter selects the operation. All of these use
the official POST /?Action=... path:
Action=CreateAssetGroup: create an asset group.ProjectNameis optional: when omitted, the gateway project (currentlyxrtoken) is used automatically; when explicitly provided (includingdefault), the value is passed through as-is.Action=CreateAsset: create an asset.ProjectNameis optional: when omitted, the gateway project (currentlyxrtoken) is used automatically; when explicitly provided (includingdefault), the value is passed through as-is.Nameis optional too.Action=GetAssetGroup: query an asset group, body{"Id": "group-xxx"}.Action=GetAsset: query an asset, body{"Id": "asset-xxx"}.Action=ListAssetGroups: list asset groups.Action=ListAssets: list assets.Action=UpdateAssetGroup: update an asset group.Action=UpdateAsset: update an asset.Action=DeleteAssetGroup: delete an asset group.Action=DeleteAsset: delete an asset.Action=CreateVisualValidateSession: create a real-person verification session.Action=GetVisualValidateResult: query a real-person verification result.
Responses use the official Volcengine ResponseMetadata / Result
envelope and keep the asset library's tenant isolation (you can only
operate on assets under groups you own).
Authorization
BearerAuth API key authentication (OpenAI format). Pass in the Authorization header:
Authorization: Bearer tr-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
In: header
Query Parameters
Operation:
CreateAssetGroup-- create an asset groupCreateAsset-- create an assetGetAssetGroup-- query an asset groupGetAsset-- query an assetListAssetGroups-- list asset groupsListAssets-- list assetsUpdateAssetGroup-- update an asset groupUpdateAsset-- update an assetDeleteAssetGroup-- delete an asset groupDeleteAsset-- delete an assetCreateVisualValidateSession-- create a real-person verification sessionGetVisualValidateResult-- query a real-person verification result
"CreateAssetGroup" | "CreateAsset" | "GetAssetGroup" | "GetAsset" | "ListAssetGroups" | "ListAssets" | "UpdateAssetGroup" | "UpdateAsset" | "DeleteAssetGroup" | "DeleteAsset" | "CreateVisualValidateSession" | "GetVisualValidateResult"API version, defaults to 2024-01-01.
"2024-01-01"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X post "https://api.xrtoken.ai/?Action=CreateAssetGroup" \ -H "Content-Type: application/json" \ -d '{ "Name": "my-assets" }'{}{
"error": "model field is required",
"type": "invalid_request_error"
}{
"error": "invalid or missing API key",
"type": "auth_error"
}{
"error": "string",
"type": "invalid_request_error"
}{
"error": "string",
"type": "invalid_request_error"
}{
"error": "rate limit exceeded",
"type": "rate_limit_error"
}{
"error": "upstream provider error",
"type": "server_error"
}