CLI Reference

CLI Reference

Commands

capyseo analyze

Analyze a site for SEO issues.

capyseo analyze <target> [options]

Arguments:

  • target - Directory path or URL to analyze

Options:

Option Description Default
--ai Enable AI-powered suggestions false
--ci CI mode: exit with error code false
--min-score <n> Minimum acceptable score 0
--format <fmt> Output format console
-o, --output <path> Output file path -
--max-pages <n> Maximum pages to analyze 100
--no-live Disable live HTTP checks false
--config <path> Path to config file -

Examples:

# Basic analysis capyseo analyze ./dist # Live site with AI GEMINI_API_KEY=xxx capyseo analyze https://example.com --ai # CI with HTML report capyseo analyze ./dist --ci --min-score 80 --format html -o report.html

capyseo generate sitemap

Generate a sitemap.xml file.

capyseo generate sitemap <target> [options]

Options:

Option Description Default
--origin <url> Site origin URL required
-o, --output <path> Output path ./sitemap.xml
--changefreq <freq> Default change frequency weekly
--priority <p> Default priority 0.5

Example:

capyseo generate sitemap ./dist --origin https://example.com

capyseo generate robots

Generate a robots.txt file.

capyseo generate robots [options]

Options:

Option Description Default
--sitemap <url> Sitemap URL -
--disallow <paths...> Paths to disallow -
--allow <paths...> Paths to allow -
--crawl-delay <s> Crawl delay in seconds -
-o, --output <path> Output path ./robots.txt

Example:

capyseo generate robots --sitemap https://example.com/sitemap.xml --disallow /admin /api

capyseo generate meta

Generate meta tags using AI.

capyseo generate meta <url> [options]

Requires GEMINI_API_KEY environment variable.

Options:

Option Description
--title Generate title suggestion
--description Generate meta description
--all Generate all meta suggestions

capyseo init

Initialize configuration file.

capyseo init [options]

Options:

Option Description
--typescript Generate TypeScript config

capyseo watch

Watch for HTML changes and analyze in real-time.

capyseo watch <directory> [options]

Options:

Option Description Default
--ai Enable AI suggestions false
--debounce <ms> Debounce time 500
--config <path> Path to config file -

Environment Variables

Variable Description
GEMINI_API_KEY Gemini API key for AI features

Exit Codes

Code Meaning
0 Success
1 Analysis failed or score below minimum