Claude Code
Claude Code is an official intelligent coding assistant (CLI Agent) from Anthropic that runs directly in your terminal. It deeply understands large codebase structures, collaborates on edits across multiple files, and autonomously runs tests and terminal commands, providing developers with an immersive local AI coding workflow.
✨ AI One-Click Setup
Copy the prompt below and send it to your AI assistant to automatically detect your environment, install, and configure:
🔑 Prerequisites
sk-...🚀 Steps
Install CLI Globally
Claude Code is an intelligent coding assistant that runs directly in your terminal. Install the official CLI package globally via npm, after which you can invoke the claude command in any terminal:
npm install -g @anthropic-ai/claude-codeConfigure Environment Variables
Claude Code connects to the official interface by default. To connect to OpenRely, you need to replace the request URL with the OpenRely endpoint and configure your API key:
Temporarily export environment variables in the current terminal session:
export ANTHROPIC_BASE_URL="https://api.openrely.ai/v1"
export ANTHROPIC_API_KEY="sk-your-openrely-api-key"Set environment variables for the current session in a PowerShell window:
$env:ANTHROPIC_BASE_URL = "https://api.openrely.ai/v1"
$env:ANTHROPIC_API_KEY = "sk-your-openrely-api-key"[!TIP] To make them persistent in Windows, you can run:
[Environment]::SetEnvironmentVariable("ANTHROPIC_BASE_URL", "https://api.openrely.ai/v1", "User")
[Environment]::SetEnvironmentVariable("ANTHROPIC_API_KEY", "sk-your-openrely-api-key", "User")
Append the environment variables to your Shell configuration file so they automatically apply to all future terminal sessions:
# macOS (zsh)
echo 'export ANTHROPIC_BASE_URL="https://api.openrely.ai/v1"' >> ~/.zshrc
echo 'export ANTHROPIC_API_KEY="sk-your-openrely-api-key"' >> ~/.zshrc
source ~/.zshrc
# Linux (bash)
echo 'export ANTHROPIC_BASE_URL="https://api.openrely.ai/v1"' >> ~/.bashrc
echo 'export ANTHROPIC_API_KEY="sk-your-openrely-api-key"' >> ~/.bashrc
source ~/.bashrcStart and Verify
Navigate to your code project's root directory and run claude to start an interactive session:
claudeAfter launching successfully for the first time, send a test prompt to verify API communication:
> Analyze the overall architecture of this projectIf a streamed response is returned properly, OpenRely has been successfully integrated.
💡 Common Commands
Common built-in shortcut commands in Claude Code interactive sessions:
| Command | Description |
|---|---|
/help | View all built-in commands and configuration options |
/cost | View real-time Token consumption statistics for the current task and session |
/compact | Compact current long context history to free memory and save quota |
/clear | Clear current conversation context and start a new task |
❓ FAQ
Encountering other API errors or billing questions? Please refer to the complete FAQ and Troubleshooting Guide.
Was this page helpful?
Continue
Continue is a leading open-source AI code assistant extension with deep support for both VS Code and JetBrains IDEs (IntelliJ IDEA, PyCharm, WebStorm, GoLand, etc.). It allows you to seamlessly configure custom OpenAI-compatible endpoints to provide inline intelligent code autocomplete (Tab) and deep sidebar chat.
Codex CLI
Codex CLI is the official terminal AI coding assistant (CLI Agent) from OpenAI. It autonomously inspects code repositories, runs terminal commands, and edits files cleanly with atomic patch operations.