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

# 创建镜像预热任务

## 请求头

<ParamField header="Content-Type" type="string" required={true}>
  枚举值：application/json。
</ParamField>

<ParamField header="Authorization" type="string" required={true}>
  Bearer 身份验证格式，例如：Bearer \{\{API 密钥}}。
</ParamField>

## 请求体

<ParamField body="imageUrl" type="string" required={true}>
  镜像地址。
</ParamField>

<ParamField body="repositoryAuth" type="string" required={false}>
  镜像认证 ID。
</ParamField>

<ParamField body="clusterId" type="string" required={true}>
  集群 ID。
</ParamField>

<ParamField body="productIds" type="[string]" required={false}>
  产品 ID 列表。
</ParamField>

<ParamField body="note" type="string" required={false}>
  任务备注。
</ParamField>

## 示例

```bash theme={null}
curl --location --request POST 'https://api.ppio.com/gpu-instance/openapi/v1/image/prewarm' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {{API_KEY}}' \
--data-raw '{
    "imageUrl": "nginx:latest",
    "repositoryAuth": "",
    "clusterId": "dev-test",
    "productIds": [],
    "note": "test"
}'
```

## 响应参数

<ResponseField name="id" type="string" required={true}>
  预热任务 ID。
</ResponseField>

## 响应示例

```json theme={null}
{
  "id": "nzd5nyi4keefsv2d"
}
```
