Start Task
Method: POST
Endpoint: /api/v1/task/run
Send the request body with Content-Type: application/json.
Try it
Section titled “Try it”POST
/api/v1/task/runStart saved task runRequired
Stored only in this browser tab. Sent only to https://openapi.coreclaw.com.
BodyRequiredapplication/json
FieldTypeRequiredDescription
task_slugstringyesUnique saved task identifier.callback_urlstringyesWebhook URL for async completion callbacks.Request body (JSON)
When to use this endpoint
Section titled “When to use this endpoint”Use this endpoint when you already have a saved Task template and want to create a new run from that template.
Where task_slug comes from
Section titled “Where task_slug comes from”task_slug is the Task ID — a unique identifier generated when you create and save a Task template. A Task is a reusable configuration that bundles a Worker with preset parameters.
Important: Do not pass a
run_slug(Run Record ID) orscraper_slug(Worker ID) here. Each slug type serves a different purpose.
Request Example
Section titled “Request Example”{ "task_slug": "YOUR_TASK_SLUG", "callback_url": "https://your-callback.example.com/webhook"}Parameters
Section titled “Parameters”| Parameter | Example | Type | Required | Description |
|---|---|---|---|---|
| task_slug | YOUR_TASK_SLUG | String | Yes | Task ID — unique identifier for the saved Task template |
| callback_url | https://your-callback.example.com/webhook | String | Yes | Callback URL for receiving Task run results |
Response Example
Section titled “Response Example”{ "code": 0, "message": "success", "data": { "run_slug": "01KSFDS8XWTJME33C08XMCR6B9" }}Response Fields
Section titled “Response Fields”| Parameter | Example | Type | Description |
|---|---|---|---|
| code | 0 | Integer | Global status code |
| message | success | String | Response message |
| data | - | Object | Response payload |
| run_slug | 01KSFDS8XWTJME33C08XMCR6B9 | String | Run Record ID — unique identifier for this execution |
Validation behavior
Section titled “Validation behavior”callback_urlis required. Omitting it returns400 Bad Request.- Do not pass a
run_slug(Run Record ID) orscraper_slug(Worker ID) instead of a validtask_slug— each slug type is different and not interchangeable.
Error Response
Section titled “Error Response”Business-level errors may return a structured JSON body such as:
{ "code": 60001, "message": "Task does not exist", "data": null}Error Fields
Section titled “Error Fields”| Parameter | Example | Type | Description |
|---|---|---|---|
| code | 60001 | Integer | Error code |
| message | Task does not exist | String | Error description |
| data | null | Null | Empty payload |