aliyun/alibabacloud-dataworks-mcp-server

Feature: Add GetFile function to retrieve SQL content from DataWorks nodes

Closed this issue · 1 comments

Issue Title

Feature Request: Add GetFile function to retrieve SQL content from DataWorks nodes

##Issue Description

Summary

Please add a GetFile function to the DataWorks MCP server to retrieve SQL templates and file content from DataWorks nodes.

Current Gap

The MCP server provides GetTable, ListLineages, etc., but cannot retrieve the actual SQL code from nodes. When we get a nodeId from table metadata (e.g., 700001234567), we need to fetch the corresponding SQL template.

Requested Function

GetFile(nodeId: string) => {
  Content: string;  // SQL template content
  FileName: string;
  NodeId: string;
}

Use Case

Complete data lineage analysis requires both metadata AND the actual SQL code for documentation and analysis purposes.

DataWorks API Support

DataWorks already has GetFile API - this request is to expose it through the MCP interface.

Thanks!

Welcome to use DataWorks MCP Server, base on your needs, you can use GetNode tool to get node scripts in new DataStudio version.
tool defined: https://api.aliyun.com/document/dataworks-public/2024-05-18/GetNode

Image