smart-scraper

smart-scraper is a skill for Claude Code, Codex from Ertinox7711/SGRR-AGI-V2. It costs 38 tokens per session (663 once invoked), scanned A, original, MIT.

A local web-scraping workflow that turns a URL or TikTok profile into structured JSON using an on-device language model, with an option to post the result to Discord.

In plain words
What is it for?
Use it to extract selected facts from web pages or TikTok profiles and optionally send the results to a Discord channel.
Why use it?
It removes the need to copy information from pages by hand or pay for a hosted extraction API. It can also handle JavaScript-heavy pages when browser rendering is needed.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to extract selected facts from web pages or TikTok profiles and optionally send the results to a Discord channel.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ertinox7711/sgrr-agi-v2/smart-scraper
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 Ertinox7711/SGRR-AGI-V2 --skill smart-scraper
Clone the repo
git clone --depth 1 https://github.com/Ertinox7711/SGRR-AGI-V2

Made for: Claude Code, Codex.

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 smart-scraper

README.md
[![agentmods](https://agentmods.dev/badge/skills/ertinox7711/sgrr-agi-v2/smart-scraper/github.svg)](https://agentmods.dev/skills/ertinox7711/sgrr-agi-v2/smart-scraper)
Your own site
<a href="https://agentmods.dev/skills/ertinox7711/sgrr-agi-v2/smart-scraper"><img src="https://agentmods.dev/badge/skills/ertinox7711/sgrr-agi-v2/smart-scraper/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 smart-scraper

Your own site · 80×15
<a href="https://agentmods.dev/skills/ertinox7711/sgrr-agi-v2/smart-scraper"><img src="https://agentmods.dev/badge/skills/ertinox7711/sgrr-agi-v2/smart-scraper.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 663 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. 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.00038 $0.00663
Opus 5 $0.00019 $0.00331
Sonnet 5 $0.00008 $0.00133
Haiku 4.5 $0.00004 $0.00066

Measured 3d ago against content hash 838ca8cf00b8, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

smart-scraper scanned grade A with 1 finding 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 3d 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.

Makes network callslowCapability

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

curl -s -X POST "https://discord.com/api/v10/channels/<CHANNEL_ID>/messages" \
skills/smart-scraper/SKILL.md · 78 lines

How it starts

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

/smart-scraper

Scrape a URL → extract structured JSON → optionally send to Discord.

Uses C:\Users\YOU\Documents\SMART_SCRAPER\smart_scraper.py. Zero API cost. Ollama local. Playwright stealth + OpenCV captcha solver built-in.

Step 1 — Parse intent

From the user message, extract:

  • URL — the page to scrape
  • PROMPT — what to extract (natural language)
  • JS — use --js flag if site is TikTok / React / SPA
  • SEND — true if user says "envoie", "send", "balance sur Discord"
  • CHANNEL_ID — Discord channel ID if provided

If URL or PROMPT missing, ask once. Don't ask both in the same question.

Step 2 — Run scraper

cd "C:\Users\YOU\Documents\SMART_SCRAPER"
C:\Python314\python.exe smart_scraper.py scrape <URL> "<PROMPT>" [--js]

For TikTok / Instagram / JS-heavy sites → always add --js.

Capture stdout as JSON. Show result to user formatted.

Step 3 — Send to Discord (if SEND=true)

Use the Discord API v10 directly with DISCORD_BOT_TOKEN from env.

Format as embed for readability:

curl -s -X POST "https://discord.com/api/v10/channels/<CHANNEL_ID>/messages" \
  -H "Authorization: Bot $DISCORD_BOT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "embeds": [{
      "title": "Scrape result — <URL>",
      "description": "```json\n<JSON_RESULT>\n```",
      "color": 5763719
    }]
  }'

Truncate JSON to 3900 chars max (Discord embed limit).

Step 4 — Report

Show:

  • Extracted data (formatted)
  • If sent: "✅ Envoyé sur Discord (message ID: ...)"
  • If captcha was solved: mention it

Supported modes

Command What it does
/smart-scraper https://tiktok.com/@x "bio et followers" Scrape TikTok profile
/smart-scraper https://site.com "prix des produits" Scrape any page
/smart-scraper https://site.com "titres" envoie sur Discord Scrape + send
/smart-scraper search "best AI tools" "noms et descriptions" DDG search + scrape

Error handling

  • Ollama not running → ollama serve then retry
  • Captcha not solved → retry with different timing, report if still fails
  • Discord 401 → check DISCORD_BOT_TOKEN in env
  • Site blocks → already handled by Playwright stealth fallback

Read the full file on GitHub · 78 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. 3d ago First seen · 78 lines · 38 tokens per session scan A 838ca8cf00b8

Subscribe to this mod's changes

smart-scraper is a skill published in the GitHub repository Ertinox7711/SGRR-AGI-V2 (1 stars, last pushed 4d ago), licensed MIT. It adds 38 tokens to every session and 663 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-09.