-
Notifications
You must be signed in to change notification settings - Fork 9.1k
New everything server #3121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
cliffhall
merged 82 commits into
modelcontextprotocol:main
from
cliffhall:new-everything-server
Dec 19, 2025
+3,412
−1,651
Merged
New everything server #3121
Changes from all commits
Commits
Show all changes
82 commits
Select commit
Hold shift + click to select a range
5de886c
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 8845118
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 1c64b36
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall daec74f
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall d868b1c
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall eee9866
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 7435291
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 0aeb8a7
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 9084cd3
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 7b2ff6b
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 07867a5
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 8559fbd
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 16ed059
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 346c29a
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 1df8623
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 0f3e27e
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall df844b5
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 08b6a50
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 2ce87b1
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 0bf6c69
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 328a990
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 320e3d8
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 8530747
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 03d3da0
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 27793ac
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 6cd26cf
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 904d0ea
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall f759d9e
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 7acadf4
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 48bf94a
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 3d003ab
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 2afc618
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 339e056
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall ea6fe27
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 18ef6aa
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall cb073d8
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 9b25a3a
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 2093f2d
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 1157890
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall 19e588b
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall f561f70
[WIP] Refactor everything server to be more modular and use recommend…
cliffhall c5999b5
Merge branch 'main' into new-everything-server
cliffhall a008d9f
Updated structure.md
cliffhall 2b60822
Refactor-renamed long-running-operation.ts to trigger-long-running-op…
cliffhall 919b2e0
Updated AGENTS.md with guidance on tool naming
cliffhall a235ed8
Updated package.json and ran prettier
cliffhall 79c4e51
Update README.md and doc in server/index.ts
cliffhall 90d1b66
Update doc in server/index.ts
cliffhall cb5f70c
Update doc in server/index.ts
cliffhall 299aae2
Update doc in tools/toggle-subscriber-updates.ts
cliffhall 3f5e5cf
Update doc in tools/trigger-elicitation-request.ts
cliffhall 00b8c53
Update doc in tools/trigger-long-running-operation.ts
cliffhall 8291c0b
Update doc in tools/trigger-elicitation-request.ts
cliffhall b8074f9
Update doc in tools/trigger-elicitation-request.ts and trigger-long-r…
cliffhall 45ea1e2
Update doc in tools/toggle-subscriber-updates.ts
cliffhall ba09842
Update doc in tools/toggle-subscriber-updates.ts
cliffhall cd5b728
Update doc in tools/toggle-subscriber-updates.ts
cliffhall 77deef0
Update doc in tools/gzip-file-as-resource.ts
cliffhall 6854902
Use roots cache in get-roots-list tool
cliffhall e1c1dcf
Use roots cache in get-roots-list tool
cliffhall 8126179
Run pretter:fix
cliffhall 6ad8af7
Updated doc in get-resource-reference.ts
cliffhall 82cda36
Updated doc in get-env.ts
cliffhall 29a20bf
Updated doc in get-annotated-message.ts
cliffhall 0ba86f8
Updated doc in echo.ts
cliffhall eed70bb
Updated doc in trigger-sampling-request.ts
cliffhall 7b85925
Updated doc in all tools
cliffhall 20527e4
Updated doc in all tools
cliffhall cdbcdc5
Cache roots in get-roots-list.ts if list was not already present and …
cliffhall e0f1c42
Add listChanged capability for tools, prompts, and resources in serve…
cliffhall 70feb6f
Remove `includeContext: "thisServer"` from CreateMessageRequest in tr…
cliffhall 734d5c3
Updated server instructions.md. See https://github.com/modelcontextpr…
cliffhall 8758a11
Updated server instructions.md. See https://github.com/modelcontextpr…
cliffhall ebac631
Updated server instructions.md. See https://github.com/modelcontextpr…
cliffhall 1b8f376
Demonstrate registration of tools conditioned upon client capability …
cliffhall c6daef7
Get roots unconditionally when syncRoots is called
cliffhall 17a2be2
Merge branch 'main' into new-everything-server
cliffhall f8933ec
Sync roots at startup. This was deferred to list_roots tool is used, …
cliffhall 17aaa45
Sync roots at startup. This was deferred to list_roots tool is used, …
cliffhall 5fb7a71
Merge branch 'main' into new-everything-server
cliffhall 53cc385
Update src/everything/AGENTS.md
cliffhall 44faf3a
Remove console log statements
cliffhall File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| packages | ||
| dist | ||
| README.md | ||
| node_modules |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,52 @@ | ||
| # MCP "Everything" Server - Development Guidelines | ||
|
|
||
| ## Build, Test & Run Commands | ||
|
|
||
| - Build: `npm run build` - Compiles TypeScript to JavaScript | ||
| - Watch mode: `npm run watch` - Watches for changes and rebuilds automatically | ||
| - Run STDIO server: `npm run start:stdio` - Starts the MCP server using stdio transport | ||
| - Run SSE server: `npm run start:sse` - Starts the MCP server with SSE transport | ||
| - Run StreamableHttp server: `npm run start:stremableHttp` - Starts the MCP server with StreamableHttp transport | ||
| - Prepare release: `npm run prepare` - Builds the project for publishing | ||
|
|
||
| ## Code Style Guidelines | ||
|
|
||
| - Use ES modules with `.js` extension in import paths | ||
| - Strictly type all functions and variables with TypeScript | ||
| - Follow zod schema patterns for tool input validation | ||
| - Prefer async/await over callbacks and Promise chains | ||
| - Place all imports at top of file, grouped by external then internal | ||
| - Use descriptive variable names that clearly indicate purpose | ||
| - Implement proper cleanup for timers and resources in server shutdown | ||
| - Handle errors with try/catch blocks and provide clear error messages | ||
| - Use consistent indentation (2 spaces) and trailing commas in multi-line objects | ||
| - Match existing code style, import order, and module layout in the respective folder. | ||
| - Use camelCase for variables/functions, | ||
| - Use PascalCase for types/classes, | ||
| - Use UPPER_CASE for constants | ||
| - Use kebab-case for file names and registered tools, prompts, and resources. | ||
| - Use verbs for tool names, e.g., `get-annotated-message` instead of `annotated-message` | ||
|
|
||
| ## Extending the Server | ||
|
|
||
| The Everything Server is designed to be extended at well-defined points. | ||
| See [Extension Points](docs/extension.md) and [Project Structure](docs/structure.md). | ||
| The server factory is `src/everything/server/index.ts` and registers all features during startup as well as handling post-connection setup. | ||
|
|
||
| ### High-level | ||
|
|
||
| - Tools live under `src/everything/tools/` and are registered via `registerTools(server)`. | ||
| - Resources live under `src/everything/resources/` and are registered via `registerResources(server)`. | ||
| - Prompts live under `src/everything/prompts/` and are registered via `registerPrompts(server)`. | ||
| - Subscriptions and simulated update routines are under `src/everything/resources/subscriptions.ts`. | ||
| - Logging helpers are under `src/everything/server/logging.ts`. | ||
| - Transport managers are under `src/everything/transports/`. | ||
|
|
||
| ### When adding a new feature | ||
|
|
||
| - Follow the existing file/module pattern in its folder (naming, exports, and registration function). | ||
| - Export a `registerX(server)` function that registers new items with the MCP SDK in the same style as existing ones. | ||
| - Wire your new module into the central index (e.g., update `tools/index.ts`, `resources/index.ts`, or `prompts/index.ts`). | ||
| - Ensure schemas (for tools) are accurate JSON Schema and include helpful descriptions and examples. | ||
| `server/index.ts` and usages in `logging.ts` and `subscriptions.ts`. | ||
| - Keep the docs in `src/everything/docs/` up to date if you add or modify noteworthy features. |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.