Overview

VibeKit requires a configuration object to initialize the client. The configuration defines which AI agent to use, sandbox environment settings, GitHub integration, telemetry options, and session management.

Basic configuration

import { VibeKit, VibeKitConfig } from "@vibe-kit/sdk";

const config: VibeKitConfig = {
  agent: {
    type: "codex",
    model: {
      apiKey: "sk-proj-****"
      model: "codex-mini"
    },
  },
  environment: {
    // Option 1: E2B sandbox
    e2b: {
      apiKey: "e2b_****"
    }
    // Option 2: Daytona sandbox
    // daytona: {
    //   apiKey: "daytona_****",
    //   image: "codex-image",
    //   serverUrl: "https://app.daytona.io/api"
    // }
  },
  github: {
    token: "ghp_****",
    repository: "your-org/your-repo"
  },
  sessionId: "unique-session-identifier"
};

const vibeKit = new VibeKit(config);

Configuration reference

Agent Configuration

The agent section defines which AI model and mode to use.

agent.type

  • Type: "codex" | "claude" | "opencode" | "gemini"
  • Required: Yes
  • Description: The type of AI agent to use
  • Options:
    • "codex" - OpenAI Codex agent
    • "claude" - Anthropic Claude agent
    • "opencode" - Opencode agent
    • "gemini" - Google Gemini agent

agent.model

  • Type: AgentModel
  • Required: Yes
  • Description: Model configuration and API credentials
PropertyTypeRequiredDescription
namestringNoCustom name for the model
apiKeystringYesAPI key for the chosen agent provider
providerstringNoAI provider service

Available providers:

  • "openai" - OpenAI
  • "anthropic" - Anthropic
  • "openrouter" - OpenRouter
  • "azure" - Azure
  • "gemini" - Google Gemini
  • "ollama" - Ollama
  • "mistral" - Mistral AI
  • "deepseek" - DeepSeek
  • "xai" - xAI
  • "groq" - Groq
  • "arceeai" - Arcee AI
agent: {
  type: "codex",
  model: {
    name: "codex-mini-latest",
    apiKey: "sk-proj-****"
    provider: "openai"
  },
}

Environment Configuration

The environment section configures the sandbox environment where code execution happens.

E2B Configuration

environment: {
  e2b: {
    apiKey: "e2b_****",
    templateId: "custom-template-id" // optional
  }
}
PropertyTypeRequiredDescription
apiKeystringYesYour E2B API key
templateIdstringNoCustom template ID for the sandbox environment

Daytona Configuration

environment: {
  daytona: {
    apiKey: "daytona_****",
    image: "my-codex-image", // optional
    serverUrl: "https://app.daytona.io/api" // optional
  }
}
PropertyTypeRequiredDescription
apiKeystringYesYour Daytona API key
imagestringNoDocker image to use for the environment
serverUrlstringNoCustom Daytona server URL

GitHub Integration

The github section configures repository integration for pull request creation and code management.

github: {
  token: "ghp_****",
  repository: "superagent-ai/vibekit"
}
PropertyTypeRequiredDescription
tokenstringYesGitHub personal access token with repository permissions
repositorystringYesRepository in the format “owner/repo-name”

Telemetry Configuration (Optional)

The telemetry section enables OpenTelemetry observability for monitoring and debugging.

telemetry: {
  isEnabled: true,
  endpoint: "https://api.honeycomb.io/v1/traces",
  serviceName: "my-vibekit-app",
  serviceVersion: "1.0.0",
  headers: {
    "x-honeycomb-team": "your-api-key"
  },
  timeout: 5000,
  samplingRatio: 0.1,
  resourceAttributes: {
    environment: "production",
    region: "us-east-1"
  }
}
PropertyTypeRequiredDefaultDescription
isEnabledbooleanYes-Enable or disable telemetry collection
endpointstringNo-OTLP HTTP endpoint URL for traces
serviceNamestringNo"vibekit"Service name for resource attributes
serviceVersionstringNo"1.0.0"Service version for resource attributes
headersobjectNo-Additional headers for OTLP HTTP requests
timeoutnumberNo5000Request timeout in milliseconds
samplingRationumberNo1.0Sampling ratio from 0.0 to 1.0 (1.0 = 100% sampling)
resourceAttributesobjectNo-Additional resource attributes to include in telemetry data

Session Management (Optional)

sessionId: "unique-session-identifier"
PropertyTypeRequiredDescription
sessionIdstringNoUnique identifier for grouping related requests and maintaining conversation context