> ## Documentation Index
> Fetch the complete documentation index at: https://docs.geekai.co/llms.txt
> Use this file to discover all available pages before exploring further.

# 混元3D生成

混元 3D（`hunyuan-3d`） 基于腾讯自研生成式 AI 大模型，提供 3D 内容生成。支持通过文本描述或上传 2D 图像自动创建高精度 3D 模型，可广泛应用于游戏开发、影视制作、产品设计等领域。混元 3D API 显著降低了专业级建模的技术门槛，提升了创作效率及设计灵活性，赋能多行业高效完成 3D 内容生产。

混元专业版（`hunyuan-3d-pro`）采用混元 3D 3.0 生成模型，支持更高精度以及更高质量的 3D 模型。

混元 3D 极速版（`hunyuan-3d-pro-fast`）可将生成模型时间缩短到最低，以便在较短时间内生成 3D 模型文件。

三个模型在极客智坊平台可通过统一 3D 生成 API 接口进行代理调用，只是参数和价格有所区别，下面的教程会详细介绍。

### 模型参数

* 模型ID：`hunyuan-3d`/`hunyuan-3d-pro`/`hunyuan-3d-pro-fast`
* 模型价格：你可以在[模型广场](https://geekai.co/models?platform=tencent\&type=image-3d)查看最新价格信息
* 调用入口：`https://geekai.co/api/v1/image3ds/generations`
* 模型参数：参考[3D生成 API 手册](https://docs.geekai.co/cn/api/3d/generations)
* API认证：[获取 API KEY](https://docs.geekai.co/cn/docs/quick_start)

<Note>
  `prompt` 和 `image` 同时只能传递一个参数，不能同时传递，以区分文生3D和图生3D两种模式（专业版中`generate_type`设置为`Sketch`除外）。

  `hunyun-3d` 在 `hunyuan-3d-fast` 基础上支持以下额外参数：

  * `multi_view_images`

  `hunyuan-3d-pro` 在 `hunyuan-3d` 基础上支持以下额外参数：

  * `face_count`
  * `generate_type`：通过 `extra_body` 参数传递
  * `polygon_type`：通过 `extra_body` 参数传递

  附：[混元 3D 官方 API 文档](https://cloud.tencent.com/document/product/1804/120826)
</Note>

### 模型价格

不同版本的模型价格不同，以下是混元 3D 各版本的默认配置官方价格表：

| 模型版本            | 价格（单位：元/次） |
| --------------- | ---------- |
| hunyuan-3d      | 1.8        |
| hunyuan-3d-fast | 1.2        |
| hunyuan-3d-pro  | 3.6        |

`hunyuan-3d` 每次调用统一按 1.8 元/次计算，对于 `hunyuan-3d-pro`，价格由生成类型+附加参数叠加而来，不同生成类型（通过 `generate_type` 配置）的基础价格不一样：

| 生成类型        | 功能描述                | 价格（单位：元/次） |
| ----------- | ------------------- | ---------- |
| Normal（默认值） | 可生成带纹理的几何模型         | 2.4        |
| LowPoly     | 可生成智能减面后带纹理的几何模型    | 3          |
| Geometry    | 可生成不带纹理的几何模型（白模）    | 1.8        |
| Sketch      | 可输入草图或线稿图生成带纹理的几何模型 | 3          |

附加参数对应的附加价如下：

| 附加参数                    | 功能描述                          | 附加价格（单位：元/次） |
| ----------------------- | ----------------------------- | ------------ |
| `multi_view_images`     | 通过多视图生成3D 模型                  | 1.2          |
| `enable_pbr`            | 生成带PBR材质的3D 模型，包含金属度，粗糙度，法线贴图 | 1.2          |
| `face_count`（默认值500000） | 生成自定义面数的3D 模型                 | 1.2          |

因此，不配置任意参数的默认 `hunyuan-3d-pro` 生成类型为 `Normal`，生成面数为500000，因此默认价格是 2.4+1.2=3.6 元/次，其他参数请对应调整价格或者叠加计算。

对于 `hunyuan-3d-fast`，不支持生成类型参数，因此默认价格为基础价 1.2 元/次，此外，根据是否开启 PBR，模型价格会有所不同，开启 PBR 材质后价格为 1.2+0.6=1.8 元/次。

### 混元3D

以下是一个带多视角图片的混元3D调用请求示例：

```bash theme={null}
curl --location --request POST 'https://geekai.co/api/v1/image3ds/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer $GEEKAI_API_KEY' \
--data '{
  "model": "hunyuan-3d",
  "image": "https://file.style3d.com/app/intellistyle/company/ai/1756880593622/Jcpenny_junior7-f.png",
  "multi_view_images": [
    {
      "view_type": "left",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880595235/Jcpenny_junior7-sl.png"
    },
    {
      "view_type": "right",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880597122/Jcpenny_junior7-sr.png"
    },
    {
      "view_type": "back",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880596218/Jcpenny_junior7-b.png"
    }
  ]
}'
```

生成结果如下：

```json theme={null}
{
    "task_id": "7a29a22a-f871-44d4-be91-bb38a76ee856",
    "task_status": "succeed",
    "created": 1761574645,
    "files": [
        {
            "type": "OBJ",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/b874b12d-2e51-41dc-a985-2ce41e2ad554_0.zip?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574645%3B1761661045&q-key-time=1761574645%3B1761661045&q-header-list=host&q-url-param-list=&q-signature=ae337b5513527be980c25f56b362b09aaf700d16",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/%2F3d/output/1317767639/preview_b874b12d-2e51-41dc-a985-2ce41e2ad554_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574645%3B1761661045&q-key-time=1761574645%3B1761661045&q-header-list=host&q-url-param-list=&q-signature=883ae9837e9b99e413fde6d0907bb756c00cec88"
        }
    ]
}
```

### 混元3D专业版

以下是一个带多视角图片的混元3D专业版调用请求示例，和标准版不同是支持 `face_count` 和 `extra_body` 参数：

```bash theme={null}
curl --location --request POST 'https://geekai.co/api/v1/image3ds/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer $GEEKAI_API_KEY' \
--data '{
  "model": "hunyuan-3d-pro",
  "image": "https://file.style3d.com/app/intellistyle/company/ai/1756880593622/Jcpenny_junior7-f.png",
  "multi_view_images": [
    {
      "view_type": "left",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880595235/Jcpenny_junior7-sl.png"
    },
    {
      "view_type": "right",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880597122/Jcpenny_junior7-sr.png"
    },
    {
      "view_type": "back",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880596218/Jcpenny_junior7-b.png"
    }
  ],
  "face_count": 500000,
  "extra_body": {
    "generate_type": "Normal"
  }
}'
```

生成结果如下：

```json theme={null}
{
    "task_id": "e66e6270-b933-40a4-9193-70c216edf600",
    "task_status": "succeed",
    "created": 1761574911,
    "files": [
        {
            "type": "OBJ",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/2cf156a2-820d-46dd-9a5e-7a05ddc533cb_0.zip?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574911%3B1761661311&q-key-time=1761574911%3B1761661311&q-header-list=host&q-url-param-list=&q-signature=3c97751e3c307ea3f718486ce7ae89fb4649699f",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/preview_2cf156a2-820d-46dd-9a5e-7a05ddc533cb_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574911%3B1761661311&q-key-time=1761574911%3B1761661311&q-header-list=host&q-url-param-list=&q-signature=1eabc9219401d286036ef305319ae7fa0614147f"
        },
        {
            "type": "GLB",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/2cf156a2-820d-46dd-9a5e-7a05ddc533cb_0.glb?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574911%3B1761661311&q-key-time=1761574911%3B1761661311&q-header-list=host&q-url-param-list=&q-signature=875fe1296404eaa47228446239bdbfe15bd2ddf7",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/preview_2cf156a2-820d-46dd-9a5e-7a05ddc533cb_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761574911%3B1761661311&q-key-time=1761574911%3B1761661311&q-header-list=host&q-url-param-list=&q-signature=1eabc9219401d286036ef305319ae7fa0614147f"
        }
    ]
}
```

### 混元3D极速版

混元3D极速版支持更少参数，除了基本的 `image` 参数外，仅支持 `enable_pbr` 和 `result_format` 参数，以下是一个混元3D极速版调用请求示例：

```bash theme={null}
curl --location --request POST 'https://geekai.co/api/v1/image3ds/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer $GEEKAI_API_KEY' \
--data '{
  "model": "hunyuan-3d-fast", 
  "image": "https://file.style3d.com/app/intellistyle/company/ai/1756880593622/Jcpenny_junior7-f.png",
  "enable_pbr": true,
  "result_format": "GLB"
}'
```

生成结果如下：

```json theme={null}
{
    "task_id": "8d17e2ef-3d20-46cd-b435-71473b0ed0cd",
    "task_status": "succeed",
    "created": 1761575574,
    "files": [
        {
            "type": "GLB",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3drapid/output/1317767639/cf3b6eb1-4de5-4c88-a363-92e6c6e09795_0.glb?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575574%3B1761661974&q-key-time=1761575574%3B1761661974&q-header-list=host&q-url-param-list=&q-signature=bae9d53d0e2a58ec8418b3b64c27e184e3605630",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/%2F3drapid/output/1317767639/preview_cf3b6eb1-4de5-4c88-a363-92e6c6e09795_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575574%3B1761661974&q-key-time=1761575574%3B1761661974&q-header-list=host&q-url-param-list=&q-signature=3f334178bf07224c3b79722ab1e6c7a4bc8254e9"
        }
    ]
}
```

### 异步任务

对于复杂的3D生成任务，建议使用异步模式以避免请求超时。

在极客智坊中支持通过平台统一异步任务模式调用混元 3D 系列所有模型，只需在请求中将 `async` 参数设置为 `true` 即可：

```bash theme={null}
curl --location --request POST 'https://geekai.co/api/v1/image3ds/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer $GEEKAI_API_KEY' \
--data '{
  "model": "hunyuan-3d-pro",
  "image": "https://file.style3d.com/app/intellistyle/company/ai/1756880593622/Jcpenny_junior7-f.png",
  "multi_view_images": [
    {
      "view_type": "left",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880595235/Jcpenny_junior7-sl.png"
    },
    {
      "view_type": "right",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880597122/Jcpenny_junior7-sr.png"
    },
    {
      "view_type": "back",
      "view_image_url": "https://file.style3d.com/app/intellistyle/company/ai/1756880596218/Jcpenny_junior7-b.png"
    }
  ],
  "face_count": 500000,
  "extra_body": {
    "generate_type": "Normal"
  },
  "async": true
}'
```

生成结果如下：

```json theme={null}
{
    "task_id": "9c39a1fd-0ef7-4391-b586-61ad8ed07999",
    "task_status": "running",
    "created": 1761575149
}
```

和其他3D、图像、视频生成模型异步任务一样，你可以通过返回的 `task_id` 调用[3D生成结果获取接口](https://docs.geekai.co/cn/api/3d/result)查询任务状态和获取生成结果。任务状态为 `succeed` 时表示任务执行成功，响应和同步模式的混元3D生成接口响应格式相同：

```json theme={null}
{
    "task_id": "9c39a1fd-0ef7-4391-b586-61ad8ed07999",
    "task_status": "succeed",
    "created": 1761575149,
    "files": [
        {
            "type": "OBJ",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/e896e398-5545-4316-bef5-dfb7ecaaec08_0.zip?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575356%3B1761661756&q-key-time=1761575356%3B1761661756&q-header-list=host&q-url-param-list=&q-signature=086df315c109573c13e89092f45995f9398af36b",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/preview_e896e398-5545-4316-bef5-dfb7ecaaec08_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575356%3B1761661756&q-key-time=1761575356%3B1761661756&q-header-list=host&q-url-param-list=&q-signature=ee5569d51a1560c84b84a57e1b57abbefe6a04c4"
        },
        {
            "type": "GLB",
            "url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/e896e398-5545-4316-bef5-dfb7ecaaec08_0.glb?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575356%3B1761661756&q-key-time=1761575356%3B1761661756&q-header-list=host&q-url-param-list=&q-signature=b0ed002635a8af20f457ceae4d56bfa70b0cdc12",
            "preview_url": "https://hunyuan-prod-1258344699.cos.ap-guangzhou.tencentcos.cn/3d/output/1317767639/preview_e896e398-5545-4316-bef5-dfb7ecaaec08_0.png?q-sign-algorithm=sha1&q-ak=AKIDpRovliU1IJ5ctufBSVIq8AwTlnZ5MN8d&q-sign-time=1761575356%3B1761661756&q-key-time=1761575356%3B1761661756&q-header-list=host&q-url-param-list=&q-signature=ee5569d51a1560c84b84a57e1b57abbefe6a04c4"
        }
    ]
}
```

<Note>
  本教程中的演示图片均来源于[Style3D AI](https://www.style3d.ai/?refer=geekai)，仅供测试使用，请勿用于商业用途。Style3D AI 是 AI + 3D 驱动的时尚设计与营销工具，为时尚行业提供设计、营销、生产一体化智能化解决方案。
</Note>
