Prerequisites
- Vers CLI installed and authenticated
- An Anthropic API key from console.anthropic.com
Step 1: Create the project
Create a new folder for your project if you don’t already have one.Step 2: Set environment variables
Usevers env to define environment variables that get injected into every VM you create. This means any tool running inside the VM — including coding agents — can authenticate automatically.
Environment variables set with
vers env are injected at VM startup. You only need to set them once — they apply to all VMs you create going forward, including branches.Step 3: Launch the VM
Step 4: Connect and install Claude Code
Step 5: Start coding with the agent
Create a workspace and give the agent a task:Step 6: Run what the agent built
Once the agent is done, start the app:<vm-id> with your VM’s ID (shown in vers status).
Step 7: Iterate
You’re still inside the VM with Claude Code available. Keep prompting to make changes:Step 8: Branch before experiments
Want to try something risky without losing your working state? Exit the VM and branch:What you learned
- Setting environment variables with
vers envfor automatic API key injection - Installing and running Claude Code on a Vers VM
- Interactively building an app with a coding agent over SSH
- Branching a VM to safely experiment with agent-driven changes
Next steps
- Coding agent (headless) — run an agent non-interactively on a VM
- Swarm — orchestrate multiple agents across branched VMs
- Accessing your instance — networking, ports, and SSH details