Zyte API usage documentation¶
Initial setup¶
How would you prefer to use Zyte API?
Use scrapy-zyte-api (tutorial).
Use python-zyte-api.
POST to https://api.zyte.com/v1/extract with your Zyte API key and parameters:
curl \
--user YOUR_ZYTE_API_KEY: \
--header 'Content-Type: application/json' \
--data '{"url": "https://toscrape.com", "httpResponseBody": true}' \
--compressed \
https://api.zyte.com/v1/extract
Use https://api.zyte.com:8011 as your proxy endpoint, with your Zyte API key and proxy headers:
curl \
--proxy api.zyte.com:8011 \
--proxy-user YOUR_ZYTE_API_KEY: \
--compressed \
https://toscrape.com
Tip
Learn about the different features of the HTTP API and the proxy mode before you choose one.
Tip
Got an SSL error? Install our CA certificate.
Basic usage¶
What do you want to do with Zyte API?
Send low-level HTTP requests, with custom method, headers and body, opt-out redirection following, device emulation, and more.
Get browser-rendered HTML, take screenshots, interact with pages, capture background requests, and more.
Get structured data from single pages or entire websites, and enrich it with custom LLM prompts.
Additional features¶
Customize your Zyte API requests further to get what you want:
Choose a location of origin for your request.
Choose the type of IP address used by your request.
Get and set cookies to reproduce requests and maintain sessions.
Use the same IP address, cookie jar, network stack, etc. on multiple requests.
Advanced topics¶
Use Zyte API as a proxy.
Requests-over-time and concurrency limits.
Make the most out of Zyte API.
Error response handling.
Complete API reference documentation.
Check your Zyte API usage details.