@executor-js/plugin-mcp 0.0.2 → 0.2.1

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.
Files changed (47) hide show
  1. package/dist/AddMcpSource-VM3HY26S.js +762 -0
  2. package/dist/AddMcpSource-VM3HY26S.js.map +1 -0
  3. package/dist/EditMcpSource-WELWGRJG.js +259 -0
  4. package/dist/EditMcpSource-WELWGRJG.js.map +1 -0
  5. package/dist/McpSourceSummary-7TDQXLT5.js +85 -0
  6. package/dist/McpSourceSummary-7TDQXLT5.js.map +1 -0
  7. package/dist/api/group.d.ts +115 -23
  8. package/dist/api/index.d.ts +391 -0
  9. package/dist/chunk-2ETJ6LQH.js +239 -0
  10. package/dist/chunk-2ETJ6LQH.js.map +1 -0
  11. package/dist/chunk-OOOH3IO4.js +2194 -0
  12. package/dist/chunk-OOOH3IO4.js.map +1 -0
  13. package/dist/chunk-SKSXXFOA.js +104 -0
  14. package/dist/chunk-SKSXXFOA.js.map +1 -0
  15. package/dist/chunk-Z4CRPOLI.js +186 -0
  16. package/dist/chunk-Z4CRPOLI.js.map +1 -0
  17. package/dist/chunk-ZIRGIRGP.js +115 -0
  18. package/dist/chunk-ZIRGIRGP.js.map +1 -0
  19. package/dist/client.js +51 -0
  20. package/dist/client.js.map +1 -0
  21. package/dist/core.js +26 -2
  22. package/dist/index.js +2 -1
  23. package/dist/react/McpRemoteSourceFields.d.ts +18 -0
  24. package/dist/react/McpSourceSummary.d.ts +5 -0
  25. package/dist/react/atoms.d.ts +211 -11
  26. package/dist/react/client.d.ts +114 -350
  27. package/dist/react/index.d.ts +1 -1
  28. package/dist/react/plugin-client.d.ts +9 -0
  29. package/dist/react/source-plugin.d.ts +1 -1
  30. package/dist/sdk/binding-store.d.ts +110 -1
  31. package/dist/sdk/index.d.ts +1 -1
  32. package/dist/sdk/invoke.d.ts +2 -0
  33. package/dist/sdk/manifest.d.ts +2 -0
  34. package/dist/sdk/plugin.d.ts +168 -10
  35. package/dist/sdk/probe-shape-real-servers.live.test.d.ts +1 -0
  36. package/dist/sdk/probe-shape.d.ts +17 -3
  37. package/dist/sdk/stored-source.d.ts +9 -6
  38. package/dist/sdk/types.d.ts +153 -13
  39. package/dist/{stdio-connector-KNHLETKM.js → stdio-connector-AA5S6UUJ.js} +1 -1
  40. package/dist/{stdio-connector-KNHLETKM.js.map → stdio-connector-AA5S6UUJ.js.map} +1 -1
  41. package/dist/testing/index.d.ts +1 -0
  42. package/dist/testing/server.d.ts +10 -0
  43. package/dist/testing.js +51 -0
  44. package/dist/testing.js.map +1 -0
  45. package/package.json +17 -4
  46. package/dist/chunk-DJANY5EU.js +0 -1325
  47. package/dist/chunk-DJANY5EU.js.map +0 -1
@@ -1,6 +1,9 @@
1
1
  import type { ScopeId } from "@executor-js/sdk/core";
2
- export declare const mcpSourceAtom: (scopeId: ScopeId, namespace: string) => import("effect/unstable/reactivity/Atom").Atom<import("effect/unstable/reactivity/AsyncResult").AsyncResult<import("../sdk/stored-source").McpStoredSourceSchema | null, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>>;
3
- export declare const probeMcpEndpoint: import("effect/unstable/reactivity/Atom").AtomResultFn<{
2
+ import * as Atom from "effect/unstable/reactivity/Atom";
3
+ import * as AsyncResult from "effect/unstable/reactivity/AsyncResult";
4
+ export declare const mcpSourceAtom: (scopeId: ScopeId, namespace: string) => Atom.Atom<AsyncResult.AsyncResult<import("../sdk/stored-source").McpStoredSourceSchema | null, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>>;
5
+ export declare const mcpSourceBindingsAtom: (scopeId: ScopeId, namespace: string, sourceScopeId: ScopeId) => Atom.Atom<AsyncResult.AsyncResult<readonly import("../sdk").McpSourceBindingRef[], import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>>;
6
+ export declare const probeMcpEndpoint: Atom.AtomResultFn<{
4
7
  readonly params: {
5
8
  readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
6
9
  };
@@ -28,20 +31,31 @@ export declare const probeMcpEndpoint: import("effect/unstable/reactivity/Atom")
28
31
  readonly serverName: string | null;
29
32
  readonly connected: boolean;
30
33
  readonly requiresOAuth: boolean;
31
- }, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>;
32
- export declare const addMcpSource: import("effect/unstable/reactivity/Atom").AtomResultFn<{
34
+ readonly supportsDynamicRegistration: boolean;
35
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
36
+ export declare const addMcpSource: Atom.AtomResultFn<{
33
37
  readonly params: {
34
38
  readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
35
39
  };
36
40
  readonly payload: {
37
41
  readonly name: string;
38
42
  readonly endpoint: string;
43
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
39
44
  readonly transport: "remote";
40
45
  readonly namespace?: string | undefined;
41
46
  readonly headers?: {
42
47
  readonly [x: string]: string | {
43
48
  readonly secretId: string;
44
49
  readonly prefix?: string | undefined;
50
+ } | {
51
+ readonly kind: "binding";
52
+ readonly slot: string;
53
+ readonly prefix?: string | undefined;
54
+ } | {
55
+ readonly secretId: string;
56
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
57
+ readonly prefix?: string | undefined;
58
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
45
59
  };
46
60
  } | undefined;
47
61
  readonly remoteTransport?: "streamable-http" | "sse" | "auto" | undefined;
@@ -49,21 +63,43 @@ export declare const addMcpSource: import("effect/unstable/reactivity/Atom").Ato
49
63
  readonly [x: string]: string | {
50
64
  readonly secretId: string;
51
65
  readonly prefix?: string | undefined;
66
+ } | {
67
+ readonly kind: "binding";
68
+ readonly slot: string;
69
+ readonly prefix?: string | undefined;
70
+ } | {
71
+ readonly secretId: string;
72
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
73
+ readonly prefix?: string | undefined;
74
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
52
75
  };
53
76
  } | undefined;
54
77
  readonly auth?: {
55
78
  readonly kind: "none";
79
+ } | {
80
+ readonly kind: "header";
81
+ readonly headerName: string;
82
+ readonly secretSlot: string;
83
+ readonly prefix?: string | undefined;
84
+ } | {
85
+ readonly kind: "oauth2";
86
+ readonly connectionSlot: string;
87
+ readonly clientIdSlot?: string | undefined;
88
+ readonly clientSecretSlot?: string | undefined;
56
89
  } | {
57
90
  readonly secretId: string;
58
91
  readonly kind: "header";
59
92
  readonly headerName: string;
93
+ readonly targetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
60
94
  readonly prefix?: string | undefined;
95
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
61
96
  } | {
62
97
  readonly connectionId: string;
63
98
  readonly kind: "oauth2";
64
99
  readonly clientSecretSecretId?: string | null | undefined;
65
100
  readonly clientIdSecretId?: string | undefined;
66
101
  } | undefined;
102
+ readonly credentialTargetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
67
103
  };
68
104
  readonly responseMode?: "decoded-only" | undefined;
69
105
  readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
@@ -73,6 +109,7 @@ export declare const addMcpSource: import("effect/unstable/reactivity/Atom").Ato
73
109
  };
74
110
  readonly payload: {
75
111
  readonly name: string;
112
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
76
113
  readonly transport: "stdio";
77
114
  readonly command: string;
78
115
  readonly namespace?: string | undefined;
@@ -87,8 +124,100 @@ export declare const addMcpSource: import("effect/unstable/reactivity/Atom").Ato
87
124
  }, {
88
125
  readonly namespace: string;
89
126
  readonly toolCount: number;
90
- }, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>;
91
- export declare const removeMcpSource: import("effect/unstable/reactivity/Atom").AtomResultFn<{
127
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
128
+ export declare const addMcpSourceOptimistic: (arg: string & import("effect/Brand").Brand<"ScopeId">) => Atom.AtomResultFn<{
129
+ readonly params: {
130
+ readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
131
+ };
132
+ readonly payload: {
133
+ readonly name: string;
134
+ readonly endpoint: string;
135
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
136
+ readonly transport: "remote";
137
+ readonly namespace?: string | undefined;
138
+ readonly headers?: {
139
+ readonly [x: string]: string | {
140
+ readonly secretId: string;
141
+ readonly prefix?: string | undefined;
142
+ } | {
143
+ readonly kind: "binding";
144
+ readonly slot: string;
145
+ readonly prefix?: string | undefined;
146
+ } | {
147
+ readonly secretId: string;
148
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
149
+ readonly prefix?: string | undefined;
150
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
151
+ };
152
+ } | undefined;
153
+ readonly remoteTransport?: "streamable-http" | "sse" | "auto" | undefined;
154
+ readonly queryParams?: {
155
+ readonly [x: string]: string | {
156
+ readonly secretId: string;
157
+ readonly prefix?: string | undefined;
158
+ } | {
159
+ readonly kind: "binding";
160
+ readonly slot: string;
161
+ readonly prefix?: string | undefined;
162
+ } | {
163
+ readonly secretId: string;
164
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
165
+ readonly prefix?: string | undefined;
166
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
167
+ };
168
+ } | undefined;
169
+ readonly auth?: {
170
+ readonly kind: "none";
171
+ } | {
172
+ readonly kind: "header";
173
+ readonly headerName: string;
174
+ readonly secretSlot: string;
175
+ readonly prefix?: string | undefined;
176
+ } | {
177
+ readonly kind: "oauth2";
178
+ readonly connectionSlot: string;
179
+ readonly clientIdSlot?: string | undefined;
180
+ readonly clientSecretSlot?: string | undefined;
181
+ } | {
182
+ readonly secretId: string;
183
+ readonly kind: "header";
184
+ readonly headerName: string;
185
+ readonly targetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
186
+ readonly prefix?: string | undefined;
187
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
188
+ } | {
189
+ readonly connectionId: string;
190
+ readonly kind: "oauth2";
191
+ readonly clientSecretSecretId?: string | null | undefined;
192
+ readonly clientIdSecretId?: string | undefined;
193
+ } | undefined;
194
+ readonly credentialTargetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
195
+ };
196
+ readonly responseMode?: "decoded-only" | undefined;
197
+ readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
198
+ } | {
199
+ readonly params: {
200
+ readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
201
+ };
202
+ readonly payload: {
203
+ readonly name: string;
204
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
205
+ readonly transport: "stdio";
206
+ readonly command: string;
207
+ readonly namespace?: string | undefined;
208
+ readonly args?: readonly string[] | undefined;
209
+ readonly env?: {
210
+ readonly [x: string]: string;
211
+ } | undefined;
212
+ readonly cwd?: string | undefined;
213
+ };
214
+ readonly responseMode?: "decoded-only" | undefined;
215
+ readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
216
+ }, {
217
+ readonly namespace: string;
218
+ readonly toolCount: number;
219
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
220
+ export declare const removeMcpSource: Atom.AtomResultFn<{
92
221
  readonly params: {
93
222
  readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
94
223
  };
@@ -99,8 +228,8 @@ export declare const removeMcpSource: import("effect/unstable/reactivity/Atom").
99
228
  readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
100
229
  }, {
101
230
  readonly removed: boolean;
102
- }, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>;
103
- export declare const refreshMcpSource: import("effect/unstable/reactivity/Atom").AtomResultFn<{
231
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
232
+ export declare const refreshMcpSource: Atom.AtomResultFn<{
104
233
  readonly params: {
105
234
  readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
106
235
  };
@@ -111,43 +240,114 @@ export declare const refreshMcpSource: import("effect/unstable/reactivity/Atom")
111
240
  readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
112
241
  }, {
113
242
  readonly toolCount: number;
114
- }, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>;
115
- export declare const updateMcpSource: import("effect/unstable/reactivity/Atom").AtomResultFn<{
243
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
244
+ export declare const updateMcpSource: Atom.AtomResultFn<{
116
245
  readonly params: {
117
246
  readonly namespace: string;
118
247
  readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
119
248
  };
120
249
  readonly payload: {
250
+ readonly sourceScope: string & import("effect/Brand").Brand<"ScopeId">;
121
251
  readonly name?: string | undefined;
122
252
  readonly endpoint?: string | undefined;
123
253
  readonly headers?: {
124
254
  readonly [x: string]: string | {
125
255
  readonly secretId: string;
126
256
  readonly prefix?: string | undefined;
257
+ } | {
258
+ readonly kind: "binding";
259
+ readonly slot: string;
260
+ readonly prefix?: string | undefined;
261
+ } | {
262
+ readonly secretId: string;
263
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
264
+ readonly prefix?: string | undefined;
265
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
127
266
  };
128
267
  } | undefined;
129
268
  readonly queryParams?: {
130
269
  readonly [x: string]: string | {
131
270
  readonly secretId: string;
132
271
  readonly prefix?: string | undefined;
272
+ } | {
273
+ readonly kind: "binding";
274
+ readonly slot: string;
275
+ readonly prefix?: string | undefined;
276
+ } | {
277
+ readonly secretId: string;
278
+ readonly targetScope: string & import("effect/Brand").Brand<"ScopeId">;
279
+ readonly prefix?: string | undefined;
280
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
133
281
  };
134
282
  } | undefined;
135
283
  readonly auth?: {
136
284
  readonly kind: "none";
285
+ } | {
286
+ readonly kind: "header";
287
+ readonly headerName: string;
288
+ readonly secretSlot: string;
289
+ readonly prefix?: string | undefined;
290
+ } | {
291
+ readonly kind: "oauth2";
292
+ readonly connectionSlot: string;
293
+ readonly clientIdSlot?: string | undefined;
294
+ readonly clientSecretSlot?: string | undefined;
137
295
  } | {
138
296
  readonly secretId: string;
139
297
  readonly kind: "header";
140
298
  readonly headerName: string;
299
+ readonly targetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
141
300
  readonly prefix?: string | undefined;
301
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
142
302
  } | {
143
303
  readonly connectionId: string;
144
304
  readonly kind: "oauth2";
145
305
  readonly clientSecretSecretId?: string | null | undefined;
146
306
  readonly clientIdSecretId?: string | undefined;
147
307
  } | undefined;
308
+ readonly credentialTargetScope?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
148
309
  };
149
310
  readonly responseMode?: "decoded-only" | undefined;
150
311
  readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
151
312
  }, {
152
313
  readonly updated: boolean;
153
- }, import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError | import("@executor-js/api").InternalError>;
314
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
315
+ export declare const setMcpSourceBinding: Atom.AtomResultFn<{
316
+ readonly params: {
317
+ readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
318
+ };
319
+ readonly payload: {
320
+ readonly value: {
321
+ readonly text: string;
322
+ readonly kind: "text";
323
+ } | {
324
+ readonly secretId: string & import("effect/Brand").Brand<"SecretId">;
325
+ readonly kind: "secret";
326
+ readonly secretScopeId?: (string & import("effect/Brand").Brand<"ScopeId">) | undefined;
327
+ } | {
328
+ readonly connectionId: string & import("effect/Brand").Brand<"ConnectionId">;
329
+ readonly kind: "connection";
330
+ };
331
+ readonly sourceId: string;
332
+ readonly scope: string & import("effect/Brand").Brand<"ScopeId">;
333
+ readonly slot: string;
334
+ readonly sourceScope: string & import("effect/Brand").Brand<"ScopeId">;
335
+ };
336
+ readonly responseMode?: "decoded-only" | undefined;
337
+ readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
338
+ }, import("../sdk").McpSourceBindingRef, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;
339
+ export declare const removeMcpSourceBinding: Atom.AtomResultFn<{
340
+ readonly params: {
341
+ readonly scopeId: string & import("effect/Brand").Brand<"ScopeId">;
342
+ };
343
+ readonly payload: {
344
+ readonly sourceId: string;
345
+ readonly scope: string & import("effect/Brand").Brand<"ScopeId">;
346
+ readonly slot: string;
347
+ readonly sourceScope: string & import("effect/Brand").Brand<"ScopeId">;
348
+ };
349
+ readonly responseMode?: "decoded-only" | undefined;
350
+ readonly reactivityKeys?: readonly unknown[] | import("effect/Record").ReadonlyRecord<string, readonly unknown[]> | undefined;
351
+ }, {
352
+ readonly removed: boolean;
353
+ }, import("@executor-js/api").InternalError | import("../sdk/errors").McpConnectionError | import("../sdk/errors").McpToolDiscoveryError>;