Skip to content

Latest commit

 

History

History
153 lines (111 loc) · 4.4 KB

README.md

File metadata and controls

153 lines (111 loc) · 4.4 KB

Flightcheck

Pre-launch website audit CLI and library.

Flightcheck crawls a site and checks what is wrong before go-live: missing meta tags, accessibility issues, weak security headers, DNS settings, robots.txt and sitemap mismatches, exposed secrets, and more. Every run produces:

  • crawl data (*-raw.json)
  • a structured report (*-report.json) — analysis facts + findings
  • a plain-language Markdown report (*-report.md) rendered from that JSON

Install

In a Node.js project (recommended):

npm install @eightmedia/flightcheck
# or: pnpm add @eightmedia/flightcheck
# or: yarn add @eightmedia/flightcheck

Requires Node.js 22.12+. The package is ESM-only ("type": "module").

Use in a Node project

CLI via npm scripts

Add scripts to your package.json:

{
  "scripts": {
    "flightcheck": "flightcheck",
    "flightcheck:analyze": "flightcheck-analyze"
  }
}

Then:

npm run flightcheck -- https://example.com
npm run flightcheck:analyze -- ./flightcheck/20260618.1413-example.com-raw.json

Or call the binaries directly after install:

npx flightcheck https://example.com
npx flightcheck-analyze ./flightcheck/20260618.1413-example.com-raw.json

Without adding it to a project:

npx @eightmedia/flightcheck https://example.com

Programmatic API

import { runChecks } from "@eightmedia/flightcheck";

const { outputs, results } = await runChecks({
  startUrl: "https://example.com",
});

const report = outputs.analyze?.report;
console.log(report?.analysis.pagesAnalyzed, report?.findings.length);

// Write paths (when analyze ran):
console.log(outputs.analyze?.reportPath);
console.log(outputs.analyze?.reportJsonPath);

Lower-level entry points:

import { runCrawlCheck, runAnalyzeCheck } from "@eightmedia/flightcheck";
import { listChecks } from "@eightmedia/flightcheck/checks";

See docs/check-api.md for the modular check API.

How it works

  1. Crawl & checks — pages are scanned and modular checks run (SEO, a11y, security, infra, agent readiness).
  2. Analyze — issues become a flat findings[] list. Each finding has severity, category, scope, and a short title/message. Site facts (stack, DNS, …) live under analysis.
  3. Reports — *-report.json is the source of truth for tools; *-report.md is the same data in readable form (grouped by severity for humans).
Output Audience Purpose
*-raw.json Machine Source data from all checks
*-report.json Machine / tools analysis + flat findings[]
*-report.md Human Plain-language report from the JSON

See docs/analyze.md for the report schema.

Quick start

npm install @eightmedia/flightcheck
npx flightcheck https://example.com

This writes timestamped files in ./flightcheck/, for example:

  • ./flightcheck/20260618.1413-example.com-raw.json
  • ./flightcheck/20260618.1413-example.com-report.json
  • ./flightcheck/20260618.1413-example.com-report.md

By default this runs all implemented checks: crawl, security headers, DNS, robots.txt, sitemap, agent readiness, and analyze. If the start URL is a domain redirect, only redirect validation, DNS, and analyze run. Use --checks crawl to force a full crawl on redirect domains. Use --checks for a subset, or --json-only for crawl JSON only.

Re-analyze an existing crawl without re-crawling:

npx flightcheck-analyze ./flightcheck/20260618.1413-example.com-raw.json

Documentation

Development

nvm use   # see .nvmrc
pnpm install
pnpm test
pnpm build

License

Flightcheck is licensed under GNU GPL v3.0. You may use, modify, and distribute it under the GPL terms. Derivative works must also be open source under a compatible license — it cannot be incorporated into closed-source products without complying with the GPL (typically by open-sourcing the combined work).