Skip to content

Conversation

@ycjcl868
Copy link
Member

@ycjcl868 ycjcl868 commented Aug 28, 2025

This pull request introduces a complete example integration suite for MCP Hub, including documentation, a Node.js client, and core infrastructure for the MCP Hub server package. The main changes focus on making MCP Hub easier to use and integrate with other tools, providing clear usage patterns, and improving development workflows.

New Examples and Documentation

  • Added a comprehensive README.md in the examples directory, detailing MCP Hub architecture, client responsibilities, API endpoints, event system, best practices, and troubleshooting. This helps new users understand how to integrate with MCP Hub and manage its lifecycle.
  • Added a ready-to-use Node.js client (node-client.js) that demonstrates server lifecycle management, event handling via SSE, tool/resource invocation, and robust error handling. This serves as both a reference implementation and a practical integration point for Node.js environments.

Core Infrastructure for MCP Hub

  • Introduced a production-ready CLI entry point (src/utils/cli.ts) for MCP Hub, supporting flexible configuration, robust argument parsing, and auto-shutdown features. This makes it easy to start and manage MCP Hub servers from the command line.
  • Added a development watcher utility (src/utils/dev-watcher.ts) to support hot-reloading and file change tracking during development, improving developer experience for MCP Hub plugin and server authors.
  • Added package metadata and build configuration files (package.json, rslib.config.ts) to enable publishing, building, and testing MCP Hub as a standalone npm package, including dependency management and build scripts. [1] [2]

Minor Codebase Cleanup

  • Removed an unnecessary ESLint directive from the WorkspaceHeader.tsx file, likely as part of general code hygiene.

References:
[1] [2] [3] [4] [5] [6] [7]

@netlify
Copy link

netlify bot commented Aug 28, 2025

Deploy Preview for agent-tars-docs canceled.

Name Link
🔨 Latest commit cecc2e2
🔍 Latest deploy log https://app.netlify.com/projects/agent-tars-docs/deploys/6916cab10c101c0008fd9432

@ycjcl868 ycjcl868 changed the title feat/add mcp hub WIP: feat: add mcp-hub Aug 28, 2025
@ycjcl868 ycjcl868 changed the title WIP: feat: add mcp-hub WIP: feat(agent-infra): add mcp-hub Aug 28, 2025

// If disabling, update config
if (disable) {
serverConfig.disabled = true;

Check warning

Code scanning / CodeQL

Prototype-polluting assignment Medium

This assignment may alter Object.prototype if a malicious '__proto__' string is injected from
user controlled input
.
const { code, server_name } = req.query;

try {
if (!code || !server_name) {

Check failure

Code scanning / CodeQL

User-controlled bypass of security check High

This condition guards a sensitive
action
, but a
user-provided value
controls it.
const { code, server_name } = req.query;

try {
if (!code || !server_name) {

Check failure

Code scanning / CodeQL

User-controlled bypass of security check High

This condition guards a sensitive
action
, but a
user-provided value
controls it.
false,
);
res.write(
`<script>updateStatus("error", "${error.message.replace(/"/g, '\\"')}");</script>`,

Check failure

Code scanning / CodeQL

Incomplete string escaping or encoding High

This does not escape backslash characters in the input.
}

logger.debug(`Executing command: ${command}`);
const { stdout } = await execPromise(command, {

Check warning

Code scanning / CodeQL

Indirect uncontrolled command line Medium

This command depends on an unsanitized
environment variable
.
This command depends on an unsanitized
environment variable
.
// File output
if (this.enableFileLogging) {
try {
fs.appendFileSync(this.logFile, message + '\n');

Check warning

Code scanning / CodeQL

Network data written to file Medium

Write to file system depends on
Untrusted data
.
Write to file system depends on
Untrusted data
.
@netlify
Copy link

netlify bot commented Sep 28, 2025

Deploy Preview for tarko canceled.

Name Link
🔨 Latest commit cecc2e2
🔍 Latest deploy log https://app.netlify.com/projects/tarko/deploys/6916cab11327d0000818fb11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants