{
  "markdown": "# flagrix\n\nScan GitHub repositories and profiles for malware **before you clone** — from the\nterminal, CI, or an AI agent. The same commit-pinned verdict as the\n[Flagrix browser extension](https://flagrix.io), made callable.\n\n```bash\nnpx flagrix scan https://github.com/some-org/coding-assignment\n```\n\n```\n  some-org/coding-assignment @ 3f9c2a1\n  HIGH RISK — Do not clone  security score 12/100\n  3 files scanned · 10 dependencies · 2 issues\n\n  CRITICAL Data exfiltration patterns detected: Keylogger Pattern\n    assignment.js:14\n      14  document.addEventListener(\"keydown\", (e) => send(e.key))\n```\n\nBuilt after real fake-recruiter campaigns (\"coding assignment\" repos that steal\nwallets, SSH keys, and browser sessions) started targeting developers.\n\n## Commands\n\n```bash\nflagrix scan <url | owner/repo>   # scan a repository (--ref <branch|sha>)\nflagrix scan-user <username>      # score a GitHub profile for scam signals\nflagrix mcp                       # MCP server (stdio) for AI agents\n```\n\n## Exit codes\n\n| code | meaning |\n|---|---|\n| 0 | low risk |\n| 1 | scan failed |\n| 2 | medium risk — review before proceeding |\n| 3 | high risk — do not clone |\n\n`--json` (automatic when stdout is piped) emits the full result. The verdict is\n**pinned to the scanned commit** (`commitSha` in the JSON): every file is read at\nthat SHA, so a push mid-scan or after the verdict can't silently invalidate it.\n\n## AI agents\n\n```bash\nclaude mcp add flagrix -- npx -y flagrix mcp\n```\n\nTools: `scan_github_repo`, `scan_github_user`. A Claude Code hook that gates every\n`git clone` on a scan ships in [hooks/](hooks/) — see\n[docs/agent-gating.md](docs/agent-gating.md).\n\n## Tokens & rate limits\n\nUnauthenticated scans use GitHub's 60 req/h budget (a scan issues one request per\nscanned file, up to ~50). Set `GITHUB_TOKEN` (or `FLAGRIX_GITHUB_TOKEN`, or\n`--token`) to raise it to 5,000/h and to scan private repositories.\n\n## Privacy\n\nFully local. No telemetry, no accounts, no Flagrix backend — the only network\ncalls go to the GitHub/npm APIs and the public\n[detection-rules](https://github.com/flagrix-io/flagrix-detection-rules)\nrepository (signature refresh, cached 6 h, with a bundled offline snapshot).\n\n## How it works\n\nScanning logic lives in [@flagrix/scanner-core](https://github.com/flagrix-io/flagrix-scanner-core)\n(MIT), signatures in [flagrix-detection-rules](https://github.com/flagrix-io/flagrix-detection-rules)\n(MIT) — the same engine and rules the browser extension uses. Verdicts are risk\nassessments, not definitive fraud determinations; always verify through official\nchannels.\n\n## AI Disclosure\n\nThis project leverages Claude AI for boilerplate generation, test-suite expansion,\nand optimization. All AI-generated code is strictly reviewed, refactored, and\nverified by human maintainers before merging.\n\n## License\n\nMIT — see [LICENSE](LICENSE).\n",
  "bytes": 2860,
  "sha": "787c0d48e6d7d1300139a5b250e8508cba497811f9950d25c5812768842209bb",
  "repo_slug": "flagrix-io/flagrix-cli",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_flagrix_io_flagrix_687c32bc/readme"
}