1. 任务查询
摄图AI-开放API
  • 图片生成
    • 生图
      POST
    • 图片抠图
      POST
    • 图片变清晰
      POST
    • 画面扩展
      POST
    • 高清放大
      POST
    • 图像消除
      POST
    • 自动意图生图
      POST
    • 模板生成图片
      POST
  • 视频生成
    • 生成视频
      POST
  • 任务查询
    • 查询生成任务
      GET
  • 模板
    • 模板列表
      GET
  • 数据模型
    • TemplateCover
    • TemplateItem
    • TemplateListData
    • TemplateListEnvelope
    • Model
    • ImageModel
    • ImageBaseRequest
    • VideoModel
    • TextToImageRequest
    • ImageInputRequest
    • PromptedImageInputRequest
    • ExpansionRatios
    • ExpansionRequest
    • UpscaleRequest
    • EraseRequest
    • AutoImageRequest
    • TemplateImageRequest
    • VideoGenerationRequest
    • SubmissionData
    • TaskAsset
    • TaskLayer
    • TaskData
    • SubmissionEnvelope
    • TaskEnvelope
  1. 任务查询

查询生成任务

GET
/web/openapi/v1/tasks/{id}
只能查询由当前 API Key 创建的任务。状态:0 待处理、1 处理中、2 成功、3 失败。

请求参数

Authorization
Bearer Token
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token
示例:
Authorization: Bearer ********************
or
Path 参数

请求示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location 'https://st-api.699pic.com/web/openapi/v1/tasks/1224715' \
--header 'Authorization: Bearer <token>'

返回响应

🟢200成功
application/json
任务查询结果。
Bodyapplication/json

示例
{
    "code": 1,
    "total": 0,
    "data": {
        "id": 0,
        "content_type": 1,
        "function": 0,
        "model": 0,
        "rate": "string",
        "quality": 0,
        "resolution": "string",
        "status": 0,
        "reason": "string",
        "type": 0,
        "copyright_type": 0,
        "is_refund": 0,
        "res": {
            "text": "string",
            "data": [
                {
                    "id": 0,
                    "status": 0,
                    "preview_path": "http://example.com",
                    "width": 0,
                    "height": 0,
                    "reason": "string",
                    "reject": 0,
                    "property1": "string",
                    "property2": "string"
                }
            ]
        },
        "layers": [
            {
                "task_id": 0,
                "pid": 0,
                "layer_type": "img",
                "z_index": 0,
                "raw_json": {
                    "property1": "string",
                    "property2": "string"
                }
            }
        ]
    },
    "msg": "成功",
    "extra": {
        "property1": "string",
        "property2": "string"
    }
}
修改于 2026-09-16 06:58:49
上一页
生成视频
下一页
模板列表
Built with