Transform scattered conversations into a unified stream. GlobalMsg RelayHub is an intelligent message aggregation engine that collects, filters, and redistributes messages across multiple Discord channels, servers, and even external platforms — all without compromising on privacy or performance.
- Overview & Vision
- Architecture Diagram
- Core Features
- Installation & Setup
- Configuration Profiles
- Console Invocation
- Multilingual Support
- AI Integration (OpenAI & Claude)
- Responsive UI & Dashboard
- OS Compatibility
- SEO & Discoverability
- 24/7 Support & Reliability
- Disclaimer
- License
Imagine standing at the center of a thousand whispering corridors — each corridor a Discord channel, each whisper a message from a community member. Now imagine being able to hear them all simultaneously, filter out the noise, and respond where it matters most.
GlobalMsg RelayHub is not merely a search tool; it is a message intelligence layer that sits atop your Discord ecosystem. Inspired by the need to locate custom phrases across guilds and DMs, this tool evolved into a full-fledged relay and discovery engine. Whether you're a community moderator tracking policy violations, a researcher gathering sentiment data, or a developer debugging cross-channel interactions — RelayHub gives you the lens to see the invisible.
Think of it as a telescope for your digital conversations — focused, powerful, and always calibrated.
graph TB
A[Discord Gateway] --> B[Message Ingestion Layer]
B --> C{Kernel Router}
C --> D[Channel Scanner]
C --> E[DM Scanner]
C --> F[Guild Aggregator]
D --> G[Filter Engine]
E --> G
F --> G
G --> H[Pattern Matcher]
H --> I[Keyword Cache]
H --> J[AI Enrichment]
J --> K[OpenAI API]
J --> L[Claude API]
H --> M[Output Buffer]
M --> N[Relay Dispatcher]
N --> O[Webhook Exporter]
N --> P[Discord Channel Push]
N --> Q[CLI Output]
N --> R[Dashboard Stream]
M --> S[Log Archive]
- Scan all guilds and all DMs simultaneously with user-defined scope restrictions.
- Use regex, fuzzy matching, or exact string patterns.
- Filter by timestamp, user ID, channel category, or message content length.
- Automatically forward matched messages to a designated relay channel or webhook endpoint.
- Support for conditional relaying (e.g., only forward if message contains a keyword AND is from a specific role).
- Integrate with OpenAI and Claude APIs to:
- Summarize matched conversations.
- Detect sentiment or toxicity.
- Translate foreign-language messages in real-time.
- Export results as JSON, CSV, or plain text.
- Optional archival logging with daily rotation.
- Stream-to-dashboard mode for live monitoring.
- Opt-in scanning — only channels explicitly configured are crawled.
- No message storage beyond the session lifetime (unless logging is enabled).
- Configurable rate limiting to respect Discord's API guidelines.
- Node.js ≥ 18.x
- A Discord bot token with
MESSAGE_CONTENTintent enabled. - (Optional) OpenAI and/or Claude API keys for AI features.
git clone https://github.com/your-org/globalmsg-relayhub.git
cd globalmsg-relayhub
npm install
cp .env.example .envEdit .env with your credentials:
DISCORD_BOT_TOKEN=your_token_here
OPENAI_API_KEY=your_openai_key_optional
CLAUDE_API_KEY=your_claude_key_optional
SCAN_INTERVAL_MS=5000npm startCreate a file named relay-profile.json:
{
"profileName": "Support-Ticket-Monitor",
"scope": {
"guilds": ["123456789012345678", "987654321098765432"],
"dmUsers": ["user_id_1", "user_id_2"],
"channelCategories": ["support", "tickets"]
},
"filters": {
"patterns": ["\\burgent\\b", "help", "error code \\d+"],
"fuzzyThreshold": 0.8,
"timeRange": {
"start": "2026-01-01T00:00:00Z",
"end": "2026-12-31T23:59:59Z"
}
},
"aiEnrichment": {
"enabled": true,
"provider": "claude",
"prompt": "Summarize the user's issue in one sentence."
},
"relay": {
"targetChannel": "109876543210987654",
"webhookUrl": "https://discord.com/api/webhooks/...",
"format": "embed"
}
}# Basic scan with default profile
npx globalmsg-relayhub scan --profile relay-profile.json
# Export results as CSV
npx globalmsg-relayhub scan --profile relay-profile.json --export csv --output ./results.csv
# AI enrichment with OpenAI
npx globalmsg-relayhub scan --profile relay-profile.json --ai openai
# Live dashboard mode
npx globalmsg-relayhub dashboard --port 3000GlobalMsg RelayHub natively supports 12 languages for interface and output:
| Language | UI | Filters | AI Translation |
|---|---|---|---|
| English | ✅ | ✅ | ✅ |
| Español | ✅ | ✅ | ✅ |
| Français | ✅ | ✅ | ✅ |
| Deutsch | ✅ | ✅ | ✅ |
| 日本語 | ✅ | ✅ | ✅ |
| 한국어 | ✅ | ✅ | ✅ |
| 中文 | ✅ | ✅ | ✅ |
| Русский | ✅ | ✅ | ✅ |
| العربية | ✅ | ✅ | ✅ |
| Português | ✅ | ✅ | ✅ |
| Italiano | ✅ | ✅ | ✅ |
| हिन्दी | ✅ | ✅ | ✅ |
All filter patterns can be written in Unicode. AI translation layer automatically detects source language and translates matched messages into your preferred output language.
- Endpoint: GPT-4 Turbo or GPT-3.5-Turbo
- Use Cases: Sentiment scoring, keyword extraction, conversation summarization.
- Configuration:
--ai openaiflag or set in profile underaiEnrichment.provider: "openai".
- Endpoint: Claude 3 Opus or Sonnet
- Use Cases: Long-form summarization, content policy compliance, contextual rewriting.
- Configuration:
--ai claudeflag or set in profile underaiEnrichment.provider: "claude".
Note: Both integrations are opt-in. No data is sent to third-party APIs unless explicitly enabled.
The optional web dashboard provides a real-time view of all relayed messages:
- Live feed with WebSocket updates.
- Filter by source, severity, or AI-generated tags.
- Dark/Light mode with persistent preferences.
- Mobile responsive — monitor from any device.
Start the dashboard with:
npx globalmsg-relayhub dashboardThen visit http://localhost:3000 in your browser.
| Operating System | Status | Notes |
|---|---|---|
| Windows 10/11 | ✅ | Full support, native binary |
| macOS 12+ | ✅ | Intel & Apple Silicon |
| Ubuntu 20.04+ | ✅ | Tested on LTS and non-LTS |
| Debian 11+ | ✅ | Requires Node.js 18+ |
| Arch Linux | ✅ | AUR package available |
| Android (Termux) | ☑️ | Experimental, CLI only |
| iOS | ❌ | No native support |
This repository is optimized for engineers searching for:
- Discord message search tool
- Multi-guild message aggregation
- AI-powered Discord analytics
- Cross-channel relay bot
- Discord DM scanner and exporter
- Claude Discord integration
- OpenAI Discord summarization
Whether you are looking to index thousands of messages across communities or build a centralized moderation dashboard, GlobalMsg RelayHub delivers a scalable, open-source solution.
- Uptime monitoring — built-in health check endpoint (
/health). - Graceful shutdown — saves progress on SIGTERM.
- Automatic reconnection — reconnects to Discord gateway on disconnect.
- Community support — open an issue or join our Discord server (link in repo sidebar).
- Enterprise support — contact us for SLAs, custom integrations, and dedicated hosting.
We treat reliability as a feature, not an afterthought.
GlobalMsg RelayHub is intended for legitimate administrative, moderation, and research purposes only. Users are responsible for:
- Compliance with Discord's Terms of Service — ensure you have permission to read messages in the channels you scan.
- Privacy laws — do not use this tool to collect personal data without consent.
- Rate limits — aggressive scanning may result in API bans. Use responsibly.
The authors assume no liability for misuse of this software. If you are unsure about the legality of scanning certain conversations, consult legal counsel first.
This project is licensed under the MIT License — see the LICENSE file for details.
You are free to:
- ✅ Use commercially
- ✅ Modify
- ✅ Distribute
- ✅ Sublicense
- ✅ Private use
Under the condition that you include the original copyright notice.
GlobalMsg RelayHub — Where messages meet intelligence.
Built with ❤️ in 2026 for the open-source community.