Scraping API
Fetch protected pages, scrape URL lists, crawl and map whole sites, and search Google. Send a target, get clean Markdown, HTML, JSON or a screenshot back.
| Base URL: | https://scraping-api.datafuel.ai/ |
| Key: | Your scraping key, df_key_…, in the X-API-Key header. See Authentication. |
| Billing: | Credits per task, charged when it is queued and refunded if it fails. See Pricing and credits. |
Your first request
Fetch one page as Markdown:
Shell
⟦ curl https://scraping-api.datafuel.ai/api/v1/task \
--request POST \
--header "Content-Type: application/json" \
--header "X-API-Key: df_key_your_key_here" \
--data '{
"type": "unlocker",
"proxy_type": "Basic",
"attributes": {
"url": "https://example.com/product/123",
"result_format": "markdown"
}
}'
⟧ The call blocks until the page is fetched and returns it in result.data. Set your client timeout to at least 120 seconds.
What you can do
| Endpoint | Use it for | Guide |
|---|---|---|
POST /task: | One page, one Google search | Scrape a page, Search Google |
POST /job: | A list of URLs you already have | Scrape a URL list |
POST /map: | Every URL of a site, without the content | Map a site |
POST /crawl: | A whole site or section, with the content | Crawl a site |
Not sure which one fits? Choosing an endpoint compares them side by side.