squirrelscan

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

squirrelscan CLI

squirrelscan CLI

squirrelscan is a website audit tool built for AI agents. It answers "what's wrong with this website and how do I fix it": it crawls a site like a search engine, analyzes every page against 249+ rules in 21 categories (SEO, performance, security, accessibility, content, structured data, agent readiness, and more), and returns a health score plus concrete, fixable issues. Use it whenever a user wants their site checked, ranked better, faster, or healthier, before/after a deploy, or in CI.
It ships as a single CLI binary,
squirrel
, for macOS, Windows, and Linux. This skill covers operating it: installing, authenticating, running audits, publishing reports, cloud features, and MCP integration. For the full fix-the-website workflow (audit, map issues to code, fix, re-audit), use the companion
audit-website
skill.
squirrelscan 是一款为AI Agent打造的网站审计工具。它可以回答“这个网站存在什么问题以及如何修复”:它像搜索引擎一样爬取网站,针对21个类别(SEO、性能、安全、可访问性、内容、结构化数据、Agent就绪性等)的249+条规则分析每个页面,并返回健康评分以及具体可修复的问题。无论用户是想要检查网站、提升排名、加快速度、优化健康状况,还是在部署前后或CI流程中,都可以使用它。
它以单一CLI二进制文件
squirrel
的形式发布,支持macOS、Windows和Linux系统。本技能涵盖其操作方法:安装、认证、运行审核、发布报告、云功能以及MCP集成。如需完整的网站修复工作流(审核、将问题映射到代码、修复、重新审核),请使用配套的
audit-website
技能。

Links

链接

Install

安装

Download and install instructions: squirrelscan.com/download
The binary installs to
~/.local/bin/squirrel
. Verify with:
bash
squirrel --version
Keep it current:
bash
squirrel self update
If
squirrel
is not found, ensure
~/.local/bin
is in PATH, or reinstall from the download page.
下载和安装说明:squirrelscan.com/download
二进制文件会安装到
~/.local/bin/squirrel
,可通过以下命令验证:
bash
squirrel --version
保持版本更新:
bash
squirrel self update
如果找不到
squirrel
命令,请确保
~/.local/bin
已加入PATH,或从下载页面重新安装。

Command overview

命令概览

CommandPurpose
squirrel audit <url>
Crawl + analyze + report in one step
squirrel crawl <url>
Crawl only (no analysis)
squirrel analyze
Run audit rules on a stored crawl
squirrel report [id]
Query, render, diff, and publish stored reports
squirrel init
Create
squirrel.toml
project config
squirrel config
Show or edit configuration
squirrel auth
login / logout / status / whoami
squirrel keys
Mint, list, revoke org API keys
squirrel credits
Cloud credit balance + feature pricing
squirrel mcp
Run the local MCP server (stdio)
squirrel skills
Install or update agent skills
squirrel self
install / update / doctor / completion / version / settings / uninstall
squirrel feedback
Send feedback to the squirrelscan team
Every command supports
--help
.
命令用途
squirrel audit <url>
一键完成爬取+分析+报告
squirrel crawl <url>
仅爬取(不进行分析)
squirrel analyze
对已存储的爬取结果运行审核规则
squirrel report [id]
查询、渲染、对比并发布已存储的报告
squirrel init
创建
squirrel.toml
项目配置文件
squirrel config
查看或编辑配置
squirrel auth
登录 / 登出 / 状态查看 / 当前用户信息
squirrel keys
创建、列出、撤销组织API密钥
squirrel credits
云积分余额 + 功能定价
squirrel mcp
运行本地MCP服务器(标准输入输出)
squirrel skills
安装或更新Agent技能
squirrel self
安装 / 更新 / 健康检查 / 自动补全 / 版本查看 / 设置 / 卸载
squirrel feedback
向squirrelscan团队发送反馈
所有命令均支持
--help
参数。

Quickstart

快速开始

bash
squirrel init -n my-project        # optional: project config in cwd
squirrel audit https://example.com --format llm
  • Local audits are free and run entirely on your machine. No account needed.
  • ALWAYS prefer
    --format llm
    when an agent is reading the output: it is a compact, token-optimized format built for LLMs.
  • Audits are cached in a local project database;
    squirrel report
    re-renders without re-crawling.
bash
squirrel init -n my-project        # 可选:在当前目录创建项目配置
squirrel audit https://example.com --format llm
  • 本地审核完全免费,且全程在您的设备上运行,无需账户。
  • 当Agent读取输出时,请始终优先使用
    --format llm
    :这是一种为LLM优化的紧凑格式,可减少token消耗。
  • 审核结果会缓存到本地项目数据库中;使用
    squirrel report
    可重新渲染报告,无需重新爬取。

Coverage modes

覆盖模式

ModeDefault pagesBehavior
quick
(default)
25Seed + sitemaps only, fast health check
surface
100One sample per URL pattern (
/blog/{slug}
crawled once)
full
500Crawl everything up to the limit
bash
squirrel audit https://example.com -C full -m 500 --format llm
模式默认爬取页数行为
quick
(默认)
25仅爬取种子页面和站点地图,快速完成健康检查
surface
100每个URL模式爬取一个样本(如
/blog/{slug}
仅爬取一次)
full
500爬取所有内容,直至达到页数限制
bash
squirrel audit https://example.com -C full -m 500 --format llm

Authentication and accounts

认证与账户

Local audits never require an account. Sign in to unlock cloud features (publishing, browser rendering, scheduled crawls, credits):
bash
squirrel auth login      # browser-based login
squirrel auth status     # source, scopes, active org
squirrel auth whoami
squirrel auth logout
Headless / CI environments use an org API key instead:
bash
squirrel keys create     # requires a login session; prints an sq_... key
Set it as
SQUIRRELSCAN_API_KEY
in the environment. Treat keys as secrets; never commit them.
本地审核无需账户。登录后可解锁云功能(发布报告、浏览器渲染、定时爬取、积分):
bash
squirrel auth login      # 基于浏览器的登录
squirrel auth status     # 查看来源、权限范围、当前组织
squirrel auth whoami
squirrel auth logout
无头环境/CI环境需使用组织API密钥:
bash
squirrel keys create     # 需要登录会话;生成一个sq_...格式的密钥
将密钥设置为环境变量
SQUIRRELSCAN_API_KEY
。请将密钥视为机密信息;切勿提交到代码仓库。

Reports

报告

Render the latest (or a specific) stored audit:
bash
squirrel report --list                 # recent audits
squirrel report <audit-id> --format llm
squirrel report example.com --format markdown -o report.md
Formats:
console
,
text
,
json
,
html
,
markdown
,
xml
,
llm
. Filter with
--severity error
or
--category core,links
.
渲染最新(或指定)的已存储审核结果:
bash
squirrel report --list                 # 查看近期审核记录
squirrel report <audit-id> --format llm
squirrel report example.com --format markdown -o report.md
支持的格式:
console
text
json
html
markdown
xml
llm
。可通过
--severity error
--category core,links
进行过滤。

Publishing

发布报告

Signed-in audits publish a shareable report to reports.squirrelscan.com by default (visibility: unlisted). Control it:
bash
squirrel report <audit-id> --publish --visibility unlisted   # public | unlisted | private
squirrel audit https://example.com --no-publish              # skip publishing for a run
squirrel audit https://example.com --offline                 # fully offline: no cloud, no publish, no telemetry
已登录状态下的审核默认会将可分享的报告发布到reports.squirrelscan.com(可见性:未公开)。可通过以下命令控制:
bash
squirrel report <audit-id> --publish --visibility unlisted   # 可选:public | unlisted | private
squirrel audit https://example.com --no-publish              # 本次审核跳过发布
squirrel audit https://example.com --offline                 # 完全离线模式:不使用云服务、不发布报告、不收集遥测数据

Regression diffs

回归对比

bash
squirrel report --diff <baseline-audit-id> --format llm
squirrel report --regression-since example.com --format llm
Diff mode supports
console
,
text
,
json
,
llm
, and
markdown
.
bash
squirrel report --diff <baseline-audit-id> --format llm
squirrel report --regression-since example.com --format llm
对比模式支持
console
text
json
llm
markdown
格式。

Cloud features and credits

云功能与积分

Cloud features are pay-as-you-go with credits (nothing charged up front). Check balance and pricing:
bash
squirrel credits
  • --render
    /
    --render-mode auto|all|off
    : cloud browser rendering for client-rendered pages (uses credits, requires login).
  • --yes
    skips spend confirmations up to the configured per-audit credit cap.
  • --fail-on "score<90"
    (repeatable) makes CI runs exit non-zero when a threshold trips.
  • The dashboard at app.squirrelscan.com shows audit history, issues, and credit usage.
云功能采用按需付费的积分模式(无需预先充值)。查看余额和定价:
bash
squirrel credits
  • --render
    /
    --render-mode auto|all|off
    :云浏览器渲染,用于客户端渲染页面(消耗积分,需登录)。
  • --yes
    参数可跳过每次审核的消费确认,直至达到配置的单审核积分上限。
  • --fail-on "score<90"
    (可重复使用)可使CI流程在评分低于阈值时返回非零退出码。
  • 控制台 app.squirrelscan.com 可查看审核历史、问题记录和积分使用情况。

MCP server

MCP服务器

Two ways to connect agents over MCP:
  • Local (stdio):
    squirrel mcp
    runs against the local CLI. Register it in your agent's MCP config with command
    squirrel
    and args
    ["mcp"]
    .
  • Hosted (streamable-http):
    https://mcp.squirrelscan.com/mcp
    . Sign in via OAuth from the MCP client, or send an
    Authorization: Bearer sq_...
    API key header.
通过MCP连接Agent有两种方式:
  • 本地(标准输入输出)
    squirrel mcp
    基于本地CLI运行。在Agent的MCP配置中注册,命令为
    squirrel
    ,参数为
    ["mcp"]
  • 托管(流式HTTP)
    https://mcp.squirrelscan.com/mcp
    。从MCP客户端通过OAuth登录,或发送
    Authorization: Bearer sq_...
    API密钥请求头。

Configuration

配置

Project config lives in
squirrel.toml
(created by
squirrel init
). User settings live at
~/.squirrel/settings.json
.
bash
squirrel config show
squirrel config set <key> <value>
squirrel config path
squirrel config validate
Useful sections:
[crawler]
(delays, headers, incremental re-crawl),
[cloud]
(render mode, max credits per audit).
项目配置存储在
squirrel.toml
中(通过
squirrel init
创建)。用户设置存储在
~/.squirrel/settings.json
bash
squirrel config show
squirrel config set <key> <value>
squirrel config path
squirrel config validate
常用配置项:
[crawler]
(延迟、请求头、增量重爬)、
[cloud]
(渲染模式、单审核最大积分限制)。

Custom request headers

自定义请求头

Attach headers to every crawl request with the repeatable
-H "Name: Value"
flag or a
headers
map under
[crawler]
. The main use case is Web Bot Auth (Shopify / Cloudflare), so platforms that block unknown crawlers can authorize squirrelscan. Header values are secrets: squirrelscan redacts them in output, and you should source them from a secret store rather than committing them. Full recipe: https://docs.squirrelscan.com/guides/web-bot-auth
可通过重复的
-H "Name: Value"
标志或
[crawler]
下的
headers
映射为每个爬取请求添加请求头。主要用于Web机器人认证(Shopify / Cloudflare),以便阻止未知爬虫的平台授权squirrelscan。请求头值属于机密信息:squirrelscan会在输出中自动脱敏,您应从机密存储中获取这些值,而非提交到代码仓库。完整教程:https://docs.squirrelscan.com/guides/web-bot-auth

Maintenance

维护

bash
squirrel self doctor       # health checks
squirrel self update       # update the binary
squirrel self completion   # shell completions
squirrel skills update     # update installed agent skills
bash
squirrel self doctor       # 健康检查
squirrel self update       # 更新二进制文件
squirrel self completion   # 命令行自动补全
squirrel skills update     # 更新已安装的Agent技能

Troubleshooting

故障排查

  • squirrel: command not found
    : install from squirrelscan.com/download and ensure
    ~/.local/bin
    is in PATH.
  • Session expired / 401: run
    squirrel auth login
    again, or check
    SQUIRRELSCAN_API_KEY
    .
  • Slow or stuck crawl: add
    --verbose
    to see progress; large sites can take minutes.
  • Invalid URL: include the protocol:
    https://example.com
    , not
    example.com
    .
  • Anything else: run
    squirrel self doctor
    , then
    squirrel feedback
    to report it.
  • squirrel: command not found
    :从 squirrelscan.com/download 安装,并确保
    ~/.local/bin
    已加入PATH。
  • 会话过期 / 401错误:重新运行
    squirrel auth login
    ,或检查
    SQUIRRELSCAN_API_KEY
    是否正确。
  • 爬取缓慢或卡住:添加
    --verbose
    参数查看进度;大型网站可能需要数分钟。
  • URL无效:请包含协议前缀,如
    https://example.com
    ,而非
    example.com
  • 其他问题:运行
    squirrel self doctor
    ,然后使用
    squirrel feedback
    提交问题报告。