Async jobs
GET
https://scrapely.15.204.158.166.sslip.io /api/v1/jobs List jobs
Parameters
statusstringquerybatch_idstringquerylimitintegerqueryCode samples
cURL
curl -X GET "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit="TypeScript
const res = await fetch('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit=', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit=",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit=", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit=');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit=')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://scrapely.15.204.158.166.sslip.io/api/v1/jobs?status=&batch_id=&limit="))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 Newest first. Results are not included; fetch a job for its content.
Example
{
"object": {},
"data": [
{
"id": "job_5f0c8a1b2d3e4f56",
"object": {},
"status": "queued",
"url": "string",
"batch_id": "string",
"options": {
"render": false,
"premium": false,
"ultra_premium": false,
"country_code": "us",
"device_type": "desktop",
"session_number": 0,
"keep_headers": false,
"output_format": "html",
"autoparse": false,
"wait_for_selector": "string"
},
"credits": 0,
"status_code": 0,
"duration_ms": 0,
"error": "string",
"callback_url": "string",
"created_at": "2024-01-01T00:00:00Z",
"finished_at": "2024-01-01T00:00:00Z",
"status_url": "string",
"response": {
"status_code": 0,
"content_type": "string",
"final_url": "string",
"headers": {},
"content": null,
"expires_at": "2024-01-01T00:00:00Z"
}
}
],
"has_more": true
}Schema
objectdataJob[]Show child parameters
idstringobjectstatusstringurlstringbatch_idstringoptionsobjectOptions shared by sync scrapes, jobs and batches.
Show child parameters
renderbooleanLoad the page in a headless browser and execute its JavaScript before returning the DOM. Cost: 10 credits.
premiumbooleanRoute through the residential proxy pool. Use for sites that block datacenter IPs. Cost: 10 credits (25 with render).
ultra_premiumbooleanOur hardest-target pipeline: premium residential IPs, browser fingerprinting and CAPTCHA handling. Includes rendering. Cannot be combined with premium. Cost: 30 credits.
country_codestringGeotarget the request from this country (lowercase ISO 3166-1 alpha-2, e.g.
us, de, jp).device_typestringSend a desktop or mobile user agent and viewport.
session_numberintegerReuse the same proxy IP across requests that share this number (sticky session, ~15 minutes idle timeout).
keep_headersbooleanForward the headers you send us (Cookie, Accept-Language, User-Agent, …) to the target instead of ours. Your API key, Host and proxy headers are never forwarded. Sync endpoint only.
output_formatstringReturn the page as raw HTML, cleaned Markdown, plain text, or JSON (title, meta, links, text).
autoparsebooleanFor supported domains, return structured JSON parsed from the page instead of HTML.
wait_for_selectorstringWith render=true: wait until this CSS selector appears before capturing the page.
creditsintegerReserved while queued/running; charged when finished; 0 when failed or cancelled.
status_codeintegerduration_msintegererrorstringcallback_urlstringcreated_atstringfinished_atstringstatus_urlstringPoll this.
responseobjectPresent once the job is finished (or failed with a target answer). Kept for 72 hours.
Show child parameters
status_codeintegercontent_typestringfinal_urlstringheadersobjectcontentstring | objectexpires_atstringhas_moreboolean400
MISSING_PARAM or INVALID_PARAM; param names the culprit.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
401
UNAUTHORIZED: missing, unknown or revoked key.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
429
RATE_LIMITED or CONCURRENCY_LIMIT. Honour Retry-After.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
500
INTERNAL: our fault, not charged. Quote X-Request-Id.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
POST
https://scrapely.15.204.158.166.sslip.io /api/v1/jobs Create an async job
Queue a scrape and return immediately (202). Credits are reserved now and refunded if the job fails or is cancelled before it starts. Jobs never fail for concurrency: they wait for a free slot. Poll status_url, or pass callback_url to receive a signed webhook.
Parameters
Idempotency-KeystringheaderAny unique string up to 255 printable characters (a UUID is ideal). Retrying with the same key returns the original response with
Idempotent-Replayed: true and charges nothing. A retry while the first is in flight is a 409; the same key with a different body is a 422. Remembered for 24 hours. Also accepted as the idempotency_key parameter.Request body application/json
urlstringrequiredThe page to scrape: an absolute http(s) URL, URL-encoded when sent in a query string. Private, loopback and link-local hosts are refused.
renderbooleanLoad the page in a headless browser and execute its JavaScript before returning the DOM. Cost: 10 credits.
premiumbooleanRoute through the residential proxy pool. Use for sites that block datacenter IPs. Cost: 10 credits (25 with render).
ultra_premiumbooleanOur hardest-target pipeline: premium residential IPs, browser fingerprinting and CAPTCHA handling. Includes rendering. Cannot be combined with premium. Cost: 30 credits.
country_codestringGeotarget the request from this country (lowercase ISO 3166-1 alpha-2, e.g.
us, de, jp).device_typestringSend a desktop or mobile user agent and viewport.
session_numberintegerReuse the same proxy IP across requests that share this number (sticky session, ~15 minutes idle timeout).
keep_headersbooleanForward the headers you send us (Cookie, Accept-Language, User-Agent, …) to the target instead of ours. Your API key, Host and proxy headers are never forwarded. Sync endpoint only.
output_formatstringReturn the page as raw HTML, cleaned Markdown, plain text, or JSON (title, meta, links, text).
autoparsebooleanFor supported domains, return structured JSON parsed from the page instead of HTML.
wait_for_selectorstringWith render=true: wait until this CSS selector appears before capturing the page.
callback_urlstringHTTPS URL to POST the finished job to (signed). Falls back to the account webhook set in the dashboard.
{
"url": "string",
"render": false,
"premium": false,
"ultra_premium": false,
"country_code": "us",
"device_type": "desktop",
"session_number": 0,
"keep_headers": false,
"output_format": "html",
"autoparse": false,
"wait_for_selector": "string",
"callback_url": "string"
}Code samples
cURL
curl -X POST "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs" \
-H "Idempotency-Key: <value>" \
-H "Content-Type: application/json" \
-d '{"url":"string","render":false,"premium":false,"ultra_premium":false,"country_code":"us","device_type":"desktop","session_number":0,"keep_headers":false,"output_format":"html","autoparse":false,"wait_for_selector":"string","callback_url":"string"}'TypeScript
const res = await fetch('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs', {
method: 'POST',
headers: {
'Idempotency-Key': '<value>',
'Content-Type': 'application/json',
},
body: JSON.stringify({"url":"string","render":false,"premium":false,"ultra_premium":false,"country_code":"us","device_type":"desktop","session_number":0,"keep_headers":false,"output_format":"html","autoparse":false,"wait_for_selector":"string","callback_url":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://scrapely.15.204.158.166.sslip.io/api/v1/jobs",
headers={
"Idempotency-Key": "<value>",
"Content-Type": "application/json",
},
json={"url": "string", "render": False, "premium": False, "ultra_premium": False, "country_code": "us", "device_type": "desktop", "session_number": 0, "keep_headers": False, "output_format": "html", "autoparse": False, "wait_for_selector": "string", "callback_url": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs", strings.NewReader(`{"url":"string","render":false,"premium":false,"ultra_premium":false,"country_code":"us","device_type":"desktop","session_number":0,"keep_headers":false,"output_format":"html","autoparse":false,"wait_for_selector":"string","callback_url":"string"}`))
req.Header.Set("Idempotency-Key", "<value>")
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://scrapely.15.204.158.166.sslip.io/api/v1/jobs');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Idempotency-Key: <value>', 'Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"url":"string","render":false,"premium":false,"ultra_premium":false,"country_code":"us","device_type":"desktop","session_number":0,"keep_headers":false,"output_format":"html","autoparse":false,"wait_for_selector":"string","callback_url":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs')
req = Net::HTTP::Post.new(uri)
req['Idempotency-Key'] = '<value>'
req['Content-Type'] = 'application/json'
req.body = '{"url":"string","render":false,"premium":false,"ultra_premium":false,"country_code":"us","device_type":"desktop","session_number":0,"keep_headers":false,"output_format":"html","autoparse":false,"wait_for_selector":"string","callback_url":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://scrapely.15.204.158.166.sslip.io/api/v1/jobs"))
.header("Idempotency-Key", "<value>")
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"url\":\"string\",\"render\":false,\"premium\":false,\"ultra_premium\":false,\"country_code\":\"us\",\"device_type\":\"desktop\",\"session_number\":0,\"keep_headers\":false,\"output_format\":\"html\",\"autoparse\":false,\"wait_for_selector\":\"string\",\"callback_url\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
202 Queued.
Example
{
"id": "job_5f0c8a1b2d3e4f56",
"object": {},
"status": "queued",
"url": "string",
"batch_id": "string",
"options": {
"render": false,
"premium": false,
"ultra_premium": false,
"country_code": "us",
"device_type": "desktop",
"session_number": 0,
"keep_headers": false,
"output_format": "html",
"autoparse": false,
"wait_for_selector": "string"
},
"credits": 0,
"status_code": 0,
"duration_ms": 0,
"error": "string",
"callback_url": "string",
"created_at": "2024-01-01T00:00:00Z",
"finished_at": "2024-01-01T00:00:00Z",
"status_url": "string",
"response": {
"status_code": 0,
"content_type": "string",
"final_url": "string",
"headers": {},
"content": "string",
"expires_at": "2024-01-01T00:00:00Z"
}
}Schema
idstringobjectstatusstringurlstringbatch_idstringoptionsobjectOptions shared by sync scrapes, jobs and batches.
Show child parameters
renderbooleanLoad the page in a headless browser and execute its JavaScript before returning the DOM. Cost: 10 credits.
premiumbooleanRoute through the residential proxy pool. Use for sites that block datacenter IPs. Cost: 10 credits (25 with render).
ultra_premiumbooleanOur hardest-target pipeline: premium residential IPs, browser fingerprinting and CAPTCHA handling. Includes rendering. Cannot be combined with premium. Cost: 30 credits.
country_codestringGeotarget the request from this country (lowercase ISO 3166-1 alpha-2, e.g.
us, de, jp).device_typestringSend a desktop or mobile user agent and viewport.
session_numberintegerReuse the same proxy IP across requests that share this number (sticky session, ~15 minutes idle timeout).
keep_headersbooleanForward the headers you send us (Cookie, Accept-Language, User-Agent, …) to the target instead of ours. Your API key, Host and proxy headers are never forwarded. Sync endpoint only.
output_formatstringReturn the page as raw HTML, cleaned Markdown, plain text, or JSON (title, meta, links, text).
autoparsebooleanFor supported domains, return structured JSON parsed from the page instead of HTML.
wait_for_selectorstringWith render=true: wait until this CSS selector appears before capturing the page.
creditsintegerReserved while queued/running; charged when finished; 0 when failed or cancelled.
status_codeintegerduration_msintegererrorstringcallback_urlstringcreated_atstringfinished_atstringstatus_urlstringPoll this.
responseobjectPresent once the job is finished (or failed with a target answer). Kept for 72 hours.
Show child parameters
status_codeintegercontent_typestringfinal_urlstringheadersobjectcontentstring | objectexpires_atstring400
MISSING_PARAM or INVALID_PARAM; param names the culprit.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
401
UNAUTHORIZED: missing, unknown or revoked key.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
402
INSUFFICIENT_CREDITS: nothing was charged.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
409
CONFLICT: idempotent request in flight, or the job is already running/done.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
422
INVALID_PARAM with param: idempotency_key: the key was used for a different request.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
429
RATE_LIMITED or CONCURRENCY_LIMIT. Honour Retry-After.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
500
INTERNAL: our fault, not charged. Quote X-Request-Id.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
GET
https://scrapely.15.204.158.166.sslip.io /api/v1/jobs/{id} Get a job
Status, and response (the page) once finished. Results are kept for 72 hours.
Parameters
idstringpathrequiredThe job id.
Code samples
cURL
curl -X GET "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}"TypeScript
const res = await fetch('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 The job.
Example
{
"id": "job_5f0c8a1b2d3e4f56",
"object": {},
"status": "queued",
"url": "string",
"batch_id": "string",
"options": {
"render": false,
"premium": false,
"ultra_premium": false,
"country_code": "us",
"device_type": "desktop",
"session_number": 0,
"keep_headers": false,
"output_format": "html",
"autoparse": false,
"wait_for_selector": "string"
},
"credits": 0,
"status_code": 0,
"duration_ms": 0,
"error": "string",
"callback_url": "string",
"created_at": "2024-01-01T00:00:00Z",
"finished_at": "2024-01-01T00:00:00Z",
"status_url": "string",
"response": {
"status_code": 0,
"content_type": "string",
"final_url": "string",
"headers": {},
"content": "string",
"expires_at": "2024-01-01T00:00:00Z"
}
}Schema
idstringobjectstatusstringurlstringbatch_idstringoptionsobjectOptions shared by sync scrapes, jobs and batches.
Show child parameters
renderbooleanLoad the page in a headless browser and execute its JavaScript before returning the DOM. Cost: 10 credits.
premiumbooleanRoute through the residential proxy pool. Use for sites that block datacenter IPs. Cost: 10 credits (25 with render).
ultra_premiumbooleanOur hardest-target pipeline: premium residential IPs, browser fingerprinting and CAPTCHA handling. Includes rendering. Cannot be combined with premium. Cost: 30 credits.
country_codestringGeotarget the request from this country (lowercase ISO 3166-1 alpha-2, e.g.
us, de, jp).device_typestringSend a desktop or mobile user agent and viewport.
session_numberintegerReuse the same proxy IP across requests that share this number (sticky session, ~15 minutes idle timeout).
keep_headersbooleanForward the headers you send us (Cookie, Accept-Language, User-Agent, …) to the target instead of ours. Your API key, Host and proxy headers are never forwarded. Sync endpoint only.
output_formatstringReturn the page as raw HTML, cleaned Markdown, plain text, or JSON (title, meta, links, text).
autoparsebooleanFor supported domains, return structured JSON parsed from the page instead of HTML.
wait_for_selectorstringWith render=true: wait until this CSS selector appears before capturing the page.
creditsintegerReserved while queued/running; charged when finished; 0 when failed or cancelled.
status_codeintegerduration_msintegererrorstringcallback_urlstringcreated_atstringfinished_atstringstatus_urlstringPoll this.
responseobjectPresent once the job is finished (or failed with a target answer). Kept for 72 hours.
Show child parameters
status_codeintegercontent_typestringfinal_urlstringheadersobjectcontentstring | objectexpires_atstring401
UNAUTHORIZED: missing, unknown or revoked key.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
404
NOT_FOUND.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
429
RATE_LIMITED or CONCURRENCY_LIMIT. Honour Retry-After.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
500
INTERNAL: our fault, not charged. Quote X-Request-Id.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
DELETE
https://scrapely.15.204.158.166.sslip.io /api/v1/jobs/{id} Cancel a job
Cancels a job that has not started and refunds its credits. A running job cannot be cancelled (409); if it fails, it is free anyway.
Parameters
idstringpathrequiredThe job id.
Code samples
cURL
curl -X DELETE "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}"TypeScript
const res = await fetch('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}', {
method: 'DELETE',
});
const data = await res.json();Python
import requests
res = requests.request(
"DELETE",
"https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'DELETE');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}')
req = Net::HTTP::Delete.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://scrapely.15.204.158.166.sslip.io/api/v1/jobs/{id}"))
.method("DELETE", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 Cancelled and refunded.
Example
{
"id": "job_5f0c8a1b2d3e4f56",
"object": {},
"status": "queued",
"url": "string",
"batch_id": "string",
"options": {
"render": false,
"premium": false,
"ultra_premium": false,
"country_code": "us",
"device_type": "desktop",
"session_number": 0,
"keep_headers": false,
"output_format": "html",
"autoparse": false,
"wait_for_selector": "string"
},
"credits": 0,
"status_code": 0,
"duration_ms": 0,
"error": "string",
"callback_url": "string",
"created_at": "2024-01-01T00:00:00Z",
"finished_at": "2024-01-01T00:00:00Z",
"status_url": "string",
"response": {
"status_code": 0,
"content_type": "string",
"final_url": "string",
"headers": {},
"content": "string",
"expires_at": "2024-01-01T00:00:00Z"
},
"refunded_credits": 0
}Schema
idstringobjectstatusstringurlstringbatch_idstringoptionsobjectOptions shared by sync scrapes, jobs and batches.
Show child parameters
renderbooleanLoad the page in a headless browser and execute its JavaScript before returning the DOM. Cost: 10 credits.
premiumbooleanRoute through the residential proxy pool. Use for sites that block datacenter IPs. Cost: 10 credits (25 with render).
ultra_premiumbooleanOur hardest-target pipeline: premium residential IPs, browser fingerprinting and CAPTCHA handling. Includes rendering. Cannot be combined with premium. Cost: 30 credits.
country_codestringGeotarget the request from this country (lowercase ISO 3166-1 alpha-2, e.g.
us, de, jp).device_typestringSend a desktop or mobile user agent and viewport.
session_numberintegerReuse the same proxy IP across requests that share this number (sticky session, ~15 minutes idle timeout).
keep_headersbooleanForward the headers you send us (Cookie, Accept-Language, User-Agent, …) to the target instead of ours. Your API key, Host and proxy headers are never forwarded. Sync endpoint only.
output_formatstringReturn the page as raw HTML, cleaned Markdown, plain text, or JSON (title, meta, links, text).
autoparsebooleanFor supported domains, return structured JSON parsed from the page instead of HTML.
wait_for_selectorstringWith render=true: wait until this CSS selector appears before capturing the page.
creditsintegerReserved while queued/running; charged when finished; 0 when failed or cancelled.
status_codeintegerduration_msintegererrorstringcallback_urlstringcreated_atstringfinished_atstringstatus_urlstringPoll this.
responseobjectPresent once the job is finished (or failed with a target answer). Kept for 72 hours.
Show child parameters
status_codeintegercontent_typestringfinal_urlstringheadersobjectcontentstring | objectexpires_atstringrefunded_creditsinteger401
UNAUTHORIZED: missing, unknown or revoked key.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
404
NOT_FOUND.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
409
CONFLICT: idempotent request in flight, or the job is already running/done.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
429
RATE_LIMITED or CONCURRENCY_LIMIT. Honour Retry-After.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
500
INTERNAL: our fault, not charged. Quote X-Request-Id.Example
{
"error": {
"code": "MISSING_PARAM",
"message": "string",
"param": "string",
"docs": "/docs/errors#insufficient_credits"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredStable, machine-readable. Branch on this, never on
message.messagestringrequiredHuman-readable; may change.
paramstringThe parameter at fault, when there is one.
docsstringLink to this code on /docs/errors.
Updated