Deploy from Codex CLI
Use VibeHost from inside OpenAI's Codex CLI. Two paths: MCP server (interactive) or PAT-driven CLI (scripted).
The Codex CLI is OpenAI's local coding agent. It talks to VibeHost two ways: through our MCP server (interactive, OAuth) or through the vibehost CLI wrapped as a tool (scripted, PAT).
Option 1: MCP server (recommended for interactive use)
Add VibeHost with the Codex CLI:
codex mcp add vibehost --url https://api.vibehost.com/mcp
codex mcp login vibehostYour browser opens, you approve, and the flow returns to Codex. Codex can now call every VibeHost tool to deploy, promote, roll back, read logs, and manage custom domains.
You can verify the server is configured:
codex mcp listIf you prefer to edit config by hand, add this to ~/.codex/config.toml and then run codex mcp login vibehost:
[mcp_servers.vibehost]
url = "https://api.vibehost.com/mcp"In a Codex session, describe what you want:
Deploy this directory to VibeHost as a new app called my-codex-app. It's a Vite + React build.
Codex creates the app, uploads the files, deploys them and returns the live URL. The tool calls behind that are described once, in Choosing an upload path. Whether Codex asks before each step depends on its approval settings (see Confirmation prompts).
Option 2: CLI as a tool (recommended for scripts and CI)
Install the CLI:
curl -fsSL -o vibehost-install.sh https://vibehost.com/install.sh
cat vibehost-install.sh
sh vibehost-install.sh && rm vibehost-install.shAuthenticate once with a Personal Access Token. The example below reads the token from pass; substitute your own secret manager of choice:
export VIBEHOST_TOKEN=$(pass vibehost/pat)
vibehost whoami --jsonCodex can now invoke vibehost like any other shell command. Every command takes --json and returns {ok, data | error} so the agent can branch on error.code without parsing prose. See the CLI reference.
When to pick which
| Situation | Use |
|---|---|
| First-time setup | MCP (browser sign-in, no token to paste) |
| Interactive deploys from your editor | Either |
| Scripted / CI / unattended runs | CLI + PAT |
| You want every tool call to prompt for confirmation | MCP |
| You want zero confirmation prompts | CLI (with PAT) |
Both can coexist. Set up MCP for interactive sessions and keep the CLI installed for scripts.
See also
- MCP server lists every tool and explains authentication.
- Personal access tokens covers PAT setup for CI and other non-interactive use.
- Sibling coding agents: Claude Code, Cursor, Antigravity, Antigravity CLI, Windsurf, OpenCode, Copilot CLI, Hermes Agent, Grok Build