squirrelscan
GitHub

Website CI gate skill for Claude Code, Codex and Cursor

The website-ci-gate agent skill adds a squirrelscan audit to CI and fails builds on a score threshold, errors or new issues. It covers GitHub Actions.

website-ci-gate is an Agent Skills SKILL.md from squirrelscan that adds a website audit check to CI: a GitHub Actions website audit and preview deploy gate for coding agents. It uses the squirrel CLI in Claude Code, Codex, Cursor and other agents to fail builds on a score threshold, error issues or new issues. It writes pipeline config and picks thresholds from a real baseline. It does not fix issues.

New to skills? Start with the skills overview.

What it does

  • Runs a baseline audit first and chooses thresholds the website passes today, since a gate that is red on day one gets turned off.
  • Writes --fail-on gates: score<N, score:<category><N, severity>=error, errors>0 and warnings>0, quoted so the shell does not read < as redirection.
  • Fails only on new issues with squirrel ci <url> --website <id> --fail-on-new error, using an org API key.
  • Handles exit codes: 2 is a tripped threshold. 3, 4 and 5 (blocked, redirected, unreachable) mean nothing was audited. The job must fail on any non-zero exit.
  • Writes a GitHub Actions workflow with the official action or the plain CLI, plus the GitLab equivalent.
  • Audits preview deploys (Vercel, Netlify, Cloudflare Pages) after the deploy is ready.
  • Shows you the diff before editing a workflow file, and tells you which secret to create instead of adding it.
  • Keeps SQUIRRELSCAN_API_KEY in the CI secret store, never in the repo.

Questions it answers

  • Add squirrelscan to GitHub Actions
  • Fail CI on website audit errors
  • Gate preview deploys on audit scores
  • How do I fail a build when my website’s score drops?
  • What score threshold should I start with?
  • What do squirrel exit codes 2, 3, 4 and 5 mean in CI?
  • How do I fail only on new issues?
  • How do I audit a preview deployment URL in a pull request?

Install

Works with any Agent Skills tool (Claude Code, Codex, Cursor, Gemini CLI, Amp and others):

npx skills add squirrelscan/skills --skill website-ci-gate

The plugin installs all the skills and the hosted squirrelscan MCP server:

/plugin marketplace add squirrelscan/skills
/plugin install squirrelscan@squirrelscan

npx skills add puts the skill in .agents/skills/. To add the MCP server too, configure it in ~/.codex/config.toml. See squirrelscan for Codex.

Run npx skills add, then use the Cursor plugin from the skills repository or the one-click MCP link. See squirrelscan for Cursor.

Gemini CLI, GitHub Copilot, Amp and other Agent Skills tools: run npx skills add, then add the MCP server. See coding agents.

Requirements

The squirrel CLI installed and in your PATH, or the hosted squirrelscan MCP server connected (https://mcp.squirrelscan.com/mcp). Check the CLI with squirrel --version. Setup steps are in install and MCP clients.

Install the CLI on macOS or Linux:

curl -fsSL https://install.squirrelscan.com | bash

Example prompts

Paste one of these into your coding agent:

Add squirrelscan to GitHub Actions for https://staging.example.com
Fail CI on website audit errors and score drops below 85
Gate preview deploys on audit scores

The agent runs a baseline and proposes thresholds. It shows you the workflow diff and tells you which secret to create. Then it checks the job is green on main.

How it works

  1. Run a baseline locally with squirrel audit at --level quick and read the scores.
  2. Pick the gate: absolute --fail-on thresholds, or squirrel ci with --fail-on-new for new issues.
  3. Handle exit codes so 3, 4 and 5 fail the job.
  4. Write the workflow with the official action or the plain CLI, after showing you the diff.
  5. Stop when the job is green on main and you have seen it go red on a deliberate regression. Document the thresholds next to the workflow.

Source on GitHub

Type to search…

↑↓ navigate↵ openesc close