Skip to content

Commit 51ccdb3

Browse files
author
Cowork 3P
committed
docs: version field in /api/v1/scraper/run is now optional, defaults to latest
1 parent 87a2935 commit 51ccdb3

7 files changed

Lines changed: 21 additions & 22 deletions

File tree

public/openapi.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1219,7 +1219,7 @@
12191219
},
12201220
"version": {
12211221
"type": "string",
1222-
"description": "Scraper version. Must be copied from `/api/scraper` -> `data.version`.",
1222+
"description": "Scraper version. Optional — if omitted, defaults to the latest version.",
12231223
"example": "v1.0.5"
12241224
},
12251225
"is_async": {
@@ -1239,7 +1239,6 @@
12391239
},
12401240
"required": [
12411241
"scraper_slug",
1242-
"version",
12431242
"is_async",
12441243
"input"
12451244
]

src/content/docs/api/worker/run.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
title: Start Worker
33
description: Start a Worker run.
44
sidebar:
@@ -34,7 +34,7 @@ You can find it:
3434

3535
```json
3636
{
37-
"scraper_slug": "YOUR_SCRAPER_SLUG",
37+
"version": "YOUR_WORKER_VERSION", // Optional — defaults to latest version
3838
"version": "YOUR_WORKER_VERSION",
3939
"input": {
4040
"parameters": {
@@ -65,7 +65,7 @@ You can find it:
6565
| Parameter | Required | Type | Description |
6666
| ------------ | -------- | ------- | ----------- |
6767
| scraper_slug | Yes | string | **Worker ID** — unique identifier for the Worker you want to run |
68-
| version | Yes | string | Worker version |
68+
| version | No | string | Worker version. If omitted, defaults to the latest version. |
6969
| input | Yes | object | Input parameters |
7070
| is_async | Yes | boolean | `true`: async execution (default), `false`: sync execution (waits for completion) |
7171
| callback_url | No | string | Callback URL for receiving run results |
@@ -129,4 +129,4 @@ You can get the Worker version from:
129129
| code | 0 | Integer | Global status code |
130130
| message | success | String | Response message |
131131
| data | - | Object | Response payload |
132-
| run_slug | 01KSFDS8XWTJME33C08XMCR6B9 | String | **Run Record ID** — unique identifier for this execution |
132+
| run_slug | 01KSFDS8XWTJME33C08XMCR6B9 | String | **Run Record ID** — unique identifier for this execution |

src/content/docs/integrations/workflows-and-notifications/n8n.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
title: n8n
33
description: Connect CoreClaw to n8n workflows using the CoreClaw community node
44
sidebar:
@@ -120,14 +120,14 @@ Start an asynchronous scraper run with custom parameters.
120120
| Field | Description |
121121
| --------------------- | ------------------------------------------------------------------------ |
122122
| **Scraper** | Pick from the marketplace list, or paste a slug directly |
123-
| **Version** | Scraper version string (required). Obtain from **Get Details** → version |
123+
| **Version** | Scraper version string (optional — defaults to latest). Obtain from **Get Details** → version |
124124
| **Custom Parameters** | Scraper-specific input parameters as JSON (schema from Get Details) |
125125
| **System Parameters** | Optional JSON overrides for cpus, memory, timeout, max charge, traffic |
126126
| **Callback URL** | Optional webhook URL for async notifications |
127127

128128

129129
:::caution
130-
**Version is required.** The node does not support "leave empty for latest". Always obtain the correct version string from **Get Details** first.
130+
**Version is optional.** If left empty, the platform uses the latest version automatically. To pin a specific version, obtain the version string from **Get Details** first.
131131
:::
132132

133133
Get the `scraper_slug` (Worker Slug) from the Worker page in the [CoreClaw Console](https://console.coreclaw.com/store) or from the API (`GET /api/scraper?slug=<scraper_slug>`).
@@ -341,4 +341,4 @@ curl "https://openapi.coreclaw.com/api/scraper?slug=YOUR_SCRAPER_SLUG"
341341
```
342342

343343
The response contains `data.parameters.custom.properties` — each entry maps to an input field.
344-
</details>
344+
</details>

src/content/docs/user-guide/run-worker/api-calls.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ POST /api/v1/scraper/run
4545
```json
4646
{
4747
"scraper_slug": "YOUR_SCRAPER_SLUG",
48-
"version": "<version>",
48+
"version": "<version>", // Optional — defaults to latest version
4949
"input": {
5050
"parameters": {
5151
"system": {
@@ -86,9 +86,9 @@ When building `custom`:
8686
- Follow the declared `type`, nested structure, and array shape
8787
- Provide every field where `required: true`
8888
- If `custom` is empty or does not match, the API returns `400 Bad Request`
89-
9089
### How to get `version`
9190

91+
`version` is optional. If omitted, the platform uses the latest version automatically. To pin a specific version, use one of the following sources:
9292
Use one of the following sources:
9393

9494
- the Worker version shown on the Worker page

src/content/docs/zh-cn/api/worker/run.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
title: 运行 Worker
33
description: 启动 Worker 运行
44
sidebar:
@@ -36,7 +36,7 @@ import ApiPlayground from '../../../../../components/ApiPlayground.astro'
3636
```json
3737
{
3838
"scraper_slug": "YOUR_SCRAPER_SLUG",
39-
"version": "YOUR_WORKER_VERSION",
39+
"version": "YOUR_WORKER_VERSION", // 可选 — 默认使用最新版本
4040
"input": {
4141
"parameters": {
4242
"system": {
@@ -66,7 +66,7 @@ import ApiPlayground from '../../../../../components/ApiPlayground.astro'
6666
| 参数 | 必填 | 类型 | 说明 |
6767
| ------------ | ---- | ------- | ---- |
6868
| scraper_slug || string | **Worker ID**——要运行的 Worker 的唯一标识符 |
69-
| version | | string | Worker 版本 |
69+
| version | | string | Worker 版本。如不填写,默认使用最新版本。 |
7070
| input || object | 输入参数 |
7171
| is_async || boolean | `true`:异步执行(默认),`false`:同步执行(等待完成) |
7272
| callback_url || string | 用于接收运行结果的回调地址 |
@@ -130,4 +130,4 @@ import ApiPlayground from '../../../../../components/ApiPlayground.astro'
130130
| code | 0 | Integer | 全局状态码 |
131131
| message | success | String | 响应消息 |
132132
| data | - | Object | 响应数据 |
133-
| run_slug | 01KSFDS8XWTJME33C08XMCR6B9 | String | **运行记录 ID**——本次执行的唯一标识符 |
133+
| run_slug | 01KSFDS8XWTJME33C08XMCR6B9 | String | **运行记录 ID**——本次执行的唯一标识符 |

src/content/docs/zh-cn/integrations/workflows-and-notifications/n8n.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
title: n8n
33
description: 使用 CoreClaw 社区节点将 CoreClaw 接入 n8n 工作流
44
sidebar:
@@ -115,13 +115,13 @@ CoreClaw 节点按**资源**(Scraper、Run、Task、Account)组织。先选
115115
| 字段 | 说明 |
116116
|------|------|
117117
| **Scraper** | 从商店列表中选择,或直接粘贴 slug |
118-
| **Version** | 爬虫版本字符串(必填)。从 **Get Details** → version 获取 |
118+
| **Version** | 爬虫版本字符串(可选 — 默认使用最新版)。从 **Get Details** → version 获取 |
119119
| **Custom Parameters** | 爬虫特有的输入参数 JSON(schema 来自 Get Details) |
120120
| **System Parameters** | 可选 JSON,覆盖 cpus、memory、timeout、max charge、traffic |
121121
| **Callback URL** | 可选,异步通知的 Webhook 地址 |
122122

123123
:::caution
124-
**Version 是必填字段** 节点不支持"留空使用最新版"。务必先从 **Get Details** 获取正确的版本号
124+
**Version 为可选字段** 如不填写,平台将自动使用最新版本。如需指定版本,请先从 **Get Details** 获取版本号
125125
:::
126126

127127
`scraper_slug`(Worker Slug)可从 [CoreClaw 控制台](https://console.coreclaw.com/store)的 Worker 页面获取,或通过 API 查询(`GET /api/scraper?slug=<scraper_slug>`)。
@@ -315,4 +315,4 @@ curl "https://openapi.coreclaw.com/api/scraper?slug=YOUR_SCRAPER_SLUG"
315315
```
316316

317317
响应中的 `data.parameters.custom.properties` — 每个条目对应一个输入字段。
318-
</details>
318+
</details>

src/content/docs/zh-cn/user-guide/run-worker/api-calls.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ POST /api/v1/scraper/run
4545
```json
4646
{
4747
"scraper_slug": "YOUR_SCRAPER_SLUG",
48-
"version": "<version>",
48+
"version": "<version>", // 可选 — 默认使用最新版本
4949
"input": {
5050
"parameters": {
5151
"system": {
@@ -87,8 +87,8 @@ POST /api/v1/scraper/run
8787
- 对于 `required: true` 的字段,必须显式提供
8888
- 如果 `custom` 为空,或结构不匹配,接口会返回 `400 Bad Request`
8989

90-
### 如何获取 `version`
9190

91+
`version` 为可选字段。如不填写,平台将自动使用最新版本。如需指定版本,可通过以下方式获取:
9292
可以从以下位置获得:
9393

9494
- Worker 页面显示的版本号

0 commit comments

Comments
 (0)