OpenCode logoCoding Agent

OpenCode with DEVUP AI

Run the OpenCode terminal agent on DEVUP AI models. Add DEVUP AI to opencode.json as a custom OpenAI-compatible provider, and OpenCode writes files and runs shell commands through tool calling.

System Architecture

How OpenCode Connects to DEVUP AI

OpenCode communicates directly with DEVUP AI via the OpenAI-compatible Chat Completions protocol on https://api.devupai.com/v1/chat/completions. The terminal agent authenticates with your DEVUP AI API key from the environment, executes tools in your local workspace, and streams token deltas in real time.

1. Client
OpenCode
Terminal agent
2. Gateway
DEVUP OpenAI-compatible API
POST /v1/chat/completions
3. Inference
Model
Set in opencode.json
4. Response
Response
Streaming tokens and tool calls

Configuration

Quick Setup in OpenCode

1

Install OpenCode

Install OpenCode globally with npm install -g opencode-ai.

2

Set DEVUP_API_KEY in your shell

Export your API key in your environment so OpenCode can read your key securely without storing it in files.

3

Add opencode.json to your project

Create an opencode.json file in your project root or in your global config directory with the DEVUP AI provider block.

opencode.jsonJSON
json
{
  "$schema": "https://opencode.ai/config.json",
  "provider": {
    "devupai": {
      "npm": "@ai-sdk/openai-compatible",
      "name": "DEVUP AI",
      "options": {
        "baseURL": "https://api.devupai.com/v1",
        "apiKey": "{env:DEVUP_API_KEY}"
      },
      "models": {
        "deepseek-ai/DeepSeek-V4-Pro": {
          "name": "DeepSeek V4 Pro",
          "limit": { "context": 1048576, "output": 16000 }
        }
      }
    }
  },
  "model": "devupai/deepseek-ai/DeepSeek-V4-Pro"
}

In Action

OpenCode running on DEVUP AI

OpenCode writing hello.py and running it with DeepSeek V4 Pro on DEVUP AI

Capabilities

Supported Agent Capabilities

File edits and shell commands

OpenCode writes files and runs shell commands through tool calling on the OpenAI-compatible endpoint.

Key from the environment

opencode.json references DEVUP_API_KEY, so your key never has to be written into the config file.

Context usage

OpenCode shows context usage against the limit set for the model in opencode.json.

Local DZD billing

Metered billing in Algerian Dinar with BaridiMob, Edahabia, and CIB local payment support.

Ready to Code with OpenCode on DEVUP AI?

Create an API key in your dashboard, configure your OpenAI-compatible provider in opencode.json, and start executing agentic coding workflows today.