Skip to content

// integration

OpenAI API Integration

Applies to

Product: Cloud · Server · Audience: Developer / Integrator

basebox's OpenAI-compatible API allows you to use any tool, library, or application designed for OpenAI's API with your basebox instance.

The OpenAI-compatible API is always available — it no longer needs to be switched on and is part of every basebox installation. For Anthropic models, basebox adds no extra instructions to requests.

🚀 Quick Start

New to the OpenAI API? Start here:

  1. Quickstart - API key, base URL and realm; your first chat completion with curl and the OpenAI SDK
  2. User Guide - Complete technical documentation with examples
  3. IDE Integration - Connect your favorite code editor to basebox
  4. OpenClaw Integration - Use basebox with OpenClaw for AI coding workflows

🎯 What Can You Do?

With the OpenAI-compatible API, you can:

  • Use any OpenAI-compatible tool with the AI models in your basebox
  • Integrate AI into your development workflow (VS Code, Zed, Neovim, etc.)
  • Build custom applications using familiar OpenAI libraries
  • Test and prototype with interactive Swagger UI
  • Maintain privacy and control while using popular AI tools
  • Use thinking modes through the API — see Thinking Modes

📖 Documentation Overview

For Beginners

For Developers

For Tool Integration

🔧 Quick Examples

Test Your Connection

curl -H "Authorization: Bearer YOUR_API_TOKEN" \
     -H "X-Realm: YOUR_REALM" \
     https://your-basebox.example.com/v1/models

Simple Chat Request

curl -X POST "https://your-basebox.example.com/v1/chat/completions" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_API_TOKEN" \
     -H "X-Realm: YOUR_REALM" \
     -d '{
       "model": "claude-sonnet-4",
       "messages": [
         {"role": "user", "content": "Hello, what model are you?"}
       ]
     }'

Interactive Testing

Visit https://your-basebox.example.com/v1/api/docs for Swagger UI testing interface.

🆘 Need Help?

  • Code Assistance: Use GitHub Copilot, Cursor, or similar tools with your models
  • Custom Applications: Build chatbots, content generators, or analysis tools
  • Development Workflow: Integrate AI directly into your editor
  • Team Tools: Create organization-specific AI-powered utilities

The interactive Swagger UI is available at /v1/api/docs on your basebox instance.

Next step: Quickstart · User Guide

Need help? Contact support