Skip to main content
Glama

dokploy_compose

Create, deploy, and manage Docker Compose services in Dokploy. Update configurations, set environment variables, move services between environments, and read logs.

Instructions

Manage Docker Compose services. create: name+environmentId. get: composeId (metadata + masked env summary — never values). update: composeId+fields (supports sourceType, composeFile for raw/inline, git source fields, autoDeploy, createEnvFile, serviceNetworks). delete/start/stop/getDefaultCommand: composeId. deploy: composeId, redeploy?, freshVolumes? (DESTRUCTIVE: runs docker compose down --volumes first, deleting the service's volume data; docker-compose type only, ignored for stack) (note: first deploy on new services may fail — retry immediately). move: composeId+targetEnvironmentId. loadServices: composeId (must deploy first). loadMounts: composeId+serviceName. saveEnvironment: composeId+env (full replace), createEnvFile? (also write a .env file next to the compose file). setEnvVars: composeId + set?/unset? (merge inside the server, masked confirmation only). getEnvKeys: composeId — KEY names only. getEnvValuesUnsafe: composeId — UNSAFE escape hatch that returns full KEY=VALUE pairs (output goes to the tool transcript). cancelDeployment/cleanQueues/killBuild/refreshToken: composeId. readLogs: composeId+containerId, tail?, since?, search?. search (as action): q|name|appName|description|projectId|environmentId + limit/offset. Note: the API's search index is narrower than the project tree — it can return fewer results than dokploy_project/dokploy_overview list, so use it to find a known service, not to inventory.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "dokploy_compose"
  }
}

Input Schema

NameRequiredDescriptionDefault
qNosearch: freeform query
envNoEnvironment variables as KEY=VALUE pairs, one per line. Example: 'DB_HOST=localhost\nDB_PORT=5432'. Used by saveEnvironment (full replace).
setNosetEnvVars: KEY=VALUE pairs to upsert, one per line.
nameNo
tailNoNumber of recent log lines (default 100)
typeNo
limitNosearch: max results (default 20)
ownerNoGitHub owner/organization
sinceNoTime range: 'all' or a duration like '30m', '1h', '7d'
titleNo
unsetNosetEnvVars: list of KEY names to remove.
actionYes
branchNoGitHub branch
offsetNosearch: pagination offset
searchNoFilter log lines by substring
appNameNoInternal app name
commandNo
redeployNo
serverIdNo
composeIdNo
projectIdNosearch: filter to a project
autoDeployNoEnable auto-deploy on git push
repositoryNoGitHub repository (owner/repo format)
sourceTypeNoSource type. github → set repository+owner+branch (+composePath). git → set customGitUrl+customGitBranch (+customGitSSHKeyId for private). raw → set composeFile (inline YAML). The API also supports gitlab/bitbucket/gitea sources, but those need provider-specific fields not yet exposed by this tool.
composeFileNoDocker Compose YAML content (for sourceType: raw, set this to the inline compose file)
composePathNoPath to compose file in repo
composeTypeNodocker-compose or stack
containerIdNoContainer ID for readLogs (use dokploy_docker findContainers to discover)
descriptionNo
serviceNameNo
customGitUrlNoCustom git repository URL
freshVolumesNodeploy: delete the service's volumes before deploying — destroys their data
createEnvFileNoupdate/saveEnvironment: also write the env out to a .env file beside the compose file
deleteVolumesNo
environmentIdNo
customGitBranchNoCustom git branch
serviceNetworksNoupdate: per-service Docker network attachments. All three fields are required per entry (see dokploy_network list for IDs).
customGitSSHKeyIdNoSSH key ID for private git repos
deployDescriptionNo
targetEnvironmentIdNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.11.2
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
  2. Changed1 schema field changedv1.10.0
    • addedInput schema / properties / freshVolumes
      Added value: +{
      +  "description": "deploy: delete the service's volumes before deploying — destroys their data",
      +  "type": "boolean"
      +}
  3. Changed2 schema fields changedv1.9.1
    • addedInput schema / properties / createEnvFile
      Added value: +{
      +  "description": "update/saveEnvironment: also write the env out to a .env file beside the compose file",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / serviceNetworks
      Added value: +{
      +  "description": "update: per-service Docker network attachments. All three fields are required per entry (see dokploy_network list for IDs).",
      +  "items": {
      +    "properties": {
      +      "detachDokployNetwork": {
      +        "type": "boolean"
      +      },
      +      "networkIds": {
      +        "items": {
      +          "type": "string"
      +        },
      +        "type": "array"
      +      },
      +      "serviceName": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "serviceName",
      +      "networkIds",
      +      "detachDokployNetwork"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  4. Changed5 schema fields changedv1.8.3
    • changedInput schema / properties / action / enum
      Previous value: -[
      -  "create",
      -  "get",
      -  "update",
      -  "delete",
      -  "deploy",
      -  "start",
      -  "stop",
      -  "move",
      -  "loadServices",
      -  "loadMounts",
      -  "getDefaultCommand",
      -  "cancelDeployment",
      -  "cleanQueues",
      -  "killBuild",
      -  "refreshToken",
      -  "saveEnvironment",
      -  "setEnvVars",
      -  "getEnvKeys",
      -  "getEnvValuesUnsafe",
      -  "readLogs"
      -]New value: +[
      +  "create",
      +  "get",
      +  "update",
      +  "delete",
      +  "deploy",
      +  "start",
      +  "stop",
      +  "move",
      +  "loadServices",
      +  "loadMounts",
      +  "getDefaultCommand",
      +  "cancelDeployment",
      +  "cleanQueues",
      +  "killBuild",
      +  "refreshToken",
      +  "saveEnvironment",
      +  "setEnvVars",
      +  "getEnvKeys",
      +  "getEnvValuesUnsafe",
      +  "readLogs",
      +  "search"
      +]
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "search: max results (default 20)",
      +  "maximum": 100,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "description": "search: pagination offset",
      +  "maximum": 9007199254740991,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedInput schema / properties / projectId
      Added value: +{
      +  "description": "search: filter to a project",
      +  "type": "string"
      +}
    • addedInput schema / properties / q
      Added value: +{
      +  "description": "search: freeform query",
      +  "type": "string"
      +}
  5. Changed1 schema field changedv1.7.4
    • addedInput schema / additionalProperties
      Added value: +false
  6. Changed4 schema fields changedv1.7.3
    • changedInput schema / properties / action / enum
      Previous value: -[
      -  "create",
      -  "get",
      -  "update",
      -  "delete",
      -  "deploy",
      -  "start",
      -  "stop",
      -  "move",
      -  "loadServices",
      -  "loadMounts",
      -  "getDefaultCommand",
      -  "cancelDeployment",
      -  "cleanQueues",
      -  "killBuild",
      -  "refreshToken",
      -  "readLogs"
      -]New value: +[
      +  "create",
      +  "get",
      +  "update",
      +  "delete",
      +  "deploy",
      +  "start",
      +  "stop",
      +  "move",
      +  "loadServices",
      +  "loadMounts",
      +  "getDefaultCommand",
      +  "cancelDeployment",
      +  "cleanQueues",
      +  "killBuild",
      +  "refreshToken",
      +  "saveEnvironment",
      +  "setEnvVars",
      +  "getEnvKeys",
      +  "getEnvValuesUnsafe",
      +  "readLogs"
      +]
    • changedInput schema / properties / env / description
      Previous value: -"Environment variables as KEY=VALUE pairs, one per line. Example: 'DB_HOST=localhost\\nDB_PORT=5432'"New value: +"Environment variables as KEY=VALUE pairs, one per line. Example: 'DB_HOST=localhost\\nDB_PORT=5432'. Used by saveEnvironment (full replace)."
    • addedInput schema / properties / set
      Added value: +{
      +  "description": "setEnvVars: KEY=VALUE pairs to upsert, one per line.",
      +  "type": "string"
      +}
    • addedInput schema / properties / unset
      Added value: +{
      +  "description": "setEnvVars: list of KEY names to remove.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
  7. First observedv1.7.0

TDQS

A4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the whole burden and does so well: it flags deploy freshVolumes as DESTRUCTIVE with the exact `docker compose down --volumes` behavior, notes docker-compose-only applicability, and warns that first deploys may fail and should be retried. It also discloses masking behavior ("metadata + masked env summary — never values", "masked confirmation only") and that getEnvValuesUnsafe writes secrets to the transcript. Missing auth/scoping and delete-side effects keep it from a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The action: parameter cheat-sheet is front-loaded and every clause carries operational information, with no filler. The telegraphic semicolon-chained format is efficient but dense, making it harder to scan 21 actions than a structured breakdown would be.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 21-action, 40-parameter tool with no output schema, the definition covers nearly every action's inputs plus the destructive and quirk behaviors an agent must know before calling. Remaining gaps are secondary: what delete does to volumes, return shapes for get/search beyond "metadata", and permission prerequisites.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 65%, and the description genuinely compensates by mapping each action to its required parameters (create: name+environmentId, move: composeId+targetEnvironmentId, readLogs: composeId+containerId/tail/since/search). It adds semantics the schema does not, such as env being a full replace, set/unset merging server-side, and freshVolumes destroying data. Some parameters (title, type, command, deleteVolumes, deployDescription, serverId) get no explanation in either place.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a concrete verb ("Manage") and resource ("Docker Compose services") and then enumerates all 21 actions with their required identifiers, so an agent knows exactly which operations exist. It falls short of a 5 because the top-level sentence is generic and never contrasts the tool with dokploy_application (compose services vs applications), which is the most likely sibling to confuse it with.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides strong action-level routing, e.g. "loadServices: composeId (must deploy first)", "search … use it to find a known service, not to inventory", and points to dokploy_docker findContainers and dokploy_network list for prerequisite IDs. It stops short of explicitly stating when to pick this tool over dokploy_application, so it earns a 4 rather than a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.