API Documentation
Everything you need to integrate ScrapeLens into your applications. Get started in minutes with our comprehensive API reference.
Overview
ScrapeLens is a powerful web scraping API that enables you to extract data from any website with ease. Our service handles complex challenges like JavaScript rendering and proxy rotation automatically.
Authentication
Scrapelens uses bearer token authentication to secure API requests. Include your API key in the Authorization header of each request using the format Bearer YOUR_API_KEY. You can find and manage your API keys in the Scrapelens Dashboard. Keep your API key secure and never expose it in client-side code or public repositories.
Authorization: Bearer sk-1234567890abcdef...
curl -X POST https://api.scrapelens.com/v1/scrape \
-H "Authorization: Bearer sk-1234567890abcdef..." \
-H "Content-Type: application/json" \
-d '{
"url": "https://www.scrapingcourse.com/javascript-rendering"
}'
Quick Start
Scraping a web page with ScrapeLens is a simple process. Send a POST request to the root endpoint, specifying the url you want to scrape in the request body. JavaScript rendering and rotating proxies are handled automatically for you.
curl -X POST https://api.scrapelens.com \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://www.scrapingcourse.com/javascript-rendering"
}'
| Field | Required | Description |
|---|---|---|
| url | Required | The URL to scrape |
| script | Optional | Specify a request script to interract with the page before capturing the document's content. Checkout the script section to learn more. |
| output | Optional | Description of the data to extract from the page. You can learn more about data extraction in the dedicated section. |
If the output field is omitted, the full HTML content of the page will be returned in the response.
Pricing
Simple, transparent pricing based on API credits. No monthly fees, no hidden costs. Pay only for what you use with our flexible credit system.
Free Tier
New users get 1,000 free credits (50 API requests) to test our service. No credit card required to get started!