batch_create
Submit a Batch job: many URLs scraped asynchronously in the cloud (Zenrows Batch API). Suited to large URL lists; scrape and extract handle single pages. Not the same as browser_batch.
Tasks use automatic mode (mode=auto) by default: Zenrows enables JS rendering and premium proxies only on the pages that need them. Pass just the URLs. Set js_render or premium_proxy (job-level, or per task) only to force a fixed configuration; that turns automatic mode off for those tasks.
Cost: the same credits as the regular API, per successful task: 1 for a basic request, 5 with js_render, 10 with premium_proxy, 25 with both; mode=auto bills each task at the configuration that worked. Failed tasks are not billed, except target 404 and 410 answers, billed as on the regular API. Limits: up to 100,000 tasks per call; 3 active jobs per account by default, shared with Crawl (BATCH_QUOTA_EXCEEDED past that); a job frees its slot when its run ends.
Creates a closed job with every task in this one call. Each task takes a url plus optional external_id, metadata, method/body (POST tasks) and scrape params. Every call sends an Idempotency-Key, so the bounded retries on network errors and 5xx never create a second job; an error reply carries the key to retry with.
Returns job_id, status and stats at once; the job runs asynchronously. Then: batch_wait until it ends, batch_results to list rows (paged), batch_content to read one task's page. A run that ends failed (out of credits, inactive subscription, key cap) answers ok:false with error.code and server_code; batch_rerun recovers it. Submits of 10,000+ tasks keep writing tasks for a while (ingesting:true). Errors: BATCH_INVALID_REQUEST (400, server_code and invalid_tasks say what), BATCH_INSUFFICIENT_CREDITS (402), BATCH_KEY_CAP_REACHED (402, this key's cap), BATCH_QUOTA_EXCEEDED (429, job limit), AUTH_INVALID (401; server_code subscription_inactive means fix Billing), BATCH_ACCESS_DENIED (403, do not retry), BACKEND_UNAVAILABLE. Schedules, webhooks, exports, CSV inputs and open jobs are available through the Batch API and SDKs only.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "batch_create"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| urls | No | Shorthand: list of URLs (converted to tasks), up to 100,000. Ignored when tasks is provided. | |
| wait | No | If true, poll before returning until the run ends or pauses, or wait_timeout passes; a timeout returns the current state with ok:true | |
| tasks | No | Tasks (each needs a url), up to 100,000. Prefer this over urls when you need per-task params. | |
| js_render | No | Force js_render on all tasks (5 credits each). Overrides automatic mode (mode=auto), which already renders when needed. | |
| mode_auto | No | Automatic mode (mode=auto) is on by default; leave unset. False sends plain requests without it. | |
| wait_timeout | No | Max wait in seconds when wait=true (default 50). Many MCP clients cancel a call after 60 s. | |
| premium_proxy | No | Force premium_proxy on all tasks (10 credits each, 25 with js_render). Overrides automatic mode (mode=auto), which already uses premium proxies when a page needs them. | |
| proxy_country | No | Job-level ISO country code. Works in automatic mode (mode=auto); with js_render alone it requires premium_proxy. | |
| response_type | No | Job-level output format. Leave unset for the raw HTML, the default. | |
| zenrows_params | No | Additional job-level scrape params merged with the flags above. Accepted: allowed_status_codes, autoparse, block_resources, css_extractor, custom_headers, extract, extract_fields, js_instructions, js_render, json_response, mode, original_status, outputs, premium_proxy, proxy_country, response_type, session_id, wait, wait_for. | |
| idempotency_key | No | Sent as the Idempotency-Key header, up to 128 characters; generated per call when unset. Reusing a key with the identical request within 24 hours returns the original response instead of doing it again; with a different request it is BATCH_IDEMPOTENCY_CONFLICT. | |
| wait_timeout_ms | No | Deprecated: the same wait in milliseconds. Use the seconds parameter instead. |