Stu Mason · Folkestone, Kent
One entryMerged PR· StuMason/coolify-mcp· TypeScript

PR #212 merged: Add pull_latest parameter to restart action for services

additions
+33
deletions
-4
files changed
3

The Coolify API supports ?latest=true on the service restart endpoint, which pulls fresh Docker images before restarting. This is the API equivalent of the "Pull Latest Images & Restart" button in the Coolify UI.

Add an optional pull_latest boolean parameter to the control tool. When resource=service, action=restart, and pull_latest=true, appends ?latest=true to the request URL. No behavior change for other resource types or when omitted.

Summary

  • Add optional pull_latest boolean to control tool schema (services only)
  • restartService() appends ?latest=true query string when set
  • No behavior change for applications, databases, or when pull_latest is omitted/false

Changes

  • src/lib/coolify-client.tsrestartService(uuid, pullLatest) accepts optional second param
  • src/lib/mcp-server.tscontrol tool schema gains pull_latest: z.boolean().optional(), passed through for service restarts
  • src/__tests__/coolify-client.test.ts — Two new tests: pull_latest=true appends ?latest=true, pull_latest=false omits it

Test plan

  • Tests added/updated
  • Manually tested locally

Checklist

  • Code follows project conventions
  • Documentation updated if needed