scraperapi-python-sdk

scraperapi-python-sdk is a skill for Claude Code from scraperapi/scraperapi-skills. It costs 202 tokens per session (3,694 once invoked), scanned B, original, MIT.

A reference for using ScraperAPI from Python through its SDK, a library that provides ready-made code for the service. It covers direct requests, batches, supported structured-data endpoints, JavaScript pages, and proxy settings.

In plain words
What is it for?
Writing, debugging, or reviewing Python code that fetches website data with ScraperAPI, including single pages, large URL lists, JavaScript-driven sites, and supported services such as Amazon or Google.
Why use it?
It helps Python developers select between immediate requests and asynchronous jobs based on the workload. It also avoids unsafe key handling and clarifies when special request options are needed.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: built for openclaw.

Part of the scraperapi plugin — 20 skills, 1 MCP server shipped together

Good fit Writing, debugging, or reviewing Python code that fetches website data with ScraperAPI, including single pages, large URL lists, JavaScript-driven sites, and supported services such as Amazon or Google.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/scraperapi/scraperapi-skills/scraperapi-python-sdk
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add scraperapi/scraperapi-skills --skill scraperapi-python-sdk
Clone the repo
git clone --depth 1 https://github.com/scraperapi/scraperapi-skills

Made for: Claude Code.

Or install scraperapi, the plugin that ships this one along with the rest of its 20 skills, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for scraperapi-python-sdk

README.md
[![agentmods](https://agentmods.dev/badge/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk/github.svg)](https://agentmods.dev/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk)
Your own site
<a href="https://agentmods.dev/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk"><img src="https://agentmods.dev/badge/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for scraperapi-python-sdk

Your own site · 80×15
<a href="https://agentmods.dev/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk"><img src="https://agentmods.dev/badge/skills/scraperapi/scraperapi-skills/scraperapi-python-sdk.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 202 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,694 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00202 $0.03694
Opus 5.5 $0.00081 $0.01478
Sonnet 5.5 $0.00040 $0.00739
Haiku 4.5 $0.00020 $0.00369

Measured 10d ago against content hash a4e03e366b5b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

scraperapi-python-sdk scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Sends data to an external URLmediumData exfiltration

A POST to an outside endpoint may be telemetry or may be exfiltration; either way the mod talks to somewhere, and you should know where.

r = requests.post("https://async.scraperapi.com/jobs", json=payload, timeout=10)

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

| 20+ URLs, or single URL that often times out | Async Jobs API — `requests.post()` to `async.scraperapi.com/jobs` |
plugin/skills/scraperapi-python-sdk/SKILL.md · 354 lines

How it starts

The opening of the file, as written. The whole thing — 354 lines — stays where its author put it; the contents beside it link to each section on GitHub.

ScraperAPI — Python SDK Best Practices

Requires: Python 3.10+ (the SDK uses list | tuple annotations, so importing it fails on older versions), pip install scraperapi-sdk, a ScraperAPI API key.

Setup

from scraperapi_sdk import ScraperAPIClient

client = ScraperAPIClient("YOUR_API_KEY")

Replace YOUR_API_KEY with your key from https://dashboard.scraperapi.com. Never commit a real key to source control.

Decision Guide

Pick the right call pattern before writing any code.

Situation Pattern
Single URL, response needed immediately client.get() — synchronous
20+ URLs, or single URL that often times out Async Jobs API — requests.post() to async.scraperapi.com/jobs
Supported platform (Amazon, Google, Walmart, eBay, Redfin) Structured Data endpoint — api.scraperapi.com/structured/<vertical>
Page loads content via JavaScript (React, Vue, Angular) client.get() with render=True
Site blocks standard proxies client.get() with premium=True

Use the sync SDK for simple, single-URL work. For batches, the SDK has ScraperAPIAsyncClient (single jobs only); use raw requests for /batchjobs or when you need control over polling — see Async Jobs.

Basic Usage

# Simple scrape. Returns str for text/HTML, dict for JSON (autoparse, output_format=json), bytes otherwise
html = client.get(url="https://example.com/")

# With parameters
html = client.get(
    url="https://example.com/",
    params={"render": True, "country_code": "us"}
)

Parameter Reference

Rendering

# Render JavaScript before returning HTML
# Use when: page uses React/Vue/Angular, or initial scrape returns empty/partial content
# Cost: 10 credits per request (instead of 1)
html = client.get(url="https://spa-site.com/", params={"render": True})

# Wait for a specific element before capturing (requires render=True)
# Use when: content loads lazily and simple render still misses it
html = client.get(
    url="https://spa-site.com/",
    params={"render": True, "wait_for_selector": ".product-list"}
)

# Capture a screenshot (auto-enables rendering)
html = client.get(url="https://example.com/", params={"screenshot": True})

Read the full file on GitHub · 354 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago Changed · -2 lines a4e03e366b5b
  2. 15d ago Changed · +59 lines · +25 tokens per session 75c842a75118
  3. 3mo ago First seen · 297 lines · 177 tokens per session scan B 01410f5161ca

Subscribe to this mod's changes

scraperapi-python-sdk is a skill published in the GitHub repository scraperapi/scraperapi-skills (11 stars, last pushed 10d ago), licensed MIT. It adds 202 tokens to every session and 3,694 once invoked, about $0.0008 per session on Opus 5.5. A static security scan graded it B with 2 findings (sends data to an external url, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

scraperapi-python-sdk compared with skills from other repositories

scraperapi-python-sdk next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
scraperapi-python-sdkscraperapi/scraperapi-skillsSkill1110d agoMITB202Claude Code
django-patternsaffaan-m/ECCSkill317k4d agoMITA32Claude Code, Kiro
fastapi-patternsaffaan-m/ECCSkill317k4d agoMITA35Claude Code, Kiro
flask-expertJeffallan/claude-skillsSkill13ktodayMITA197Claude Code
django-expertJeffallan/claude-skillsSkill13ktodayMITA96Claude Code
fastapi-expertJeffallan/claude-skillsSkill13ktodayMITA95Claude Code
python-backendyonatangross/orchestkitSkill317todayMITA47Claude Code