MCP server returns "float" type instead of "number" for tool input schema #16834

Closed
opened 2026-02-21 19:28:06 -05:00 by yindo · 0 comments
Owner

Originally created by @estvita on GitHub (Sep 6, 2025).

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report, otherwise it will be closed.
  • 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.8.1

Cloud or Self Hosted

Cloud

Steps to reproduce

#25048 the fix does not have the desired effect

I created a mcp server in your cloud and instead of a number a float is returned there

curl -X POST  https://api.dify.ai/mcp/server/WZG4bEt2TDOCLBa9/mcp\
  -H "Content-Type: application/json" \
  -d '{"method": "tools/list", "jsonrpc": "2.0", "id": 1}'

returns

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": {
        "tools": [
            {
                "name": "123",
                "description": "test",
                "inputSchema": {
                    "type": "object",
                    "properties": {
                        "test": {
                            "description": "",
                            "type": "float"
                        }
                    },
                    "required": [
                        "test"
                    ]
                }
            }
        ]
    }
} 
Image

✔️ Expected Behavior

The MCP server should return "number" instead of "float" for fields of type "number" in the workflow.

Actual Behavior

Currently, the server returns the type "float".

Originally created by @estvita on GitHub (Sep 6, 2025). ### Self Checks - [x] I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542). - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [x] I confirm that I am using English to submit this report, otherwise it will be closed. - [x] 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.8.1 ### Cloud or Self Hosted Cloud ### Steps to reproduce #25048 the fix does not have the desired effect I created a mcp server in your cloud and instead of a number a float is returned there ``` curl -X POST https://api.dify.ai/mcp/server/WZG4bEt2TDOCLBa9/mcp\ -H "Content-Type: application/json" \ -d '{"method": "tools/list", "jsonrpc": "2.0", "id": 1}' ``` returns ``` { "jsonrpc": "2.0", "id": 1, "result": { "tools": [ { "name": "123", "description": "test", "inputSchema": { "type": "object", "properties": { "test": { "description": "", "type": "float" } }, "required": [ "test" ] } } ] } } ``` <img width="925" height="979" alt="Image" src="https://github.com/user-attachments/assets/d93b40f0-cd0e-4681-872f-9be79722df7f" /> ### ✔️ Expected Behavior The MCP server should return "number" instead of "float" for fields of type "number" in the workflow. ### ❌ Actual Behavior Currently, the server returns the type "float".
yindo added the 🌊 feat:workflow label 2026-02-21 19:28:06 -05:00
yindo closed this issue 2026-02-21 19:28:06 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#16834