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 via the vibehost CLI wrapped as a tool (scripted, PAT).
Option 1: MCP server (recommended for interactive use)
Add VibeHost to your Codex config (~/.codex/config.toml):
[mcp_servers.vibehost]
url = "https://api.vibehost.com/mcp"Then trigger the OAuth flow once:
codex mcp login vibehostYour browser opens, you approve, the flow returns. Codex now has the full VibeHost tool surface — deploy, promote, rollback, list logs, manage custom domains.
In a Codex session, just describe what you want:
Deploy this directory to VibeHost as a new app called my-codex-app. It's a Vite + React build.
Codex picks the right tools (create_app + create_deployment) and returns the live URL. First-write tools prompt for confirmation by default.
Option 2: CLI as a tool (recommended for scripts and CI)
Install the CLI:
curl -fsSL https://vibehost.com/install.sh | shAuthenticate once with a Personal Access Token:
export VIBEHOST_TOKEN=$(pass vibehost/pat) # or your secret manager of choice
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 (OAuth is one-click) |
| 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 — full tool list + auth details
- Personal access tokens — PAT setup for CI / non-interactive use
- Sibling coding agents: Claude Code, Cursor, Antigravity, Windsurf, OpenCode, Copilot CLI, Gemini CLI, Hermes Agent