source-hub
Allows pulling Gmail messages into the unified item database and querying them through MCP tools.
Allows pulling Google Calendar events into the unified item database and querying them through MCP tools.
Allows pulling Linear issues and projects into the unified item database and querying them through MCP tools.
Allows pulling Notion pages or content into the unified item database and querying them through MCP tools.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@source-hubWhat's urgent today across my email and calendar?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
source-hub
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.
Related MCP server: Notion MCP Server
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 migrateUsage
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 debuggingScans
npm run typecheck
npm run scan:sast # ESLint + security rules
npm run scan:secrets # secretlint
npm run scan:deps # npm auditREST API
Endpoint | Description |
| Filtered item list ( |
| Single item |
| Update status |
| Natural-language question → filtered lookup → summarized answer |
| Today's counts per source |
| Time-bucketed counts ( |
| Share per source/category (pie-chart shape) |
| Current vs. previous period per source/category (paired-bar shape) |
| 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.
This server cannot be deployed
Maintenance
Related MCP Connectors
Query your org's data in natural language — read-only MCP access to SQL, NoSQL, files & warehouses.
Search your newsletter and YouTube archive, drafted actions and working context from any MCP client.
Let AI agents query data and act across all your business apps via MCP.
Analytical memory for AI agents: a real Postgres queried in plain English over MCP. One command.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceA unified Model Context Protocol server that provides a consistent interface for AI assistants to interact with productivity tools like Linear, GitHub, Slack, and Notion. It enables users to search, retrieve, and manage tasks and data across multiple workplace services from a single endpoint.15 npmMIT
- FlicenseNot gradedqualityDmaintenanceEnables interaction with Notion workspaces, allowing users to search, query databases, create/update pages, and manage content via natural language through MCP.-
- FlicenseNot gradedqualityCmaintenanceEnables natural language interaction with enterprise tools including file, database, GitHub, Slack, browser, calendar, email, vector search, and Python calculation through OpenAI and MCP Client.-
- AlicenseNot gradedqualityCmaintenanceExposes your Google Drive, Slack, GitHub, and Railway to MCP clients with semantic search, per-user permissions, and optional OAuth, allowing natural-language access to your private data and infrastructure.11 npmMIT