🖱️
Platforms & Editors

Use Hanzo AI with Cursor

Use Hanzo AI models inside Cursor IDE by adding a custom API provider. Access Zen, GPT-4.1, Claude Sonnet, and 390+ other models directly in your editor.

Base URL: https://api.hanzo.ai/v1

API Key: Get yours at hanzo.ai/signup · Fully OpenAI-compatible · 390+ models available

🖱️

Created by Anysphere

License: Proprietary · View source on GitHub →

Hanzo AI is OpenAI-compatible, so existing Cursor code works with zero refactoring. We deeply appreciate the Anysphere team for building and maintaining this open-source project.

Cursor settings

json
// Settings > Models > Add custom model
{
  "provider": "openai-compatible",
  "name": "Hanzo AI",
  "baseUrl": "https://api.hanzo.ai/v1",
  "apiKey": "your-hanzo-api-key",
  "models": ["zen4-pro", "zen4-max", "openai/gpt-4.1", "anthropic/claude-sonnet-4-6"]
}

Available models

bash
# Query Hanzo models list
curl https://api.hanzo.ai/v1/models \
  -H "Authorization: Bearer $HANZO_API_KEY" | jq '.data[].id'

Test connection

bash
curl https://api.hanzo.ai/v1/chat/completions \
  -H "Authorization: Bearer $HANZO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"zen4-pro","messages":[{"role":"user","content":"Hello from Cursor!"}],"max_tokens":50}'

Tips

bash
# zen4-pro: best for code generation
# zen4-coder: specialized code model
# zen4-thinking: step-by-step reasoning
# openai/gpt-4.1: advanced reasoning
# All available at api.hanzo.ai/v1

Ready to get started?

Create a free account and get your API key. 100K API calls/month free forever.