spider: Instructions file for Claude Code

CLAUDE.md

spider CLAUDE.md is an instructions file for Claude Code from spider-rs/spider. It costs 4,676 tokens per session, scanned A, original, MIT.

Project instructions for spider-rs/spider, a Rust web-crawling and scraping library. They cover the library’s workspaces, documentation, cloud crawling, and local crawling without an API key.

In plain words
What is it for?
Use them when building, testing, or changing spider, its command-line tool, agent components, worker, utilities, or MCP server.
Why use it?
They give a coding agent the repository-specific commands, structure, and setup details needed to work on the project correctly.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md.

This is spider-rs/spider's own configuration. It tells Claude Code how to work on spider itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything spider configures →

About the project

Spider is a Rust web-crawling and scraping engine that fetches pages, follows links, and uses a headless browser when JavaScript rendering is needed. It is for collecting web data locally or through Spider Cloud, from individual scripts to distributed workers.

spider-rs/spider · 2,833 stars · on GitHub · spider.cloud

Reuse

Borrowing it

Nothing to install: this file belongs to spider-rs/spider. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/spider-rs/spider/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/spider-rs/spider

Made for: Claude Code.

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 spider CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/spider-rs/spider/claude-md/github.svg)](https://agentmods.dev/instructions/spider-rs/spider/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/spider-rs/spider/claude-md"><img src="https://agentmods.dev/badge/instructions/spider-rs/spider/claude-md/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 spider CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/spider-rs/spider/claude-md"><img src="https://agentmods.dev/badge/instructions/spider-rs/spider/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 4,676 This file is loaded in full into every session.
When invoked 4,676 The same file — it is already loaded in full.
Security scan A 0 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.04676 $0.04676
Opus 5.5 $0.01870 $0.01870
Sonnet 5.5 $0.00935 $0.00935
Haiku 4.5 $0.00468 $0.00468

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

Security

Grade A, and why

spider CLAUDE.md scanned grade A with 0 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 1mo 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 628 lines

How it starts

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

Spider - Development Guide

The fastest web crawler and scraper for Rust. Workspace: spider, spider_cli, spider_agent, spider_agent_types, spider_agent_html, spider_utils, spider_worker, spider_mcp.

Quick Reference

docs.rs/spider          # API docs
spider.cloud            # Website & managed cloud
spider.cloud/guides     # Guides
discord.spider.cloud    # Community

Getting Started

[dependencies]
spider = { version = "2", features = ["spider_cloud"] }

Spider Cloud (recommended)

Sign up at https://spider.cloud for a free API key, then:

use spider::tokio;
use spider::website::Website;

#[tokio::main]
async fn main() {
    let mut website = Website::new("https://example.com");
    website.with_spider_cloud("YOUR_API_KEY");

    let mut rx = website.subscribe(16);
    tokio::spawn(async move {
        while let Ok(page) = rx.recv().await {
            println!("{} - {}", page.get_url(), page.get_content());
        }
    });

    website.crawl().await;
    website.unsubscribe();
}

Local crawl (no API key)

let mut website = Website::new("https://example.com");
website.crawl().await;
for link in website.get_links() {
    println!("{link}");
}

Spider Cloud

Spider Cloud offloads crawling to managed infrastructure with anti-bot bypass, proxies, and browser rendering. All Spider Cloud features require features = ["spider_cloud"].

Cloud Modes (SpiderCloudMode)

Mode Description When to use
Proxy (default) Routes HTTP through proxy.spider.cloud General crawling, transparent
Api POST /crawl per page Need API-level control
Fallback Direct fetch first, cloud on 403/429/503 Cost-conscious, mostly unprotected sites
Smart Proxy default, auto-fallback to /scrape with stealth: true on bot detection Production recommended

Configuration

use spider::configuration::{SpiderCloudConfig, SpiderCloudMode};

// Full control via SpiderCloudConfig
let config = SpiderCloudConfig::new("sk-...")
    .with_mode(SpiderCloudMode::Smart)       // proxy + stealth scrape fallback
    .with_return_format("raw");              // "raw" = original HTML

let mut website = Website::new("https://example.com")
    .with_spider_cloud_config(config)
    .build()
    .unwrap();

// Or shorthand — defaults to Proxy mode
let mut website = Website::new("https://example.com");
website.with_spider_cloud("sk-...");

Read the full file on GitHub · 628 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. 1mo ago Changed · -3 lines · -44 tokens per session 05e538463eba
  2. 2mo ago First seen · 631 lines · 4,720 tokens per session scan A b5884e7b668f

Subscribe to this mod's changes

spider CLAUDE.md is an instructions file published in the GitHub repository spider-rs/spider (2,833 stars, last pushed yesterday), licensed MIT. It adds 4,676 tokens to every session, about $0.0187 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

spider CLAUDE.md compared with instructions from other repositories

spider CLAUDE.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
spider CLAUDE.mdspider-rs/spiderInstructions file2.8kyesterdayMITA4,676Claude Code
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode