Img Open
  1. 绘图工具
Img Open
  • CV任务状态码信息附录
  • 绘图信息
    • sd 文生图-v2
      POST
    • sd 文生图-v3
      POST
    • sd 图生图-v2
      POST
    • sd 图生图-v3
      POST
    • sd 局部重绘-v1
      POST
    • sd controlnet 生图
      POST
    • 查询模型列表
      POST
    • 查询lora列表
      POST
    • 查询vae列表
      POST
    • 查询Embedding列表
      POST
  • 绘图任务
    • 查询归档任务详情
    • 查询任务实时状态 (百分比/进度条/中间图)
    • 绘图工具任务查询
  • 模型训练
    • 提交训练任务
    • 训练结果回调
  • 绘图工具
    • Flux文生图
      POST
    • 个性化写真
      POST
    • 高级换脸
      POST
    • 超级换脸 faceFusion
      POST
    • 面部检测(脸部提取) faceDetection
      POST
    • 换发型
      POST
    • 提示词扩写
      POST
    • sd prompts优化
      POST
    • 提示词扩写优化
      POST
    • 图转文
      POST
    • 超分辨
      POST
    • 换脸 roop
      POST
    • 面部修复
      POST
    • 智能擦除
      POST
    • 风格识别
      POST
    • 图片外扩
      POST
    • CNT预览
      POST
    • 背景去除
      POST
    • 图片扩大
      POST
    • 给图片加水印
      POST
    • 图片去水印
      POST
    • 图生视频
      POST
  • 图片检测
    • 异步图片检测
  • 视频工具
    • 视频加水印
    • 移除视频背景
    • 视频比例调整
    • 扩大视频图像
    • 视频补帧
    • 视频格式转换
  • 音频工具
    • 人声分离
    • 文生音乐
    • 文字配音
    • 生成歌词
  • 翻译
    • 翻译
  1. 绘图工具

换发型

POST
/AIGCImgOpenServ/saas/tool/hair/change

请求参数

Header 参数
X-Request-req-accessKeyId
string 
身份鉴权ID
必需
X-Request-req-accessKeySecret
string 
身份鉴权密码
必需
Body 参数application/json
businessTaskId
string 
业务任务ID
必需
facePath
string 
必需
用户上传的更换发型目标图像
shapePath
string 
参考发型图像
必需
colorPath
string 
参考发型颜色
必需
callbackUrl
string 
回调地址
可选
示例
{
  "businessTaskId": "business_task_id_35377fd103e9",
  "facePath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/wanqian2.jpg",
  "shapePath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/lijin_01.jpg",
  "colorPath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/wanqian2.jpg"
}

示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.zhiqite.com/AIGCImgOpenServ/saas/tool/hair/change' \
--header 'X-Request-req-accessKeyId;' \
--header 'X-Request-req-accessKeySecret;' \
--header 'Content-Type: application/json' \
--data-raw '{
  "businessTaskId": "business_task_id_35377fd103e9",
  "facePath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/wanqian2.jpg",
  "shapePath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/lijin_01.jpg",
  "colorPath": "https://dbt-aigc.oss-cn-hangzhou.aliyuncs.com/Output-Img2/bbbb/wanqian2.jpg"
}'

返回响应

🟢200成功
application/json
Body
code
string 
必需
msg
string 
必需
data
object 
必需
businessTaskId
string 
业务方任务id
必需
outputImageUrl
string 
输出图片url
必需
status
integer 
必需
任务状态 0:失败 2:成功
taskId
string 
服务方任务id
必需
errorCode
integer 
状态编码
必需
示例
{
  "code": "200",
  "data": {
    "businessTaskId": "business_task_id_35377fd103e9",
    "outputImageUrl": "https://aigcoss.zhiqiteai.cn/tool/hairstyle/2024-06-11/ce265bc7-dcc4-4807-91f6-48428a681d12.png",
    "status": 2,
    "taskId": "pre1718095929488816897049",
    "errorCode": 200000
  },
  "msg": "success"
}
修改于 2025-03-12 09:03:05
上一页
面部检测(脸部提取) faceDetection
下一页
提示词扩写
Built with