Cursor IDE Integration
Use Korad.AI with Cursor IDE for cheaper AI-powered coding.
Setup
Method 1: Settings (Recommended)
- Open Cursor Settings (Cmd+, / Ctrl+,)
- Go to "Models" section
- Set "Base URL" to:
https://api.korad.ai/v1 - Set "API Key" to:
sk-korad-YOUR-KEY
Method 2: Environment Variables
# Add to your shell profile (~/.zshrc or ~/.bashrc)
export ANTHROPIC_BASE_URL="https://api.korad.ai/v1"
export ANTHROPIC_API_KEY="sk-korad-YOUR-KEY"
# Restart Cursor
Verification
Test that Cursor is using Korad.AI:
- Open a new chat in Cursor
- Ask: "What API are you using?"
- Check response for speed and quality
Features
Tab Completion
# Start typing a function
def binary_search(arr, tar
# Cursor completes with Korad.AI
# Cost: $0.003 vs $0.009 via Anthropic
Chat
# Ask Cursor to explain code
# Response optimized through Korad.AI
# 60-80% cost savings
Refactoring
# Ask Cursor to refactor
# High-quality results at lower cost
Configuration
Project-Specific Settings
Create .cursorrules in your project:
--base-url=https://api.korad.ai/v1
--api-key=sk-korad-YOUR-KEY
--model=claude-sonnet-4-20250514-optim
Workspace Settings
Create .cursor/workspace.json:
{
"anthropic.baseURL": "https://api.korad.ai/v1",
"anthropic.apiKey": "sk-korad-YOUR-KEY",
"korad.savingsLevel": "high"
}
Example Usage
Code Generation
# Prompt: "Create a REST API with FastAPI"
# Cursor generates via Korad.AI
# Cost: $0.12 vs $0.36 via Anthropic
Bug Fixing
# Prompt: "Find and fix the bug in this code"
# Cursor analyzes and fixes
# Cost: $0.08 vs $0.24 via Anthropic
Code Explanation
# Prompt: "Explain how this works"
# Cursor explains via Korad.AI
# Cost: $0.02 vs $0.06 via Anthropic
Advanced Features
Model Selection
Choose which model to use:
{
"model": "claude-sonnet-4-20250514-optim" // 60% cheaper
}
Savings Control
Set savings level:
{
"korad.savingsLevel": "medium" // low, medium, high, maximum
}
Troubleshooting
"Connection Error"
Verify base URL includes /v1:
https://api.korad.ai/v1 ✓
https://api.korad.ai ✗
"Invalid API Key"
Make sure key starts with sk-korad-:
sk-korad-xxxxxxxxxxxx ✓
sk-ant-xxxxxxxxxxxx ✗
Slow Responses
Try the optimized model:
{
"model": "claude-sonnet-4-20250514-optim"
}
Best Practices
- Use optimized model —
-optimmodels are 40-60% cheaper - Set savings level — Balance cost vs quality
- Monitor balance — Check dashboard periodically
- Use project-specific keys — Track usage per project
Cost Comparison
| Task | Anthropic | Korad.AI | Savings |
|---|---|---|---|
| Tab completion | $0.009 | $0.003 | 67% |
| Code generation | $0.36 | $0.12 | 67% |
| Bug fixing | $0.24 | $0.08 | 67% |
| Refactoring | $0.18 | $0.06 | 67% |
Next Steps
- Quick Start — Get your API key
- Features — Learn about optimization
- Billing — Add credits to your account