Authentication
Account session. Session/administrative writes are not executed in the public Playground.
Endpoint
curl --request POST 'https://api.oneaster.ai/core/v1/keys/1/tasks/lookup' \ --header 'Authorization: Bearer '"$ONEASTER_SESSION_TOKEN" \ --header 'Idempotency-Key: '"$ONEASTER_INTENT" \ --header 'Content-Type: application/json' \ --data "$REQUEST_BODY_JSON"
Parameters
- id (path, Required): {"type":"string","pattern":"^[0-9]+$"}
- Idempotency-Key (header, Required): {"type":"string","minLength":1,"maxLength":100}
Request JSON Schema
{
"oneOf": [
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "image"
},
"model": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"input": {
"type": "object",
"additionalProperties": false,
"properties": {
"prompt": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"aspect_ratio": {
"enum": [
"1:1",
"4:3",
"3:4",
"16:9",
"9:16"
]
}
},
"required": [
"prompt",
"aspect_ratio"
]
}
},
"required": [
"kind",
"model",
"input"
]
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "video"
},
"model": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"input": {
"type": "object",
"additionalProperties": false,
"properties": {
"prompt": {
"type": "string",
"minLength": 1,
"maxLength": 20480
},
"aspect_ratio": {
"enum": [
"16:9",
"4:3",
"1:1",
"3:4",
"9:16",
"9:21",
"21:9"
]
},
"resolution": {
"enum": [
"480p",
"720p",
"1080p"
]
},
"duration": {
"type": "integer",
"enum": [
5,
10
]
},
"camera_fixed": {
"type": "boolean"
}
},
"required": [
"prompt",
"aspect_ratio",
"resolution",
"duration"
]
}
},
"required": [
"kind",
"model",
"input"
],
"description": "Input is validated against the selected public model upstream. Seedance Lite: prompt<=10000, all listed resolutions at 5/10s, 9:21 supported, camera_fixed supported. Seedance 2.5: prompt<=20480, all listed resolutions at 5/10s, 21:9 supported instead of 9:21; camera_fixed must be omitted, audio/draft/search/last-frame disabled, MP4 output and safety checker enabled. Runway: prompt<=1800, 720p at 5/10s or 1080p at 5s, camera_fixed must be omitted. Read task-model capabilities for valid combinations; no arbitrary passthrough or reference inputs for Seedance 2.5."
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "video"
},
"model": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"input": {
"type": "object",
"additionalProperties": false,
"properties": {
"prompt": {
"type": "string",
"minLength": 1,
"maxLength": 1800
},
"image_task_id": {
"type": "string",
"format": "uuid"
},
"resolution": {
"enum": [
"720p",
"1080p"
]
},
"duration": {
"type": "integer",
"enum": [
5,
10
]
}
},
"required": [
"prompt",
"image_task_id",
"resolution",
"duration"
]
}
},
"required": [
"kind",
"model",
"input"
],
"description": "Runway only: same-user, same-Key settled Core PNG, <=10 MiB. Omit aspect_ratio and camera_fixed; ratio follows source image. 1080p only supports 5 seconds. No arbitrary image_url or Node asset paths."
}
]
}
Responses
200
只读查询本人任务原意图;Key撤销后仍可查历史
{
"application/json": {
"schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"success": {
"const": true
},
"data": {
"type": "object",
"additionalProperties": false,
"properties": {
"recorded": {
"type": "boolean"
},
"task": {
"anyOf": [
{
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"reused": {
"type": "boolean"
},
"status_url": {
"type": "string"
}
},
"required": [
"id",
"reused",
"status_url"
]
},
{
"type": "null"
}
]
}
},
"required": [
"recorded",
"task"
]
}
},
"required": [
"success",
"data"
]
}
}
}
default
错误代码见 core-api.md;供应商/数据库错误已隐藏。
{
"application/json": {
"schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"success": {
"const": false
},
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"type": {
"const": "oneaster_error"
}
},
"required": [
"code",
"message",
"type"
]
},
"data": {
"type": "null"
}
},
"required": [
"success",
"error",
"data"
]
}
}
}