Enables searching across Reddit communities, monitoring subreddit posts (hot, new, top, rising), retrieving nested comment threads, and discovering trending topics across Reddit's 73M daily active users and 100K+ communities.
Provides intelligent caching layer with configurable TTL policies (2min - 1hr) achieving 75%+ hit rate for Reddit data access optimization.
Reddit MCP Server
Enterprise-grade Model Context Protocol (MCP) server for seamless Reddit data access. Enables AI agents and developers to search, monitor, and analyze Reddit's 73M daily active users and 100K+ communities.
Features (MVP v0.1.0)
search_reddit - Search all of Reddit or specific subreddits with filters
get_subreddit_posts - Monitor subreddits for hot, new, top, or rising posts
get_post_comments - Retrieve nested comment threads with full context
get_trending_topics - Discover trending keywords and topics in real-time
All tools include intelligent Redis caching (75%+ hit rate) and automatic rate limiting.
Prerequisites
Python 3.11 or higher
Redis server (local or cloud)
Reddit API credentials (client ID and secret)
Getting Reddit API Credentials
Click "Create App" or "Create Another App"
Select "script" as the app type
Fill in the required fields:
Name: "Reddit MCP Server"
Redirect URI: http://localhost:8080
Save your client ID (under the app name) and client secret
Local Development Setup
1. Clone and Install
2. Configure Environment Variables
Create a .env file in the project root:
3. Start Redis (Local)
4. Run the Server
The MCP server will start in standby mode on the configured port (default: /mcp endpoint).
Testing
Apify Deployment
Deploy to Apify Platform
Install Apify CLI
Configure Secrets
In the Apify Console, add these secrets to your Actor:
REDDIT_CLIENT_IDREDDIT_CLIENT_SECRETREDIS_URL
Deploy
The Actor will be deployed in standby mode and accessible via the MCP endpoint.
Environment Variables (Apify)
Variable | Type | Required | Description |
| Secret | Yes | Reddit API client ID |
| Secret | Yes | Reddit API client secret |
| String | Yes | Redis connection URL |
| String | No | Logging level (default: INFO) |
Project Structure
Development Workflow
Code Quality
Running Individual Tools (Development)
TODO: Add examples once tools are implemented (MVP-006 through MVP-009)
Architecture
MCP Server: FastMCP framework for JSON-RPC protocol handling
Reddit API: PRAW (Python Reddit API Wrapper) for authenticated access
Caching: Redis with intelligent TTL policies (2min - 1hr)
Rate Limiting: Token bucket algorithm (100 requests/min)
Data Validation: Pydantic models for type-safe inputs/outputs
See /Users/padak/github/apify-actors/docs/architecture/ for detailed technical documentation.
Troubleshooting
Redis Connection Errors
Reddit API Authentication Errors
Verify your client ID and secret are correct
Check that your Reddit app type is "script"
Ensure the redirect URI matches: http://localhost:8080
Import Errors
Contributing
This is an MVP project. Contributions should align with the roadmap:
MVP (Week 1-2): Core 4 tools + caching + rate limiting
v1.0 (Week 3-4): Monetization, sentiment analysis, user auth
v2.0 (Month 2+): Write operations, real-time monitoring, analytics
Documentation
License
[Add license information]
Support
For issues or questions, please refer to the documentation in /docs/ or create an issue in the repository.
Status: MVP v0.1.0 (Week 1-2 Development) Target: 5,000 MAU by Month 6 (Apify $1M Challenge)
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Enables AI agents to search, monitor, and analyze Reddit's communities and discussions through authenticated API access with intelligent caching and rate limiting.