Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.anyfast.ai/llms.txt

Use this file to discover all available pages before exploring further.

Overview

Claude Code is a command-line AI assistant for coding tasks. By integrating with Anyfast, you can access powerful AI models directly from your terminal for code generation, debugging, and analysis.

Prerequisites

  • macOS or Linux (or Windows with WSL)
  • Terminal access with a bash shell
  • A valid Anyfast API Key
  • Internet connection

Environment Variables

Add the following to your shell profile (.bashrc, .zshrc, or .profile):
# Anyfast API Configuration
export ANTHROPIC_BASE_URL="https://www.anyfast.ai/"
export ANTHROPIC_MODEL="claude-opus-4-7"
export ANTHROPIC_API_KEY="sk-your-api-key-here"

Apply Configuration

# bash users
source ~/.bashrc

# zsh users
source ~/.zshrc

Start Claude Code

claude

Method 2: OpenAI-Compatible Mode

Add to your shell profile:
export OPENAI_API_KEY="sk-your-api-key-here"
export OPENAI_BASE_URL="https://www.anyfast.ai/v1"

Switching Models

To change models, update the environment variable:
export ANTHROPIC_MODEL="claude-sonnet-4-6"
source ~/.zshrc

Tips

  • Use specific, detailed prompts for better code suggestions.
  • Break complex tasks into smaller, manageable requests.
  • Review generated code before implementing.
  • Monitor your usage in the Anyfast console.

Troubleshooting

Authentication errors:
echo $ANTHROPIC_API_KEY
Model not found:
echo $ANTHROPIC_MODEL
Connection issues:
curl -H "Authorization: Bearer $ANTHROPIC_API_KEY" https://www.anyfast.ai/v1/models