+IzziAPI
Quay lại Blog
Mar 29, 2026

Hướng dẫn dùng Claude Code với Izzi API — Tiết kiệm 30% chi phí coding

Cấu hình Claude Code sử dụng Izzi API thay vì API trực tiếp từ Anthropic. Hỗ trợ Claude Opus 4, Sonnet 4, Extended Thinking. Tiết kiệm đáng kể cho developer.

claude-codeizzi-apianthropiccoding

Claude Code + Izzi API = Coding rẻ hơn

Claude Code là AI coding agent mạnh nhất hiện tại, nhưng chi phí sử dụng trực tiếp từ Anthropic khá cao. Bằng cách sử dụng Izzi API làm proxy, bạn có thể:

  • ✅ Truy cập Claude Opus 4, Sonnet 4 với bonus +$5 lần nạp đầu
  • ✅ Sử dụng Extended Thinking cho coding task phức tạp
  • ✅ Thanh toán bằng VietQR — không cần Visa/Mastercard
  • ✅ Kết hợp với 14 model miễn phí

Cấu hình Claude Code

Cách 1: Environment Variables (nhanh nhất)

# Windows PowerShell
$env:ANTHROPIC_API_KEY = "izzi-YOUR_KEY_HERE"
$env:ANTHROPIC_BASE_URL = "https://api.izziapi.com"

# macOS / Linux
export ANTHROPIC_API_KEY="izzi-YOUR_KEY_HERE"
export ANTHROPIC_BASE_URL="https://api.izziapi.com"

# Chạy Claude Code
claude

Cách 2: Claude Code Settings

Mở Claude Code settings (claude settings) và thêm:

{
  "apiKey": "izzi-YOUR_KEY_HERE",
  "apiBaseUrl": "https://api.izziapi.com"
}

Extended Thinking — Suy nghĩ sâu hơn

Izzi API hỗ trợ Forward Extended Thinking của Claude. Khi dùng lệnh phức tạp, Claude sẽ "suy nghĩ" trước khi trả lời:

curl https://api.izziapi.com/v1/messages \
  -H "x-api-key: izzi-YOUR_KEY" \
  -H "anthropic-version: 2023-06-01" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "claude-sonnet-4-20250514",
    "max_tokens": 16000,
    "thinking": {
      "type": "enabled",
      "budget_tokens": 10000
    },
    "messages": [{"role": "user", "content": "Refactor this codebase to use dependency injection"}]
  }'

Model nào nên dùng với Claude Code?

ModelGiá Input/1MKhi nào dùng
Claude Opus 4$5.00Debug phức tạp, system design, architecture
Claude Sonnet 4$3.00Coding hàng ngày, refactor, review
Claude Haiku 4.5$1.00Task nhanh: format, comment, simple fix
Llama 4 MaverickFreeGenerate boilerplate, README, docs

Tips tiết kiệm khi dùng Claude Code

  • 🎯 Dùng Sonnet 4 thay Opus 4 cho 90% tác vụ — rẻ hơn ~40%
  • 🎯 Bật Extended Thinking chỉ khi cần suy luận phức tạp
  • 🎯 Nạp $1 lần đầu → nhận +$5 bonus → đủ dùng cả ngày coding
  • 🎯 Kiểm tra chi phí trên Dashboard: izziapi.com/dashboard

Bài viết liên quan