langgenius / langgenius/dify

Workflow published as MCP with File-List variable: tools/list inputSchema is missing the file-list parameter

Open
#39,727 1 comment 1 reaction 0 assignees View on GitHub
🐞 bug 1.15.0
Dominant language
TypeScript
Stars
156k
Forks
24.6k
Avg merge
22h 9m
Merged PRs (30d)
610

Description

### 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.15.0

### Cloud or Self Hosted

Cloud

### Steps to reproduce

On Dify Cloud (online version), when a workflow that uses a File List (array[file]) input variable is published as an MCP server, calling tools/list returns an inputSchema that does not include the file-list parameter. Other input variables appear correctly in the schema; only the file-list variable is dropped.

1. Create a workflow with a File List (array[file]) input variable. here is my dsl

```yml
app:
description: ''
icon: 🤖
icon_background: '#FFEAD5'
icon_type: emoji
mode: workflow
name: extract_online_docx_file_content
use_icon_as_answer_icon: false
dependencies: []
kind: app
version: 0.6.0
workflow:
conversation_variables: []
environment_variables: []
features:
file_upload:
allowed_file_extensions:
- .JPG
- .JPEG
- .PNG
- .GIF
- .WEBP
- .SVG
allowed_file_types:
- image
allowed_file_upload_methods:
- local_file
- remote_url
enabled: false
fileUploadConfig:
attachment_image_file_size_limit: 2
audio_file_size_limit: 50
batch_count_limit: 5
file_size_limit: 15
file_upload_limit: 50
image_file_batch_limit: 10
image_file_size_limit: 10
single_chunk_attachment_limit: 10
video_file_size_limit: 100
workflow_file_upload_limit: 10
image:
enabled: false
number_limits: 3
transfer_methods:
- local_file
- remote_url
number_limits: 3
opening_statement: ''
retriever_resource:
enabled: true
sensitive_word_avoidance:
enabled: false
speech_to_text:
enabled: false
suggested_questions: []
suggested_questions_after_answer:
enabled: false
text_to_speech:
enabled: false
language: ''
voice: ''
graph:
edges:
- data:
isInIteration: false
isInLoop: false
sourceType: start
targetType: document-extractor
id: 1785288566414-source-1785288575867-target
source: '1785288566414'
sourceHandle: source
target: '1785288575867'
targetHandle: target
type: custom
zIndex: 0
- data:
isInIteration: false
isInLoop: false
sourceType: document-extractor
targetType: end
id: 1785288575867-source-1785288615044-target
source: '1785288575867'
sourceHandle: source
target: '1785288615044'
targetHandle: target
type: custom
zIndex: 0
nodes:
- data:
selected: true
title: 用户输入
type: start
variables:
- allowed_file_extensions: []
allowed_file_types:
- document
allowed_file_upload_methods:
- remote_url
default: ''
hide: false
hint: ''
label: file_url_array
max_length: 5
options: []
placeholder: ''
required: true
type: file-list
variable: file_url_array
height: 109
id: '1785288566414'
position:
x: 77
y: 261
positionAbsolute:
x: 77
y: 261
selected: true
sourcePosition: right
targetPosition: left
type: custom
width: 242
- data:
is_array_file: true
selected: false
title: 文档提取器
type: document-extractor
variable_selector:
- '1785288566414'
- file_url_array
height: 105
id: '1785288575867'
position:
x: 357
y: 282
positionAbsolute:
x: 357
y: 282
selected: false
sourcePosition: right
targetPosition: left
type: custom
width: 242
- data:
outputs:
- value_selector:
- '1785288575867'
- text
value_type: array[string]
variable: text
selected: false
title: 输出
type: end
height: 89
id: '1785288615044'
position:
x: 659
y: 282
positionAbsolute:
x: 659
y: 282
selected: false
sourcePosition: right
targetPosition: left
type: custom
width: 242
viewport:
x: 0
y: 60
zoom: 1
rag_pipeline_variables: []

```

2. Publish the workflow as an MCP server.

Image

3. Connect an MCP client and call tools/list.

Image

Inspect the returned inputSchema for the tool.

### ✔️ Expected Behavior

The file-list input variable should be present in the tool's inputSchema (or, if MCP file inputs are not supported, the limitation should be documented and surfaced clearly when publishing).

### ❌ Actual Behavior

The file-list parameter is missing from inputSchema, so MCP clients cannot pass files to the workflow.

Contributor guide

Open the contributing guide

Research direction

Start at the MCP server publishing flow and the tools/list response that generates each tool's inputSchema. Reproduce the workflow with a File List (array[file]) variable, compare its schema with other input variables, and trace where the file-list parameter is omitted. Done means the parameter appears in inputSchema, or publishing clearly reports that MCP file inputs are unsupported.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.