Skip to content
Login Sign up

Advanced

Pass headers as a URL-encoded JSON object via custom_headers:

Terminal window
curl "https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://api.example.com&custom_headers=%7B%22Authorization%22%3A%22Bearer%20abc123%22%7D"

Useful when the target expects bearer tokens, X-Requested-With: XMLHttpRequest, or locale preferences.

Set cookies inline via custom_cookies:

cookie_name=value; other_name=value2

URL-encoded:

Terminal window
curl "https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://example.com&custom_cookies=session_id%3Dabc%3B%20locale%3Den-US"

For cookies across multiple requests, prefer session_id, cookies set by the server will persist automatically.

Switch method with method. Pass the body as the request body.

Terminal window
curl -X POST \
"https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://api.example.com/users&method=POST" \
-H "Content-Type: application/json" \
-d '{"email":"user@example.com","plan":"pro"}'

PUT is identical with method=PUT.

Return a full-page PNG instead of HTML:

Terminal window
curl "https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://example.com&render_js=1&screenshot=1" \
-o screenshot.png

Options:

  • screenshot_full_page=1, capture beyond the viewport.
  • screenshot_selector=<css>, capture just one element.

For PDFs, images, or any non-text response, add binary_response=1. The scraper streams the binary payload through:

Terminal window
curl "https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://example.com/file.pdf&binary_response=1" \
-o file.pdf

Some targets flag the default browser fingerprint. You can disable stealth mode for debugging (not recommended in production):

Terminal window
curl "https://scrape.shifter.io/v1?api_key=YOUR_API_KEY&url=https://example.com&disable_stealth=1&render_js=1"

All flags compose. A real-world request looks like:

Terminal window
curl "https://scrape.shifter.io/v1?\
api_key=YOUR_API_KEY&\
url=https://shop.example.com/products/42&\
render_js=1&\
wait_for_css=.price&\
session_id=cart-001&\
premium_proxy=1&\
country=us&\
extract_rules=%7B%22price%22%3A%7B%22selector%22%3A%22.price%22%2C%22output%22%3A%22text%22%7D%7D"

One successful request, one credit.

  • Errors & limits, what codes mean and how retries interact with credits.
  • FAQ, credits, failures, custom scripts.