创建视频任务(ARK 兼容路径)
与 POST /v1/videos/generations 完全等效,但响应体直接采用官方 Volcengine Ark 的
seedance 格式:id 字段就是上游任务 ID,无 upstream_id 包裹。
用途:让已经接入官方 ARK SDK 的客户端只改 base_url 和 api_key 即可切到 XRToken。
请求体、鉴权方式、计费、模型路由全部与 /v1/videos/generations 共用一套实现。
Authorization
BearerAuth API 密钥认证(OpenAI 格式)。在 Authorization 请求头中传入:
Authorization: Bearer tr-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
In: header
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
curl -X post "https://api.xrtoken.net/v1/contents/generations/tasks" \ -H "Content-Type: application/json" \ -d '{ "model": "volcengine/doubao-seedance-2-0-260128", "content": [ { "type": "text" } ] }'{
"id": "string",
"model": "string",
"status": "queued",
"created_at": "2019-08-24T14:15:22Z"
}{
"error": "model field is required",
"type": "invalid_request_error"
}{
"error": "invalid or missing API key",
"type": "auth_error"
}{
"error": "insufficient balance -- please top up or upgrade your plan",
"type": "billing_error"
}{
"error": "rate limit exceeded",
"type": "rate_limit_error"
}{
"error": "upstream provider error",
"type": "server_error"
}