Skip to content

Web scraping API for every
Scrape.ly workflow

Use a single API client to run scrapers, manage jobs, monitor progress, and fetch structured results from Scrape.ly.

01-API-First Platform

Built to control scraping from code

Scrape.ly gives developers a reliable control layer for web scraping, automation, and structured data extraction.

Run scrapers with one call

Start sync or async scraping jobs, pass custom input, and follow the run until completion.

Structured results

Fetch clean outputs from datasets, tables, files, or key-value stores in formats your team already uses.

Developer-friendly clients

Use JavaScript, Python, or direct REST requests to connect Scrape.ly with your product or internal stack.

Secure by default

Authenticate with API tokens, manage access safely, and scale requests with clear limits and predictable behavior.

02-Quick start

Your first web scraping API call

One request starts a scraper, waits for it and returns the data. Below is a real call to the Website Content Crawler and the response it returned.

  1. Step 1

    Get an API token

    Create a free account and copy a token from Settings → API & Integrations. Send it in the Authorization header as a Bearer token.

  2. Step 2

    Send the scraper its input

    POST the input as JSON to the Actor’s run-sync-get-dataset-items endpoint. The body is the input itself, the same JSON the Actor page shows.

  3. Step 3

    Read structured JSON

    The response is the run’s dataset items as a JSON array. Add ?format=csv, xlsx or jsonl to the URL for another format.

Request
curl -X POST "https://api.scrape.ly/v2/actors/querystone~website-content-crawler/run-sync-get-dataset-items" \
-H "Authorization: Bearer $SCRAPELY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"startUrls":[{"url":"https://example.com"}],"maxCrawlPages":1}'
Response · 200
[
{
"url": "https://example.com/",
"crawl": {
"loadedUrl": "https://example.com/",
"loadedTime": "2026-10-28T00:13:20.416Z",
"depth": 0,
"httpStatusCode": 200,
"contentLengthBytes": 577,
"contentType": "text/html; charset=utf-8"
},
"metadata": {
"canonicalUrl": "https://example.com/",
"title": "Example Domain",
"languageCode": "en"
},
"text": "This domain is for use in documentation examples without needing permission. This is not a service; avoid relying on it for testing and monitoring purposes.",
"markdown": "This domain is for use in documentation examples without needing permission. This is not a service; avoid relying on it for testing and monitoring purposes."
}
]

Response from a run on 28 October 2026, with the page’s HTTP headers left out. A synchronous call waits up to 90 seconds; longer runs keep going and are read asynchronously.

03-How it works

How the scraper API works

One REST API under /v2 runs every scraper in the Store. Start a run, wait for it or get a webhook, then read the results in the format you need.

Read the API guide

Authentication

Every request sends a token as Authorization: Bearer. Tokens in the query string are ignored. Extra API keys can be limited to scopes, specific Actors, an IP allowlist and a daily spending cap.

API keys & permissions →

Synchronous runs

run-sync-get-dataset-items starts a run and answers with its results in the same response, for jobs that finish within 90 seconds. A slower run returns 408 with its run ID and keeps going.

Run an Actor synchronously →

Asynchronous runs

POST /v2/actors/{actorId}/runs returns a run ID right away. Wait with waitForFinish, then read the run’s dataset. An Idempotency-Key header makes a retried start return the same run.

Start a run →

Webhooks

Get a POST when a run succeeds, fails, aborts or times out. Failed deliveries are retried up to five times, and a payload template shapes the body your endpoint receives.

Webhooks API →

Output formats

Read results as JSON, JSONL, CSV, Excel, XML, RSS, HTML or PDF from the same endpoint, and pick fields, skip empty items and page through large datasets with offset and limit.

Get dataset items →

Rate limits and errors

The API allows 1,000 requests a minute per account, 5,000 for storage. Errors come back as JSON with a type and a message; retry 429 and 503 with backoff, as the clients do.

Limits and error codes →

Any language

Call the REST API from any language that speaks HTTP, or use the official JavaScript/TypeScript and Python clients, which add retries, pagination helpers and run waiting.

Python client →

AI agents over MCP

The hosted MCP server lets Claude, Cursor, VS Code and other MCP clients search the Store, run scrapers and read the results from your account.

MCP server →
04-API Clients

Run Scrape.ly from JavaScript or Python

Use Scrape.ly’s API clients to trigger scrapers, pass inputs, monitor runs, and fetch structured results from your own code.

from scrapely_client import ScrapelyClient
client = ScrapelyClient('YOUR_TOKEN', api_url='https://api.scrape.ly')
run = client.actor('username/my-actor').call(
run_input={'url': 'https://example.com/products'}
)
for item in client.dataset(run.default_dataset_id).iterate_items():
print(item)

Scheduling & Monitoring

Run scrapers hourly, daily, weekly, or on custom intervals with built-in status tracking.

Proxy Reliability

Use smart proxy routing to reduce blocks, avoid rate limits, and keep requests moving.

Scalable Runs

Start small and scale up as your data needs grow without rebuilding your scraping stack.

//06-FAQ\\

Common questions about Scrape.ly APIs

Quick answers about using Scrape.ly's APIs, available data, setup, and legal usage.

Got more questions?Reach out to us


A web scraping API runs the scraping for you and returns the data over HTTP. On Scrape.ly every scraper in the Store is an Actor with its own input: you send that input as JSON, the Actor collects the data in the cloud, and you read structured results as JSON, CSV or Excel.

//From the blog\\

Latest articles

All articles

The internet is full of data.
Start owning yours.

Scrape.ly gives you the infrastructure, the tooling, and the team to extract, process, and operationalize web data at any scale. Setup takes minutes.

No credit card. No setup calls.