Coolify MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Coolify MCP Server Show me the status of my latest deployment"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Coolify MCP Server
A production-grade MCP (Model Context Protocol) server that provides AI agents with secure, controlled access to Coolify infrastructure management.
β‘ 1-Click AI Setup (Cursor, Claude, Windsurf, OpenCode, Copilot)
Give this single instruction or raw URL to any AI assistant:
Read https://raw.githubusercontent.com/hecateq/mcp-coolify/main/INSTALL_PROMPT.md and set up the Coolify MCP server for my active environment.
Table of Contents
Related MCP server: mcp-devtools
Why This MCP Exists
Coolify ships its own MCP integration that exposes raw Coolify API resources directly to AI agents. While powerful, that MCP operates as a transparent pass-through to the API, with minimal guardrails between the agent and your production infrastructure.
This MCP is different. It adds a security and policy enforcement layer between the AI agent and Coolify:
Aspect | Coolify Built-in MCP | This MCP Server |
Security Model | Direct API token passthrough | Least-privilege token selection, scoped by operation |
Operation Modes | None |
|
Access Control | Coolify-native RBAC only | Allowlists by project, environment, and resource UUID |
Production Guard | None | Blocks mutations on production environments by default |
Audit Trail | Minimal | Structured audit events for every mutation (allowed/denied/error) |
Secret Redaction | None | Automatic redaction of tokens, passwords, DB URLs, logs, SSH keys, email addresses |
Rate/Scope | Full API surface | 42 curated tools grouped into 10 domains: core, GitHub discovery, scheduled tasks, deployments, backups, servers, teams, configuration, storage, and environment variables |
This MCP is designed for operational control β letting AI safely observe, deploy, and manage Coolify resources without risking accidental production damage.
Architecture
ββββββββββββββββ MCP Protocol ββββββββββββββββββββββββββββββββββββββββββββββββββββ
β β (stdio or HTTP SSE) β β
β AI Agent βββββββββββββββββββββββββΊβ Coolify MCP Server β
β (Claude, β β β
β Copilot, β Tool Calls β ββββββββββββ ββββββββββββ ββββββββββββββββ β
β Cursor, βββββββββββββββββββββββββΊβ β Auth & βββΊβ Policy & βββΊβ Scope β β
β OpenCode) β JSON Responses β β Token β β Operationβ β Allowlist β β
β β β β Selector β β Mode β β β β
ββββββββββββββββ β ββββββββββββ ββββββ¬ββββββ ββββββββ¬ββββββββ β
β β β β
β βββββββββββββββββββββΌββββββββββββββββΌβββββββββ β
β β Production Guard β β
β β (Deny/allow production mutations) β β
β βββββββββββββββββββββ¬βββββββββββββββββββββββββ β
β β β
β βββββββββββββββββββββΌβββββββββββββββββββββββββ β
β β Tool Domains (42 tools across 10 areas) β β
β β β β
β β Core Read (10) β GitHub Discovery (3) β β
β β Actions (11) β Scheduled Tasks (4) β β
β β Servers (5) β Backups (2) β β
β β Teams (2) β Configuration (2) β β
β β Storage (2) β Deployments (1) β β
β βββββββββββββββββββββ¬βββββββββββββββββββββββββ β
β β β
β βββββββββββββββββββββΌβββββββββββββββββββββββββ β
β β Coolify API Client β β
β β (Token-scoped HTTP requests, redaction) β β
β βββββββββββββββββββββ¬βββββββββββββββββββββββββ β
β β β
ββββββββββββββββββββββββΌββββββββββββββββββββββββββββ
β
HTTPS (Bearer Token)
β
ββββββββββββββββββββββββΌβββββββββββββββββββββββββββ
β Coolify Instance β
β (Projects, Resources, Deployments, Envs, β
β Servers, Teams, GitHub Apps, Backups, β
β Scheduled Tasks, Storage Mounts) β
βββββββββββββββββββββββββββββββββββββββββββββββββββSecurity Model
Least-Privilege Tokens
Instead of a single master token, you can configure up to 5 scoped tokens:
Token Env Var | Used For | Example Coolify Token Scopes |
| All read operations (list/get resources) |
|
| Reading sensitive data (env vars, logs) |
|
| Write operations (set env vars) |
|
| Deploy/start/restart operations |
|
| Fallback when no scoped token matches |
|
The server selects the minimum-privilege token for each operation. If COOLIFY_READ_TOKEN is set, list-projects uses it, never the master token.
Secret Redaction
Environment variable values are NEVER returned by
coolify_list_environment_variablesβ only keys and metadata.Logs are scanned for
Bearertokens,password,secret,api_keypatterns and automatically redacted.The Pino logger has built-in redaction paths for sensitive fields.
Audit events do not contain secret values.
Phase 2 Security Controls
With the addition of 21 new tools in Phase 2, the following security controls were added:
Scheduled Task Command Redaction
Task command output in
coolify_get_task_executionsis redacted to prevent command injection visibility.Cron expressions are validated server-side before creation/update.
Path Traversal Prevention (Storage)
coolify_create_storagevalidatessourceanddestinationpaths against directory traversal patterns (../,..\\, absolute paths).If a path contains traversal sequences, the operation is denied with a
VALIDATION_ERROR.
Field Allowlisting (Configuration Updates)
coolify_update_application_configandcoolify_update_database_configuse PATCH semantics with explicit field allowlisting.Only documented fields can be updated. Arbitrary field injection is blocked.
Each update is audited with
coolify.application.config.update/coolify.database.config.updateevents.
Email/SSH Key Redaction
coolify_list_team_membersgates email addresses behind policy. By default,[REDACTED]is returned.coolify_get_serverredacts SSH private keys and sensitive connection details.coolify_list_serversredacts network information (IP addresses, ports).
GitHub Discovery Security
coolify_list_github_appsreturns no secrets β only UUID, name, organization, and installation metadata.Repository browsing is scoped to what the configured GitHub App can access.
All GitHub discovery tools are read-only with no mutation capabilities.
Database Password Protection
coolify_create_databasenever returns generated passwords or connection strings in its response.coolify_list_database_backupsredacts destination storage paths.
Additional Protections
Timing-safe API key comparison for HTTP transport auth (prevents timing attacks).
Scope checking via allowlists before any operation touches a resource.
Production guard runs before any mutation.
Coolify API Permissions
The relationship between the Coolify API token permissions and this MCP's tool categories:
Permission Class | Required Coolify Token Scope | MCP Tools |
Read |
| All 25 read tools (core + discovery + servers + teams + storage) |
Sensitive Read |
|
|
Deploy |
|
|
Write |
| All safe-write tools (create project/env/app/service/db, set env vars, create scheduled tasks, create backups, create storage, update configs, validate server) |
Stop |
|
|
Quick Start
Prerequisites
Node.js >= 18
A Coolify instance with API tokens configured
Coolify API token(s) with appropriate scopes
Option A β Install from npm (recommended)
npm install -g @imhecateq/mcp-coolify
# Or run it on the fly
npx -y @imhecateq/mcp-coolifyOption B β Install from GitHub
git clone https://github.com/hecateq/mcp-coolify.git
cd mcp-coolify
npm install
npm run buildThen configure your MCP client (see Local stdio Usage) with:
{
"type": "local",
"command": ["node", "node_modules/@imhecateq/mcp-coolify/dist/index.js"],
"environment": { "COOLIFY_URL": "...", "COOLIFY_API_TOKEN": "..." }
}Option C β Clone and run locally
# 1. Clone the repository
git clone https://github.com/hecateq/mcp-coolify.git
cd mcp-coolify
# 2. Install dependencies (prepares dist/ automatically)
npm install
# 3. Configure environment
cp .env.example .env
# Edit .env with your Coolify URL and API token
# 4. Run the server (stdio mode β default)
npm startTest the connection
The server exposes a health tool. In stdio mode, use an MCP client to query:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "coolify_health",
"arguments": {}
}
}Expected response:
{
"content": [{
"text": "{\n \"ok\": true,\n \"coolifyUrl\": \"[CONFIGURED]\",\n \"authStatus\": \"authenticated\",\n \"latencyMs\": 42,\n \"transport\": \"stdio\"\n}"
}]
}π€ LLM Install Prompt (copy-paste this into any AI assistant)
Copy and paste this single instruction into any AI assistant (Cursor, Claude Code, Gemini CLI, OpenCode, GitHub Copilot, Windsurf, Aider, etc.):
Read https://raw.githubusercontent.com/hecateq/mcp-coolify/main/INSTALL_PROMPT.md and set up the Coolify MCP server for my environment.Or copy the prompt instructions directly:
Configure the @imhecateq/mcp-coolify MCP server on this machine.
1. Ask me first for:
- COOLIFY_URL (e.g. https://coolify.example.com)
- COOLIFY_API_TOKEN (read-only token is fine)
- COOLIFY_OPERATION_MODE (default: read-only)
2. Detect my MCP client (Cursor .cursor/mcp.json, Claude Desktop claude_desktop_config.json, OpenCode opencode.json, Cline, etc.) and add:
- command: "npx"
- args: ["-y", "@imhecateq/mcp-coolify"]
- env: { COOLIFY_URL, COOLIFY_API_TOKEN, COOLIFY_OPERATION_MODE: "read-only" }
3. Verify connection by calling `coolify_health`.
Show me what changed when done.See INSTALL_PROMPT.md for the standalone guide.
Environment Variables
All configuration is via environment variables. Read from src/config/schema.ts via Zod validation.
Required
Variable | Type | Default | Description |
|
| β | Base URL of your Coolify instance (e.g. |
API Tokens (at least one required)
Variable | Type | Default | Description |
|
| β | Fallback API token (used when no scoped token matches) |
|
| β | Read-only token for normal read operations |
|
| β | Token for reading sensitive data (envs, logs) |
|
| β | Token for write operations (env vars, settings) |
|
| β | Token for deploy operations |
Note: Scoped tokens override
COOLIFY_API_TOKEN. The server automatically selects the least-privilege token for each operation.
Transport
Variable | Type | Default | Description |
|
|
| Transport mode |
|
|
| HTTP transport host (only used when |
|
|
| HTTP transport port |
|
| β | API key for authenticating HTTP MCP requests (required for HTTP transport) |
Operation Mode
Variable | Type | Default | Description |
|
|
| Restricts what operations the MCP server allows |
Allowlists (Optional)
Variable | Type | Default | Description |
|
| β | Restrict access to specific projects. Accepts UUID v4 or Coolify-native identifiers |
|
| β | Restrict access to specific environments. Accepts UUID v4 or Coolify-native identifiers |
|
| β | Restrict access to specific resources. Accepts UUID v4 or Coolify-native identifiers |
Production Protection
Variable | Type | Default | Description |
|
|
| Environment names considered "production" |
|
|
| Block all mutations on production environments |
|
|
| Allow deploy on production (only if |
|
|
| Allow stop operations (globally) |
|
|
| Allow environment variable modifications |
Logging
Variable | Type | Default | Description |
|
|
| Max log lines to return from application logs |
|
|
| Pino log level ( |
Local stdio Usage (Client Configuration)
1. OpenCode (opencode.local.jsonc or opencode.json)
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"coolify": {
"type": "local",
"command": ["npx", "-y", "@imhecateq/mcp-coolify"],
"environment": {
"COOLIFY_URL": "https://coolify.example.com",
"COOLIFY_API_TOKEN": "{env:COOLIFY_API_TOKEN}",
"COOLIFY_OPERATION_MODE": "read-only"
}
}
}
}Using a local clone? Replace
"command": ["npx", "-y", "@imhecateq/mcp-coolify"]with"command": ["node", "/path/to/mcp-coolify/dist/index.js"]. A complete example is atexamples/opencode.local.jsonc.
2. Claude Desktop (claude_desktop_config.json)
On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%\Claude\claude_desktop_config.json
On Linux: ~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"coolify": {
"command": "npx",
"args": ["-y", "@imhecateq/mcp-coolify"],
"env": {
"COOLIFY_URL": "https://coolify.example.com",
"COOLIFY_API_TOKEN": "your-coolify-api-token",
"COOLIFY_OPERATION_MODE": "read-only"
}
}
}
}3. Cursor (.cursor/mcp.json)
{
"mcpServers": {
"coolify": {
"command": "npx",
"args": ["-y", "@imhecateq/mcp-coolify"],
"env": {
"COOLIFY_URL": "https://coolify.example.com",
"COOLIFY_API_TOKEN": "your-coolify-api-token",
"COOLIFY_OPERATION_MODE": "read-only"
}
}
}
}4. VS Code (Cline / Roo Code)
In your MCP settings (cline_mcp_settings.json):
{
"mcpServers": {
"coolify": {
"command": "npx",
"args": ["-y", "@imhecateq/mcp-coolify"],
"env": {
"COOLIFY_URL": "https://coolify.example.com",
"COOLIFY_API_TOKEN": "your-coolify-api-token",
"COOLIFY_OPERATION_MODE": "read-only"
},
"disabled": false,
"autoApprove": []
}
}
}Remote HTTP Usage (OpenCode)
When running the MCP server in HTTP mode behind a reverse proxy, configure OpenCode for remote access:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"coolify-remote": {
"type": "remote",
"url": "https://coolify-mcp.example.com/mcp",
"headers": {
"Authorization": "Bearer {env:MCP_SERVER_API_KEY}"
}
}
}
}A complete example is at examples/opencode.remote.jsonc.
HTTP Transport Endpoints
Endpoint | Auth Required | Purpose |
| No | Liveness check β returns |
| No | Readiness check β verifies Coolify API is reachable |
| Yes (Bearer) | MCP protocol endpoint β all tool calls go here |
Tool Catalog
The server registers 42 tools: 25 read-only tools and 17 action (mutation/deploy) tools.
Note: Tool numbering is for reference only. Tools 1-15 are Phase 1 (original), tools 16-42 are Phase 2 (new).
Read Tools (25)
Core Read Tools (10 β Phase 1)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
1 |
| Check Coolify API and MCP server connectivity. Returns health status, auth status, and latency. No secrets in response. |
| β | β |
2 |
| List all Coolify projects with optional name filter. |
| β | β |
3 |
| Get a single project by UUID with its environments and resource counts. |
| β | β |
4 |
| List all resources with filters. |
| β | β |
5 |
| Get a single resource detail by UUID and type. Sensitive fields (DB URLs) redacted. |
| β | β |
6 |
| High-level project overview: project info, envs, resources, deployments, health summary. Aggregates 4 API calls into one. |
| β | β |
7 |
| List deployments with filters. Newest first. |
| β | β |
8 |
| Get deployment detail by UUID: status, timestamps, commit info, error summary. |
| β | β |
9 |
| Get application logs (capped by |
| β | β |
10 |
| List env vars for a resource. Values are NEVER returned β only keys and metadata. |
| β | β |
GitHub Discovery Tools (3 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
16 |
| List GitHub Apps connected to your Coolify instance. Returns team and system-wide apps. No secrets. |
| β | β |
17 |
| List repositories accessible via a GitHub App. Supports pagination and search. |
| β | β |
18 |
| List branches of a GitHub repository via a GitHub App. |
| β | β |
Scheduled Task Read Tools (2 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
19 |
| List scheduled tasks for an application or service. Returns task UUID, name, command, schedule, enabled, last execution. |
| β | β |
20 |
| Get execution history for a scheduled task. Output is redacted for security. |
| β | β |
Backup Read Tool (1 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
21 |
| List backup configurations and executions for a database. Sensitive destination paths are redacted. |
| β | β |
Server Read Tools (4 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
22 |
| List all servers connected to your Coolify instance. Sensitive network info and SSH keys redacted. |
| β | β |
23 |
| Get a single server detail by UUID. SSH keys and sensitive network info redacted. |
| β | β |
24 |
| List resources associated with a specific server. |
| β | β |
25 |
| List domains associated with a server. |
| β | β |
Team Read Tools (2 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
26 |
| Get the current team context: id, name, and permission scope. |
| β | β |
27 |
| List members of the current team. Email addresses policy-gated and redacted by default. |
| β | β |
Storage Read Tool (1 β Phase 2)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
28 |
| List storage mounts for an app/service/database. Sensitive host paths redacted. |
| β | β |
Configuration Update Tools (2 β Phase 2, safe-write)
# | Tool Name | Purpose | Input | Read-Only | Idempotent |
29 |
| Update application config: health check, resource limits, replicas, ports, build settings. PATCH semantics. Audit: |
| β (safe-write) | β |
30 |
| Update database config: CPU/memory limits, name, description. PATCH semantics. Audit: |
| β (safe-write) | β |
Action Tools (17)
Core Deploy Tools (5 β Phase 1)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
11 |
| Deploy a resource. Supports force deploy (POST vs GET). |
| β | β | Mode + Scope + Production |
12 |
| Restart a resource. |
| β οΈ | β | Mode + Scope + Production |
13 |
| Start a stopped resource. |
| β | β | Mode + Scope + Production |
14 |
| Stop a resource. Disabled by default β must set |
| β | β | AllowStop gate + Mode + Scope + Production |
15 |
| Set a single env var on a resource. Disabled by default β |
| β οΈ | β | AllowEnvWrite gate + Mode + Scope + Production |
New Action Tools (6 β Phase 2, safe-write)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
31 |
| Create a new project. |
| β | β | Mode + Scope + Production |
32 |
| Create a new environment within a project. |
| β | β | Mode + Scope + Production |
33 |
| Create a new application in a project environment. |
| β | β | Mode + Scope + Production |
34 |
| Create a new service in a project environment. |
| β | β | Mode + Scope + Production |
35 |
| Create a new database. Passwords/connection strings NEVER returned. |
| β | β | Mode + Scope + Production |
36 |
| Set multiple env vars in bulk (1β50). Disabled by default β |
| β οΈ | β | AllowEnvWrite gate + Mode + Scope + Production |
Deployment Action Tool (1 β Phase 2)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
37 |
| Cancel a queued or in-progress deployment. Returns UNSUPPORTED_OPERATION for terminal states. Audit: |
| β | β | Mode + Scope |
Backup Action Tool (1 β Phase 2, safe-write)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
38 |
| Create a backup config for a database. Cron expression validated. Audit: |
| β | β | Mode + Scope + Production |
Scheduled Task Action Tools (2 β Phase 2, safe-write)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
39 |
| Create a scheduled task (cron job). Cron expression validated. Audit: |
| β | β | Mode + Scope + Production |
40 |
| Update a scheduled task. |
| β | β | Mode + Scope + Production |
Server Validation Tool (1 β Phase 2)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
41 |
| Validate server connectivity and configuration. Audited as mutation action. |
| β | β | Mode + Scope |
Storage Action Tool (1 β Phase 2, safe-write)
# | Tool Name | Purpose | Input | Destructive | Idempotent | Policy Checks |
42 |
| Create a storage mount for a resource. Path traversal validated. Audit: |
| β | β | Mode + Scope + Production |
Policy Check Chain (Action Tools)
Every action tool runs through the following policy checks before executing:
Allow Gate Check β Some tools have dedicated allow gates:
COOLIFY_ALLOW_STOP(for stop),COOLIFY_ALLOW_ENV_WRITE(for env var modifications). If the gate is closed, the operation is denied.Operation Mode Check β Does the mode (
read-only/deploy-only/safe-write) permit this operation?Scope/Allowlist Check β Is the target resource UUID in the allowed list (if configured)?
Production Guard Check β If the
environment_namematches a production pattern, is this mutation allowed?Input Validation β All inputs are validated via Zod schemas. Cron expressions are validated. Path traversal is prevented for storage operations.
Audit Logging β Every mutation is logged with a structured audit event containing the operation, resource, and result (allowed/denied/error).
If any check fails, the operation is denied with a POLICY_DENIED error code and an audit event is logged.
Common Response Format
All tools return a consistent JSON response structure:
Success:
{
"ok": true,
"summary": "Found 3 project(s)",
"data": [ /* ... */ ],
"meta": {
"durationMs": 42,
"truncated": false
}
}Error (policy denied):
{
"ok": false,
"summary": "Operation denied by policy",
"error": {
"code": "POLICY_DENIED",
"message": "Operation mode is 'read-only' β 'deploy' operations are not permitted",
"retryable": false
},
"meta": {
"durationMs": 5
}
}Error (upstream):
{
"ok": false,
"summary": "Failed to list projects",
"error": {
"code": "UPSTREAM_ERROR",
"message": "Coolify API returned status 500",
"retryable": true
},
"meta": {
"durationMs": 1203
}
}Error Codes
Code | Meaning | Retryable |
| Token missing or invalid | β |
| Token lacks required scope | β |
| Operation blocked by MCP policy (mode/scope/production) | β |
| Coolify resource not found (404) | β |
| Coolify API rate limit hit (429) | β |
| Coolify instance unreachable or 5xx | β |
| Request exceeded 30s timeout | β |
| Invalid input parameters | β |
| Generic Coolify API error | varies |
| MCP server internal error | β |
Operation Modes
The COOLIFY_OPERATION_MODE environment variable controls what operations the MCP server permits:
read-only (default)
Safe for monitoring and exploration. Only the 10 read tools are allowed. All 5 action tools return POLICY_DENIED.
Allowed | Denied |
All read tools (health, list, get, logs) | All action tools (deploy, restart, start, stop, set env) |
deploy-only
Read access plus deploy operations (deploy, restart, start). Write operations (stop, set env vars) are denied.
Allowed | Denied |
All read tools |
|
|
|
| |
|
safe-write
Full read + deploy + write access. Stop and env-write are still gated behind their respective ALLOW_* flags.
Allowed | Gated By |
All read tools | β |
| β |
| β |
| β |
|
|
|
|
Mode Decision Matrix
Operation |
|
|
|
All read tools (25) | β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β
(if |
| β | β | β
(if |
| β | β | β
(if |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
| β | β | β |
Production Safeguards
Production Environment Detection
The server defines "production" environments via COOLIFY_PRODUCTION_ENV_NAMES (default: production,prod). When an action tool receives an environment_name parameter, it checks if that name matches any production name (case-insensitive).
Protection Layers
Layer | Env Var | Default | Effect |
Deny All Production Mutations |
|
| Blocks ALL mutations (deploy, restart, start, stop, env write) on production environments |
Allow Production Deploy |
|
| If |
Allow Stop |
|
| Globally disables stop operations. Required for production stop too |
Allow Env Write |
|
| Globally disables env var modifications. Required for production env writes too |
Recommended Production Configuration
# Strict β no mutations on production at all (default)
COOLIFY_OPERATION_MODE=read-only
COOLIFY_DENY_PRODUCTION_MUTATIONS=true
COOLIFY_ALLOW_STOP=false
COOLIFY_ALLOW_ENV_WRITE=false# Moderate β allow deploys to production, block everything else
COOLIFY_OPERATION_MODE=deploy-only
COOLIFY_DENY_PRODUCTION_MUTATIONS=false
COOLIFY_ALLOW_PRODUCTION_DEPLOY=true
COOLIFY_ALLOW_STOP=false
COOLIFY_ALLOW_ENV_WRITE=falseDocker Usage
Build from source
npm run buildRun with Docker
FROM node:20-alpine
WORKDIR /app
COPY package*.json ./
RUN npm ci --only=production
COPY dist/ ./dist/
EXPOSE 3000
CMD ["node", "dist/index.js"]Docker Compose
services:
coolify-mcp:
build: .
environment:
COOLIFY_URL: "https://coolify.example.com"
COOLIFY_API_TOKEN: "${COOLIFY_API_TOKEN}"
MCP_TRANSPORT: "http"
MCP_HTTP_PORT: "3000"
MCP_SERVER_API_KEY: "${MCP_SERVER_API_KEY}"
COOLIFY_OPERATION_MODE: "read-only"
ports:
- "3000:3000"Troubleshooting
Server won't start
Symptom: Configuration validation failed: coolifyUrl: Required
Fix: Set COOLIFY_URL environment variable to your Coolify instance URL.
export COOLIFY_URL="https://coolify.example.com"Symptom: Configuration validation failed: coolifyUrl: Invalid URL
Fix: Ensure COOLIFY_URL is a valid URL including protocol (https://).
Authentication failures
Symptom: AUTHENTICATION_FAILED β "No Coolify API token configured"
Fix: Set at least COOLIFY_API_TOKEN or a scoped token like COOLIFY_READ_TOKEN.
HTTP transport not working
Symptom: MCP_SERVER_API_KEY is required for HTTP transport mode
Fix: Set MCP_SERVER_API_KEY to a strong random key when using MCP_TRANSPORT=http.
# Generate a secure key
openssl rand -hex 32Production mutations blocked
Symptom: POLICY_DENIED β "Production mutations are denied"
Cause: Environment name matches a production pattern (default: production, prod) and COOLIFY_DENY_PRODUCTION_MUTATIONS is true (the default).
Fix: If intentional, use a non-production environment. To allow production mutations, set COOLIFY_DENY_PRODUCTION_MUTATIONS=false and review the specific allow flags.
Stop operations blocked
Symptom: POLICY_DENIED β "Stop operations are disabled"
Cause: COOLIFY_ALLOW_STOP defaults to false.
Fix: Set COOLIFY_ALLOW_STOP=true if stop operations are required.
Application logs truncated
Symptom: Logs show fewer lines than requested
Cause: Server caps at COOLIFY_LOG_MAX_LINES (default 200, max 1000).
Fix: Increase COOLIFY_LOG_MAX_LINES up to 1000, or request fewer lines.
Development
Commands
npm run dev # Run in development mode with hot-reload (tsx watch)
npm run build # Build to dist/ (tsup, ESM format)
npm start # Run the built server
npm test # Run all tests (vitest)
npm run test:watch # Run tests in watch mode
npm run test:coverage # Run tests with coverage report
npm run lint # Lint source code
npm run lint:fix # Fix lint issues
npm run format # Format with Prettier
npm run typecheck # Type-check without emitting (tsc --noEmit)Project Structure
src/
βββ config/
β βββ schema.ts # Zod schema for all environment config
β βββ load-config.ts # Config loading and validation
βββ coolify/
β βββ client.ts # Coolify API HTTP client
β βββ types.ts # TypeScript types for Coolify data models
β βββ normalizers.ts # Response normalizers (strip undefined, redact secrets)
β βββ errors.ts # Error handling and mapping
βββ security/
β βββ policy.ts # Operation mode enforcement
β βββ scope.ts # Allowlist-based scope checking
β βββ production-guard.ts # Production environment protection
β βββ redaction.ts # Secret redaction utilities
βββ observability/
β βββ logger.ts # Pino logger with secret redaction
β βββ audit.ts # Structured audit event logging
βββ server/
β βββ create-server.ts # MCP server setup and tool registration (42 tools)
βββ tools/
β βββ read/ # 10 core read-only tools (Phase 1)
β βββ actions/ # 11 action tools (5 Phase 1 + 6 Phase 2)
β βββ discovery/ # 3 GitHub discovery tools (Phase 2)
β βββ scheduled-tasks/ # 4 scheduled task tools (Phase 2)
β βββ deployments/ # 1 deployment cancel tool (Phase 2)
β βββ backups/ # 2 database backup tools (Phase 2)
β βββ servers/ # 5 server tools (Phase 2)
β βββ teams/ # 2 team tools (Phase 2)
β βββ configuration/ # 2 config update tools (Phase 2)
β βββ storage/ # 2 storage tools (Phase 2)
βββ transports/
β βββ stdio.ts # stdio transport (default)
β βββ http.ts # HTTP/SSE transport with auth
βββ index.ts # Entry pointLicense
Available Tools
59 toolscoolify_cancel_deploymentA
Cancel a queued or in-progress deployment. Returns UNSUPPORTED_OPERATION for terminal states. Audit: coolify.deployment.cancel.
Inputs: deployment_uuid (required).
coolify_create_applicationA
Create a new application in a project environment. Subject to operation mode, allowlist, and production guard policies.
Inputs: name (required), project_uuid (required), environment_uuid (required), port, +6 more.
coolify_create_backup_configA
Create a backup configuration for a database. Cron expression is validated. Audit: coolify.database_backup_config.create
Inputs: schedule (required), database_uuid (required), enabled, retention, +1 more.
coolify_create_databaseA
Create a new database in a project environment. Passwords and connection strings are NEVER returned in response. Requires safe-write operation mode.
Inputs: name (required), server_uuid (required), project_uuid (required), database_type (required), +3 more.
coolify_create_destinationA
Create a Docker network destination on a server. Subject to operation mode, allowlist, and production guard policies. Audit: coolify.destination.create.
Inputs: network (required), server_uuid (required), name, destination_type.
coolify_create_environmentA
Create a new environment within a project. Requires safe-write operation mode.
Inputs: name (required), project_uuid (required).
coolify_create_projectB
Create a new project. Requires safe-write operation mode.
Inputs: name (required), description.
coolify_create_s3_storageA
Create a new S3 storage configuration for the authenticated team. Credentials are never returned or logged. Subject to operation mode policy. Audit: coolify.s3_storage.create
Inputs: key (required), name (required), bucket (required), region (required), +4 more.
coolify_create_scheduled_taskA
Create a scheduled task (cron job) on an application or service. Subject to operation mode, allowlist, and production guard policies. Cron expression is validated.
Inputs: name (required), command (required), schedule (required), resource_type (required), +5 more.
coolify_create_serviceA
Create a new service in a project environment. Requires safe-write operation mode.
Inputs: name (required), server_uuid (required), project_uuid (required), environment_uuid (required), +3 more.
coolify_create_storageA
Create a storage mount for a resource. Path traversal is validated. Subject to operation mode, allowlist, and production guard policies. Audit: coolify.storage.create
Inputs: source (required), destination (required), resource_type (required), resource_uuid (required), +2 more.
coolify_deployBIdempotent
Deploy a resource. Subject to operation mode, allowlist, and production guard policies.
Inputs: resource_type (required), resource_uuid (required), force, environment_name.
coolify_execute_scheduled_taskA
Execute a scheduled task immediately. Subject to operation mode, allowlist, and production guard policies.
Inputs: task_uuid (required), resource_type (required), resource_uuid (required).
coolify_get_application_logsARead-onlyIdempotent
Get application logs with configurable line count (capped by COOLIFY_LOG_MAX_LINES). Secrets are redacted.
Inputs: application_uuid (required), lines.
coolify_get_current_teamARead-onlyIdempotent
Get the current team context: id, name, and permission scope.
Inputs: no named parameters.
coolify_get_database_logsARead-onlyIdempotent
Get database container logs. Secrets are redacted.
Inputs: database_uuid (required), lines.
coolify_get_deploymentARead-onlyIdempotent
Get deployment detail by UUID: status, timestamps, commit info, error summary.
Inputs: deployment_uuid (required).
coolify_get_destinationARead-onlyIdempotent
Get a single destination by UUID.
Inputs: destination_uuid (required).
coolify_get_projectARead-onlyIdempotent
Get a single project by UUID with its environments and resource counts.
Inputs: uuid (required).
coolify_get_resourceARead-onlyIdempotent
Get a single resource detail by UUID and type. Sensitive fields are redacted.
Inputs: type (required), uuid (required).
coolify_get_serverARead-onlyIdempotent
Get a single server detail by UUID. SSH keys and sensitive network info are redacted.
Inputs: uuid (required).
coolify_get_service_logsARead-onlyIdempotent
Get service container logs. Secrets are redacted.
Inputs: service_uuid (required), lines.
coolify_get_task_executionsARead-onlyIdempotent
Get execution history for a scheduled task. Output is redacted for security.
Inputs: task_uuid (required), resource_uuid (required), limit, status, +1 more.
coolify_get_versionARead-onlyIdempotent
Get the Coolify instance version.
Inputs: no named parameters.
coolify_healthARead-onlyIdempotent
Check Coolify API and MCP server connectivity. Returns health status, auth status, and latency. No secrets in response.
Inputs: no named parameters.
coolify_list_backup_executionsARead-onlyIdempotent
List backup executions for a scheduled backup configuration. Output is redacted for security.
Inputs: database_uuid (required), scheduled_backup_uuid (required), limit.
coolify_list_branchesARead-onlyIdempotent
List branches of a GitHub repository via a GitHub App.
Inputs: owner (required), repository (required), github_app_uuid (required).
coolify_list_database_backupsARead-onlyIdempotent
List backup executions for a database. Sensitive destination paths are redacted.
Inputs: database_uuid (required).
coolify_list_deploymentsARead-onlyIdempotent
List deployments with filters: resource_uuid, status, limit. Newest first.
Inputs: limit, status, resource_uuid.
coolify_list_destinationsARead-onlyIdempotent
List all Docker network destinations for the authenticated team.
Inputs: no named parameters.
coolify_list_environment_variablesARead-onlyIdempotent
List environment variables for a resource. Returns keys and metadata only β VALUES ARE NEVER RETURNED.
Inputs: resource_type (required), resource_uuid (required), environment_name.
coolify_list_github_appsARead-onlyIdempotent
List GitHub Apps connected to your Coolify instance. Returns team and system-wide apps.
Inputs: no named parameters.
coolify_list_notificationsARead-onlyIdempotent
List notification channel settings. Credential values (webhook URLs, tokens, passwords) are never exposed.
Inputs: channel.
coolify_list_projectsARead-onlyIdempotent
List all Coolify projects with optional name filter.
Inputs: name.
coolify_list_repositoriesARead-onlyIdempotent
List repositories accessible via a GitHub App. Supports pagination and search.
Inputs: github_app_uuid (required), page, limit, search.
coolify_list_resourcesARead-onlyIdempotent
List all resources with filters: project_uuid, environment_uuid, resource_type, status, search.
Inputs: search, status, project_uuid, resource_type, +1 more.
coolify_list_rollback_imagesARead-onlyIdempotent
List available Docker images for rolling back an application. Returns current tag and available image tags.
Inputs: application_uuid (required).
coolify_list_s3_storagesARead-onlyIdempotent
List all S3 storages for the authenticated team with optional name filter. Credentials are NEVER returned.
Inputs: name.
coolify_list_scheduled_tasksBRead-onlyIdempotent
List scheduled tasks for an application or service.
Inputs: resource_uuid (required), resource_type.
coolify_list_server_domainsARead-onlyIdempotent
List domains associated with a server.
Inputs: server_uuid (required).
coolify_list_server_resourcesARead-onlyIdempotent
List resources associated with a specific server with optional type and status filters.
Inputs: server_uuid (required), status, resource_type.
coolify_list_serversARead-onlyIdempotent
List all servers connected to your Coolify instance. Sensitive network info and SSH keys are redacted.
Inputs: no named parameters.
coolify_list_storagesARead-onlyIdempotent
List storage mounts for an application, service, or database. Sensitive host paths are redacted.
Inputs: resource_type (required), resource_uuid (required).
coolify_list_team_membersARead-onlyIdempotent
List members of the current team. Email addresses are policy-gated and redacted by default.
Inputs: no named parameters.
coolify_project_overviewARead-onlyIdempotent
High-level project overview: project info, all environments, resources with status, recent deployments, and health summary. Optimized to prevent multiple separate calls.
Inputs: project_uuid (required).
coolify_restartADestructive
Restart a resource. Production policy check is mandatory.
Inputs: resource_type (required), resource_uuid (required), environment_name.
coolify_rollback_applicationADestructive
Queue a rollback deployment for an application to a previous image tag/commit. Deploy-only operation subject to operation mode, allowlist, and production guard policies. Audit: coolify.application.rollback
Inputs: image (required), application_uuid (required), environment_name.
coolify_run_volume_backupA
Run a volume backup for a storage mount on an application, database, or service. Subject to operation mode, allowlist, and production guard policies.
Inputs: storage_uuid (required), resource_type (required), resource_uuid (required).
coolify_set_environment_variableADestructiveIdempotent
Set an environment variable on a resource. DEFAULT DISABLED β COOLIFY_ALLOW_ENV_WRITE must be true. Value is NEVER returned in response.
Inputs: key (required), value (required), resource_uuid (required), environment_name.
coolify_set_environment_variablesAIdempotent
Set multiple environment variables on a resource in bulk (1-50). DEFAULT DISABLED β COOLIFY_ALLOW_ENV_WRITE must be true. Values are NEVER returned in response.
Inputs: variables (required), resource_type (required), resource_uuid (required), environment_name.
coolify_startAIdempotent
Start a stopped resource.
Inputs: resource_type (required), resource_uuid (required), environment_name.
coolify_stopBDestructive
Stop a resource. DEFAULT DISABLED β COOLIFY_ALLOW_STOP must be true. Marked destructive.
Inputs: resource_type (required), resource_uuid (required), environment_name.
coolify_update_application_configAIdempotent
Update application configuration: health check, resource limits, replicas, ports, build settings. PATCH semantics. Audit: coolify.application.config.update
Inputs: application_uuid (required), fqdn, name, ports, +11 more.
coolify_update_backup_configAIdempotent
Update a backup configuration for a database. PATCH semantics β only provided fields are updated. Cron expression is validated.
Inputs: database_uuid (required), scheduled_backup_uuid (required), enabled, schedule, +1 more.
coolify_update_database_configAIdempotent
Update database configuration: CPU/memory limits, name, description. PATCH semantics. Audit: coolify.database.config.update
Inputs: database_uuid (required), name, cpu_limit, description, +1 more.
coolify_update_notificationB
Update notification settings for a channel. PATCH semantics. Credential values are never echoed back or logged. Subject to operation mode and production guard policies. Audit: coolify.notification.update.
Inputs: no named parameters.
coolify_update_scheduled_taskBIdempotent
Update a scheduled task. Subject to operation mode, allowlist, and production guard policies.
Inputs: task_uuid (required), resource_type (required), resource_uuid (required), name, +6 more.
coolify_validate_s3_storageAIdempotent
Validate an S3 storage connection using ListObjectsV2. Audited as a mutation action.
Inputs: s3_storage_uuid (required).
coolify_validate_serverAIdempotent
Validate server connectivity and configuration. Audited as a mutation action.
Inputs: server_uuid (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
TDQS
Scored across 59 tools
Most tools follow a clear resource-action pattern with distinct entities (servers, projects, deployments, etc.). A few pairs like list_database_backups vs list_backup_executions and set_environment_variable(s) could be confused, but descriptions provide adequate differentiation.
Tools consistently use the coolify_ prefix followed by verb_noun (list_servers, get_server, create_application). A few tools deviate with bare verbs (deploy, restart, start, stop) or noun-only names (health, project_overview), but the pattern is largely predictable.
With 59 tools, the server presents a very large surface area. While the domain is broad, the count exceeds reasonable expectations and places a heavy burden on agent selection, even if each tool may be individually useful.
The toolset covers creation, reading, updating, and deployment for core resources, but lacks delete operations for applications, services, databases, and other entities. Additionally, services have no dedicated update tool, leaving notable gaps in lifecycle management.
Maintenance
Related MCP Connectors
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows
MCP server for building and testing AI agents with multi-model experimentation and insights.
MCP server connecting AI agents to 100+ apps (Gmail, Slack, Notion, GitHub) via one-click OAuth.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn MCP server that enables AI assistants to manage infrastructure, applications, databases, and services through the Coolify PaaS platform.9 npm4MIT
- AlicenseBqualityDmaintenanceProduction-grade MCP server that gives AI agents safe access to your local dev environment: filesystem, databases, processes, and OpenAPI specs.1555 npm4MIT
- AlicenseBqualityDmaintenanceMCP server that integrates with Coolify to let AI assistants manage Coolify instances via a clean toolkit wrapping the official REST API.35416 npm7MIT
- AlicenseNot gradedqualityDmaintenanceA production-grade MCP server designed for multi-tenant, authenticated, and observable AI agent systems, enabling secure tool execution across heterogeneous data sources.67MIT