Add Tasks
Task
Add Tasks
Create new tasks within a specified squid
POST
Add Tasks
This endpoint creates new tasks within a specified squid. Tasks define the specific scraping jobs to be executed, such as URLs to scrape or search parameters.
Note: The accepted task input keys (e.g.,
url, city, activity) depend on the crawler used in your squid. Use the Get Crawler Parameters endpoint to discover valid keys for your crawler.
Headers
string
required
Your API authentication token. Value:
Token YOUR_API_KEYstring
required
Must be application/json. Value:
application/jsonRequest Body
string
required
The hash ID of the squid to add tasks to. Example:
"a1b2c3d4e5f6g7h8i9j0"array
required
Array of task objects. Each task contains parameters specific to the crawler. Example:
[{"url": "https://example.com"}]Response Field Explanations
integer
Number of tasks that were duplicates and not added. Example:
0array
Array of created task objects.
string
Unique task identifier (hash). Example:
"c5e29d2aba8b77cdc56391e7405302de"string
Always
"task".string
Task creation timestamp (ISO 8601). Example:
"2025-02-10T14:19:32.916901"boolean
Whether the task is active and ready to run. Example:
trueobject
Task parameters specific to the crawler (URL, search terms, etc.). Example:
{"url": "https://..."}string
Identifier of the crawler module this task belongs to.
Duplicate tasks (same parameters) are automatically detected and not added. Check duplicated_count in the response.
Code Examples
Response
200
400