Account session

POST /core/v1/playground/tasks

Account session · POST /core/v1/playground/tasks

仅当前有效登录会话;无需创建或选择 API Key。复用账号分组、钱包预留、原价格与唯一结算。未知结果保留占款,查询原意图。已受理执行不因退出登录取消。

POST/core/v1/playground/tasks

Authorizations

Authorizationstringrequired

Use an account session; required access: Account session.

Authorization: Bearer $ONEASTER_SESSION_TOKEN

Parameters

Idempotency-Keystringrequired

header · 一次用户意图的稳定标识;网络重试保持原键和输入。

Body · application/json

See the complete schema below.

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": 20000
            },
            "aspect_ratio": {
              "type": "string",
              "description": "新KIE型号默认1:1;受型号及分辨率限制,读取task-models.specifications。旧z-image/MiniMax仍必须明确传既有比例。"
            },
            "resolution": {
              "enum": [
                "1K",
                "1.5K",
                "2K",
                "4K"
              ],
              "description": "新KIE型号默认第一个支持规格;旧z-image/MiniMax不接受此字段。"
            },
            "image_task_id": {
              "type": "string",
              "format": "uuid",
              "description": "同账号同Key已结算的Core PNG,最多单张;仅编辑型号或支持两种输入的Nano型号。"
            }
          },
          "required": [
            "prompt"
          ]
        }
      },
      "required": [
        "kind",
        "model",
        "input"
      ],
      "description": "依管理员配置的上游及规格校验。新KIE提示词按型号限长,旧型号1000;数量1,不接受任意图片URL。"
    },
    {
      "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": {
              "type": "string",
              "description": "新型号按目录校验;Wan 文生默认 adaptive,其余文生默认 16:9;参考帧通常省略。"
            },
            "resolution": {
              "enum": [
                "480p",
                "720p",
                "1080p",
                "4k"
              ]
            },
            "duration": {
              "type": "integer",
              "minimum": 1,
              "maximum": 30
            },
            "camera_fixed": {
              "type": "boolean"
            },
            "generate_audio": {
              "type": "boolean"
            }
          },
          "required": [
            "prompt",
            "duration"
          ]
        }
      },
      "required": [
        "kind",
        "model",
        "input"
      ],
      "description": "新KIE型号支持基础文生视频,时长范围及分辨率按目录和管理员报价进一步校验。音频选填默认false;只允许有该能力的型号。旧Lite/Runway仍沿用原控制及5/10秒限制。"
    },
    {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "kind": {
          "const": "video"
        },
        "model": {
          "type": "string",
          "minLength": 1,
          "maxLength": 200
        },
        "input": {
          "type": "object",
          "additionalProperties": false,
          "properties": {
            "prompt": {
              "type": "string",
              "maxLength": 20480
            },
            "image_task_id": {
              "type": "string",
              "format": "uuid"
            },
            "resolution": {
              "enum": [
                "480p",
                "720p",
                "1080p",
                "4k"
              ]
            },
            "duration": {
              "type": "integer",
              "minimum": 1,
              "maximum": 30
            },
            "generate_audio": {
              "type": "boolean"
            },
            "video_task_id": {
              "type": "string",
              "format": "uuid"
            },
            "character_orientation": {
              "enum": [
                "video",
                "image"
              ]
            },
            "aspect_ratio": {
              "type": "string"
            }
          },
          "required": [
            "prompt",
            "image_task_id",
            "resolution",
            "duration"
          ]
        }
      },
      "required": [
        "kind",
        "model",
        "input"
      ],
      "description": "基础单张自有PNG参考视频;同一账号同Key,结算Core图片或受信任Node媒体。Motion Control另外需要同Key已结算video_task_id,后端校验MP4真实3–30整秒,duration必须一致;image朝向最多10秒。Kling4 Reference图片每边>=300且比例0.4–2.5。"
    }
  ]
}