Commit c6f10cb
authored
chore: release v2.5.0 - type safety improvements (#85)
* refactor: eliminate all `as any` casts in MCP tool handlers (#81)
Application handlers (create_public, create_github, create_key, create_dockerimage)
and service create handler now use explicit typed objects instead of `as any` casts.
Changes:
- Replace all 5 `as any` casts with explicit object construction
- Import BuildPack type for proper typing
- Fix CreateApplicationPrivateGHRequest and CreateApplicationPrivateKeyRequest types:
- build_pack and ports_exposes are optional (verified against Coolify API)
- Remove `eslint-disable @typescript-eslint/no-explicit-any` directive
- Add tested Coolify version to README (v4.0.0-beta.460)
This prevents bugs like #76 where MCP-internal fields leaked to the API.
Closes #81
Stu Mason + AI <me@stumason.dev>
* fix: address PR review feedback for #81
- Change build_pack from z.string() to z.enum() for type safety
- Move apiData destructuring inside update cases only (fixes unused variable)
- Remove as BuildPack casts (Zod enum handles typing)
- Remove unused BuildPack import
Stu Mason + AI <me@stumason.dev>
* chore: bump version to 2.5.0 and finalize type safety (#81)
- Reverted build_pack from Zod enum to z.string() for safety
(let Coolify API validate - tested against real API)
- Updated version to 2.5.0
- Updated CHANGELOG with release notes
Verified against Coolify v4.0.0-beta.460:
- nixpacks, dockerfile, static, dockercompose all work
- Invalid values return clear error from Coolify API
Stu Mason + AI <me@stumason.dev>1 parent a08d29c commit c6f10cb
File tree
6 files changed
+100
-21
lines changed- src
- lib
- types
6 files changed
+100
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
10 | 12 | | |
11 | 13 | | |
12 | 14 | | |
| |||
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
25 | 34 | | |
26 | 35 | | |
27 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | 5 | | |
7 | 6 | | |
8 | 7 | | |
| |||
16 | 15 | | |
17 | 16 | | |
18 | 17 | | |
19 | | - | |
| 18 | + | |
20 | 19 | | |
21 | | - | |
| 20 | + | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
| |||
330 | 329 | | |
331 | 330 | | |
332 | 331 | | |
333 | | - | |
334 | | - | |
| 332 | + | |
335 | 333 | | |
336 | 334 | | |
337 | 335 | | |
| |||
351 | 349 | | |
352 | 350 | | |
353 | 351 | | |
354 | | - | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
355 | 367 | | |
356 | 368 | | |
357 | 369 | | |
| |||
369 | 381 | | |
370 | 382 | | |
371 | 383 | | |
372 | | - | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
373 | 400 | | |
374 | 401 | | |
375 | 402 | | |
| |||
387 | 414 | | |
388 | 415 | | |
389 | 416 | | |
390 | | - | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
391 | 433 | | |
392 | 434 | | |
393 | 435 | | |
| |||
404 | 446 | | |
405 | 447 | | |
406 | 448 | | |
407 | | - | |
408 | | - | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
409 | 464 | | |
410 | 465 | | |
411 | | - | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
412 | 470 | | |
413 | 471 | | |
414 | 472 | | |
| |||
550 | 608 | | |
551 | 609 | | |
552 | 610 | | |
553 | | - | |
554 | | - | |
| 611 | + | |
555 | 612 | | |
556 | 613 | | |
557 | 614 | | |
| |||
573 | 630 | | |
574 | 631 | | |
575 | 632 | | |
576 | | - | |
| 633 | + | |
577 | 634 | | |
578 | 635 | | |
579 | | - | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
580 | 640 | | |
581 | 641 | | |
582 | 642 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
269 | 269 | | |
270 | 270 | | |
271 | 271 | | |
272 | | - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
273 | 276 | | |
| 277 | + | |
| 278 | + | |
274 | 279 | | |
275 | 280 | | |
276 | | - | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
277 | 285 | | |
| 286 | + | |
| 287 | + | |
278 | 288 | | |
279 | 289 | | |
280 | 290 | | |
| |||
0 commit comments