@vibetools/dokploy-mcp 1.2.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/README.md +61 -168
  2. package/dist/api/client.d.ts +2 -1
  3. package/dist/api/client.js +3 -11
  4. package/dist/cli/index.js +1 -0
  5. package/dist/codemode/context/execute-context.d.ts +590 -0
  6. package/dist/codemode/context/execute-context.js +64 -0
  7. package/dist/codemode/context/search-context.d.ts +13851 -0
  8. package/dist/codemode/context/search-context.js +42 -0
  9. package/dist/codemode/gateway/api-gateway.d.ts +12 -0
  10. package/dist/codemode/gateway/api-gateway.js +160 -0
  11. package/dist/codemode/gateway/error-format.d.ts +13 -0
  12. package/dist/codemode/gateway/error-format.js +9 -0
  13. package/dist/codemode/gateway/request-normalizer.d.ts +3 -0
  14. package/dist/codemode/gateway/request-normalizer.js +21 -0
  15. package/dist/codemode/gateway/trace.d.ts +13 -0
  16. package/dist/codemode/gateway/trace.js +11 -0
  17. package/dist/codemode/sandbox/host.d.ts +11 -0
  18. package/dist/codemode/sandbox/host.js +28 -0
  19. package/dist/codemode/sandbox/limits.d.ts +2 -0
  20. package/dist/codemode/sandbox/limits.js +20 -0
  21. package/dist/codemode/sandbox/runner.d.ts +8 -0
  22. package/dist/codemode/sandbox/runner.js +113 -0
  23. package/dist/codemode/sandbox/runtime.d.ts +2 -0
  24. package/dist/codemode/sandbox/runtime.js +3 -0
  25. package/dist/codemode/sandbox/serialize.d.ts +1 -0
  26. package/dist/codemode/sandbox/serialize.js +45 -0
  27. package/dist/codemode/sandbox/subprocess-runner.d.ts +10 -0
  28. package/dist/codemode/sandbox/subprocess-runner.js +91 -0
  29. package/dist/codemode/sandbox/types.d.ts +12 -0
  30. package/dist/codemode/sandbox/types.js +1 -0
  31. package/dist/codemode/sandbox/worker-entry.d.ts +1 -0
  32. package/dist/codemode/sandbox/worker-entry.js +70 -0
  33. package/dist/codemode/server-codemode.d.ts +2 -0
  34. package/dist/codemode/server-codemode.js +17 -0
  35. package/dist/codemode/tools/execute.d.ts +583 -0
  36. package/dist/codemode/tools/execute.js +64 -0
  37. package/dist/codemode/tools/index.d.ts +2 -0
  38. package/dist/codemode/tools/index.js +3 -0
  39. package/dist/codemode/tools/search.d.ts +2 -0
  40. package/dist/codemode/tools/search.js +73 -0
  41. package/dist/generated/dokploy-catalog.d.ts +27 -0
  42. package/dist/generated/dokploy-catalog.js +16 -0
  43. package/dist/generated/dokploy-schemas.d.ts +17533 -0
  44. package/dist/generated/dokploy-schemas.js +20639 -0
  45. package/dist/generated/dokploy-sdk.d.ts +558 -0
  46. package/dist/generated/dokploy-sdk.js +561 -0
  47. package/dist/generated/openapi-index.json +10591 -0
  48. package/dist/{tools/_factory.js → mcp/tool-factory.js} +7 -5
  49. package/dist/server.d.ts +1 -1
  50. package/dist/server.js +2 -15
  51. package/package.json +22 -11
  52. package/dist/tools/_database.d.ts +0 -12
  53. package/dist/tools/_database.js +0 -115
  54. package/dist/tools/admin.d.ts +0 -2
  55. package/dist/tools/admin.js +0 -61
  56. package/dist/tools/application.d.ts +0 -2
  57. package/dist/tools/application.js +0 -601
  58. package/dist/tools/backup.d.ts +0 -2
  59. package/dist/tools/backup.js +0 -133
  60. package/dist/tools/certificates.d.ts +0 -2
  61. package/dist/tools/certificates.js +0 -54
  62. package/dist/tools/cluster.d.ts +0 -2
  63. package/dist/tools/cluster.js +0 -38
  64. package/dist/tools/compose.d.ts +0 -2
  65. package/dist/tools/compose.js +0 -451
  66. package/dist/tools/deployment.d.ts +0 -2
  67. package/dist/tools/deployment.js +0 -107
  68. package/dist/tools/destination.d.ts +0 -2
  69. package/dist/tools/destination.js +0 -78
  70. package/dist/tools/docker.d.ts +0 -2
  71. package/dist/tools/docker.js +0 -110
  72. package/dist/tools/domain.d.ts +0 -2
  73. package/dist/tools/domain.js +0 -147
  74. package/dist/tools/environment.d.ts +0 -2
  75. package/dist/tools/environment.js +0 -104
  76. package/dist/tools/git-provider.d.ts +0 -2
  77. package/dist/tools/git-provider.js +0 -22
  78. package/dist/tools/github.d.ts +0 -2
  79. package/dist/tools/github.js +0 -66
  80. package/dist/tools/gitlab.d.ts +0 -2
  81. package/dist/tools/gitlab.js +0 -98
  82. package/dist/tools/index.d.ts +0 -2
  83. package/dist/tools/index.js +0 -72
  84. package/dist/tools/mariadb.d.ts +0 -1
  85. package/dist/tools/mariadb.js +0 -14
  86. package/dist/tools/mongo.d.ts +0 -1
  87. package/dist/tools/mongo.js +0 -13
  88. package/dist/tools/mounts.d.ts +0 -2
  89. package/dist/tools/mounts.js +0 -109
  90. package/dist/tools/mysql.d.ts +0 -1
  91. package/dist/tools/mysql.js +0 -14
  92. package/dist/tools/notification.d.ts +0 -2
  93. package/dist/tools/notification.js +0 -559
  94. package/dist/tools/patch.d.ts +0 -2
  95. package/dist/tools/patch.js +0 -179
  96. package/dist/tools/port.d.ts +0 -2
  97. package/dist/tools/port.js +0 -54
  98. package/dist/tools/postgres.d.ts +0 -1
  99. package/dist/tools/postgres.js +0 -13
  100. package/dist/tools/preview-deployment.d.ts +0 -2
  101. package/dist/tools/preview-deployment.js +0 -50
  102. package/dist/tools/project.d.ts +0 -2
  103. package/dist/tools/project.js +0 -125
  104. package/dist/tools/redirects.d.ts +0 -2
  105. package/dist/tools/redirects.js +0 -53
  106. package/dist/tools/redis.d.ts +0 -1
  107. package/dist/tools/redis.js +0 -11
  108. package/dist/tools/registry.d.ts +0 -2
  109. package/dist/tools/registry.js +0 -81
  110. package/dist/tools/rollback.d.ts +0 -2
  111. package/dist/tools/rollback.js +0 -28
  112. package/dist/tools/schedule.d.ts +0 -2
  113. package/dist/tools/schedule.js +0 -92
  114. package/dist/tools/security.d.ts +0 -2
  115. package/dist/tools/security.js +0 -48
  116. package/dist/tools/server.d.ts +0 -2
  117. package/dist/tools/server.js +0 -192
  118. package/dist/tools/settings.d.ts +0 -2
  119. package/dist/tools/settings.js +0 -509
  120. package/dist/tools/ssh-key.d.ts +0 -2
  121. package/dist/tools/ssh-key.js +0 -74
  122. package/dist/tools/user.d.ts +0 -2
  123. package/dist/tools/user.js +0 -85
  124. package/dist/tools/volume-backups.d.ts +0 -2
  125. package/dist/tools/volume-backups.js +0 -96
  126. /package/dist/{tools/_factory.d.ts → mcp/tool-factory.d.ts} +0 -0
package/README.md CHANGED
@@ -2,61 +2,19 @@
2
2
 
3
3
  [![npm version](https://img.shields.io/npm/v/@vibetools/dokploy-mcp)](https://www.npmjs.com/package/@vibetools/dokploy-mcp)
4
4
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
5
- [![Node >= 22](https://img.shields.io/badge/node-%3E%3D22-brightgreen)](https://nodejs.org/)
5
+ [![Node >= 24](https://img.shields.io/badge/node-%3E%3D24-brightgreen)](https://nodejs.org/)
6
6
 
7
- MCP server for the Dokploy API. 377 tools across 35 modules. Your AI agent can now deploy apps, manage databases, configure domains, and handle backups -- without you touching a dashboard.
7
+ MCP server for [Dokploy](https://dokploy.com). Two tools. 463 API procedures. Your AI agent can now deploy, configure, and manage your entire infrastructure without memorizing 377 endpoint definitions first.
8
8
 
9
- Forked from [Dokploy/mcp](https://github.com/Dokploy/mcp) and rebuilt with expanded API coverage, tool annotations, Zod v4 schemas, lazy config loading, and a setup wizard. The original had 67 tools. This one has 377. Standing on shoulders, etc.
9
+ Most MCP servers dump hundreds of tool schemas into your context window and call it a day. This one doesn't. **Code Mode** gives your agent `search` and `execute` -- it finds what it needs from a compact API catalog, writes a workflow, and the sandbox runs the whole thing in one call. Create an app, set env vars, mount volumes, configure domains, deploy -- all in a single round-trip.
10
10
 
11
- ## Quick Start
11
+ The result: **99.8% fewer tokens** on tool definitions. Your context window can go back to doing its actual job.
12
12
 
13
- Grab your API key from **Dokploy Settings > Profile > API/CLI** and add this to your MCP client config:
13
+ > Previously: 377 tools = ~92,354 tokens just to list them. Now: 2 tools = ~218 tokens. The math is embarrassing for everyone else.
14
14
 
15
- ```json
16
- {
17
- "mcpServers": {
18
- "dokploy": {
19
- "command": "npx",
20
- "args": ["@vibetools/dokploy-mcp"],
21
- "env": {
22
- "DOKPLOY_URL": "https://panel.example.com",
23
- "DOKPLOY_API_KEY": "your-api-key"
24
- }
25
- }
26
- }
27
- }
28
- ```
29
-
30
- That's it. No setup wizard, no config files, no PhD.
31
-
32
- ### Alternative: setup wizard
33
-
34
- If you prefer saving credentials to disk instead of env vars:
35
-
36
- ```bash
37
- npx @vibetools/dokploy-mcp setup
38
- ```
39
-
40
- Validates credentials, saves to `~/.config/dokploy-mcp/config.json`, and shows you the minimal MCP config to copy. After that, the `env` block is optional.
41
-
42
- ### Alternative: Dokploy CLI auto-detection
43
-
44
- If you already have the [Dokploy CLI](https://github.com/Dokploy/cli) installed and authenticated -- zero config needed. It just works.
45
-
46
- ## Features
47
-
48
- - **377 tools, 35 modules** -- applications, compose, environments, servers, Git providers, notifications, databases (Postgres/MySQL/MariaDB/MongoDB/Redis), domains, backups, deployment queues, rollback, patching, Docker, settings, preview deployments, schedules, and more
49
- - **Tool annotations** -- `readOnlyHint`, `destructiveHint`, `idempotentHint` so clients can warn before you nuke something
50
- - **Type-safe schemas** -- Zod v4 validation on every parameter
51
- - **Lazy config loading** -- validates credentials on first API call, not at startup
52
- - **Three config sources** -- env vars > config file > Dokploy CLI (first match wins)
53
- - **Minimal dependencies** -- just `@modelcontextprotocol/sdk`, `zod`, and `@clack/prompts`
15
+ ## Quick start
54
16
 
55
- ## MCP Client Config
56
-
57
- ### Claude Desktop
58
-
59
- Add to `claude_desktop_config.json`:
17
+ Grab your API key from **Dokploy Settings > Profile > API/CLI**:
60
18
 
61
19
  ```json
62
20
  {
@@ -73,163 +31,98 @@ Add to `claude_desktop_config.json`:
73
31
  }
74
32
  ```
75
33
 
76
- ### Claude Code
34
+ Drop this into Claude Desktop, Claude Code, Cursor, VS Code, Windsurf -- anything that speaks MCP. Done. No ceremony.
77
35
 
78
- Add to `.mcp.json`:
36
+ Already have the [Dokploy CLI](https://github.com/Dokploy/cli) authenticated? Skip the `env` block entirely. It just works.
79
37
 
80
- ```json
81
- {
82
- "mcpServers": {
83
- "dokploy": {
84
- "command": "npx",
85
- "args": ["@vibetools/dokploy-mcp"],
86
- "env": {
87
- "DOKPLOY_URL": "https://panel.example.com",
88
- "DOKPLOY_API_KEY": "your-api-key"
89
- }
90
- }
91
- }
92
- }
93
- ```
38
+ Want a wizard? `npx @vibetools/dokploy-mcp setup` -- validates credentials, saves config, holds your hand exactly once.
94
39
 
95
- ### Cursor
40
+ ## How it works
96
41
 
97
- Add to `~/.cursor/mcp.json` or `.cursor/mcp.json`:
42
+ Your agent gets two tools:
98
43
 
99
- ```json
100
- {
101
- "mcpServers": {
102
- "dokploy": {
103
- "command": "npx",
104
- "args": ["@vibetools/dokploy-mcp"],
105
- "env": {
106
- "DOKPLOY_URL": "https://panel.example.com",
107
- "DOKPLOY_API_KEY": "your-api-key"
108
- }
109
- }
110
- }
111
- }
44
+ ```
45
+ search → "what can Dokploy do with applications?"
46
+ execute → runs a multi-step workflow in one sandboxed call
112
47
  ```
113
48
 
114
- ### VS Code
49
+ One `execute` call can spin up an app, configure resource limits, set 5 env vars, create 3 file mounts, attach a domain with HTTPS, deploy, wait for it to come up, verify it's running, and clean up after itself. Eight API calls. One context window round-trip. Sub-second sandbox overhead.
115
50
 
116
- Add to `.vscode/mcp.json`:
51
+ **What this looks like in practice:**
117
52
 
118
- ```json
119
- {
120
- "servers": {
121
- "dokploy": {
122
- "command": "npx",
123
- "args": ["@vibetools/dokploy-mcp"],
124
- "env": {
125
- "DOKPLOY_URL": "https://panel.example.com",
126
- "DOKPLOY_API_KEY": "your-api-key"
127
- }
128
- }
129
- }
130
- }
131
- ```
53
+ | | Old way (endpoint-per-tool) | Code Mode |
54
+ |---|---|---|
55
+ | Tool definitions sent | ~92,354 tokens (377 tools) | ~218 tokens (2 tools) |
56
+ | Deploy workflow (8 API calls) | 8 round-trips through the model | 1 execute call, done |
57
+ | Context window tax | ~738k tokens on tool schemas alone | ~218 tokens total |
132
58
 
133
- Already ran `setup` or have Dokploy CLI authenticated? Drop the `env` block entirely.
134
-
135
- ## Tools
136
-
137
- | Module | Tools | Module | Tools |
138
- |--------|-------|--------|-------|
139
- | Project | 8 | Deployment | 8 |
140
- | Environment | 7 | Docker | 7 |
141
- | Application | 29 | Server | 16 |
142
- | Compose | 28 | Certificates | 4 |
143
- | Domain | 9 | Registry | 6 |
144
- | Patch | 12 | SSH Key | 6 |
145
- | Git Provider | 2 | GitHub | 6 |
146
- | GitLab | 7 | PostgreSQL | 14 |
147
- | Notification | 38 | MySQL | 14 |
148
- | Destination | 6 | MariaDB | 14 |
149
- | Backup | 11 | MongoDB | 14 |
150
- | Mounts | 6 | Redis | 14 |
151
- | Port | 4 | Volume Backups | 6 |
152
- | Redirects | 4 | Rollback | 2 |
153
- | Preview Deployment | 4 | Schedule | 6 |
154
- | Security | 4 | Cluster | 4 |
155
- | Settings | 49 | Admin | 1 |
156
- | User | 7 | | |
157
-
158
- Full reference with parameters and descriptions: **[docs/tools.md](docs/tools.md)**
159
-
160
- API coverage report: **[docs/coverage.md](docs/coverage.md)**
59
+ That last row is why this exists. Every token spent on tool definitions is a token your agent can't use for reasoning. We just gave you 738k of them back.
161
60
 
162
61
  ## Configuration
163
62
 
164
63
  | Variable | Required | Description |
165
64
  |---|---|---|
166
- | `DOKPLOY_URL` | Yes | Dokploy panel URL -- automatically normalized to `/api/trpc` |
167
- | `DOKPLOY_API_KEY` | Yes | API key from Dokploy Settings > API |
65
+ | `DOKPLOY_URL` | Yes | Your Dokploy panel URL |
66
+ | `DOKPLOY_API_KEY` | Yes | API key from Dokploy settings |
168
67
  | `DOKPLOY_TIMEOUT` | No | Request timeout in ms (default: `30000`) |
169
68
 
170
- Resolution order: env vars > `~/.config/dokploy-mcp/config.json` > Dokploy CLI config.
69
+ Resolution order: env vars > `~/.config/dokploy-mcp/config.json` > Dokploy CLI config. First match wins.
70
+
71
+ <details>
72
+ <summary>Sandbox tuning -- for when the defaults aren't enough drama</summary>
73
+
74
+ | Variable | Default | What it does |
75
+ |---|---|---|
76
+ | `DOKPLOY_MCP_SANDBOX_TIMEOUT_MS` | `30000` | How long before the sandbox gives up on your workflow |
77
+ | `DOKPLOY_MCP_SANDBOX_MAX_CALLS` | `25` | Max API calls per execute (prevents runaway loops) |
78
+ | `DOKPLOY_MCP_SANDBOX_MAX_RESULT_BYTES` | `131072` | Max result payload (128 KB) |
79
+ | `DOKPLOY_MCP_SANDBOX_MAX_RESPONSE_BYTES` | `2097152` | Cumulative API response cap (2 MB) |
80
+ | `DOKPLOY_MCP_SANDBOX_RUNTIME` | `subprocess` | `subprocess` (isolated) or `local` (faster, less safe) |
81
+
82
+ </details>
83
+
84
+ ## What's in the box
85
+
86
+ The Code Mode catalog covers the full Dokploy OpenAPI surface -- 463 procedures across every module. Applications, compose stacks, databases (Postgres, MySQL, MariaDB, MongoDB, Redis), domains, certificates, Docker, servers, backups, notifications, and about 30 more categories you'll discover when you need them.
87
+
88
+ Your agent doesn't need to know any of this upfront. That's the point. It searches when it needs something, executes when it knows what to do.
89
+
90
+ Coverage details: **[docs/coverage.md](docs/coverage.md)**
171
91
 
172
92
  ## CLI
173
93
 
174
94
  ```bash
175
- npx @vibetools/dokploy-mcp # Start MCP server (stdio)
176
- npx @vibetools/dokploy-mcp setup # Interactive setup wizard (aliases: init, auth)
177
- npx @vibetools/dokploy-mcp version # Show version
95
+ npx @vibetools/dokploy-mcp # Start Code Mode server
96
+ npx @vibetools/dokploy-mcp setup # Interactive setup
97
+ npx @vibetools/dokploy-mcp version # Because you'll be asked
178
98
  ```
179
99
 
180
100
  ## Development
181
101
 
182
102
  ```bash
183
- git clone https://github.com/vcode-sh/dokploy-mcp.git
184
- cd dokploy-mcp
103
+ git clone https://github.com/vcode-sh/dokploy-mcp.git && cd dokploy-mcp
185
104
  npm install && npm run build
186
- ```
187
-
188
- Point your MCP client at the local build:
189
-
190
- ```json
191
- {
192
- "mcpServers": {
193
- "dokploy": {
194
- "command": "node",
195
- "args": ["/path/to/dokploy-mcp/dist/index.js"],
196
- "env": {
197
- "DOKPLOY_URL": "https://panel.example.com",
198
- "DOKPLOY_API_KEY": "your-api-key"
199
- }
200
- }
201
- }
202
- }
105
+ npm run typecheck # TypeScript 6
106
+ npm run lint # Biome
107
+ npm test # Vitest
108
+ npm run ci:budgets # Protocol and runtime budget checks
203
109
  ```
204
110
 
205
- ```bash
206
- npm run dev # Watch mode
207
- npm run typecheck # Type-check
208
- npm run lint # Lint with Biome
209
- npm run lint:fix # Auto-fix
210
- ```
211
-
212
- Test with the MCP Inspector:
213
-
214
111
  ```bash
215
112
  npx @modelcontextprotocol/inspector node dist/index.js
216
113
  ```
217
114
 
218
- ## Standing on the Shoulders of People Who Actually Did the Work
219
-
220
- This project is a fork of [Dokploy/mcp](https://github.com/Dokploy/mcp). I rewrote most of it, tripled the tool count, and added things like a setup wizard and config resolution chain -- but "rewrote" is easy when someone else already built the thing you're rewriting.
221
-
222
- [Mauricio Siu](https://github.com/Siumauricio) created [Dokploy](https://dokploy.com) itself -- a genuinely impressive open-source PaaS -- and kicked off the MCP server repo. Without Dokploy, there's no API. Without the API, there's no MCP server. Without the MCP server, I'd have had to start from zero instead of "from scratch."
115
+ ## Credits
223
116
 
224
- [Henrique Andrade](https://github.com/andradehenrique) did the actual heavy lifting on the original MCP. Projects, applications, PostgreSQL, MySQL, domains -- that was all him. 15 commits, every merged PR. The kind of contributor who doesn't just open issues, he closes them.
117
+ Forked from [Dokploy/mcp](https://github.com/Dokploy/mcp). Started at 67 tools, mass-refactored to 377, then rebuilt the whole thing into an architecture that makes the tool count irrelevant.
225
118
 
226
- And to everyone who opened PRs on the original repo -- merged or not -- your code and ideas shaped what this became:
119
+ [Mauricio Siu](https://github.com/Siumauricio) built [Dokploy](https://dokploy.com) itself -- the PaaS this server talks to. Without the platform, this is a very elaborate way to POST into the void.
227
120
 
228
- [Joshua Macauley](https://github.com/Macawls) · [lucasleal-developer](https://github.com/lucasleal-developer) · [Nour Eddine Hamaidi](https://github.com/HenkDz) · [Corey](https://github.com/limehawk) · [Azil0ne](https://github.com/Azilone)
121
+ [Henrique Andrade](https://github.com/andradehenrique) wrote the original MCP server. 15 commits, every PR merged. The kind of contributor who closes issues instead of opening them.
229
122
 
230
- Unmerged PRs are still blueprints. Someone reads your compose tools PR and thinks "right, I should cover that." Someone sees your consolidation approach and borrows the idea. That's how open source actually works -- not through clean merge histories, but through stolen inspiration with better commit messages.
123
+ Contributors who shaped the original: [Joshua Macauley](https://github.com/Macawls) -- [lucasleal-developer](https://github.com/lucasleal-developer) -- [Nour Eddine Hamaidi](https://github.com/HenkDz) -- [Corey](https://github.com/limehawk) -- [Azil0ne](https://github.com/Azilone)
231
124
 
232
- Cheers to all of you. I owe you mass-produced coffee at minimum.
125
+ Unmerged PRs are still blueprints. That's how open source works -- stolen inspiration with better commit messages.
233
126
 
234
127
  ## License
235
128
 
@@ -1,3 +1,4 @@
1
+ import { buildTrpcQueryString } from '../codemode/gateway/request-normalizer.js';
1
2
  export declare function unwrapTrpcResponse(data: unknown): unknown;
2
3
  export declare class ApiError extends Error {
3
4
  readonly status: number;
@@ -6,7 +7,7 @@ export declare class ApiError extends Error {
6
7
  readonly endpoint: string;
7
8
  constructor(status: number, statusText: string, body: unknown, endpoint: string);
8
9
  }
9
- export declare function buildQueryString(body: unknown): string;
10
+ export declare const buildQueryString: typeof buildTrpcQueryString;
10
11
  export declare const api: {
11
12
  get: <T = unknown>(path: string, params?: Record<string, unknown>) => Promise<T>;
12
13
  post: <T = unknown>(path: string, body?: unknown) => Promise<T>;
@@ -1,3 +1,4 @@
1
+ import { buildTrpcPostBody, buildTrpcQueryString } from '../codemode/gateway/request-normalizer.js';
1
2
  import { resolveConfig } from '../config/resolver.js';
2
3
  const DEFAULT_TIMEOUT = 30_000;
3
4
  function getErrorMessage(body, statusText) {
@@ -71,16 +72,7 @@ export class ApiError extends Error {
71
72
  this.name = 'ApiError';
72
73
  }
73
74
  }
74
- export function buildQueryString(body) {
75
- if (body == null)
76
- return '';
77
- if (typeof body !== 'object')
78
- return '';
79
- const params = Object.fromEntries(Object.entries(body).filter(([, value]) => value != null));
80
- return new URLSearchParams({
81
- input: JSON.stringify({ json: params }),
82
- }).toString();
83
- }
75
+ export const buildQueryString = buildTrpcQueryString;
84
76
  /**
85
77
  * Checks whether an error was caused by an aborted fetch.
86
78
  * Both checks are needed: older Node versions throw DOMException,
@@ -103,7 +95,7 @@ async function request(method, path, body) {
103
95
  Accept: 'application/json',
104
96
  'x-api-key': apiKey,
105
97
  },
106
- body: method === 'POST' && body ? JSON.stringify({ json: body }) : undefined,
98
+ body: method === 'POST' ? buildTrpcPostBody(body) : undefined,
107
99
  signal: controller.signal,
108
100
  });
109
101
  const text = await response.text();
package/dist/cli/index.js CHANGED
@@ -41,6 +41,7 @@ Environment Variables:
41
41
  DOKPLOY_URL Dokploy panel URL (e.g. https://panel.example.com)
42
42
  DOKPLOY_API_KEY API key from Dokploy Settings
43
43
  DOKPLOY_TIMEOUT Request timeout in ms (default: 30000)
44
+ DOKPLOY_MCP_SANDBOX_RUNTIME subprocess or local (default: subprocess)
44
45
 
45
46
  Documentation:
46
47
  https://github.com/vcode-sh/dokploy-mcp