@1mcp/agent 0.14.0 → 0.16.0
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/README.md +118 -30
- package/build/constants.d.ts +2 -1
- package/build/constants.d.ts.map +1 -1
- package/build/constants.js +2 -1
- package/build/constants.js.map +1 -1
- package/build/core/server/agentConfig.d.ts +16 -0
- package/build/core/server/agentConfig.d.ts.map +1 -1
- package/build/core/server/agentConfig.js +32 -7
- package/build/core/server/agentConfig.js.map +1 -1
- package/build/index.js +20 -0
- package/build/index.js.map +1 -1
- package/build/services/healthService.d.ts +107 -0
- package/build/services/healthService.d.ts.map +1 -0
- package/build/services/healthService.js +294 -0
- package/build/services/healthService.js.map +1 -0
- package/build/transport/http/routes/healthRoutes.d.ts +7 -0
- package/build/transport/http/routes/healthRoutes.d.ts.map +1 -0
- package/build/transport/http/routes/healthRoutes.js +113 -0
- package/build/transport/http/routes/healthRoutes.js.map +1 -0
- package/build/transport/http/routes/sseRoutes.d.ts +1 -1
- package/build/transport/http/routes/sseRoutes.d.ts.map +1 -1
- package/build/transport/http/routes/sseRoutes.js +4 -3
- package/build/transport/http/routes/sseRoutes.js.map +1 -1
- package/build/transport/http/routes/streamableHttpRoutes.d.ts +1 -1
- package/build/transport/http/routes/streamableHttpRoutes.d.ts.map +1 -1
- package/build/transport/http/routes/streamableHttpRoutes.js +5 -4
- package/build/transport/http/routes/streamableHttpRoutes.js.map +1 -1
- package/build/transport/http/server.d.ts.map +1 -1
- package/build/transport/http/server.js +16 -3
- package/build/transport/http/server.js.map +1 -1
- package/build/utils/logo.d.ts +8 -0
- package/build/utils/logo.d.ts.map +1 -0
- package/build/utils/logo.js +26 -0
- package/build/utils/logo.js.map +1 -0
- package/package.json +18 -3
package/README.md
CHANGED
|
@@ -6,18 +6,39 @@ A unified Model Context Protocol server implementation that aggregates multiple
|
|
|
6
6
|
[](https://www.npmjs.com/package/@1mcp/agent)
|
|
7
7
|
[](https://smithery.ai/server/@1mcp-app/agent)
|
|
8
8
|
|
|
9
|
+
## Table of Contents
|
|
10
|
+
|
|
11
|
+
- [Overview](#overview)
|
|
12
|
+
- [Features](#features)
|
|
13
|
+
- [Quick Start](#quick-start)
|
|
14
|
+
- [Prerequisites](#prerequisites)
|
|
15
|
+
- [Usage](#usage)
|
|
16
|
+
- [Docker](#docker)
|
|
17
|
+
- [Trust Proxy Configuration](#trust-proxy-configuration)
|
|
18
|
+
- [Understanding Tags](#understanding-tags)
|
|
19
|
+
- [Configuration](#configuration)
|
|
20
|
+
- [Authentication](#authentication)
|
|
21
|
+
- [Health Monitoring](#health-monitoring)
|
|
22
|
+
- [How It Works](#how-it-works)
|
|
23
|
+
- [Development](#development)
|
|
24
|
+
- [Contributing](#contributing)
|
|
25
|
+
- [License](#license)
|
|
26
|
+
|
|
9
27
|
## Overview
|
|
10
28
|
|
|
11
|
-
1MCP (One MCP) is designed to simplify the way you work with AI assistants. Instead of configuring multiple MCP servers for different clients (Claude Desktop, Cherry Studio, Cursor, Roo Code, Claude, etc.), 1MCP provides a single, unified server
|
|
29
|
+
1MCP (One MCP) is designed to simplify the way you work with AI assistants. Instead of configuring multiple MCP servers for different clients (Claude Desktop, Cherry Studio, Cursor, Roo Code, Claude, etc.), 1MCP provides a single, unified server.
|
|
30
|
+
|
|
31
|
+
## Features
|
|
12
32
|
|
|
13
|
-
- Aggregates multiple MCP servers into one
|
|
14
|
-
- Reduces system resource usage by eliminating redundant server instances
|
|
15
|
-
- Simplifies configuration management across different AI assistants
|
|
16
|
-
- Provides a standardized way for AI models to interact with external tools and resources
|
|
17
|
-
- Supports dynamic configuration reloading without server restart
|
|
18
|
-
- Handles graceful shutdown and resource cleanup
|
|
19
|
-
- Includes comprehensive authentication and security features
|
|
20
|
-
- Supports advanced filtering, pagination, and request optimization
|
|
33
|
+
- **Unified Interface**: Aggregates multiple MCP servers into one.
|
|
34
|
+
- **Resource Friendly**: Reduces system resource usage by eliminating redundant server instances.
|
|
35
|
+
- **Simplified Configuration**: Simplifies configuration management across different AI assistants.
|
|
36
|
+
- **Standardized Interaction**: Provides a standardized way for AI models to interact with external tools and resources.
|
|
37
|
+
- **Dynamic Configuration**: Supports dynamic configuration reloading without server restart.
|
|
38
|
+
- **Graceful Shutdown**: Handles graceful shutdown and resource cleanup.
|
|
39
|
+
- **Secure**: Includes comprehensive authentication and security features.
|
|
40
|
+
- **Optimized**: Supports advanced filtering, pagination, and request optimization.
|
|
41
|
+
- **Health Monitoring**: Built-in health check endpoints for monitoring and observability.
|
|
21
42
|
|
|
22
43
|
## Quick Start
|
|
23
44
|
|
|
@@ -44,6 +65,11 @@ npx -y @1mcp/agent --config ~/Library/Application\ Support/Claude/claude_desktop
|
|
|
44
65
|
|
|
45
66
|
3. Enjoy it!
|
|
46
67
|
|
|
68
|
+
## Prerequisites
|
|
69
|
+
|
|
70
|
+
- [Node.js](https://nodejs.org/) (version 21 or higher)
|
|
71
|
+
- [pnpm](https://pnpm.io/)
|
|
72
|
+
|
|
47
73
|
## Usage
|
|
48
74
|
|
|
49
75
|
You can run the server directly using `npx`:
|
|
@@ -61,30 +87,34 @@ npx -y @1mcp/agent --transport stdio
|
|
|
61
87
|
# Use external URL for reverse proxy setup (nginx, etc.)
|
|
62
88
|
npx -y @1mcp/agent --external-url https://example.com
|
|
63
89
|
|
|
90
|
+
# Configure trust proxy for reverse proxy setup
|
|
91
|
+
npx -y @1mcp/agent --trust-proxy=192.168.1.1
|
|
92
|
+
|
|
64
93
|
# Show all available options
|
|
65
94
|
npx -y @1mcp/agent --help
|
|
66
95
|
```
|
|
67
96
|
|
|
68
97
|
Available options:
|
|
69
98
|
|
|
70
|
-
| Option (CLI) | Environment Variable | Description
|
|
71
|
-
| :--------------------------- | :--------------------------------- |
|
|
72
|
-
| `--transport`, `-t` | `ONE_MCP_TRANSPORT` | Choose transport type ("stdio", "http", or "sse")
|
|
73
|
-
| `--config`, `-c` | `ONE_MCP_CONFIG` | Use a specific config file
|
|
74
|
-
| `--port`, `-P` | `ONE_MCP_PORT` | Change HTTP port
|
|
75
|
-
| `--host`, `-H` | `ONE_MCP_HOST` | Change HTTP host
|
|
76
|
-
| `--external-url`, `-u` | `ONE_MCP_EXTERNAL_URL` | External URL for OAuth callbacks and public URLs (e.g., https://example.com)
|
|
77
|
-
| `--
|
|
78
|
-
| `--
|
|
79
|
-
| `--
|
|
80
|
-
| `--enable-auth` | `ONE_MCP_ENABLE_AUTH` | Enable authentication (OAuth 2.1)
|
|
81
|
-
| `--enable-scope-validation` | `ONE_MCP_ENABLE_SCOPE_VALIDATION` | Enable tag-based scope validation (boolean)
|
|
82
|
-
| `--enable-enhanced-security` | `ONE_MCP_ENABLE_ENHANCED_SECURITY` | Enable enhanced security middleware (boolean)
|
|
83
|
-
| `--session-ttl` | `ONE_MCP_SESSION_TTL` | Session expiry time in minutes (number)
|
|
84
|
-
| `--session-storage-path` | `ONE_MCP_SESSION_STORAGE_PATH` | Custom session storage directory path (string)
|
|
85
|
-
| `--rate-limit-window` | `ONE_MCP_RATE_LIMIT_WINDOW` | OAuth rate limit window in minutes (number)
|
|
86
|
-
| `--rate-limit-max` | `ONE_MCP_RATE_LIMIT_MAX` | Maximum requests per OAuth rate limit window (number)
|
|
87
|
-
| `--
|
|
99
|
+
| Option (CLI) | Environment Variable | Description | Default |
|
|
100
|
+
| :--------------------------- | :--------------------------------- | :---------------------------------------------------------------------------- | :--------: |
|
|
101
|
+
| `--transport`, `-t` | `ONE_MCP_TRANSPORT` | Choose transport type ("stdio", "http", or "sse") | "http" |
|
|
102
|
+
| `--config`, `-c` | `ONE_MCP_CONFIG` | Use a specific config file | |
|
|
103
|
+
| `--port`, `-P` | `ONE_MCP_PORT` | Change HTTP port | 3050 |
|
|
104
|
+
| `--host`, `-H` | `ONE_MCP_HOST` | Change HTTP host | localhost |
|
|
105
|
+
| `--external-url`, `-u` | `ONE_MCP_EXTERNAL_URL` | External URL for OAuth callbacks and public URLs (e.g., https://example.com) | |
|
|
106
|
+
| `--trust-proxy` | `ONE_MCP_TRUST_PROXY` | Trust proxy configuration for client IP detection (boolean, IP, CIDR, preset) | "loopback" |
|
|
107
|
+
| `--tags`, `-g` | `ONE_MCP_TAGS` | Filter servers by tags | |
|
|
108
|
+
| `--pagination`, `-p` | `ONE_MCP_PAGINATION` | Enable pagination for client/server lists (boolean) | false |
|
|
109
|
+
| `--enable-auth` | `ONE_MCP_ENABLE_AUTH` | Enable authentication (OAuth 2.1) | false |
|
|
110
|
+
| `--enable-scope-validation` | `ONE_MCP_ENABLE_SCOPE_VALIDATION` | Enable tag-based scope validation (boolean) | true |
|
|
111
|
+
| `--enable-enhanced-security` | `ONE_MCP_ENABLE_ENHANCED_SECURITY` | Enable enhanced security middleware (boolean) | false |
|
|
112
|
+
| `--session-ttl` | `ONE_MCP_SESSION_TTL` | Session expiry time in minutes (number) | 1440 |
|
|
113
|
+
| `--session-storage-path` | `ONE_MCP_SESSION_STORAGE_PATH` | Custom session storage directory path (string) | |
|
|
114
|
+
| `--rate-limit-window` | `ONE_MCP_RATE_LIMIT_WINDOW` | OAuth rate limit window in minutes (number) | 15 |
|
|
115
|
+
| `--rate-limit-max` | `ONE_MCP_RATE_LIMIT_MAX` | Maximum requests per OAuth rate limit window (number) | 100 |
|
|
116
|
+
| `--health-info-level` | `ONE_MCP_HEALTH_INFO_LEVEL` | Health endpoint information detail level ("full", "basic", "minimal") | "minimal" |
|
|
117
|
+
| `--help`, `-h` | | Show help | |
|
|
88
118
|
|
|
89
119
|
## Docker
|
|
90
120
|
|
|
@@ -122,14 +152,32 @@ docker run -p 3051:3051 \
|
|
|
122
152
|
# With external URL for reverse proxy
|
|
123
153
|
docker run -p 3050:3050 \
|
|
124
154
|
-e ONE_MCP_EXTERNAL_URL=https://mcp.example.com \
|
|
155
|
+
-e ONE_MCP_TRUST_PROXY=true \
|
|
125
156
|
ghcr.io/1mcp-app/agent
|
|
126
157
|
```
|
|
127
158
|
|
|
128
|
-
|
|
159
|
+
## Trust Proxy Configuration
|
|
160
|
+
|
|
161
|
+
When running 1MCP behind a reverse proxy, configure trust proxy settings for proper client IP detection:
|
|
162
|
+
|
|
163
|
+
```bash
|
|
164
|
+
# Default (safe for local development)
|
|
165
|
+
npx -y @1mcp/agent --trust-proxy=loopback
|
|
166
|
+
|
|
167
|
+
# Behind reverse proxy
|
|
168
|
+
npx -y @1mcp/agent --trust-proxy=192.168.1.1
|
|
169
|
+
|
|
170
|
+
# Behind CDN/Cloudflare
|
|
171
|
+
npx -y @1mcp/agent --trust-proxy=true
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
See [docs/TRUST_PROXY.md](docs/TRUST_PROXY.md) for detailed configuration options, security considerations, and reverse proxy setup examples.
|
|
175
|
+
|
|
176
|
+
## Understanding Tags
|
|
129
177
|
|
|
130
178
|
Tags help you control which MCP servers are available to different clients. Think of tags as labels that describe what each server can do.
|
|
131
179
|
|
|
132
|
-
|
|
180
|
+
### How to Use Tags
|
|
133
181
|
|
|
134
182
|
1. **In your server config**: Add tags to each server to describe its capabilities
|
|
135
183
|
|
|
@@ -211,8 +259,40 @@ The server automatically manages configuration in a global location:
|
|
|
211
259
|
}
|
|
212
260
|
```
|
|
213
261
|
|
|
262
|
+
## Authentication
|
|
263
|
+
|
|
264
|
+
1MCP supports OAuth 2.1 for secure authentication. To enable it, use the `--enable-auth` flag. The `--auth` flag is deprecated and will be removed in a future version.
|
|
265
|
+
|
|
266
|
+
When authentication is enabled, 1MCP acts as an OAuth 2.1 provider, allowing client applications to securely connect. This ensures that only authorized clients can access the MCP servers.
|
|
267
|
+
|
|
268
|
+
## Health Monitoring
|
|
269
|
+
|
|
270
|
+
1MCP provides comprehensive health check endpoints for monitoring and observability:
|
|
271
|
+
|
|
272
|
+
### Health Check Endpoints
|
|
273
|
+
|
|
274
|
+
- **`GET /health`** - Complete health status including system metrics, server status, and configuration
|
|
275
|
+
- **`GET /health/live`** - Simple liveness probe (always returns 200 if server is running)
|
|
276
|
+
- **`GET /health/ready`** - Readiness probe (returns 200 if configuration is loaded and ready)
|
|
277
|
+
|
|
278
|
+
### Health Status Levels
|
|
279
|
+
|
|
280
|
+
- **`healthy`** - All systems operational (HTTP 200)
|
|
281
|
+
- **`degraded`** - Some issues but still functional (HTTP 200)
|
|
282
|
+
- **`unhealthy`** - Critical issues affecting functionality (HTTP 503)
|
|
283
|
+
|
|
284
|
+
### Monitoring Integration
|
|
285
|
+
|
|
286
|
+
Use these endpoints with:
|
|
287
|
+
|
|
288
|
+
- Load balancers (health checks)
|
|
289
|
+
- Container orchestration (Kubernetes health probes)
|
|
290
|
+
- CI/CD pipelines (deployment validation)
|
|
291
|
+
|
|
214
292
|
## How It Works
|
|
215
293
|
|
|
294
|
+
1MCP acts as a proxy, managing and aggregating multiple MCP servers. It starts and stops these servers as subprocesses and forwards requests from AI assistants to the appropriate server. This architecture allows for a single point of entry for all MCP traffic, simplifying management and reducing overhead.
|
|
295
|
+
|
|
216
296
|
### System Architecture
|
|
217
297
|
|
|
218
298
|
```mermaid
|
|
@@ -303,8 +383,16 @@ pnpm inspector
|
|
|
303
383
|
|
|
304
384
|
The Inspector will provide a URL to access debugging tools in your browser.
|
|
305
385
|
|
|
306
|
-
|
|
386
|
+
### Debugging & Source Maps
|
|
307
387
|
|
|
308
388
|
This project uses [source-map-support](https://www.npmjs.com/package/source-map-support) to enhance stack traces. When you run the server, stack traces will reference the original TypeScript source files instead of the compiled JavaScript. This makes debugging much easier, as error locations and line numbers will match your source code.
|
|
309
389
|
|
|
310
390
|
No extra setup is required—this is enabled by default. If you see a stack trace, it will point to `.ts` files and the correct line numbers. 🗺️
|
|
391
|
+
|
|
392
|
+
## Contributing
|
|
393
|
+
|
|
394
|
+
Contributions are welcome! Please read our [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.
|
|
395
|
+
|
|
396
|
+
## License
|
|
397
|
+
|
|
398
|
+
This project is licensed under the Apache License 2.0. See the [LICENSE](LICENSE) file for details.
|
package/build/constants.d.ts
CHANGED
|
@@ -7,9 +7,10 @@ export declare const HOST = "localhost";
|
|
|
7
7
|
export declare const SSE_ENDPOINT = "/sse";
|
|
8
8
|
export declare const MESSAGES_ENDPOINT = "/messages";
|
|
9
9
|
export declare const STREAMABLE_HTTP_ENDPOINT = "/mcp";
|
|
10
|
+
export declare const HEALTH_ENDPOINT = "/health";
|
|
10
11
|
export declare const MCP_CONFIG_FILE = "mcp.json";
|
|
11
12
|
export declare const MCP_SERVER_NAME = "1mcp";
|
|
12
|
-
export declare const MCP_SERVER_VERSION = "0.
|
|
13
|
+
export declare const MCP_SERVER_VERSION = "0.16.0";
|
|
13
14
|
export declare const MCP_URI_SEPARATOR = "_1mcp_";
|
|
14
15
|
export declare const CONFIG_DIR_NAME = "1mcp";
|
|
15
16
|
export declare const DEFAULT_CONFIG: {
|
package/build/constants.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,oCAAoC,CAAC;AAG5F,eAAO,MAAM,IAAI,OAAO,CAAC;AACzB,eAAO,MAAM,IAAI,cAAc,CAAC;AAGhC,eAAO,MAAM,YAAY,SAAS,CAAC;AACnC,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,eAAO,MAAM,wBAAwB,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,oCAAoC,CAAC;AAG5F,eAAO,MAAM,IAAI,OAAO,CAAC;AACzB,eAAO,MAAM,IAAI,cAAc,CAAC;AAGhC,eAAO,MAAM,YAAY,SAAS,CAAC;AACnC,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,eAAO,MAAM,wBAAwB,SAAS,CAAC;AAC/C,eAAO,MAAM,eAAe,YAAY,CAAC;AAGzC,eAAO,MAAM,eAAe,aAAa,CAAC;AAC1C,eAAO,MAAM,eAAe,SAAS,CAAC;AACtC,eAAO,MAAM,kBAAkB,WAAW,CAAC;AAE3C,eAAO,MAAM,iBAAiB,WAAW,CAAC;AAG1C,eAAO,MAAM,eAAe,SAAS,CAAC;AACtC,eAAO,MAAM,cAAc;;CAE1B,CAAC;AAEF;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,MAAM,CAY3C;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,MAAM,CAE5C;AAGD,eAAO,MAAM,gBAAgB;;;CAG5B,CAAC;AAGF,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkEvB,CAAC;AAGF,eAAO,MAAM,iBAAiB;;;;;;;;CAM7B,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,kBAYrC,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,kBAUrC,CAAC"}
|
package/build/constants.js
CHANGED
|
@@ -8,10 +8,11 @@ export const HOST = 'localhost';
|
|
|
8
8
|
export const SSE_ENDPOINT = '/sse';
|
|
9
9
|
export const MESSAGES_ENDPOINT = '/messages';
|
|
10
10
|
export const STREAMABLE_HTTP_ENDPOINT = '/mcp';
|
|
11
|
+
export const HEALTH_ENDPOINT = '/health';
|
|
11
12
|
// MCP constants
|
|
12
13
|
export const MCP_CONFIG_FILE = 'mcp.json';
|
|
13
14
|
export const MCP_SERVER_NAME = '1mcp';
|
|
14
|
-
export const MCP_SERVER_VERSION = '0.
|
|
15
|
+
export const MCP_SERVER_VERSION = '0.16.0';
|
|
15
16
|
export const MCP_URI_SEPARATOR = '_1mcp_';
|
|
16
17
|
// Global config paths
|
|
17
18
|
export const CONFIG_DIR_NAME = '1mcp';
|
package/build/constants.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,uBAAuB;AACvB,MAAM,CAAC,MAAM,IAAI,GAAG,IAAI,CAAC;AACzB,MAAM,CAAC,MAAM,IAAI,GAAG,WAAW,CAAC;AAEhC,gBAAgB;AAChB,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC;AACnC,MAAM,CAAC,MAAM,iBAAiB,GAAG,WAAW,CAAC;AAC7C,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,uBAAuB;AACvB,MAAM,CAAC,MAAM,IAAI,GAAG,IAAI,CAAC;AACzB,MAAM,CAAC,MAAM,IAAI,GAAG,WAAW,CAAC;AAEhC,gBAAgB;AAChB,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC;AACnC,MAAM,CAAC,MAAM,iBAAiB,GAAG,WAAW,CAAC;AAC7C,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAC;AAC/C,MAAM,CAAC,MAAM,eAAe,GAAG,SAAS,CAAC;AAEzC,gBAAgB;AAChB,MAAM,CAAC,MAAM,eAAe,GAAG,UAAU,CAAC;AAC1C,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC;AACtC,MAAM,CAAC,MAAM,kBAAkB,GAAG,QAAQ,CAAC;AAE3C,MAAM,CAAC,MAAM,iBAAiB,GAAG,QAAQ,CAAC;AAE1C,sBAAsB;AACtB,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC;AACtC,MAAM,CAAC,MAAM,cAAc,GAAG;IAC5B,UAAU,EAAE,EAAE;CACf,CAAC;AAEF;;GAEG;AACH,MAAM,UAAU,kBAAkB;IAChC,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,OAAO,CAAC,GAAG,CAAC,WAAW,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IACD,OAAO,EAAE,EAAE;CACZ,CAAC;AAEF,MAAM,CAAC,MAAM,uBAAuB,GAAuB;IACzD,KAAK,EAAE;QACL,WAAW,EAAE,KAAK;KACnB;IACD,QAAQ,EAAE;QACR,WAAW,EAAE,KAAK;KACnB;IACD,WAAW,EAAE;QACX,WAAW,EAAE,KAAK;KACnB;CACF,CAAC"}
|
|
@@ -8,6 +8,7 @@ export interface AgentConfig {
|
|
|
8
8
|
host: string;
|
|
9
9
|
port: number;
|
|
10
10
|
externalUrl?: string;
|
|
11
|
+
trustProxy: string | boolean;
|
|
11
12
|
auth: {
|
|
12
13
|
enabled: boolean;
|
|
13
14
|
sessionTtlMinutes: number;
|
|
@@ -24,6 +25,9 @@ export interface AgentConfig {
|
|
|
24
25
|
scopeValidation: boolean;
|
|
25
26
|
enhancedSecurity: boolean;
|
|
26
27
|
};
|
|
28
|
+
health: {
|
|
29
|
+
detailLevel: 'full' | 'basic' | 'minimal';
|
|
30
|
+
};
|
|
27
31
|
}
|
|
28
32
|
/**
|
|
29
33
|
* AgentConfigManager manages agent-specific configuration settings.
|
|
@@ -138,11 +142,23 @@ export declare class AgentConfigManager {
|
|
|
138
142
|
* @returns The external URL or undefined if not set
|
|
139
143
|
*/
|
|
140
144
|
getExternalUrl(): string | undefined;
|
|
145
|
+
/**
|
|
146
|
+
* Gets the trust proxy configuration for Express.js.
|
|
147
|
+
*
|
|
148
|
+
* @returns Trust proxy setting (boolean, string preset, IP address, or CIDR range)
|
|
149
|
+
*/
|
|
150
|
+
getTrustProxy(): string | boolean;
|
|
141
151
|
/**
|
|
142
152
|
* Gets the server URL, preferring external URL if set, otherwise falling back to http://host:port.
|
|
143
153
|
*
|
|
144
154
|
* @returns The server URL to use for OAuth callbacks and public URLs
|
|
145
155
|
*/
|
|
146
156
|
getUrl(): string;
|
|
157
|
+
/**
|
|
158
|
+
* Gets the health endpoint detail level configuration.
|
|
159
|
+
*
|
|
160
|
+
* @returns Health detail level ('full' | 'basic' | 'minimal')
|
|
161
|
+
*/
|
|
162
|
+
getHealthDetailLevel(): 'full' | 'basic' | 'minimal';
|
|
147
163
|
}
|
|
148
164
|
//# sourceMappingURL=agentConfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agentConfig.d.ts","sourceRoot":"","sources":["../../../src/core/server/agentConfig.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE;QACJ,OAAO,EAAE,OAAO,CAAC;QACjB,iBAAiB,EAAE,MAAM,CAAC;QAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAC;QAC5B,cAAc,EAAE,MAAM,CAAC;QACvB,eAAe,EAAE,MAAM,CAAC;KACzB,CAAC;IACF,SAAS,EAAE;QACT,QAAQ,EAAE,MAAM,CAAC;QACjB,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IACF,QAAQ,EAAE;QACR,IAAI,EAAE,OAAO,CAAC;QACd,eAAe,EAAE,OAAO,CAAC;QACzB,gBAAgB,EAAE,OAAO,CAAC;KAC3B,CAAC;CACH;AAED;;;;;;;;;;;;;;;GAeG;AACH,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAqB;IAC5C,OAAO,CAAC,MAAM,CAAc;IAE5B;;;;;OAKG;IACH,OAAO;
|
|
1
|
+
{"version":3,"file":"agentConfig.d.ts","sourceRoot":"","sources":["../../../src/core/server/agentConfig.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC;IAC7B,IAAI,EAAE;QACJ,OAAO,EAAE,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OAIG;IACI,aAAa,IAAI,MAAM,GAAG,OAAO;IAIxC;;;;OAIG;IACI,MAAM,IAAI,MAAM;IAIvB;;;;OAIG;IACI,oBAAoB,IAAI,MAAM,GAAG,OAAO,GAAG,SAAS;CAG5D"}
|
|
@@ -28,6 +28,7 @@ export class AgentConfigManager {
|
|
|
28
28
|
this.config = {
|
|
29
29
|
host: HOST,
|
|
30
30
|
port: PORT,
|
|
31
|
+
trustProxy: 'loopback',
|
|
31
32
|
auth: {
|
|
32
33
|
enabled: AUTH_CONFIG.SERVER.DEFAULT_ENABLED,
|
|
33
34
|
sessionTtlMinutes: AUTH_CONFIG.SERVER.SESSION.TTL_MINUTES,
|
|
@@ -43,6 +44,9 @@ export class AgentConfigManager {
|
|
|
43
44
|
scopeValidation: AUTH_CONFIG.SERVER.DEFAULT_ENABLED,
|
|
44
45
|
enhancedSecurity: false,
|
|
45
46
|
},
|
|
47
|
+
health: {
|
|
48
|
+
detailLevel: 'minimal',
|
|
49
|
+
},
|
|
46
50
|
};
|
|
47
51
|
}
|
|
48
52
|
/**
|
|
@@ -68,15 +72,20 @@ export class AgentConfigManager {
|
|
|
68
72
|
* @param updates - Partial configuration object with new values
|
|
69
73
|
*/
|
|
70
74
|
updateConfig(updates) {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
75
|
+
// Handle nested object merging properly
|
|
76
|
+
const { auth, rateLimit, features, health, ...otherUpdates } = updates;
|
|
77
|
+
this.config = { ...this.config, ...otherUpdates };
|
|
78
|
+
if (auth) {
|
|
79
|
+
this.config.auth = { ...this.config.auth, ...auth };
|
|
80
|
+
}
|
|
81
|
+
if (rateLimit) {
|
|
82
|
+
this.config.rateLimit = { ...this.config.rateLimit, ...rateLimit };
|
|
74
83
|
}
|
|
75
|
-
if (
|
|
76
|
-
this.config.
|
|
84
|
+
if (features) {
|
|
85
|
+
this.config.features = { ...this.config.features, ...features };
|
|
77
86
|
}
|
|
78
|
-
if (
|
|
79
|
-
this.config.
|
|
87
|
+
if (health) {
|
|
88
|
+
this.config.health = { ...this.config.health, ...health };
|
|
80
89
|
}
|
|
81
90
|
}
|
|
82
91
|
/**
|
|
@@ -170,6 +179,14 @@ export class AgentConfigManager {
|
|
|
170
179
|
getExternalUrl() {
|
|
171
180
|
return this.config.externalUrl;
|
|
172
181
|
}
|
|
182
|
+
/**
|
|
183
|
+
* Gets the trust proxy configuration for Express.js.
|
|
184
|
+
*
|
|
185
|
+
* @returns Trust proxy setting (boolean, string preset, IP address, or CIDR range)
|
|
186
|
+
*/
|
|
187
|
+
getTrustProxy() {
|
|
188
|
+
return this.config.trustProxy;
|
|
189
|
+
}
|
|
173
190
|
/**
|
|
174
191
|
* Gets the server URL, preferring external URL if set, otherwise falling back to http://host:port.
|
|
175
192
|
*
|
|
@@ -178,5 +195,13 @@ export class AgentConfigManager {
|
|
|
178
195
|
getUrl() {
|
|
179
196
|
return this.config.externalUrl || `http://${this.config.host}:${this.config.port}`;
|
|
180
197
|
}
|
|
198
|
+
/**
|
|
199
|
+
* Gets the health endpoint detail level configuration.
|
|
200
|
+
*
|
|
201
|
+
* @returns Health detail level ('full' | 'basic' | 'minimal')
|
|
202
|
+
*/
|
|
203
|
+
getHealthDetailLevel() {
|
|
204
|
+
return this.config.health.detailLevel;
|
|
205
|
+
}
|
|
181
206
|
}
|
|
182
207
|
//# sourceMappingURL=agentConfig.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agentConfig.js","sourceRoot":"","sources":["../../../src/core/server/agentConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,IAAI,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"agentConfig.js","sourceRoot":"","sources":["../../../src/core/server/agentConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,IAAI,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAkChF;;;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AAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,eAAe,CAAC;IAC1C,CAAC;IAED;;;;OAIG;IACI,oBAAoB;QACzB,OAAO,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC;IACxC,CAAC;IAED;;;;OAIG;IACI,eAAe;QACpB,OAAO,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC;IACnC,CAAC;IAED;;;;OAIG;IACI,wBAAwB;QAC7B,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,eAAe,CAAC;IAC9C,CAAC;IAED;;;;OAIG;IACI,yBAAyB;QAC9B,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,gBAAgB,CAAC;IAC/C,CAAC;IAED;;;;OAIG;IACI,cAAc;QACnB,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC;IACjC,CAAC;IAED;;;;OAIG;IACI,aAAa;QAClB,OAAO,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC;IAChC,CAAC;IAED;;;;OAIG;IACI,MAAM;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,IAAI,UAAU,IAAI,CAAC,MAAM,CAAC,IAAI,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;IACrF,CAAC;IAED;;;;OAIG;IACI,oBAAoB;QACzB,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC;IACxC,CAAC;CACF"}
|
package/build/index.js
CHANGED
|
@@ -10,6 +10,7 @@ import { McpConfigManager } from './config/mcpConfigManager.js';
|
|
|
10
10
|
import { ExpressServer } from './transport/http/server.js';
|
|
11
11
|
import { AgentConfigManager } from './core/server/agentConfig.js';
|
|
12
12
|
import { PORT, HOST } from './constants.js';
|
|
13
|
+
import { displayLogo } from './utils/logo.js';
|
|
13
14
|
// Parse command line arguments
|
|
14
15
|
const argv = yargs(hideBin(process.argv))
|
|
15
16
|
.usage('Usage: $0 [options]')
|
|
@@ -98,6 +99,17 @@ const argv = yargs(hideBin(process.argv))
|
|
|
98
99
|
type: 'number',
|
|
99
100
|
default: 100,
|
|
100
101
|
},
|
|
102
|
+
'trust-proxy': {
|
|
103
|
+
describe: 'Trust proxy configuration for Express.js (boolean, IP address, subnet, or preset: loopback, linklocal, uniquelocal)',
|
|
104
|
+
type: 'string',
|
|
105
|
+
default: 'loopback',
|
|
106
|
+
},
|
|
107
|
+
'health-info-level': {
|
|
108
|
+
describe: 'Health endpoint information detail level (full, basic, minimal)',
|
|
109
|
+
type: 'string',
|
|
110
|
+
choices: ['full', 'basic', 'minimal'],
|
|
111
|
+
default: 'minimal',
|
|
112
|
+
},
|
|
101
113
|
})
|
|
102
114
|
.help()
|
|
103
115
|
.alias('help', 'h')
|
|
@@ -145,6 +157,7 @@ async function main() {
|
|
|
145
157
|
try {
|
|
146
158
|
if (argv.transport !== 'stdio') {
|
|
147
159
|
enableConsoleTransport();
|
|
160
|
+
displayLogo();
|
|
148
161
|
}
|
|
149
162
|
McpConfigManager.getInstance(argv.config);
|
|
150
163
|
// Configure server settings from CLI arguments
|
|
@@ -153,10 +166,14 @@ async function main() {
|
|
|
153
166
|
const authEnabled = argv['enable-auth'] ?? argv['auth'] ?? false;
|
|
154
167
|
const scopeValidationEnabled = argv['enable-scope-validation'] ?? authEnabled;
|
|
155
168
|
const enhancedSecurityEnabled = argv['enable-enhanced-security'] ?? false;
|
|
169
|
+
// Handle trust proxy configuration (convert 'true'/'false' strings to boolean)
|
|
170
|
+
const trustProxyValue = argv['trust-proxy'];
|
|
171
|
+
const trustProxy = trustProxyValue === 'true' ? true : trustProxyValue === 'false' ? false : trustProxyValue;
|
|
156
172
|
serverConfigManager.updateConfig({
|
|
157
173
|
host: argv.host,
|
|
158
174
|
port: argv.port,
|
|
159
175
|
externalUrl: argv['external-url'],
|
|
176
|
+
trustProxy,
|
|
160
177
|
auth: {
|
|
161
178
|
enabled: authEnabled,
|
|
162
179
|
sessionTtlMinutes: argv['session-ttl'],
|
|
@@ -173,6 +190,9 @@ async function main() {
|
|
|
173
190
|
scopeValidation: scopeValidationEnabled,
|
|
174
191
|
enhancedSecurity: enhancedSecurityEnabled,
|
|
175
192
|
},
|
|
193
|
+
health: {
|
|
194
|
+
detailLevel: argv['health-info-level'],
|
|
195
|
+
},
|
|
176
196
|
});
|
|
177
197
|
// Initialize server and get server manager with custom config path if provided
|
|
178
198
|
const serverManager = await setupServer();
|
package/build/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,gCAAgC,CAAC;AAExC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAEjF,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,MAAM,EAAE,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,mBAAmB,MAAM,mCAAmC,CAAC;AAEpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAClE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,gCAAgC,CAAC;AAExC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAEjF,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,MAAM,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AAI,CAAC,UAAU,EAAE,CAAC,CAAC;gBACtG,MAAM,CAAC,IAAI,CAAC,qCAAqC,CAAC,CAAC;gBACnD,MAAM;YACR,CAAC;YACD,KAAK,KAAK,CAAC,CAAC,CAAC;gBACX,MAAM,CAAC,OAAO,CAAC,4CAA4C,CAAC,CAAC;YAC/D,CAAC;YACD,0CAA0C;YAC1C,KAAK,MAAM,CAAC,CAAC,CAAC;gBACZ,yBAAyB;gBACzB,aAAa,GAAG,IAAI,aAAa,CAAC,aAAa,CAAC,CAAC;gBACjD,aAAa,CAAC,KAAK,EAAE,CAAC;gBACtB,MAAM;YACR,CAAC;YACD;gBACE,MAAM,CAAC,KAAK,CAAC,sBAAsB,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC;gBACrD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QACpB,CAAC;QAED,oCAAoC;QACpC,qBAAqB,CAAC,aAAa,EAAE,aAAa,CAAC,CAAC;IACtD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,CAAC,KAAK,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;QACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,MAAM,CAAC,KAAK,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;IACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { ClientStatus } from '../core/types/index.js';
|
|
2
|
+
/**
|
|
3
|
+
* Health status levels
|
|
4
|
+
*/
|
|
5
|
+
export declare enum HealthStatus {
|
|
6
|
+
HEALTHY = "healthy",
|
|
7
|
+
DEGRADED = "degraded",
|
|
8
|
+
UNHEALTHY = "unhealthy"
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* MCP server health information
|
|
12
|
+
*/
|
|
13
|
+
export interface McpServerHealth {
|
|
14
|
+
name: string;
|
|
15
|
+
status: ClientStatus;
|
|
16
|
+
healthy: boolean;
|
|
17
|
+
lastConnected?: Date;
|
|
18
|
+
lastError?: string;
|
|
19
|
+
tags?: string[];
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* System health metrics
|
|
23
|
+
*/
|
|
24
|
+
export interface SystemHealth {
|
|
25
|
+
uptime: number;
|
|
26
|
+
memory: {
|
|
27
|
+
used: number;
|
|
28
|
+
total: number;
|
|
29
|
+
percentage: number;
|
|
30
|
+
};
|
|
31
|
+
process: {
|
|
32
|
+
pid: number;
|
|
33
|
+
nodeVersion: string;
|
|
34
|
+
platform: string;
|
|
35
|
+
arch: string;
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Complete health check response
|
|
40
|
+
*/
|
|
41
|
+
export interface HealthCheckResponse {
|
|
42
|
+
status: HealthStatus;
|
|
43
|
+
timestamp: string;
|
|
44
|
+
version: string;
|
|
45
|
+
system: SystemHealth;
|
|
46
|
+
servers: {
|
|
47
|
+
total: number;
|
|
48
|
+
healthy: number;
|
|
49
|
+
unhealthy: number;
|
|
50
|
+
details: McpServerHealth[];
|
|
51
|
+
};
|
|
52
|
+
configuration: {
|
|
53
|
+
loaded: boolean;
|
|
54
|
+
serverCount: number;
|
|
55
|
+
enabledCount: number;
|
|
56
|
+
disabledCount: number;
|
|
57
|
+
authEnabled: boolean;
|
|
58
|
+
transport: string;
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Health service for monitoring system and MCP server status
|
|
63
|
+
*/
|
|
64
|
+
export declare class HealthService {
|
|
65
|
+
private static instance;
|
|
66
|
+
private startTime;
|
|
67
|
+
private agentConfig;
|
|
68
|
+
private constructor();
|
|
69
|
+
/**
|
|
70
|
+
* Get singleton instance
|
|
71
|
+
*/
|
|
72
|
+
static getInstance(): HealthService;
|
|
73
|
+
/**
|
|
74
|
+
* Perform complete health check
|
|
75
|
+
*/
|
|
76
|
+
performHealthCheck(): Promise<HealthCheckResponse>;
|
|
77
|
+
/**
|
|
78
|
+
* Sanitize health response based on security configuration
|
|
79
|
+
*/
|
|
80
|
+
private sanitizeHealthResponse;
|
|
81
|
+
/**
|
|
82
|
+
* Sanitize error messages to prevent information leakage
|
|
83
|
+
*/
|
|
84
|
+
private sanitizeErrorMessage;
|
|
85
|
+
/**
|
|
86
|
+
* Get system health metrics
|
|
87
|
+
*/
|
|
88
|
+
private getSystemHealth;
|
|
89
|
+
/**
|
|
90
|
+
* Get MCP server health status
|
|
91
|
+
*/
|
|
92
|
+
private getServerHealth;
|
|
93
|
+
/**
|
|
94
|
+
* Get configuration health status
|
|
95
|
+
*/
|
|
96
|
+
private getConfigurationHealth;
|
|
97
|
+
/**
|
|
98
|
+
* Determine overall health status based on component status
|
|
99
|
+
*/
|
|
100
|
+
private determineOverallHealth;
|
|
101
|
+
/**
|
|
102
|
+
* Get HTTP status code based on health status
|
|
103
|
+
*/
|
|
104
|
+
getHttpStatusCode(healthStatus: HealthStatus): number;
|
|
105
|
+
}
|
|
106
|
+
export default HealthService;
|
|
107
|
+
//# sourceMappingURL=healthService.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"healthService.d.ts","sourceRoot":"","sources":["../../src/services/healthService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAOtD;;GAEG;AACH,oBAAY,YAAY;IACtB,OAAO,YAAY;IACnB,QAAQ,aAAa;IACrB,SAAS,cAAc;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,YAAY,CAAC;IACrB,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,CAAC,EAAE,IAAI,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC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