apps 0.0.1-beta.21 → 0.0.1-beta.22
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/framework-reference.json +1 -1
- package/js/{chunk-VXWY44LE.js → chunk-2KZ7GG43.js} +3 -3
- package/js/{chunk-CHAK4P5C.js → chunk-3HH4OZR3.js} +5 -5
- package/js/{chunk-4QQ62BVS.js → chunk-66JAEDTE.js} +5 -2
- package/js/{chunk-XNCYIB4D.js → chunk-A5BSZKFF.js} +3 -3
- package/js/{chunk-OZ4UK3CD.js → chunk-AK54RD3A.js} +1 -1
- package/js/{chunk-BLI53LPN.js → chunk-B3T7CZOH.js} +64 -17
- package/js/{chunk-RAAPJMVZ.js → chunk-JWNSH5CA.js} +4 -3
- package/js/{chunk-CMRKLZZY.js → chunk-K2QATKIF.js} +2 -2
- package/js/{chunk-NMKHTJOQ.js → chunk-S47NFEWF.js} +2 -2
- package/js/{chunk-625MBYU4.js → chunk-WFEUCUFF.js} +4 -3
- package/js/client.js +1 -1
- package/js/contracts.js +1 -1
- package/js/effect.js +6 -6
- package/js/graphql.js +8 -8
- package/js/host.js +6 -6
- package/js/index.js +17 -11
- package/js/mcp/effect.js +8 -8
- package/js/mcp/stdio.js +8 -8
- package/js/mcp.js +38 -25
- package/js/openapi.js +5 -5
- package/js/skills.js +2 -2
- package/package.json +1 -1
- package/runtime.json +1 -1
- package/types/apps/src/contracts/mcp.d.ts +18 -7
- package/types/apps/src/contracts/operations.d.ts +5 -1
- package/types/apps/src/implementation/mcp-call.d.ts +3 -3
- package/types/apps/src/implementation/mcp-client.d.ts +3 -3
- package/types/apps/src/implementation/mcp.d.ts +3 -3
- package/types/apps/src/implementation/protocol-operations.d.ts +3 -0
- package/types/apps/src/implementation/schema.d.ts +8 -0
package/js/mcp.js
CHANGED
|
@@ -1,43 +1,45 @@
|
|
|
1
1
|
import {
|
|
2
2
|
mcpClientEffect
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-K2QATKIF.js";
|
|
4
4
|
import {
|
|
5
5
|
catalogCache,
|
|
6
6
|
catalogScope
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-AK54RD3A.js";
|
|
8
8
|
import {
|
|
9
9
|
adaptMcpTool
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-B3T7CZOH.js";
|
|
11
11
|
import {
|
|
12
12
|
protocolOperations
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-JWNSH5CA.js";
|
|
14
14
|
import "./chunk-BCSNKUAC.js";
|
|
15
|
-
import "./chunk-
|
|
15
|
+
import "./chunk-3HH4OZR3.js";
|
|
16
16
|
import {
|
|
17
17
|
cacheKey
|
|
18
18
|
} from "./chunk-NKLWZJLE.js";
|
|
19
|
-
import
|
|
19
|
+
import {
|
|
20
|
+
operationDescription
|
|
21
|
+
} from "./chunk-WFEUCUFF.js";
|
|
20
22
|
import "./chunk-IPI4MFSN.js";
|
|
21
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-A5BSZKFF.js";
|
|
22
24
|
import "./chunk-ZQINWV4W.js";
|
|
23
25
|
import {
|
|
24
26
|
nativeOperation,
|
|
25
27
|
routerDeclaration
|
|
26
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-S47NFEWF.js";
|
|
27
29
|
import "./chunk-MKWZPDR6.js";
|
|
28
30
|
import {
|
|
29
31
|
McpError,
|
|
30
32
|
McpServerHeader,
|
|
31
33
|
McpToolMetadata,
|
|
32
34
|
McpToolsOptions
|
|
33
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-2KZ7GG43.js";
|
|
34
36
|
import "./chunk-N7YDVXYJ.js";
|
|
35
37
|
import "./chunk-R3EV5FTO.js";
|
|
36
38
|
import "./chunk-JU7VHODU.js";
|
|
37
39
|
import "./chunk-ODEIDRGW.js";
|
|
38
40
|
import "./chunk-57RKNWL2.js";
|
|
39
41
|
import "./chunk-UK573G7W.js";
|
|
40
|
-
import "./chunk-
|
|
42
|
+
import "./chunk-66JAEDTE.js";
|
|
41
43
|
import "./chunk-PZB6T6KU.js";
|
|
42
44
|
import "./chunk-27F7W2LG.js";
|
|
43
45
|
import {
|
|
@@ -102,12 +104,18 @@ var mcpCatalog = (options, kinds) => Effect_exports.gen(function* () {
|
|
|
102
104
|
...tool.title === void 0 ? {} : { title: tool.title },
|
|
103
105
|
annotations: { ...tool.annotations, readOnlyHint: kindOf(tool) === "query" }
|
|
104
106
|
});
|
|
105
|
-
const
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
107
|
+
const operation = (tool) => adaptMcpTool(client, tool).pipe(
|
|
108
|
+
Effect_exports.map(
|
|
109
|
+
(adapted) => nativeOperation(
|
|
110
|
+
protocolOperations({ selected: adapted }, { selected: kindOf(tool) }).selected
|
|
111
|
+
)
|
|
112
|
+
)
|
|
113
|
+
);
|
|
114
|
+
const describe = (tool) => operation(tool).pipe(
|
|
115
|
+
Effect_exports.flatMap(
|
|
116
|
+
(selected) => selected === void 0 ? Effect_exports.succeed(void 0) : operationDescription(tool.name, "", selected)
|
|
117
|
+
)
|
|
118
|
+
);
|
|
111
119
|
const router = {
|
|
112
120
|
kind: "dynamic",
|
|
113
121
|
meta: () => catalog.header().pipe(
|
|
@@ -116,16 +124,21 @@ var mcpCatalog = (options, kinds) => Effect_exports.gen(function* () {
|
|
|
116
124
|
),
|
|
117
125
|
Effect_exports.map(serverMeta)
|
|
118
126
|
),
|
|
119
|
-
list: () => catalog.list().pipe(
|
|
127
|
+
list: () => catalog.list().pipe(
|
|
128
|
+
Effect_exports.flatMap((tools) => Effect_exports.forEach(tools, describe)),
|
|
129
|
+
Effect_exports.map((tools) => tools.filter((tool) => tool !== void 0))
|
|
130
|
+
),
|
|
120
131
|
summaries: () => catalog.summaries().pipe(Effect_exports.map((tools) => tools.map(summarize))),
|
|
121
|
-
describe: (name) => catalog.resolve(name).pipe(
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
132
|
+
describe: (name) => catalog.resolve(name).pipe(
|
|
133
|
+
Effect_exports.flatMap(
|
|
134
|
+
(tool) => tool === void 0 ? Effect_exports.succeed(void 0) : describe(tool)
|
|
135
|
+
)
|
|
136
|
+
),
|
|
137
|
+
resolve: (name) => catalog.resolve(name).pipe(
|
|
138
|
+
Effect_exports.flatMap(
|
|
139
|
+
(tool) => tool === void 0 ? Effect_exports.succeed(void 0) : operation(tool)
|
|
140
|
+
)
|
|
141
|
+
)
|
|
129
142
|
};
|
|
130
143
|
return routerDeclaration(router);
|
|
131
144
|
});
|
package/js/openapi.js
CHANGED
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
import {
|
|
9
9
|
protocolOperations,
|
|
10
10
|
protocolRouter
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-JWNSH5CA.js";
|
|
12
12
|
import {
|
|
13
13
|
OpenapiError,
|
|
14
14
|
OpenapiErrorResponse,
|
|
@@ -21,14 +21,14 @@ import {
|
|
|
21
21
|
isOpenapiTextMedia,
|
|
22
22
|
openapiBinaryResultSchema,
|
|
23
23
|
openapiMediaKind
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-WFEUCUFF.js";
|
|
25
25
|
import "./chunk-IPI4MFSN.js";
|
|
26
26
|
import {
|
|
27
27
|
fromPromise,
|
|
28
28
|
nativeOperation,
|
|
29
29
|
routerDeclaration,
|
|
30
30
|
toPromise
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-S47NFEWF.js";
|
|
32
32
|
import {
|
|
33
33
|
accountProviderError,
|
|
34
34
|
httpProviderError
|
|
@@ -39,7 +39,7 @@ import {
|
|
|
39
39
|
OpenapiResponseError,
|
|
40
40
|
RouterMeta,
|
|
41
41
|
defaultOpenapiErrorLimits
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-2KZ7GG43.js";
|
|
43
43
|
import "./chunk-N7YDVXYJ.js";
|
|
44
44
|
import {
|
|
45
45
|
ProviderError,
|
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
lazyJsonSchemaDecoder,
|
|
59
59
|
once,
|
|
60
60
|
wrap
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-66JAEDTE.js";
|
|
62
62
|
import "./chunk-PZB6T6KU.js";
|
|
63
63
|
import {
|
|
64
64
|
JsonObject
|
package/js/skills.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
catalogCache
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-AK54RD3A.js";
|
|
4
4
|
import "./chunk-NKLWZJLE.js";
|
|
5
5
|
import {
|
|
6
6
|
folderSkillsEffect,
|
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
} from "./chunk-UK573G7W.js";
|
|
30
30
|
import {
|
|
31
31
|
wrap
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-66JAEDTE.js";
|
|
33
33
|
import "./chunk-27F7W2LG.js";
|
|
34
34
|
import {
|
|
35
35
|
Effect_exports,
|