[Plugin Request]: MCP DataSource Plugin #336

Open
opened 2026-02-22 17:26:17 -05:00 by yindo · 0 comments
Owner

Originally created by @wail-asad on GitHub (Oct 27, 2025).

Plugin Name

MCPDataSource

Function Description

🧠 Objective

Add support for an MCP (Model Context Protocol) Tool as a DataSource plugin in Dify, allowing dynamic retrieval of external data with optional user-defined filters.


🧩 Feature Summary

Feature name: MCP DataSource Plugin
Category: Data Source → External Connector
Goal: Enable Dify apps to pull in real-time data from external systems via the MCP protocol, with configurable input filters.


⚙️ Functional Requirements

Item Description
DataSource Type mcp_tool
Purpose Fetch structured data from an external system (API, DB, service) through an MCP interface
Input Parameters - endpoint (string): The MCP endpoint or tool ID.
- filters (object or key:value list): Optional filter criteria passed to the MCP request.
- fields (optional array): Specific fields or attributes to return.
- Input from previous action (Important).
Behavior 1. When triggered, Dify calls the MCP tool with the given endpoint and filters.
2. The returned data becomes part of the context (like RAG data or variables) for the current workflow or agent.
3. The user can map MCP results to variables or documents inside Dify.
Output JSON array or text, depending on MCP response format.
UI Integration - Add a “MCP Tool” option in DataSource setup.
- Provide an input editor for filters (JSON, form, or key-value pairs).
- Show a “Test connection” button to validate the MCP endpoint and preview results.

Official Website URL

No response

Originally created by @wail-asad on GitHub (Oct 27, 2025). ### Plugin Name MCPDataSource ### Function Description ## 🧠 Objective Add support for an **MCP (Model Context Protocol) Tool** as a **DataSource plugin** in Dify, allowing dynamic retrieval of external data with optional user-defined filters. --- ## 🧩 Feature Summary **Feature name:** MCP DataSource Plugin **Category:** Data Source → External Connector **Goal:** Enable Dify apps to pull in real-time data from external systems via the MCP protocol, with configurable input filters. --- ## ⚙️ Functional Requirements | Item | Description | | -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **DataSource Type** | `mcp_tool` | | **Purpose** | Fetch structured data from an external system (API, DB, service) through an MCP interface | | **Input Parameters** | - `endpoint` (string): The MCP endpoint or tool ID.<br>- `filters` (object or key:value list): Optional filter criteria passed to the MCP request.<br>- `fields` (optional array): Specific fields or attributes to return. <br>- `Input` from `previous action` (Important). | | **Behavior** | 1. When triggered, Dify calls the MCP tool with the given endpoint and filters.<br>2. The returned data becomes part of the context (like RAG data or variables) for the current workflow or agent.<br>3. The user can map MCP results to variables or documents inside Dify. | | **Output** | JSON array or text, depending on MCP response format. | | **UI Integration** | - Add a “MCP Tool” option in DataSource setup.<br>- Provide an input editor for `filters` (JSON, form, or key-value pairs).<br>- Show a “Test connection” button to validate the MCP endpoint and preview results. | ### Official Website URL _No response_
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-plugins#336