Skip to content

Proposal: Implement Resumable File Uploads in MCP Using the TUS Protocol #189

@gunta

Description

@gunta

Is your feature request related to a problem? Please describe.

Currently, the Model Context Protocol (MCP) lacks a standardized method for resumable file uploads, posing challenges in transferring large files between clients and servers, especially over unstable network connections. Interruptions during file uploads often necessitate restarting the process from the beginning, leading to increased bandwidth usage and time consumption. This limitation affects users who require reliable and efficient data transfers. With the upcoming support for Remote MCP connections, efficient file transfer mechanisms are becoming increasingly critical. Implementing this feature from the outset is crucial, as retrofitting such capabilities later may result in fragmented implementations and reduced adoption.

Describe the solution you'd like

Integrate the TUS protocol into MCP to support resumable file uploads. TUS is an open protocol that allows for reliable, resumable uploads, enabling clients to pause and resume file transfers seamlessly. By adopting TUS as the default method for file transfers within MCP, we can ensure that:

  • Resumable Uploads: Users can resume interrupted uploads from the point of failure, enhancing reliability.

  • Bandwidth Efficiency: Resuming uploads minimizes redundant data transmission, conserving bandwidth.

  • Standardization: Implementing a widely adopted protocol like TUS promotes consistency and interoperability across different systems.

This enhancement is particularly important for the upcoming Remote MCP support, where efficient and reliable file transfers over potentially unstable networks are essential. Implementing this feature from the beginning ensures a consistent and robust experience across all platforms, benefiting users who require dependable data transfer capabilities.

Describe alternatives you've considered

Alternative approaches to address large file transfers include:

  • Chunked Uploads via REST: Implementing custom chunked upload mechanisms using standard REST endpoints. However, this requires developing and maintaining custom solutions, which may lack the robustness and community support of established protocols like TUS.

  • Third-Party File Transfer Services: Utilizing external services specialized in large file transfers. While effective, this approach introduces dependencies on third-party providers and may raise concerns regarding data privacy and security.

Additional context

Integrating TUS into MCP aligns with ongoing efforts to standardize resumable uploads, as evidenced by active development and adoption within the community. For instance, the TerminusDB TUS server serves as a reference implementation that could guide MCP's integration process. TusFlow using serverless Cloudflare also serves as a good reference implementation.

By adopting TUS, MCP can enhance its file transfer capabilities, providing users with a more reliable and efficient experience, particularly when dealing with large files or unstable network conditions. This improvement is crucial for the forthcoming Remote MCP support, ensuring seamless and efficient remote interactions. Implementing this feature from the outset is crucial, as retrofitting such capabilities later may result in fragmented implementations and reduced adoption.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions