Getting Started¶
Get from zero to a running AI-generated test in about five minutes.
Prerequisites¶
- Python 3.10 or newer
- An Anthropic API key (for test generation) or a Synthesize account
1. Install¶
Optional extras for specific test types:
pip install "synthesize-ai[web]" # Selenium browser testing
pip install "synthesize-ai[api]" # API/HTTP testing
pip install "synthesize-ai[db]" # Database testing
pip install "synthesize-ai[watch]" # Watch mode (TDD)
pip install "synthesize-ai[visual]" # Visual regression
pip install "synthesize-ai[all]" # Everything
2. Authenticate¶
Option A — Anthropic API key (simplest for local use):
Option B — Synthesize account (enables Studio features, usage tracking):
# Interactive browser login
synthesize auth login
# Or headless with an API key from studio.synthesize-ai.dev/profile/api-keys
synthesize auth login --token synth_YOUR_KEY
# Verify
synthesize auth status
3. Initialize a Project¶
This creates synth.yaml — your project configuration. The defaults work out of the box; see Configuration when you want to customize.
4. Write Your First Test¶
Create login.synth:
suite: User Login
context: Web app, login page at https://example.com/login
tests:
- Successful login redirects to dashboard
- Bad password shows an error message
- Empty form shows validation errors
That's the whole test file. No selectors, no boilerplate — describe intent, in English.
5. Generate¶
# Robot Framework (default)
synthesize generate login.synth
# Or pick your framework
synthesize generate login.synth --format playwright
synthesize generate login.synth --format cypress
synthesize generate login.synth --format selenium
Generated test files land in output/.
6. Run¶
# Generate + execute in one step
synthesize run login.synth
# Validate without executing
synthesize run login.synth --dry-run
# With self-healing: broken locators get fixed automatically
synthesize run login.synth --heal auto --max-retries 3
Where to Go Next¶
- The .synth Format — extended syntax, priorities, compliance tags
- CLI Reference — the full command surface (analytics, CI/CD, security, and more)
- Configuration — models, environments, healing strategies
- Try
synthesize chatfor conversational test authoring