Add comprehensive tool coverage for Dokploy API#17
Draft
limehawk wants to merge 3 commits intoDokploy:mainfrom
Draft
Add comprehensive tool coverage for Dokploy API#17limehawk wants to merge 3 commits intoDokploy:mainfrom
limehawk wants to merge 3 commits intoDokploy:mainfrom
Conversation
|
Great work! This comprehensive coverage is exactly what the community needs. Looking forward to seeing this merged! |
403ca9e to
09589cc
Compare
|
Issue in this PR: MCP Tools with Large/Complex Schemas Fail to Execute Properly Description: Evidence: Root Cause: Reproduction Steps: Proposed Resolution: Impact: Blocks full utilization of Dokploy management capabilities through MCP Priority: High - affects core functionality |
Author
|
Thank you for testing @yoinks-yoinks I'll look into this and add a commit. This may be a Zod3 vs. Zod4 thing |
0bebf48 to
617d004
Compare
- Upgrade to Zod v4 for native JSON Schema draft-2020-12 support (Claude API requires draft-2020-12, MCP SDK outputs draft-07) - Normalize response IDs to top level for consistent LLM access (e.g., projectId, applicationId always at data.projectId) - Fix Zod v4 breaking changes: - z.record() now requires 2 args: z.record(z.string(), z.string()) - ZodError.errors → ZodError.issues - Add talismanrc for false positive secret patterns Tested with 8 comprehensive scenarios against live sandbox: - Full application deployment workflow - Database stack setup (PostgreSQL + MySQL) - Docker Compose deployment - Complex 87-field application updates - Multi-environment setup - Mounts and port mappings - Git-based deployments - Error handling validation
617d004 to
86bada1
Compare
The SDK expects Zod schemas for input validation (calls safeParseAsync). Passing raw JSON Schema objects broke all tool execution.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR resolves the issue where MCP tools with large/complex schemas fail to execute properly (e.g.,
compose-updatewith 43 fields,application-updatewith 87 fields).Root Cause
Claude API requires JSON Schema draft-2020-12, but the MCP SDK's default Zod-to-JSON-Schema conversion outputs draft-07, causing schema validation failures.
Fixes
z.toJSONSchema()withtarget: "draft-2020-12"supportdata.projectIdalways accessible)z.record(z.string())→z.record(z.string(), z.string())ZodError.errors→ZodError.issuesTesting
Verified with 8 comprehensive scenarios against a live Dokploy sandbox:
All scenarios pass with proper cleanup (0 orphaned resources).
API Limitations Documented
Some Dokploy API endpoints don't return IDs on create:
mounts.create,port.create,redirects.create,security.createThese operations succeed but LLMs cannot chain delete/update without querying for IDs first.
🤖 Generated with Claude Code