CLI Reference
A11YSmith provides 13 commands for auditing web, Android, iOS, document, and markdown projects, plus agent management and report sanitization.
audit-web
Run an accessibility audit against live web pages or local HTML files using axe-core and Playwright.
| Option | Description | Required |
|---|---|---|
--url <urls...> | URLs or local HTML file paths to audit | Yes |
--format | Report format: json, markdown, html, or all | No (default: json) |
--output <dir> | Output directory for reports | No (default: ./a11ysmith-output) |
--headless | Run browser in headless mode | No (default: true) |
--no-headless | Run browser in visible mode | No |
--timeout <ms> | Navigation timeout in milliseconds | No (default: 30000) |
Example:
a11ysmith audit-web --url https://example.com --format html --output ./reports audit-document
Run an accessibility audit on Office documents (.docx, .xlsx, .pptx) and PDF files.
| Option | Description | Required |
|---|---|---|
--file <files...> | Document file paths to audit | Yes |
--format | Report format: json, markdown, html, or all | No (default: json) |
--output <dir> | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-document --file report.docx presentation.pptx --format markdown audit-markdown
Run an accessibility audit on markdown files.
| Option | Description | Required |
|---|---|---|
--file <files...> | Specific markdown file paths to audit | No |
--dir <directory> | Directory to scan recursively for markdown files | No (default: .) |
--format | Report format: json, markdown, html, or all | No (default: json) |
--output <dir> | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-markdown --dir ./docs --format markdown audit-android-source
Scan Android source code (XML layouts, Kotlin/Java) for accessibility issues.
| Option | Description | Required |
|---|---|---|
--source <files...> | Kotlin or XML source files to audit | Yes |
--format | Output format: json, markdown, or html | No (default: json) |
--output | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-android-source --source ./app/src/main/res/layout/*.xml ./app/src/main/kotlin/**/*.kt --format markdown audit-android-artifact
Audit Android runtime artifacts such as view hierarchies, Espresso test results, and lint reports.
| Option | Description | Required |
|---|---|---|
--hierarchy | Path to view hierarchy JSON file | No |
--espresso | Path to Espresso test results | No |
--lint | Path to Android Lint XML report | No |
--screen-id | Screen identifier for the audit | No |
--format | Output format: json, markdown, or html | No (default: json) |
--output | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-android-artifact --hierarchy dump.json --lint lint-results.xml --format json audit-android-hybrid
Combine source and artifact analysis for a comprehensive Android audit.
Accepts all options from both audit-android-source and audit-android-artifact.
Example:
a11ysmith audit-android-hybrid --source ./app/src/**/*.xml --hierarchy dump.json --espresso results.json --format html audit-ios-source
Scan iOS source code (SwiftUI, UIKit) for accessibility issues.
| Option | Description | Required |
|---|---|---|
--source <files...> | Swift source files to audit | Yes |
--format | Output format: json, markdown, or html | No (default: json) |
--output | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-ios-source --source ./MyApp/**/*.swift --format markdown audit-ios-artifact
Audit iOS runtime artifacts such as accessibility hierarchies and XCTest results.
| Option | Description | Required |
|---|---|---|
--hierarchy | Path to accessibility hierarchy JSON | No |
--xctest | Path to XCTest accessibility results | No |
--screen-id | Screen identifier for the audit | No |
--format | Output format: json, markdown, or html | No (default: json) |
--output | Output directory for reports | No (default: ./a11ysmith-output) |
Example:
a11ysmith audit-ios-artifact --hierarchy a11y-tree.json --xctest test-results.json --format html audit-ios-hybrid
Combine source and artifact analysis for a comprehensive iOS audit.
Accepts all options from both audit-ios-source and audit-ios-artifact.
Example:
a11ysmith audit-ios-hybrid --source ./MyApp/**/*.swift --hierarchy a11y-tree.json --xctest test-results.json --format html sanitize-report
Strip PII and internal paths from audit reports before sharing.
| Option | Description | Required |
|---|---|---|
--input <file> | Input report file (JSON, Markdown, or HTML) | Yes |
--output <file> | Output file | No (default: stdout) |
--keep-paths | Do not strip file paths | No |
--keep-hosts | Do not strip hostnames | No |
--keep-emails | Do not strip email addresses | No |
--keep-ips | Do not strip IP addresses | No |
Example:
a11ysmith sanitize-report --input report.json --output sanitized.json --keep-paths agent-init
Initialize agent configuration in the current project.
| Option | Description | Required |
|---|---|---|
--force | Overwrite existing configuration | No |
--enforcement <level> | Hook enforcement level: strict, advisory, off | No (default: advisory) |
Example:
a11ysmith agent-init --enforcement strict agent-generate
Generate agent files for target AI coding platforms.
| Option | Description | Required |
|---|---|---|
--platform <platforms> | Target platforms (comma-separated): claude-code, github-copilot, gemini, claude-desktop, vscode, all | Yes |
--output <dir> | Output base directory | No (default: project root) |
Example:
a11ysmith agent-generate --platform claude-code,github-copilot agent-list
List available accessibility agents.
| Option | Description | Required |
|---|---|---|
--team <team> | Filter by team: web, document, markdown, github, mobile-desktop, supporting | No |
--command <command> | Find agent by slash command (e.g. /aria) | No |
--search <query> | Search agents by keyword | No |
--all | Include hidden (non-user-invokable) agents | No |
Example:
a11ysmith agent-list --team web