@contextstream/mcp-server 0.4.32 → 0.4.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -21
- package/README.md +131 -318
- package/dist/index.js +30 -5
- package/package.json +1 -1
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 ContextStream
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 ContextStream
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,177 +1,171 @@
|
|
|
1
1
|
# ContextStream MCP Server
|
|
2
2
|
|
|
3
|
-
**
|
|
3
|
+
**Your AI coding assistant finally has a memory.**
|
|
4
|
+
|
|
5
|
+
ContextStream gives your AI tools persistent context across sessions, semantic code search, and team knowledge sharing. Every decision, preference, and lesson learned is captured and surfaced when relevant.
|
|
4
6
|
|
|
5
7
|
```bash
|
|
6
8
|
npx -y @contextstream/mcp-server setup
|
|
7
9
|
```
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
Persistent memory, semantic search, and code intelligence for any MCP-compatible AI tool (Cursor, Claude Code, Windsurf, VS Code, Claude Desktop, Codex CLI, etc.).
|
|
12
|
-
|
|
13
|
-
**At a glance:**
|
|
14
|
-
- Shared "brain" for decisions, preferences, notes (including implementation notes), lessons, tasks, and project context.
|
|
15
|
-
- Search + analysis across sessions with consistent context (semantic/hybrid/keyword + graph tools).
|
|
16
|
-
- v0.4.x consolidated domain tools (~11 tools) for ~75% lower tool-registry token overhead vs previous versions.
|
|
11
|
+
Works with Cursor, Antigravity, Claude Code, Windsurf, VS Code, Claude Desktop, Codex CLI, and more.
|
|
17
12
|
|
|
18
13
|
---
|
|
19
14
|
|
|
20
|
-
##
|
|
15
|
+
## The Problem
|
|
21
16
|
|
|
22
|
-
|
|
17
|
+
Without ContextStream, every AI conversation starts from scratch:
|
|
23
18
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
| "remember we're using PostgreSQL" | Captures that fact for future sessions |
|
|
29
|
-
| "search for payment code" | Searches your codebase semantically/hybrid/keyword |
|
|
30
|
-
| "what depends on UserService?" | Analyzes dependency graph & impact |
|
|
19
|
+
- "We decided to use PostgreSQL" — forgotten next session
|
|
20
|
+
- "Don't use that deprecated API" — your AI suggests it anyway
|
|
21
|
+
- "Here's how our auth flow works" — explained for the 10th time
|
|
22
|
+
- Team decisions live in Slack threads no one can find
|
|
31
23
|
|
|
32
|
-
|
|
33
|
-
> https://contextstream.io/docs/quickstart
|
|
24
|
+
## The Solution
|
|
34
25
|
|
|
35
|
-
|
|
26
|
+
ContextStream creates a shared brain for your AI assistant:
|
|
27
|
+
|
|
28
|
+
| What you get | How it works |
|
|
29
|
+
|--------------|--------------|
|
|
30
|
+
| **Persistent Memory** | Decisions, preferences, and notes survive across sessions |
|
|
31
|
+
| **Semantic Code Search** | Find code by meaning, not just keywords |
|
|
32
|
+
| **Team Knowledge** | Share context across your team's AI tools |
|
|
33
|
+
| **Integration Sync** | Pull context from GitHub, Slack, and Notion automatically |
|
|
34
|
+
| **Smart Context** | Your AI gets relevant context for every message |
|
|
36
35
|
|
|
37
36
|
---
|
|
38
37
|
|
|
39
|
-
##
|
|
38
|
+
## See It In Action
|
|
40
39
|
|
|
41
|
-
|
|
40
|
+
**You say...** → **ContextStream does...**
|
|
42
41
|
|
|
43
|
-
|
|
|
44
|
-
|
|
45
|
-
|
|
|
46
|
-
|
|
|
47
|
-
|
|
|
42
|
+
| Prompt | What happens |
|
|
43
|
+
|--------|--------------|
|
|
44
|
+
| "What did we decide about auth?" | Finds the decision from 3 weeks ago |
|
|
45
|
+
| "Remember we're using PostgreSQL" | Captured for all future sessions |
|
|
46
|
+
| "Search for payment handling code" | Semantic search across your codebase |
|
|
47
|
+
| "What depends on UserService?" | Analyzes dependency graph and impact |
|
|
48
|
+
| "Show me recent GitHub activity" | Surfaces issues, PRs, and discussions |
|
|
49
|
+
| "What's in our API docs on Notion?" | Searches your Notion knowledge base |
|
|
48
50
|
|
|
49
|
-
|
|
51
|
+
No special commands needed. Just describe what you want.
|
|
50
52
|
|
|
51
|
-
|
|
53
|
+

|
|
52
54
|
|
|
53
|
-
|
|
55
|
+
---
|
|
54
56
|
|
|
55
|
-
|
|
56
|
-
- Session-aware context loading (`session_init`, `context_smart`)
|
|
57
|
-
- Memory capture + recall (decisions, preferences, notes, implementation notes, lessons, tasks, bugs)
|
|
58
|
-
- Code search (semantic, hybrid, keyword, pattern)
|
|
59
|
-
- Knowledge graph + code analysis (dependencies, impact, call paths, circular deps, unused code)
|
|
60
|
-
- Graph ingestion for full graph builds (`graph(action="ingest")`)
|
|
61
|
-
- Local repo ingestion for indexing (`project(action="ingest_local")`)
|
|
62
|
-
- Auto-context: on first tool call in a new session, the server can auto-initialize context
|
|
57
|
+
## Quick Setup (30 seconds)
|
|
63
58
|
|
|
64
|
-
|
|
59
|
+
The setup wizard handles everything:
|
|
65
60
|
|
|
66
|
-
|
|
61
|
+
```bash
|
|
62
|
+
npx -y @contextstream/mcp-server setup
|
|
63
|
+
```
|
|
67
64
|
|
|
68
|
-
|
|
65
|
+
This will:
|
|
66
|
+
1. Authenticate your account (opens browser)
|
|
67
|
+
2. Create and store your API key
|
|
68
|
+
3. Install editor rules for best results
|
|
69
|
+
4. Configure your AI tools automatically
|
|
69
70
|
|
|
70
|
-
|
|
71
|
-
|------|--------------|
|
|
72
|
-
| **Pro (Graph-Lite)** | Module-level import graph, dependencies, and 1-hop impact |
|
|
73
|
-
| **Elite/Team (Full Graph)** | Module + call + dataflow + type layers, plus full graph ingestion |
|
|
71
|
+
That's it. Start a conversation and your AI now has memory.
|
|
74
72
|
|
|
75
73
|
---
|
|
76
74
|
|
|
77
|
-
##
|
|
75
|
+
## What Gets Captured
|
|
76
|
+
|
|
77
|
+
ContextStream automatically tracks:
|
|
78
78
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
79
|
+
| Type | Examples |
|
|
80
|
+
|------|----------|
|
|
81
|
+
| **Decisions** | "We chose JWT over sessions", "Using Tailwind for styling" |
|
|
82
|
+
| **Preferences** | "I prefer functional components", "Always use TypeScript" |
|
|
83
|
+
| **Lessons** | "That approach caused a memory leak", "This pattern works well" |
|
|
84
|
+
| **Tasks** | Implementation plans, TODOs, follow-ups |
|
|
85
|
+
| **Code Context** | File relationships, dependencies, patterns |
|
|
82
86
|
|
|
83
|
-
|
|
87
|
+
Everything is searchable by meaning, not just keywords.
|
|
84
88
|
|
|
85
89
|
---
|
|
86
90
|
|
|
87
|
-
##
|
|
91
|
+
## Integrations
|
|
88
92
|
|
|
89
|
-
|
|
93
|
+
Connect your team's tools to enrich AI context automatically:
|
|
90
94
|
|
|
91
|
-
|
|
92
|
-
-
|
|
93
|
-
-
|
|
94
|
-
-
|
|
95
|
-
- Writes MCP config files for supported tools
|
|
95
|
+
### GitHub
|
|
96
|
+
- Issues, PRs, releases, and comments synced as searchable memory
|
|
97
|
+
- "What's the status of the auth refactor?" finds the relevant PR
|
|
98
|
+
- Decisions from issue discussions surface when relevant
|
|
96
99
|
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
+
### Slack
|
|
101
|
+
- Channel discussions become searchable knowledge
|
|
102
|
+
- Team decisions captured from conversations
|
|
103
|
+
- "What did we discuss about the API?" finds the thread
|
|
100
104
|
|
|
101
|
-
|
|
105
|
+
### Notion
|
|
106
|
+
- Documentation and wikis become AI context
|
|
107
|
+
- Smart type detection for tasks, meetings, bugs, features
|
|
108
|
+
- "How does our deployment process work?" finds the runbook
|
|
102
109
|
|
|
103
|
-
|
|
104
|
-
|------|-------------|
|
|
105
|
-
| `--dry-run` | Preview without writing files |
|
|
110
|
+
---
|
|
106
111
|
|
|
107
|
-
|
|
108
|
-
- The wizard stores credentials at `~/.contextstream/credentials.json` for convenience. Delete it to force a fresh login.
|
|
109
|
-
- Codex CLI MCP config is global-only (`~/.codex/config.toml`), so the wizard writes Codex config globally when selected.
|
|
110
|
-
- Some tools still require UI/CLI setup (the wizard will tell you when it can't write a config).
|
|
112
|
+
## Team Features
|
|
111
113
|
|
|
112
|
-
|
|
114
|
+
ContextStream shines for teams:
|
|
113
115
|
|
|
114
|
-
**
|
|
116
|
+
- **Shared workspace memory** — decisions made by anyone benefit everyone
|
|
117
|
+
- **Onboarding acceleration** — new team members get full context from day one
|
|
118
|
+
- **Knowledge preservation** — context survives when people leave
|
|
119
|
+
- **Consistent AI behavior** — everyone's AI knows the same preferences
|
|
115
120
|
|
|
116
|
-
|
|
117
|
-
npx -y @contextstream/mcp-server
|
|
118
|
-
```
|
|
121
|
+
---
|
|
119
122
|
|
|
120
|
-
|
|
123
|
+
## Smarter Context, Fewer Tokens
|
|
121
124
|
|
|
122
|
-
|
|
123
|
-
npm install -g @contextstream/mcp-server
|
|
124
|
-
contextstream-mcp
|
|
125
|
-
```
|
|
125
|
+
AI tools typically gather context by reading entire files, running grep searches, and iterating until they find what they need. This burns through your token budget fast.
|
|
126
126
|
|
|
127
|
-
|
|
127
|
+
ContextStream takes a different approach:
|
|
128
128
|
|
|
129
|
-
**
|
|
130
|
-
(or pin the version: `npx -y @contextstream/mcp-server@0.4.3`)
|
|
129
|
+
**Bounded retrieval** — `context_smart` returns only the context relevant to your current message, within a strict token budget. Instead of reading 10 files to find one decision, you get exactly what matters.
|
|
131
130
|
|
|
132
|
-
**
|
|
131
|
+
**Semantic search** — Find code by meaning in a single query. No more `grep "auth" → read file → grep "middleware" → read another file` loops. One search, relevant results.
|
|
133
132
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
133
|
+
**Smart output formats** — Choose the verbosity you need:
|
|
134
|
+
- Need file locations? Use `paths` format (80% smaller responses)
|
|
135
|
+
- Just checking if something exists? Use `count` format (90% smaller)
|
|
136
|
+
- Need full context? Use `full` format
|
|
137
137
|
|
|
138
|
-
|
|
138
|
+
**AI-powered compression** — For complex queries, Context Pack distills large code contexts into compact, high-signal summaries that preserve file paths, line numbers, and essential snippets.
|
|
139
|
+
|
|
140
|
+
The result: your AI gets better context while using fewer tokens. Faster responses, lower costs, and more room in the context window for actual work.
|
|
139
141
|
|
|
140
142
|
---
|
|
141
143
|
|
|
142
|
-
##
|
|
144
|
+
## Core Tools
|
|
143
145
|
|
|
144
|
-
|
|
146
|
+
Your AI uses these automatically:
|
|
145
147
|
|
|
146
|
-
|
|
148
|
+
| Tool | Purpose |
|
|
149
|
+
|------|---------|
|
|
150
|
+
| `session_init` | Load workspace/project context at conversation start |
|
|
151
|
+
| `context_smart` | Get relevant context for each message |
|
|
152
|
+
| `search` | Semantic, hybrid, or keyword search across everything |
|
|
153
|
+
| `session` | Capture and recall decisions, preferences, lessons |
|
|
154
|
+
| `memory` | Create and manage knowledge nodes |
|
|
155
|
+
| `graph` | Analyze code dependencies and impact |
|
|
156
|
+
| `integration` | Query GitHub, Slack, Notion directly |
|
|
147
157
|
|
|
148
|
-
|
|
158
|
+
**Full tool reference:** https://contextstream.io/docs/mcp/tools
|
|
149
159
|
|
|
150
|
-
|
|
151
|
-
|--------|-------------|
|
|
152
|
-
| **Cursor** | `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project) |
|
|
153
|
-
| **Windsurf** | `~/.codeium/windsurf/mcp_config.json` |
|
|
154
|
-
| **Claude Desktop (macOS)** | `~/Library/Application Support/Claude/claude_desktop_config.json` |
|
|
155
|
-
| **Claude Desktop (Windows)** | `%APPDATA%\Claude\claude_desktop_config.json` |
|
|
160
|
+
---
|
|
156
161
|
|
|
157
|
-
|
|
162
|
+
## Manual Configuration
|
|
158
163
|
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
"contextstream": {
|
|
163
|
-
"command": "npx",
|
|
164
|
-
"args": ["-y", "@contextstream/mcp-server"],
|
|
165
|
-
"env": {
|
|
166
|
-
"CONTEXTSTREAM_API_URL": "https://api.contextstream.io",
|
|
167
|
-
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY"
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
```
|
|
164
|
+
> Skip this if you used the setup wizard.
|
|
165
|
+
|
|
166
|
+
### Cursor / Windsurf / Claude Desktop
|
|
173
167
|
|
|
174
|
-
|
|
168
|
+
Add to your MCP config:
|
|
175
169
|
|
|
176
170
|
```json
|
|
177
171
|
{
|
|
@@ -180,36 +174,29 @@ These clients use an `mcpServers` JSON config:
|
|
|
180
174
|
"command": "npx",
|
|
181
175
|
"args": ["-y", "@contextstream/mcp-server"],
|
|
182
176
|
"env": {
|
|
183
|
-
"
|
|
184
|
-
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY",
|
|
185
|
-
"CONTEXTSTREAM_PROGRESSIVE_MODE": "true"
|
|
177
|
+
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY"
|
|
186
178
|
}
|
|
187
179
|
}
|
|
188
180
|
}
|
|
189
181
|
}
|
|
190
182
|
```
|
|
191
183
|
|
|
192
|
-
|
|
184
|
+
Config locations:
|
|
185
|
+
- **Cursor:** `~/.cursor/mcp.json`
|
|
186
|
+
- **Windsurf:** `~/.codeium/windsurf/mcp_config.json`
|
|
187
|
+
- **Claude Desktop (macOS):** `~/Library/Application Support/Claude/claude_desktop_config.json`
|
|
193
188
|
|
|
194
|
-
|
|
189
|
+
### Claude Code (CLI)
|
|
195
190
|
|
|
196
|
-
```
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
"type": "stdio",
|
|
201
|
-
"command": "npx",
|
|
202
|
-
"args": ["-y", "@contextstream/mcp-server"],
|
|
203
|
-
"env": {
|
|
204
|
-
"CONTEXTSTREAM_API_URL": "https://api.contextstream.io",
|
|
205
|
-
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY"
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
}
|
|
191
|
+
```bash
|
|
192
|
+
claude mcp add --transport stdio contextstream --scope user \
|
|
193
|
+
--env CONTEXTSTREAM_API_KEY=YOUR_KEY \
|
|
194
|
+
-- npx -y @contextstream/mcp-server
|
|
210
195
|
```
|
|
211
196
|
|
|
212
|
-
|
|
197
|
+
### VS Code
|
|
198
|
+
|
|
199
|
+
Add to `.vscode/mcp.json`:
|
|
213
200
|
|
|
214
201
|
```json
|
|
215
202
|
{
|
|
@@ -219,7 +206,6 @@ VS Code uses a top-level `servers` map:
|
|
|
219
206
|
"command": "npx",
|
|
220
207
|
"args": ["-y", "@contextstream/mcp-server"],
|
|
221
208
|
"env": {
|
|
222
|
-
"CONTEXTSTREAM_API_URL": "https://api.contextstream.io",
|
|
223
209
|
"CONTEXTSTREAM_API_KEY": "${input:contextstreamApiKey}"
|
|
224
210
|
}
|
|
225
211
|
}
|
|
@@ -235,30 +221,9 @@ VS Code uses a top-level `servers` map:
|
|
|
235
221
|
}
|
|
236
222
|
```
|
|
237
223
|
|
|
238
|
-
###
|
|
239
|
-
|
|
240
|
-
**User scope (all projects):**
|
|
241
|
-
|
|
242
|
-
```bash
|
|
243
|
-
claude mcp add --transport stdio contextstream --scope user \
|
|
244
|
-
--env CONTEXTSTREAM_API_URL=https://api.contextstream.io \
|
|
245
|
-
--env CONTEXTSTREAM_API_KEY=YOUR_KEY \
|
|
246
|
-
-- npx -y @contextstream/mcp-server
|
|
247
|
-
```
|
|
248
|
-
|
|
249
|
-
**Router mode:**
|
|
250
|
-
|
|
251
|
-
```bash
|
|
252
|
-
claude mcp add --transport stdio contextstream --scope user \
|
|
253
|
-
--env CONTEXTSTREAM_API_URL=https://api.contextstream.io \
|
|
254
|
-
--env CONTEXTSTREAM_API_KEY=YOUR_KEY \
|
|
255
|
-
--env CONTEXTSTREAM_PROGRESSIVE_MODE=true \
|
|
256
|
-
-- npx -y @contextstream/mcp-server
|
|
257
|
-
```
|
|
224
|
+
### Codex CLI
|
|
258
225
|
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
### Codex CLI (`~/.codex/config.toml`)
|
|
226
|
+
Add to `~/.codex/config.toml`:
|
|
262
227
|
|
|
263
228
|
```toml
|
|
264
229
|
[mcp_servers.contextstream]
|
|
@@ -266,155 +231,19 @@ command = "npx"
|
|
|
266
231
|
args = ["-y", "@contextstream/mcp-server"]
|
|
267
232
|
|
|
268
233
|
[mcp_servers.contextstream.env]
|
|
269
|
-
CONTEXTSTREAM_API_URL = "https://api.contextstream.io"
|
|
270
234
|
CONTEXTSTREAM_API_KEY = "YOUR_API_KEY"
|
|
271
235
|
```
|
|
272
236
|
|
|
273
|
-
### Antigravity (Google)
|
|
274
|
-
|
|
275
|
-
Antigravity uses project-scoped `.mcp.json` files with the same format as Cursor/Claude Desktop:
|
|
276
|
-
|
|
277
|
-
**Project configuration (`.mcp.json` in project root):**
|
|
278
|
-
|
|
279
|
-
```json
|
|
280
|
-
{
|
|
281
|
-
"mcpServers": {
|
|
282
|
-
"contextstream": {
|
|
283
|
-
"command": "npx",
|
|
284
|
-
"args": ["-y", "@contextstream/mcp-server"],
|
|
285
|
-
"env": {
|
|
286
|
-
"CONTEXTSTREAM_API_URL": "https://api.contextstream.io",
|
|
287
|
-
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY"
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
}
|
|
291
|
-
}
|
|
292
|
-
```
|
|
293
|
-
|
|
294
|
-
**Windows users:** Use `cmd /c npx` wrapper:
|
|
295
|
-
|
|
296
|
-
```json
|
|
297
|
-
{
|
|
298
|
-
"mcpServers": {
|
|
299
|
-
"contextstream": {
|
|
300
|
-
"command": "cmd",
|
|
301
|
-
"args": ["/c", "npx", "-y", "@contextstream/mcp-server"],
|
|
302
|
-
"env": {
|
|
303
|
-
"CONTEXTSTREAM_API_URL": "https://api.contextstream.io",
|
|
304
|
-
"CONTEXTSTREAM_API_KEY": "YOUR_API_KEY"
|
|
305
|
-
}
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
}
|
|
309
|
-
```
|
|
310
|
-
|
|
311
|
-
After adding the config, access via the "..." menu → "MCP Servers" → "View raw config" to verify.
|
|
312
|
-
|
|
313
|
-
**Rules files:**
|
|
314
|
-
- Global rules: `~/.gemini/GEMINI.md`
|
|
315
|
-
- Workspace rules: `.agent/rules/contextstream.md`
|
|
316
|
-
|
|
317
|
-
---
|
|
318
|
-
|
|
319
|
-
## Tool Overview (v0.4.x Consolidated)
|
|
320
|
-
|
|
321
|
-
In consolidated mode, you call **domain tools** with `action` / `mode`:
|
|
322
|
-
|
|
323
|
-
### Core
|
|
324
|
-
|
|
325
|
-
| Tool | Description |
|
|
326
|
-
|------|-------------|
|
|
327
|
-
| `session_init` | Initialize workspace/project context |
|
|
328
|
-
| `context_smart` | Retrieve the best bounded context for the current message |
|
|
329
|
-
|
|
330
|
-
### Domain Tools
|
|
331
|
-
|
|
332
|
-
| Tool | Description |
|
|
333
|
-
|------|-------------|
|
|
334
|
-
| `search` | `mode=semantic\|hybrid\|keyword\|pattern` |
|
|
335
|
-
| `session` | `action=capture\|recall\|remember\|get_lessons\|capture_lesson\|...` |
|
|
336
|
-
| `memory` | Events + nodes CRUD, decisions, lessons, etc. |
|
|
337
|
-
| `graph` | Dependencies, impact, call_path, ingest, etc. |
|
|
338
|
-
| `project` | Indexing, ingest_local, stats, files, etc. |
|
|
339
|
-
| `workspace` | List, get, associate, bootstrap |
|
|
340
|
-
| `reminder` | List, create, snooze, complete, dismiss |
|
|
341
|
-
| `integration` | `provider=slack\|github`, search, activity, etc. |
|
|
342
|
-
| `help` | Tools, auth, version, editor_rules |
|
|
343
|
-
|
|
344
|
-
### Examples
|
|
345
|
-
|
|
346
|
-
```
|
|
347
|
-
search(mode="semantic", query="auth middleware", limit=3)
|
|
348
|
-
memory(action="create_node", node_type="decision", title="Auth strategy", content="...")
|
|
349
|
-
graph(action="impact", target="UserService")
|
|
350
|
-
```
|
|
351
|
-
|
|
352
|
-
**Full tool catalog:** https://contextstream.io/docs/mcp/tools
|
|
353
|
-
|
|
354
|
-
---
|
|
355
|
-
|
|
356
|
-
## Authentication
|
|
357
|
-
|
|
358
|
-
Set **one** of:
|
|
359
|
-
|
|
360
|
-
| Variable | Use case |
|
|
361
|
-
|----------|----------|
|
|
362
|
-
| `CONTEXTSTREAM_API_KEY` | Recommended for local/dev |
|
|
363
|
-
| `CONTEXTSTREAM_JWT` | Useful for hosted/user-session flows |
|
|
364
|
-
|
|
365
237
|
---
|
|
366
238
|
|
|
367
239
|
## Environment Variables
|
|
368
240
|
|
|
369
|
-
### Required
|
|
370
|
-
|
|
371
|
-
| Variable | Description |
|
|
372
|
-
|----------|-------------|
|
|
373
|
-
| `CONTEXTSTREAM_API_URL` | Base API URL (default `https://api.contextstream.io`) |
|
|
374
|
-
| `CONTEXTSTREAM_API_KEY` | API key (unless using JWT) |
|
|
375
|
-
| `CONTEXTSTREAM_JWT` | JWT (unless using API key) |
|
|
376
|
-
|
|
377
|
-
### Token + Tool Surface Controls
|
|
378
|
-
|
|
379
241
|
| Variable | Description |
|
|
380
242
|
|----------|-------------|
|
|
381
|
-
| `
|
|
382
|
-
| `
|
|
383
|
-
| `
|
|
384
|
-
| `
|
|
385
|
-
| `CONTEXTSTREAM_TOOL_ALLOWLIST` | Comma-separated tool names to expose (legacy granular mode) |
|
|
386
|
-
| `CONTEXTSTREAM_SCHEMA_MODE` | Reduce schema verbosity; e.g., `compact` |
|
|
387
|
-
| `CONTEXTSTREAM_OUTPUT_FORMAT` | Output formatting; e.g., `compact` / `pretty` |
|
|
388
|
-
| `CONTEXTSTREAM_SEARCH_LIMIT` | Default MCP search limit (default: 3) |
|
|
389
|
-
| `CONTEXTSTREAM_SEARCH_MAX_CHARS` | Max chars per search result content (default: 400) |
|
|
390
|
-
|
|
391
|
-
### Optional Defaults
|
|
392
|
-
|
|
393
|
-
| Variable | Description |
|
|
394
|
-
|----------|-------------|
|
|
395
|
-
| `CONTEXTSTREAM_WORKSPACE_ID` | Default workspace fallback |
|
|
396
|
-
| `CONTEXTSTREAM_PROJECT_ID` | Default project ID fallback |
|
|
397
|
-
| `CONTEXTSTREAM_USER_AGENT` | Custom user agent string |
|
|
398
|
-
| `CONTEXTSTREAM_PRO_TOOLS` | Comma-separated tool names treated as PRO |
|
|
399
|
-
| `CONTEXTSTREAM_UPGRADE_URL` | Upgrade link for Free users calling PRO tools |
|
|
400
|
-
|
|
401
|
-
---
|
|
402
|
-
|
|
403
|
-
## Migration Notes (pre-0.4.x → 0.4.x)
|
|
404
|
-
|
|
405
|
-
Most workflows **just work**, but tool names change in consolidated mode.
|
|
406
|
-
|
|
407
|
-
| Before (granular) | After (consolidated) |
|
|
408
|
-
|-------------------|----------------------|
|
|
409
|
-
| `search_semantic(query="auth")` | `search(mode="semantic", query="auth")` |
|
|
410
|
-
| `session_capture(...)` | `session(action="capture", ...)` |
|
|
411
|
-
| `graph_dependencies(...)` | `graph(action="dependencies", ...)` |
|
|
412
|
-
|
|
413
|
-
If you rely on granular tool names, you can temporarily set:
|
|
414
|
-
|
|
415
|
-
```bash
|
|
416
|
-
CONTEXTSTREAM_CONSOLIDATED=false
|
|
417
|
-
```
|
|
243
|
+
| `CONTEXTSTREAM_API_KEY` | Your API key (required) |
|
|
244
|
+
| `CONTEXTSTREAM_API_URL` | API endpoint (default: `https://api.contextstream.io`) |
|
|
245
|
+
| `CONTEXTSTREAM_WORKSPACE_ID` | Default workspace |
|
|
246
|
+
| `CONTEXTSTREAM_PROJECT_ID` | Default project |
|
|
418
247
|
|
|
419
248
|
---
|
|
420
249
|
|
|
@@ -422,23 +251,9 @@ CONTEXTSTREAM_CONSOLIDATED=false
|
|
|
422
251
|
|
|
423
252
|
| Issue | Solution |
|
|
424
253
|
|-------|----------|
|
|
425
|
-
|
|
|
426
|
-
|
|
|
427
|
-
|
|
|
428
|
-
| **Client warns about tool context size** | Use Router mode (`CONTEXTSTREAM_PROGRESSIVE_MODE=true`), or keep consolidated mode and reduce schema/output verbosity |
|
|
429
|
-
|
|
430
|
-
---
|
|
431
|
-
|
|
432
|
-
## Development
|
|
433
|
-
|
|
434
|
-
```bash
|
|
435
|
-
git clone https://github.com/contextstream/mcp-server.git
|
|
436
|
-
cd mcp-server
|
|
437
|
-
npm install
|
|
438
|
-
npm run dev
|
|
439
|
-
npm run typecheck
|
|
440
|
-
npm run build
|
|
441
|
-
```
|
|
254
|
+
| Tools not appearing | Restart your editor after config changes |
|
|
255
|
+
| 401 Unauthorized | Check your API key is correct |
|
|
256
|
+
| Wrong workspace | Run `session_init` or re-run the setup wizard |
|
|
442
257
|
|
|
443
258
|
---
|
|
444
259
|
|
|
@@ -447,11 +262,9 @@ npm run build
|
|
|
447
262
|
| Resource | URL |
|
|
448
263
|
|----------|-----|
|
|
449
264
|
| **Website** | https://contextstream.io |
|
|
450
|
-
| **
|
|
451
|
-
| **Tool
|
|
265
|
+
| **Documentation** | https://contextstream.io/docs |
|
|
266
|
+
| **Tool Reference** | https://contextstream.io/docs/mcp/tools |
|
|
452
267
|
| **Pricing** | https://contextstream.io/pricing |
|
|
453
|
-
| **npm** | https://www.npmjs.com/package/@contextstream/mcp-server |
|
|
454
|
-
| **GitHub** | https://github.com/contextstream/mcp-server |
|
|
455
268
|
|
|
456
269
|
---
|
|
457
270
|
|
package/dist/index.js
CHANGED
|
@@ -7881,7 +7881,7 @@ W:${wsHint}
|
|
|
7881
7881
|
);
|
|
7882
7882
|
}
|
|
7883
7883
|
/**
|
|
7884
|
-
* Search/list pages in Notion
|
|
7884
|
+
* Search/list pages in Notion with smart type detection filtering
|
|
7885
7885
|
*/
|
|
7886
7886
|
async notionSearchPages(params) {
|
|
7887
7887
|
const withDefaults = this.withDefaults(params || {});
|
|
@@ -7892,6 +7892,11 @@ W:${wsHint}
|
|
|
7892
7892
|
if (params?.query) query.set("query", params.query);
|
|
7893
7893
|
if (params?.database_id) query.set("database_id", params.database_id);
|
|
7894
7894
|
if (params?.limit) query.set("limit", String(params.limit));
|
|
7895
|
+
if (params?.event_type) query.set("event_type", params.event_type);
|
|
7896
|
+
if (params?.status) query.set("status", params.status);
|
|
7897
|
+
if (params?.priority) query.set("priority", params.priority);
|
|
7898
|
+
if (params?.has_due_date !== void 0) query.set("has_due_date", String(params.has_due_date));
|
|
7899
|
+
if (params?.tags) query.set("tags", params.tags);
|
|
7895
7900
|
const suffix = query.toString() ? `?${query.toString()}` : "";
|
|
7896
7901
|
return request(
|
|
7897
7902
|
this.config,
|
|
@@ -8916,7 +8921,16 @@ var TOOL_CATALOG = [
|
|
|
8916
8921
|
{
|
|
8917
8922
|
name: "Notion",
|
|
8918
8923
|
tools: [
|
|
8919
|
-
{ name: "create_page", hint: "new-page" }
|
|
8924
|
+
{ name: "create_page", hint: "new-page" },
|
|
8925
|
+
{ name: "search_pages", hint: "find" },
|
|
8926
|
+
{ name: "list_databases", hint: "list-dbs" },
|
|
8927
|
+
{ name: "get_page", hint: "get" },
|
|
8928
|
+
{ name: "query_database", hint: "query-db" },
|
|
8929
|
+
{ name: "update_page", hint: "edit" },
|
|
8930
|
+
{ name: "stats", hint: "overview" },
|
|
8931
|
+
{ name: "activity", hint: "recent" },
|
|
8932
|
+
{ name: "knowledge", hint: "insights" },
|
|
8933
|
+
{ name: "summary", hint: "brief" }
|
|
8920
8934
|
]
|
|
8921
8935
|
}
|
|
8922
8936
|
];
|
|
@@ -16399,7 +16413,7 @@ Output formats: full (default, includes content), paths (file paths only - 80% t
|
|
|
16399
16413
|
"integration",
|
|
16400
16414
|
{
|
|
16401
16415
|
title: "Integration",
|
|
16402
|
-
description: `Integration operations for Slack, GitHub, and Notion. Provider: slack, github, notion, all. Actions: status, search, stats, activity, contributors, knowledge, summary, channels (slack), discussions (slack), repos (github), issues (github), create_page (notion), list_databases (notion), search_pages (notion), get_page (notion), query_database (notion), update_page (notion).`,
|
|
16416
|
+
description: `Integration operations for Slack, GitHub, and Notion. Provider: slack, github, notion, all. Actions: status, search, stats, activity, contributors, knowledge, summary, channels (slack), discussions (slack), repos (github), issues (github), create_page (notion), list_databases (notion), search_pages (notion with smart type detection - filter by event_type, status, priority, has_due_date, tags), get_page (notion), query_database (notion), update_page (notion).`,
|
|
16403
16417
|
inputSchema: external_exports.object({
|
|
16404
16418
|
provider: external_exports.enum(["slack", "github", "notion", "all"]).describe("Integration provider"),
|
|
16405
16419
|
action: external_exports.enum([
|
|
@@ -16443,7 +16457,13 @@ Output formats: full (default, includes content), paths (file paths only - 80% t
|
|
|
16443
16457
|
property: external_exports.string(),
|
|
16444
16458
|
direction: external_exports.enum(["ascending", "descending"])
|
|
16445
16459
|
})).optional().describe("Sort order (for Notion query_database)"),
|
|
16446
|
-
properties: external_exports.record(external_exports.unknown()).optional().describe("Page properties (for Notion update_page)")
|
|
16460
|
+
properties: external_exports.record(external_exports.unknown()).optional().describe("Page properties (for Notion update_page)"),
|
|
16461
|
+
// Smart type detection filters (for Notion search_pages)
|
|
16462
|
+
event_type: external_exports.enum(["NotionTask", "NotionMeeting", "NotionWiki", "NotionBugReport", "NotionFeature", "NotionJournal", "NotionPage"]).optional().describe("Filter by detected content type (for Notion search_pages)"),
|
|
16463
|
+
status: external_exports.string().optional().describe("Filter by status property, e.g. 'Done', 'In Progress' (for Notion search_pages)"),
|
|
16464
|
+
priority: external_exports.string().optional().describe("Filter by priority property, e.g. 'High', 'Medium', 'Low' (for Notion search_pages)"),
|
|
16465
|
+
has_due_date: external_exports.boolean().optional().describe("Filter to pages with or without due dates (for Notion search_pages)"),
|
|
16466
|
+
tags: external_exports.string().optional().describe("Filter by tags, comma-separated (for Notion search_pages)")
|
|
16447
16467
|
})
|
|
16448
16468
|
},
|
|
16449
16469
|
async (input) => {
|
|
@@ -16748,7 +16768,12 @@ Created: ${result.created_time}`
|
|
|
16748
16768
|
workspace_id: workspaceId,
|
|
16749
16769
|
query: input.query,
|
|
16750
16770
|
database_id: input.database_id,
|
|
16751
|
-
limit: input.limit
|
|
16771
|
+
limit: input.limit,
|
|
16772
|
+
event_type: input.event_type,
|
|
16773
|
+
status: input.status,
|
|
16774
|
+
priority: input.priority,
|
|
16775
|
+
has_due_date: input.has_due_date,
|
|
16776
|
+
tags: input.tags
|
|
16752
16777
|
});
|
|
16753
16778
|
return {
|
|
16754
16779
|
content: [{ type: "text", text: formatContent(pages) }],
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contextstream/mcp-server",
|
|
3
3
|
"mcpName": "io.github.contextstreamio/mcp-server",
|
|
4
|
-
"version": "0.4.
|
|
4
|
+
"version": "0.4.33",
|
|
5
5
|
"description": "ContextStream MCP server - v0.4.x with consolidated domain tools (~11 tools, ~75% token reduction). Code context, memory, search, and AI tools.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"license": "MIT",
|