Skip to content

Integrations and delegation ​

Oibre can connect external tools, load extensions, query language servers, delegate work, and search the web. These capabilities have different trust boundaries; none should be assumed to run in a sandbox.

MCP servers ​

Open /mcp and choose Add an MCP server, run /mcp add, or ask the agent to add a server with its command or URL and required credentials. The add flow test-connects the server before saving it and offers three scopes: this session, every session in this folder, or everywhere. In print mode, install tool calls need an explicit scope because there is no interactive picker.

Local servers use stdio with command, args, and env. Remote servers use HTTP/SSE with url, headers, and an optional transport. Connected tools appear as mcp__<server>__<tool>.

For remote credentials, enter complete headers such as Authorization: Bearer YOUR_API_KEY or X-API-Key: YOUR_API_KEY, according to the server's requirements. For local credentials, include the environment variable name, for example API_KEY=YOUR_API_KEY. Inputs are hidden; a blank line skips authentication or finishes adding credentials. Use the server's actual header or variable name, not just the key.

Session servers are saved with the conversation. Folder-scoped configuration is private to Oibre at ~/.oibre/projects/<project>/mcp.json, not in the repository; global configuration is at ~/.oibre/mcp.json. Both accept this shape:

json
{
  "mcpServers": {
    "example": {
      "command": "example-mcp-server",
      "args": [],
      "env": { "API_KEY": "$API_KEY" }
    }
  }
}

Environment references such as $API_KEY and ${API_KEY} expand on connection. Use /mcp to inspect status, /mcp reconnect to retry failed connections, and /mcp remove <name> to remove a server.

Treat servers as executable code and install only trusted servers. Repository .oibre/mcp.json and .mcp.json load only after /trust. /trust off disables repository MCP servers and extensions, but cannot undo or sandbox code that has already run. Print mode loads trusted MCP servers and extensions too.

Extensions ​

Place a TypeScript or JavaScript extension in ~/.oibre/extensions for all projects, or in a trusted project's .oibre/extensions. Entry points can be .ts, .js, or .mjs files, or folders with index.ts or index.js. A default-exported function receives an API with registerTool and registerCommand; see the repository's examples/extensions/word-count.ts for a working example.

Use Node/Bun builtins and relative imports. Bare npm imports work only when their packages are resolvable from the extension's location. Tool implementations receive raw model arguments and must validate them. /reload reloads entry modules, but not their imported dependencies; /extensions lists extensions and load errors.

Extensions execute with your process permissions. Trust project code before enabling it, and do not treat /trust off as a way to reverse prior side effects.

Language servers ​

The read-only lsp tool provides diagnostics, hover, definitions, type definitions, implementations, references, document symbols, and workspace-symbol search. It starts installed stdio language servers on demand, synchronizes file changes before queries, and closes servers on exit. It is available to the parent, children, print mode, and plan mode. Oibre does not download servers automatically; install the server and its runtime yourself.

To configure an exact command, add an entry to ~/.oibre/config.json and restart oc:

json
{
  "lsp": {
    "servers": {
      "typescript": {
        "argv": ["typescript-language-server", "--stdio"],
        "extensions": [".ts", ".tsx", ".js", ".jsx"],
        "rootMarkers": ["tsconfig.json", "package.json"],
        "timeoutMs": 20000
      }
    }
  }
}

Server entries also accept env, languageId, initializationOptions, and settings. Set "lsp": { "disabled": true } to hide the tool. Missing executables and unsupported capabilities return explicit errors. Positions and returned ranges use one-based UTF-16 columns; most emoji occupy two columns. Diagnostics include errors, warnings, and server hints.

Subagents ​

Ask the agent to delegate independent work, for example: “Have one agent inspect authentication and another inspect database access, then combine their findings.” The parent calls task with named assignments and receives job IDs immediately; it uses wait to collect results or errors. Up to four children run concurrently, with additional jobs queued. Each task call accepts up to 16 assignments and optional shared context. Children inherit the current model unless an assignment specifies another configured provider/model.

Each child has a fresh conversation, project instructions, session skills, and inherited tools, but cannot see the parent's conversation. Include the full requirements and acceptance criteria in each assignment. Children cannot delegate recursively, prompt the user, change MCP or skill configuration, or control other agents. A failed tool call fails the child and returns an error to the parent.

Children share the working directory and process permissions: there is no worktree isolation or sandbox. Give editing children non-overlapping files. Changes are real workspace changes; cancelling or removing a child does not undo files or external side effects.

Open /agents to see jobs and select a child, or use /agents <id> to watch its conversation and activity. Type in the child view to send a follow-up, even after its original assignment finishes; messages sent during a turn queue for its next turn. Each conversation keeps its own draft and attachments. /parent or Esc returns to the parent, which continues working while you view a child.

CommandAction
/agents listShow child IDs, states, activity, and pending-message counts
/agents message <id> <text>Send a follow-up without switching views
/agents pause <id|all>Request a cooperative pause after the current model request or tool finishes
/agents resume <id|all>Continue paused work without restarting completed steps
/agents cancel <id|all>Cancel unfinished work but keep its conversation
/agents remove <id|all>Cancel and drain work, then delete its in-memory conversation

The parent can also manage children via agent_control. A paused job remains unfinished, so a parent waiting for it continues waiting until it resumes, is cancelled, or is removed. The status bar shows active, queued, paused, and pending-pause counts. Interrupting the spawning turn cancels its unfinished children; session changes, conversation resets, and exit cancel and drain jobs. Jobs and conversations remain in memory for the active session until removed, not across restarts. Child token usage counts toward the session's per-model totals. Print mode supports the same delegation tools and cancels unfinished children before exit; plan mode does not expose delegation or child control.

Plan mode and web tools ​

Use /plan [prompt] or Alt+Shift+P to enable planning; the status bar shows PLAN. After a planning turn, choose Approve and implement it, Keep planning, or Exit plan mode.

Plan mode exposes only read, grep, find, lsp, web_search, web_fetch, and ask; shell, file writes, extensions, MCP tools, and delegation are excluded. This is a tool restriction, not an OS sandbox. Reads and network requests still have their normal effects.

Ask the agent to search or fetch a page when current web information is useful. web_search uses DuckDuckGo without a key by default. Set TAVILY_API_KEY, BRAVE_API_KEY, or EXA_API_KEY to select a keyed backend automatically, or configure one explicitly in ~/.oibre/config.json:

json
{
  "search": { "provider": "brave", "apiKey": "$BRAVE_API_KEY" }
}

Supported providers are auto, tavily, brave, exa, and duckduckgo. web_fetch extracts readable HTML, preserves links, and supports offset-based pagination. Search and fetch send network requests; avoid exposing sensitive information in queries or URLs.