shivam-bhandari/ressl-mcp-server
If you are the rightful owner of ressl-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.
This project is a Model Context Protocol (MCP) Server that provides file search and reading capabilities for `.txt` files.
File Search MCP Server
Overview
This project is a Model Context Protocol (MCP) Server that provides file search and reading capabilities for .txt files. The server implements the MCP specification to expose tools that can be used by MCP clients (such as AI assistants or other applications) to search for keywords within text files and read file contents.
What is MCP?
The Model Context Protocol (MCP) is a standardized protocol that enables AI assistants and other applications to interact with external tools and resources. This server implements an MCP-compliant service that provides file operations as tools.
Features
The server exposes two main tools:
1. search_in_file
Searches for a specified keyword within a .txt file and returns matching lines with their line numbers.
Parameters:
file_path(required): The path to the.txtfile to search inkeyword(required): The keyword to search forcase_sensitive(optional): Whether the search should be case-sensitive (default:false)
Returns: JSON object containing:
- The file path
- The search keyword
- Total number of matches
- Array of matches with line numbers and content
2. read_file
Reads a .txt file and returns its contents, optionally limited to a specific line range.
Parameters:
file_path(required): The path to the.txtfile to readstart_line(optional): Starting line number (1-indexed)end_line(optional): Ending line number (1-indexed)
Returns: JSON object containing:
- The file path
- Total number of lines in the file
- Start and end line numbers (if specified)
- The file content (or selected line range)
How It Works
-
File Discovery: The server automatically scans the current working directory for all
.txtfiles when tools are listed. -
Tool Registration: The server registers its tools with the MCP protocol, making them available to MCP clients.
-
Communication: The server communicates via standard input/output (stdio) using the MCP protocol, allowing it to be integrated with various MCP-compatible clients.
Technical Details
- Language: TypeScript
- Runtime: Node.js
- Protocol: Model Context Protocol (MCP)
- Communication: Standard I/O (stdio)
- File Format: Currently supports
.txtfiles only
Project Structure
ressl-mcp-file-search-server/
├── src/
│ └── index.ts # Main server implementation
├── dist/
│ └── index.js # Compiled JavaScript output
├── package.json # Project dependencies and scripts
├── tsconfig.json # TypeScript configuration
├── mcp.json # MCP server configuration
└── README.md # This file
Usage
Building the Project
npm install
npm run build
Running the Server
npm start
The server will start and communicate via stdio, ready to receive MCP protocol messages from clients.
Dependencies
@modelcontextprotocol/sdk: The official MCP SDK for implementing MCP servers@types/node: TypeScript type definitions for Node.jstypescript: TypeScript compiler