@wuyax/mcps 0.1.0-beta.3 → 0.1.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/LICENSE +21 -0
- package/README.md +22 -14
- package/dist/chunk-AWD3VQ3S.js +1624 -0
- package/dist/chunk-O3BRJFEC.js +1898 -0
- package/dist/cli.cjs +1057 -979
- package/dist/cli.js +188 -17
- package/dist/index.cjs +702 -2478
- package/dist/index.d.cts +152 -452
- package/dist/index.d.ts +152 -452
- package/dist/index.js +9 -85
- package/dist/{chunk-BUKA3NPJ.js → interactive.cjs} +1555 -1779
- package/dist/interactive.d.cts +228 -0
- package/dist/interactive.d.ts +228 -0
- package/dist/interactive.js +53 -0
- package/dist/types-lEP3zGvf.d.cts +128 -0
- package/dist/types-lEP3zGvf.d.ts +128 -0
- package/package.json +31 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 wuyax
|
|
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
|
@@ -653,7 +653,7 @@ import {
|
|
|
653
653
|
resolveConfigClusters,
|
|
654
654
|
getCoHostedAgents,
|
|
655
655
|
getCandidateAgentsForScope,
|
|
656
|
-
|
|
656
|
+
sortAgentsByClusters,
|
|
657
657
|
installToCompatibleAgents,
|
|
658
658
|
} from "@wuyax/mcps";
|
|
659
659
|
|
|
@@ -673,7 +673,7 @@ for (const cluster of clusters) {
|
|
|
673
673
|
}
|
|
674
674
|
|
|
675
675
|
// 3. Sort agents so cluster peers appear adjacent in lists
|
|
676
|
-
const sorted =
|
|
676
|
+
const sorted = sortAgentsByClusters(["github-copilot-cli", "cursor", "claude-code"]);
|
|
677
677
|
// ['github-copilot-cli', 'claude-code', 'cursor']
|
|
678
678
|
|
|
679
679
|
// 4. Batch-install to compatible agents with cluster deduplication
|
|
@@ -688,7 +688,25 @@ const results = installToCompatibleAgents("my-server", serverConfig, {
|
|
|
688
688
|
|
|
689
689
|
### Exported Utilities & Interactive Prompts
|
|
690
690
|
|
|
691
|
-
|
|
691
|
+
`mcps` provides two dedicated export surfaces:
|
|
692
|
+
1. **Headless Programmatic SDK (`@wuyax/mcps`)**: Clean, dependency-light API for servers, clusters, protocols, and security masking.
|
|
693
|
+
2. **Interactive UI Wizards & Prompts (`@wuyax/mcps/interactive`)**: Terminal UI wizards and Inquirer prompts for custom CLI integrations.
|
|
694
|
+
|
|
695
|
+
#### Headless Utilities (`@wuyax/mcps`)
|
|
696
|
+
|
|
697
|
+
```typescript
|
|
698
|
+
import {
|
|
699
|
+
parseServerConfig,
|
|
700
|
+
buildMcpServerConfig,
|
|
701
|
+
applyServerConfigDelta,
|
|
702
|
+
detectUpdateTransition,
|
|
703
|
+
sanitizeUpdatedServerConfig,
|
|
704
|
+
maskSecretValue,
|
|
705
|
+
maskSecretHeader,
|
|
706
|
+
} from "@wuyax/mcps";
|
|
707
|
+
```
|
|
708
|
+
|
|
709
|
+
#### Interactive Terminal UI & Wizards (`@wuyax/mcps/interactive`)
|
|
692
710
|
|
|
693
711
|
```typescript
|
|
694
712
|
import {
|
|
@@ -698,16 +716,6 @@ import {
|
|
|
698
716
|
wizardRemove,
|
|
699
717
|
linkedCheckbox,
|
|
700
718
|
buildLinkedAgentChoices,
|
|
701
|
-
groupInstalledServersByName,
|
|
702
|
-
normalizeServerConfig,
|
|
703
|
-
formatCoHostedBadge,
|
|
704
|
-
logCoHostedNotice,
|
|
705
|
-
displayServerDetails,
|
|
706
|
-
resolveTransport,
|
|
707
|
-
maskSecretValue,
|
|
708
|
-
maskSecretHeader,
|
|
709
|
-
sanitizeUpdatedServerConfig,
|
|
710
|
-
detectUpdateTransition,
|
|
711
719
|
promptSwitchServerType,
|
|
712
720
|
promptScopeAndAgents,
|
|
713
721
|
promptEnvConfig,
|
|
@@ -715,7 +723,7 @@ import {
|
|
|
715
723
|
promptArgsConfig,
|
|
716
724
|
parseEnvText,
|
|
717
725
|
parseHeadersText,
|
|
718
|
-
} from "@wuyax/mcps";
|
|
726
|
+
} from "@wuyax/mcps/interactive";
|
|
719
727
|
```
|
|
720
728
|
|
|
721
729
|
---
|