Skip to main content

Getting Started

This guide covers the fastest path from installation to a useful local scan. Skylos works as a local CLI first; cloud upload, LLM review, and CI gates are optional layers you can add later.

Key Commands​

pip install skylos

No account needed. Your code and findings stay on your machine.

ToRun
Find dead codeskylos .
Run every check: security, secrets, dependencies, quality, AI-code mistakesskylos . -a
Check only what your branch changedskylos . -a --diff origin/main
Fail the build when the gate failsskylos . --gate
Check the agent really finished (runs your tests)skylos done --base main
Check every pull request in CIskylos cicd init
Set up Claude Code and Codex in this reposkylos setup

skylos . -a stays local, except that it looks up package names online: OSV.dev for known CVEs, and PyPI or npm for packages that don't exist.

Skylos Cloud, Step by Step​

Optional. See every scan online and block pull requests that fail. Five steps, in this order, from your repository folder. No token to copy.

StepRun or doWhat happens
1. Upload your first scanskylos cloudYour browser opens skylos.dev. Sign in, then pick or create the project for this repo. Back in the terminal, Skylos scans with every check and uploads the findings (not your code).
2. Open your resultsClick the Open: link it printsThe scan in your dashboard: its gate result and every issue. Find it again later at skylos.dev/dashboard.
3. Add the pull request checkskylos cicd initWrites .github/workflows/skylos.yml and prints the next steps: the git commands that open a pull request with it, and the GitHub App link.
4. Install the GitHub App, then mergeOpen the GitHub App link it printedInstall the Skylos GitHub App on the repo before you merge that pull request. CI then uploads with its GitHub identity (OIDC), so there is no token or secret to add.
5. Make the check requiredskylos setupRun it after the merge (it uses the GitHub CLI, gh). A pull request that fails the Skylos check can no longer merge.

The end of step 1 looks like this:

✓ Scan saved · gate (not blocking): fail
Open: https://skylos.dev/dashboard/projects/<project>/scans/<scan>
Saved for review. Only verified CI scans block merges and update the project verdict.
Next: to block pull requests, run skylos cicd init and merge the workflow it writes.

A scan from your machine is saved for review but never blocks a merge; only CI scans do. Upload again any time with skylos cloud. See Cloud Platform for what it sends.

The steps below go through each one in more detail.

What Skylos catches that other tools miss

The Skylos tutorial walks through eight checks we didn't find in other tools as of October 2026 (for example, risky pull requests that need a person's approval even when an AI reviewer approved, and agents that hard-code test answers), each with a one-minute demo you can paste.

Prerequisites​

Before installing Skylos, ensure your environment meets the following requirements:

  • Operating System: macOS, Linux, or Windows (WSL2 recommended).
  • Python: Version 3.10 or newer.
  • Package Manager: pip or uv.
note

Browser Support: Skylos is a CLI tool and does not require a web browser, although it can generate HTML reports that support Chrome, Edge, Firefox, and Safari.

Step 1: Installation​

Skylos is distributed via PyPI. Install it globally or within your project's virtual environment.

pip install skylos

To verify the installation, run:

skylos --version

Step 2: Run Your First Scan​

Go to the repository root and scan it:

skylos .

This starts with dead code detection. To run the main local audit, including dead code, dangerous flows, secrets, quality, and dependency checks:

skylos . -a

Optional: Initialize Project Config​

You do not need config for a first scan. Initialize Skylos when you want repository-owned thresholds, excludes, or gate policy.

  1. Navigate to your project folder.
  2. Run the initialization command:
skylos init

This will create (or append to) a pyproject.toml file with default settings:

[tool.skylos]
complexity = 10
nesting = 3
max_args = 5

Optional: Configure AI Access​

Skylos does not require an LLM for core static analysis. Configure a provider only if you want agent review or remediation workflows.

Skylos checks for keys in the following priority:

  1. Environment Variables: OPENAI_API_KEY or ANTHROPIC_API_KEY.
  2. System Keyring: Keys saved via previous interactive sessions.
  3. Interactive Prompt: You will be prompted to paste a key if none is found.
export OPENAI_API_KEY="sk-..."

Step 3: Review Results​

The CLI outputs findings as tables, grouped by category. Each table includes a legend explaining what the columns mean.

  • Dead Code (default): Unused functions, imports, classes, and variables. Each finding has a Conf (confidence) score — higher means safer to remove.
  • Security (--danger): Vulnerabilities like SQL injection and command injection. Shows Issue, Severity, and the Symbol (function) where it occurs. Also reports committed agent hooks, unpinned MCP servers and risky package publish jobs (SKY-D365 to SKY-D377); see Agent Configs And Publish Jobs.
  • Secrets (--secrets): Hardcoded credentials. Shows the Provider (e.g. AWS, Stripe) and a masked Preview.
  • Quality (--quality): Complexity, nesting, duplicate literals, and structural issues. Shows the measured value vs. the configured threshold (e.g. Complexity: 18 (max 10)).
  • AI Defects (--ai-defects): Evidence-backed AI-code failure modes such as phantom references, hallucinated APIs, impossible dependency versions, and weakened assertions. JSON uses the ai_defects bucket and finding category ai_defect; some rules keep historical SKY-L or SKY-D IDs for compatibility, while new AI-defect-only rules use SKY-A.
  • SCA (--sca): Known vulnerabilities in your dependencies. Shows the Package, Reachability, and the Fix version. Versions reported as malware are CRITICAL, and supply-chain checks flag dependency confusion, unpinned Git or URL sources and lockfile entries without integrity hashes. In a pull request (--diff or --diff-base), it also flags weakened install hardening, and --review-upgrades compares each upgraded npm or PyPI package with its previous release. See Supply Chain.

Reducing False Positives​

If Skylos flags code you know is used (common with visitor patterns or dynamic dispatch), enable tracing:

skylos . --trace

This runs your test suite and records which functions were actually called, eliminating false positives from dynamic code.

See Smart Tracing for details.

Step 4: Add CI Or Cloud Later​

Set up a pull request gate for your CI (GitHub Actions, GitLab CI, Jenkins, Bitbucket Pipelines, Azure Pipelines or CircleCI):

skylos cicd init

See CI/CD Integration for local gates, cloud uploads, GitHub OIDC, tokens, annotations, and branch protection.

Optional: Connect to Cloud​

Track your results per branch on the Skylos Cloud dashboard for history tracking, team collaboration, and trend visualization.

skylos cloud

skylos cloud runs every check (-a), shows the findings, uploads them to Skylos Cloud, then prints this branch's quality gate and one link to it. It sends findings, not your repository.

On first run, the browser opens automatically — sign in with GitHub, pick a project, and you're done. No API keys to copy or config files to edit.

To run only some checks, name them, for example skylos cloud --danger --secrets. See Cloud Platform for what skylos cloud sends and prints.

tip

Your first workspace gets a 14-day Workspace trial with 50 credits: no card, and nothing renews or charges you. Uploads never cost credits. See Billing & Credits.

See Authentication for CI/CD setup, OIDC, and advanced options.