The Copy-Paste MCP server enables precise text extraction while preserving formatting. With this server, you can:
- Extract specific line ranges from text content (inclusive start and end lines)
- Preserve original formatting, spacing, and newlines during extraction
- Handle both single-line and multi-line extractions without modifying content
- Work effectively with large text blocks or documents
- Select and process specific sections from larger content
- Integrate with MCP-compatible tools like Claude Desktop, VS Code, and other AI applications
Copy-Paste MCP
A Model Context Protocol (MCP) server that provides a tool for extracting specific lines from text content.
Features
- Simple tool to extract specific line ranges from any text content
- Preserves exact content formatting and newlines
- No modification of content - pure extraction
- MCP server implementation for easy integration with AI tools
MCP Server
This package includes an MCP server that exposes the line extraction functionality as a tool that can be used by any MCP client like Claude Desktop, VS Code, or other MCP-compatible applications.
Available Tools
- extract-lines - Extract a specific range of lines from text content
Installation
- Clone the repository
- Install dependencies:
Usage
Starting the MCP Server
This will start the MCP server using the stdio transport, which can be connected to by MCP clients.
Connecting to the Server
In an MCP-compatible client (like Claude Desktop), you can add this server with:
- Name: Copy-Paste
- Command:
node /path/to/copy-paste-mcp/dist/index.js
- Transport: stdio
Using the Tool
Once connected, you can use the tool through your MCP client's interface:
Extract Lines
This will return the first two lines of the provided text content.
Examples
Extract lines 10-20 from a large text block:
Extract just a single line (line 5):
Why use this?
This tool is useful when you need to:
- Extract specific sections from large text blocks
- Copy exact line ranges from code or documentation
- Ensure precise content extraction without any alterations
- Integrate line extraction capabilities into AI workflows via MCP
- Work with specific portions of large documents
Tools
A Model Context Protocol server that provides a tool for extracting specific line ranges from text content while preserving exact formatting and newlines.
Related MCP Servers
- AsecurityAlicenseAqualityA Model Context Protocol server that provides tools for analyzing text documents, including counting words and characters. This server helps LLMs perform text analysis tasks by exposing simple document statistics functionality.Last updated -187JavaScriptApache 2.0
- AsecurityAlicenseAqualityA Model Context Protocol server that extracts embedded data (such as i18n translations or key/value configurations) from TypeScript/JavaScript source code into structured JSON configuration files.Last updated -2142JavaScriptMIT License
- -securityFlicense-qualityA Model Context Protocol server that enables LLMs to extract and use content from unstructured documents across a wide variety of file formats.Last updated -2Python
- -securityFlicense-qualityA Model Context Protocol server that enables LLMs to fetch and process web content in multiple formats (HTML, JSON, Markdown, text) with automatic format detection.Last updated -TypeScript