Source Hub
FreeNot checkedMulti-source ETL: Gmail, Notion, Linear and Google Calendar into one Postgres database, with a normalization step, REST API, and MCP server
About
Multi-source ETL: Gmail, Notion, Linear and Google Calendar into one Postgres database, with a normalization step, REST API, and MCP server
README
Backend pipeline that pulls items from Gmail, Notion, Linear, and Google Calendar into a single Postgres database, normalizing each one into a common shape (source, sender/creator, origin org, summary, category, relevant date) via a pluggable language-model extraction step. Exposes the result through a REST API, a set of stats endpoints for charting, and an MCP server for querying directly from a client that speaks MCP.
No frontend here by design — this is the data layer a separate web app is expected to read from.
Features
- Connectors: Gmail, Notion, Linear, Google Calendar — each does incremental polling via a stored cursor, so re-runs only fetch what changed.
- Extraction: every new/changed item is normalized into a fixed schema (title, summary, category, sender, org, relevant date) through a pluggable LLM provider — Anthropic by default, or any OpenAI-compatible endpoint (Ollama, vLLM, LM Studio, OpenRouter, etc.), so it also runs against open-weight models.
- Storage: Postgres with a two-stage design — a
raw_itemslanding table (content-hashed, so unchanged items skip re-extraction) and a normalizeditemstable with full-text search, JSONB metadata per source, and indexes for common filters. - REST API: filtered item queries, status updates, a natural-language
/askendpoint (the model chooses its own query filters), and stats endpoints (breakdown, time-series at any granularity from year down to second, period-over-period comparison, distribution histograms). - MCP server: the same data, exposed as MCP tools, so a chat client can query it directly without opening a web page.
See ARCHITECTURE.md for the system design in detail.
Requirements
- Node.js 18+
- Docker (for local Postgres) or any reachable Postgres 14+ instance
- API credentials for whichever sources you want to sync, and for whichever LLM provider you configure
Setup
npm install
cp .env.example .env # fill in DATABASE_URL and the credentials you have
docker compose up -d # starts a local Postgres if you don't have one already
npm run migrate
Usage
npm run sync # sync all configured sources once
npm run sync -- --source=email
npm run api # start the REST API
npm run mcp # start the MCP server (stdio)
npm run mcp:debug # same, wrapped with protocol tracing for debugging
Scans
npm run typecheck
npm run scan:sast # ESLint + security rules
npm run scan:secrets # secretlint
npm run scan:deps # npm audit
REST API
| Endpoint | Description |
|---|---|
GET /items |
Filtered item list (sources, categories, status, fromDate, toDate, search, limit) |
GET /items/:id |
Single item |
PATCH /items/:id/status |
Update status |
POST /ask |
Natural-language question → filtered lookup → summarized answer |
GET /stats/today |
Today's counts per source |
GET /stats/series |
Time-bucketed counts (granularity: second…year, or a custom fromDate/toDate range) |
GET /stats/breakdown |
Share per source/category (pie-chart shape) |
GET /stats/compare |
Current vs. previous period per source/category (paired-bar shape) |
GET /stats/distribution |
Histogram by hour-of-day or extraction confidence |
Set API_KEY in .env to require a bearer token on every route except /health.
MCP tools
query_items, get_urgent_today, get_today_counts, get_series, get_breakdown, get_compare, get_distribution, get_item, set_item_status.
Configuration
See .env.example for the full list. Only DATABASE_URL and one LLM provider's credentials are required; source credentials (Gmail/Notion/Linear/Calendar) are independent of each other — configure only the ones you use.
Installing Source Hub
This server has no published package — it is built from source. Open the repository and follow its README.
▸ github.com/raven-clown/source-hubFAQ
Is Source Hub MCP free?
Yes, Source Hub MCP is free — one-click install via Unyly at no cost.
Does Source Hub need an API key?
No, Source Hub runs without API keys or environment variables.
Is Source Hub hosted or self-hosted?
Self-hosted: the server runs locally on your machine via the install command above.
How do I install Source Hub in Claude Desktop, Claude Code or Cursor?
Open Source Hub on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
Gmail
Read, send and search emails from Claude
by GoogleSlack
Send, search and summarize Slack messages
by SlackRunbear
No-code MCP client for team chat platforms, such as Slack, Microsoft Teams, and Discord.
Discord Server
A community discord server dedicated to MCP by [Frank Fiegel](https://github.com/punkpeye)
Klavis AI
Open Source MCP Infra. Hosted MCP servers and MCP clients on Slack and Discord.
Work90210/APIFold
Turn any REST API into a hosted MCP server, with ready-made public servers for GitHub, Stripe, Slack, OpenAI, Notion and more.
by Work90210arikusi/deepseek-mcp-server
DeepSeek AI chat and reasoning with multi-turn sessions, function calling, thinking mode and cost tracking.
by arikusihashgraph-online/hashnet-mcp-js
Discover, register and chat with AI agents on the Hashgraph network via the Registry Broker.
by hashgraph-onlineprofullstack/mcp-server
Developer utilities: SEO optimization, document conversion, domain lookup, email validation, QR codes, weather data, social media posting and security scanning.
by profullstackWayStation-ai/mcp
Connect MCP hosts to apps such as Notion, Slack, Monday and Airtable.
by waystation-aiCompare Source Hub with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All communication MCPs
