# Crawl 参数预览 (/zh/api-reference/endpoint/crawl-params-preview)

<!-- agent-signals: reading_time_min: 2 · est_tokens: 1276 · updated: 2026-07-30 -->
Related: [Search（搜索）](/zh/api-reference/endpoint/search.md), [搜索反馈](/zh/api-reference/endpoint/search-feedback.md), [Scrape](/zh/api-reference/endpoint/scrape.md), [批量抓取](/zh/api-reference/endpoint/batch-scrape.md), [获取批量抓取状态](/zh/api-reference/endpoint/batch-scrape-get.md), [取消批量抓取](/zh/api-reference/endpoint/batch-scrape-delete.md)



`POST /crawl/params-preview`

预览由自然语言提示词生成的爬取参数

## OpenAPI

```json
{
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "requestBody": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "prompt": {
              "description": "用自然语言编写的、描述你想爬取内容的提示词",
              "maxLength": 10000,
              "type": "string"
            },
            "url": {
              "description": "要抓取的 URL",
              "format": "uri",
              "type": "string"
            }
          },
          "required": [
            "url",
            "prompt"
          ],
          "type": "object"
        }
      }
    },
    "required": true
  },
  "responses": {
    "200": {
      "content": {
        "application/json": {
          "schema": {
            "properties": {
              "data": {
                "properties": {
                  "allowExternalLinks": {
                    "description": "是否允许外部链接",
                    "type": "boolean"
                  },
                  "allowSubdomains": {
                    "description": "是否允许子域名",
                    "type": "boolean"
                  },
                  "crawlEntireDomain": {
                    "description": "是否爬取整个域名",
                    "type": "boolean"
                  },
                  "deduplicateSimilarURLs": {
                    "description": "是否对相似 URL 去重",
                    "type": "boolean"
                  },
                  "delay": {
                    "description": "请求间隔（毫秒）",
                    "type": "number"
                  },
                  "excludePaths": {
                    "description": "排除的 URL 模式",
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "ignoreQueryParameters": {
                    "description": "是否忽略查询参数",
                    "type": "boolean"
                  },
                  "ignoreRobotsTxt": {
                    "description": "是否忽略 robots.txt 规则",
                    "type": "boolean"
                  },
                  "includePaths": {
                    "description": "包含的 URL 模式",
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "limit": {
                    "description": "最大抓取页面数",
                    "type": "integer"
                  },
                  "maxDepth": {
                    "description": "最大爬取深度",
                    "type": "integer"
                  },
                  "maxDiscoveryDepth": {
                    "description": "最大探索深度",
                    "type": "integer"
                  },
                  "robotsUserAgent": {
                    "description": "用于评估 robots.txt 的自定义 User-Agent 字符串",
                    "type": "string"
                  },
                  "sitemap": {
                    "description": "站点地图处理策略",
                    "enum": [
                      "skip",
                      "include"
                    ],
                    "type": "string"
                  },
                  "url": {
                    "description": "要爬取的 URL",
                    "format": "uri",
                    "type": "string"
                  }
                },
                "type": "object"
              },
              "success": {
                "example": true,
                "type": "boolean"
              }
            },
            "type": "object"
          }
        }
      },
      "description": "成功响应（包含生成的爬取参数）"
    },
    "400": {
      "content": {
        "application/json": {
          "schema": {
            "properties": {
              "error": {
                "example": "Invalid request parameters",
                "type": "string"
              },
              "success": {
                "example": false,
                "type": "boolean"
              }
            },
            "type": "object"
          }
        }
      },
      "description": "错误请求"
    },
    "401": {
      "content": {
        "application/json": {
          "schema": {
            "properties": {
              "error": {
                "example": "Unauthorized",
                "type": "string"
              },
              "success": {
                "example": false,
                "type": "boolean"
              }
            },
            "type": "object"
          }
        }
      },
      "description": "未授权"
    },
    "500": {
      "content": {
        "application/json": {
          "schema": {
            "properties": {
              "error": {
                "example": "Failed to process natural language prompt",
                "type": "string"
              },
              "success": {
                "example": false,
                "type": "boolean"
              }
            },
            "type": "object"
          }
        }
      },
      "description": "服务器错误"
    }
  }
}
```
