Redlib MCP Server

by devthatdoes

Not rated
GitHub

About

An MCP server that integrates your private Redlib instance, allowing AI assistants access to utilize Redlib.

Details

Author
devthatdoes
Categories
Web Scraping, Search, Other

Setup

Install Redlib MCP Server in your MCP client (Claude Desktop, Cursor, Windsurf, and others).

Repository: https://github.com/devthatdoes/redlib-mcp-server

Follow the installation instructions in the repository README, then restart your MCP client.

AModel Context Protocol (MCP) serverthat enables AI agents to interact with Reddit through your privateRedlibinstance. No Reddit API keys required - just a running Redlib instance!

https://github.com/user-attachments/assets/66eec084-e911-4eed-a51f-be303e86f1a7

- Features
-
Current Implementation
-
Prerequisites
-
Quick Start
-
Configuration
-
Available Tools
-
Integration with AI Clients

- Claude Desktop
-
Cursor
-
VS Code / GitHub Copilot
-
OpenAI Codex
-
ForgeCode
-
KiloCode

- Privacy-First- Uses your self-hosted Redlib, no tracking or API keys
- 3 Powerful Tools- Search posts, get hot posts, fetch full post details with comments
- Docker Ready- Both simple and hardened Docker images available
- Easy Setup- Works with Claude Desktop, Cursor, VS Code, Codex, ForgeCode, KiloCode and any MCP-compatible client
- Structured Output- Returns clean JSON instead of raw HTML

Important: This server currently usesstdio transport(stdin/stdout communication) for local development. It runs as a child process and communicates through standard input/output.

- No HTTP endpoint- The server does not expose any HTTP ports
- Local-only- Designed for local development and testing scenarios
- Child process- MCP clients spawn this server as a subprocess
- No network access- All communication happens locally via stdin/stdout

HTTP transport functionality is planned for future releases to enable:

- Remote access over HTTP
- Multiple concurrent client connections
- Production deployment scenarios
- Network-based health checks
-

Redlib Instance- A running Redlib instance (default:http://localhost:8080)

- Claude Desktop
-
Cursor
-
VS Codewith GitHub Copilot
-
OpenAI Codex
-
ForgeCode
-
KiloCode

# Pull and run the default version docker run -i --rm \ --network host \ -e REDLIB_URL=http://localhost:8080 \ alfafadock/mcp-redlib:latest

Option 2: Hardened Docker (Security-Focused)

# Uses non-root user and minimal privileges docker run -i --rm \ --network host \ --cap-drop=ALL \ --security-opt no-new-privileges:true \ -e REDLIB_URL=http://localhost:8080 \ alfafadock/mcp-redlib:hardened
# Clone and setup git clone https://github.com/Devthatdoes/redlib-mcp-server.git cd redlib-mcp-server # Install dependencies npm install # Build npm run build # Run npm start
services: redlib-mcp: image: alfafadock/mcp-redlib:latest container_name: redlib-mcp network_mode: "host" # Uses host network for MCP client communication environment: - REDLIB_URL=http://localhost:8080 # Change if Redlib is on a different port restart: unless-stopped # For hardened image, change image to: alfafadock/mcp-redlib:hardened

If your Redlib runs on a different port (e.g., 8085):

docker run -i --rm \ --network host \ -e REDLIB_URL=http://localhost:8085 \ alfafadock/mcp-redlib:latest

Copy.env.exampleto.envand modify as needed:

Search Reddit posts using your private Redlib instance.

- query(required) - Search query string
- subreddit(optional) - Limit search to specific subreddit

{ "query": "rust programming", "subreddit": "rust" }

Returns:JSON with post IDs, titles, authors, scores, and comment counts.

Get hot posts from a specific subreddit.

- subreddit(required) - Subreddit name (without r/)
- limit(optional) - Number of posts (default: 25)

{ "subreddit": "rust", "limit": 10 }

- subreddit(required) - Subreddit name
- postId(required) - Reddit post ID (from search results)

{ "subreddit": "rust", "postId": "abc123" }

Returns:Full post body, score, and up to 10 top comments.

Edit~/.config/claude/claude_desktop_config.json(Linux/macOS) or%APPDATA%\Claude\claude_desktop_config.json(Windows):

{ "mcpServers": { "redlib": { "command": "docker", "args": [ "run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest" ] } } }
{ "mcpServers": { "redlib": { "command": "docker", "args": [ "run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8085", "alfafadock/mcp-redlib:latest" ] } } }

After updating:Restart Claude Desktop. You should see a hammer icon (πŸ”¨) indicating MCP tools are available.

Add to~/.cursor/mcp.json(global) or.cursor/mcp.json(project level):

{ "mcpServers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } }

Project-level setup:Create.cursor/mcp.jsonin your project root.

After updating:Cursor will automatically detect the changes. Use the Command Palette (Cmd/Ctrl+Shift+P) and search for "MCP" to manage servers.

Create.vscode/mcp.jsonin your project:

{ "servers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } }

Use Command Palette (Cmd/Ctrl+Shift+P) β†’ "MCP: Open User Configuration":

{ "mcp": { "servers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } } }

After updating:Reload VS Code. The tools will appear in GitHub Copilot's Agent Mode.

Edit~/.codex/config.toml(global) or.codex/config.toml(project):

[mcp_servers.redlib] command = "docker" args = ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"]

Project-level setup:Create.codex/config.tomlin your project root.

After updating:Restart Codex. Usecodex mcp listto verify the server is loaded.

ForgeCode supports MCP servers via theforge mcpcommand for easy import.

Use the built-in MCP import functionality:

# Import the Redlib MCP server forge mcp import alfafadock/mcp-redlib:latest # List imported servers forge mcp list # Reload to apply changes forge mcp reload
{ "mcpServers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } }

Edit ForgeCode's config directory (check extension settings for the exact path).

After updating:Reload the ForgeCode extension usingforge mcp reload. The MCP tools should appear in the AI assistant interface.

Edit~/.config/kilo/kilo.jsoncor use Settings β†’ MCP in KiloCode:

{ "mcpServers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } }

Create.kilocode/mcp.jsonorkilo.jsoncin your project root:

{ "mcpServers": { "redlib": { "command": "docker", "args": ["run", "-i", "--rm", "--network", "host", "-e", "REDLIB_URL=http://localhost:8080", "alfafadock/mcp-redlib:latest"] } } }

After updating:Open KiloCode Settings β†’ MCP β†’ Add Server, or edit the config file directly.

docker run -i --rm \ --cap-drop=ALL \ --security-opt no-new-privileges:true \ --network host \ -e REDLIB_URL=http://localhost:8080 \ alfafadock/mcp-redlib:hardened
redlib-mcp-server/ β”œβ”€β”€ src/ β”‚ └── index.ts # Main server code (stdio transport) β”œβ”€β”€ dist/ # Compiled JavaScript (gitignored) β”œβ”€β”€ Dockerfile # Default Docker image β”œβ”€β”€ Dockerfile.hardened # Hardened Docker image β”œβ”€β”€ docker-compose.yml # Production compose β”œβ”€β”€ package.json β”œβ”€β”€ tsconfig.json └── README.md
# Install dependencies npm install # Build TypeScript npm run build # Run locally npm start
# Default version docker build -t redlib-mcp-server . # Hardened version docker build -f Dockerfile.hardened -t redlib-mcp-server:hardened .

Once connected to your AI client (e.g., Claude), you can:

User: "Search Reddit for 'home lab setup' and summarize the top results" AI uses search_reddit tool β†’ Returns structured JSON with posts β†’ AI summarizes the findings for you
User: "Get the full post and comments for that Rust tutorial I searched earlier" AI uses get_post with postId β†’ Returns post body + comments β†’ AI provides detailed analysis

- Fork the repository
- Create a feature branch
- Submit a pull request

MIT License - feel free to use this project however you want!

- Redlib- The private Reddit front-end this server interfaces with
-
Model Context Protocol- The protocol that makes this integration possible
-
Cheerio- HTML parsing library used to extract structured data

- Docker Hub:alfafadock/mcp-redlib
- Issues:
GitHub Issues
- Redlib:
github.com/redlib-org/redlib

Made with ❀️ for the privacy-conscious Reddit community

Unified MCP server giving any AI agent access to 20+ social platforms, web search, scraping, and crypto data β€” one install, any MCP client.

A server to browse, search, and read content on Reddit using the Reddit API.

Real-time trend data from Google (Search, Images, News, Shopping), YouTube, TikTok, Reddit, Amazon, Wikipedia, X (Twitter), LinkedIn, Spotify, GitHub, Steam, npm, App Store, news sentiment and web traffic via one MCP connection. Free API key, 20 requests/day, no credit card required.

Scrape Weibo user information, feeds, and perform searches.

Adds powerful web scraping and search capabilities to LLM clients like Cursor and Claude.

Official OpenWeb Ninja MCP server connecting any AI agent to 40+ web data APIs for web search, e-commerce, local business, jobs, real estate, and finance data.

Integrate real-time Scrapeless Google SERP(Google Search, Google Flight, Google Map, Google Jobs....) results into your LLM applications. This server enables dynamic context retrieval for AI workflows, chatbots, and research tools.

MCP server for Al Jazeera 360 β€” Connect AI assistants to Al Jazeera's streaming catalog. Search, browse, and retrieve Arabic video content with direct watch links.

No reviews yet β€” be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.