Your first Claude Code run starts inside VS Code
Claude Code is a coding assistant you run from a terminal. The VS Code integrated terminal is simply a command-line window inside your editor. Put them together and you can ask questions about a project, request edits, and review the resulting changes without leaving your workspace.
You do not need a separate editor extension for this terminal workflow. VS Code displays your files and terminal; Claude Code runs as a command-line program with access governed by its permissions and your choices.
Open the project before starting Claude Code
In VS Code, open the folder containing your project. Then choose Terminal → New Terminal. The terminal will usually start in that folder, but check its location before proceeding. Starting in the wrong directory can give the assistant the wrong project context.
For your first attempt, choose a small project with version control enabled. Commit existing changes first so that you can distinguish your work from the assistant’s edits and undo individual changes if necessary.
- Use a folder you recognize and trust.
- Keep passwords, private keys, and production credentials outside the task.
- Confirm that the terminal is using your intended shell, such as PowerShell or Bash.
Install Claude Code and check the command
If you already use Node.js and npm, one installation route is npm install -g @anthropic-ai/claude-code. This requires a supported Node.js version. Claude Code also provides native installers; use its official installation instructions if you prefer that route.
After installation, run claude --version. If the terminal cannot find the command, close it and open a new terminal. An installation may update your executable search path without updating terminals that are already open.
A terminal running through WSL, a container, or a remote connection is a separate environment. Install and configure Claude Code in the environment where you intend to run it.
Connect Claude Code to SwiftRelay
SwiftRelay is a practical option for pay-as-you-go access, with billing based on token usage. Sign up for SwiftRelay, collect the small gift credit available to new accounts, and create an API key in your dashboard.
For Claude Code, use the bare API host https://api.fastapirelay.com. Do not add /v1; that suffix is used for OpenAI-compatible SDK configurations, not this setup.
In Bash or Zsh, enter these as two separate commands:
- export ANTHROPIC_BASE_URL="https://api.fastapirelay.com"
- export ANTHROPIC_AUTH_TOKEN="YOUR_SWIFTRELAY_API_KEY"
In PowerShell, use these instead:
- $env:ANTHROPIC_BASE_URL="https://api.fastapirelay.com"
- $env:ANTHROPIC_AUTH_TOKEN="YOUR_SWIFTRELAY_API_KEY"
Replace the placeholder with your actual key. These settings apply to the current terminal session and programs launched from it. Avoid sharing screenshots or terminal history containing credentials, and do not save your key in project files.
Start with a read-only project question
Run claude in that same terminal. Review any workspace trust and permission prompts carefully. If you need to select a model, use the exact Claude Code-compatible model identifier supplied by SwiftRelay rather than guessing from a display name.
Try this first request: Explain this project’s folder structure and identify its test command. Do not change any files. This gives you a chance to check whether the assistant understands the project before authorizing edits.
Next, request one small change with a clear boundary: Add a test for the empty-input case. Show me your plan before editing, and do not install dependencies. Review requested commands and file changes rather than approving everything automatically.
Check edits and resolve connection problems
Use VS Code’s Source Control view to inspect the diff, then run the relevant tests. Treat generated changes as a draft that needs your review.
If authentication fails, check the key and environment variables in the terminal that launched Claude Code. If a model is unavailable, confirm its supported identifier with SwiftRelay. Keep error details when asking for help, but remove credentials first.