Integration Guide

Connect your favorite coding agent to Twodelta in under 5 minutes. Our infrastructure provides top-tier model quality through a simple base URL swap.

Twodelta is compatible with the OpenAI API format. If your tool supports custom OpenAI-compatible endpoints, it works with Twodelta.

Prerequisites

Before you begin, make sure you have:

  1. A Twodelta account (sign up here if you haven't already)
  2. An active subscription (view plans)
  3. Your API token (found in your Account Dashboard)
  4. A coding agent installed (Claude Code, Cursor, Cline, etc.)

Get Your API Token

After subscribing, navigate to your Account Dashboard to find your API token.

  1. Go to Account Management
  2. Under the Subscription tab, find the API Token section
  3. Click Copy to copy your token
Keep your API token secret. Do not commit it to version control. Use environment variables instead.

Claude Code Integration

Claude Code is our primary supported agent. Here's how to configure it to use Twodelta.

Step 1: Set the environment variable

Add the Twodelta base URL and your API token to your shell profile:

~/.bashrc or ~/.zshrc
# Twodelta Configuration
export ANTHROPIC_BASE_URL="https://api.twodelta.dev/v1"
export ANTHROPIC_API_KEY="your_api_token_here"

Step 2: Restart your terminal

After saving your shell profile, restart your terminal or source the file:

Terminal
source ~/.zshrc   # or source ~/.bashrc

Step 3: Launch Claude Code

Start Claude Code as usual. It will automatically use the Twodelta endpoint:

Terminal
claude

That's it! Claude Code will now route through Twodelta, giving you top-tier model quality at a fraction of the cost.

Cursor Integration

To use Twodelta with Cursor, configure it as a custom OpenAI-compatible provider:

Step 1: Open Cursor Settings

Go to Cursor Settings → Models → OpenAI API Key.

Step 2: Configure the endpoint

Cursor Settings
Base URL:  https://api.twodelta.dev/v1
API Key:   your_api_token_here
Model:     twodelta-coder

Step 3: Select the model

In the model picker, select twodelta-coder as your active model.

Cline / Other Agents

Any coding agent that supports custom OpenAI-compatible endpoints can use Twodelta. The general setup is:

General Configuration
{
  "apiProvider": "openai-compatible",
  "baseUrl": "https://api.twodelta.dev/v1",
  "apiKey": "your_api_token_here",
  "model": "twodelta-coder"
}

For Cline specifically, go to Settings → API Provider and select OpenAI Compatible, then enter the values above.

API Details

PropertyValue
Base URLhttps://api.twodelta.dev/v1
AuthenticationBearer token (your API key)
ProtocolOpenAI-compatible REST API
StreamingSupported (SSE)
Rate LimitsBased on your subscription plan

Available Models

Model IDDescriptionSWE-bench
twodelta-coderQwen2.5-Coder-7B — fast, capable coding model served by Twodelta

More models coming soon. Your subscription grants access to all available models.

Troubleshooting

Authentication Error (401)

Double-check your API token. Make sure it has been correctly copied from your dashboard without trailing spaces.

Verify your token
echo $ANTHROPIC_API_KEY
# Should output your API key from the dashboard

Connection Timeout

Ensure your network allows outbound HTTPS connections to api.twodelta.dev. If you're behind a corporate proxy, you may need to configure it.

Model Not Found (404)

Make sure you're using a valid model ID. Currently the only available model is twodelta-coder.

Rate Limit Exceeded (429)

You've exceeded your plan's quota. Check your usage in the Account Dashboard. Consider upgrading your plan for higher limits.

Need help?

Reach out to our support team for assistance.

Contact Support