@decocms/runtime 0.24.0 → 0.25.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.
Files changed (67) hide show
  1. package/dist/bindings/deconfig/index.d.ts +3 -3
  2. package/dist/bindings/deconfig/index.js +5 -5
  3. package/dist/bindings/index.d.ts +41 -41
  4. package/dist/bindings/index.js +6 -6
  5. package/dist/{chunk-4UQ5U73Y.js → chunk-F6XZPFWM.js} +3 -5
  6. package/dist/chunk-F6XZPFWM.js.map +1 -0
  7. package/dist/{chunk-ZRJ5SGAO.js → chunk-I2KGAHFY.js} +26 -6
  8. package/dist/chunk-I2KGAHFY.js.map +1 -0
  9. package/dist/{chunk-73FIKR3X.js → chunk-NKUMVYKI.js} +3 -3
  10. package/dist/chunk-NKUMVYKI.js.map +1 -0
  11. package/dist/{chunk-377XXI4J.js → chunk-O6IURJAY.js} +4 -4
  12. package/dist/{chunk-377XXI4J.js.map → chunk-O6IURJAY.js.map} +1 -1
  13. package/dist/{chunk-G3NWZG2F.js → chunk-QELHWEZH.js} +3 -3
  14. package/dist/chunk-QELHWEZH.js.map +1 -0
  15. package/dist/drizzle.d.ts +2 -2
  16. package/dist/{index-D_J_044C.d.ts → index-CStCyFvK.d.ts} +12 -3
  17. package/dist/{index-BBAR4TQu.d.ts → index-DswRTp9B.d.ts} +8 -8
  18. package/dist/index.d.ts +2 -2
  19. package/dist/index.js +6 -6
  20. package/dist/mastra.d.ts +2 -2
  21. package/dist/mastra.js +2 -2
  22. package/dist/mcp-client.js +1 -1
  23. package/dist/{mcp-Bv7IAgWX.d.ts → mcp-yTBduksO.d.ts} +4 -4
  24. package/dist/proxy.d.ts +1 -1
  25. package/dist/proxy.js +2 -2
  26. package/dist/resources.d.ts +44 -75
  27. package/dist/resources.js +1 -1
  28. package/dist/views.d.ts +12 -12
  29. package/package.json +14 -1
  30. package/src/admin.ts +16 -0
  31. package/src/auth.ts +233 -0
  32. package/src/bindings/README.md +132 -0
  33. package/src/bindings/binder.ts +143 -0
  34. package/src/bindings/channels.ts +54 -0
  35. package/src/bindings/deconfig/helpers.ts +107 -0
  36. package/src/bindings/deconfig/index.ts +1 -0
  37. package/src/bindings/deconfig/resources.ts +659 -0
  38. package/src/bindings/deconfig/types.ts +106 -0
  39. package/src/bindings/index.ts +61 -0
  40. package/src/bindings/resources/bindings.ts +99 -0
  41. package/src/bindings/resources/helpers.ts +95 -0
  42. package/src/bindings/resources/schemas.ts +265 -0
  43. package/src/bindings/utils.ts +22 -0
  44. package/src/bindings/views.ts +14 -0
  45. package/src/bindings.ts +178 -0
  46. package/src/cf-imports.ts +1 -0
  47. package/src/client.ts +201 -0
  48. package/src/connection.ts +53 -0
  49. package/src/d1-store.ts +34 -0
  50. package/src/deprecated.ts +59 -0
  51. package/src/drizzle.ts +201 -0
  52. package/src/http-client-transport.ts +66 -0
  53. package/src/index.ts +405 -0
  54. package/src/mastra.ts +894 -0
  55. package/src/mcp-client.ts +119 -0
  56. package/src/mcp.ts +170 -0
  57. package/src/proxy.ts +212 -0
  58. package/src/resources.ts +168 -0
  59. package/src/state.ts +44 -0
  60. package/src/views.ts +26 -0
  61. package/src/well-known.ts +20 -0
  62. package/src/workflow.ts +193 -0
  63. package/src/wrangler.ts +146 -0
  64. package/dist/chunk-4UQ5U73Y.js.map +0 -1
  65. package/dist/chunk-73FIKR3X.js.map +0 -1
  66. package/dist/chunk-G3NWZG2F.js.map +0 -1
  67. package/dist/chunk-ZRJ5SGAO.js.map +0 -1
@@ -27,7 +27,7 @@ declare const QueryResult: z.ZodObject<{
27
27
  rows_read?: number | undefined;
28
28
  rows_written?: number | undefined;
29
29
  served_by_primary?: boolean | undefined;
30
- served_by_region?: "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | "OC" | undefined;
30
+ served_by_region?: "OC" | "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | undefined;
31
31
  size_after?: number | undefined;
32
32
  timings?: {
33
33
  sql_duration_ms?: number | undefined;
@@ -40,7 +40,7 @@ declare const QueryResult: z.ZodObject<{
40
40
  rows_read?: number | undefined;
41
41
  rows_written?: number | undefined;
42
42
  served_by_primary?: boolean | undefined;
43
- served_by_region?: "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | "OC" | undefined;
43
+ served_by_region?: "OC" | "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | undefined;
44
44
  size_after?: number | undefined;
45
45
  timings?: {
46
46
  sql_duration_ms?: number | undefined;
@@ -57,7 +57,7 @@ declare const QueryResult: z.ZodObject<{
57
57
  rows_read?: number | undefined;
58
58
  rows_written?: number | undefined;
59
59
  served_by_primary?: boolean | undefined;
60
- served_by_region?: "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | "OC" | undefined;
60
+ served_by_region?: "OC" | "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | undefined;
61
61
  size_after?: number | undefined;
62
62
  timings?: {
63
63
  sql_duration_ms?: number | undefined;
@@ -74,7 +74,7 @@ declare const QueryResult: z.ZodObject<{
74
74
  rows_read?: number | undefined;
75
75
  rows_written?: number | undefined;
76
76
  served_by_primary?: boolean | undefined;
77
- served_by_region?: "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | "OC" | undefined;
77
+ served_by_region?: "OC" | "WNAM" | "ENAM" | "WEUR" | "EEUR" | "APAC" | undefined;
78
78
  size_after?: number | undefined;
79
79
  timings?: {
80
80
  sql_duration_ms?: number | undefined;
package/dist/proxy.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { C as CreateStubAPIOptions } from './mcp-Bv7IAgWX.js';
1
+ import { C as CreateStubAPIOptions } from './mcp-yTBduksO.js';
2
2
  import 'zod';
3
3
  import './connection-DDtQYrea.js';
4
4
 
package/dist/proxy.js CHANGED
@@ -1,5 +1,5 @@
1
- export { createMCPClientProxy } from './chunk-G3NWZG2F.js';
2
- import './chunk-4UQ5U73Y.js';
1
+ export { createMCPClientProxy } from './chunk-QELHWEZH.js';
2
+ import './chunk-F6XZPFWM.js';
3
3
  import './chunk-I7BWSAN6.js';
4
4
  //# sourceMappingURL=proxy.js.map
5
5
  //# sourceMappingURL=proxy.js.map
@@ -1,45 +1,14 @@
1
1
  import { z } from 'zod';
2
2
 
3
- declare const ResourceSchema: z.ZodObject<{
4
- name: z.ZodString;
5
- title: z.ZodOptional<z.ZodString>;
6
- description: z.ZodOptional<z.ZodString>;
7
- uri: z.ZodString;
8
- mimeType: z.ZodOptional<z.ZodString>;
9
- thumbnail: z.ZodOptional<z.ZodString>;
10
- timestamp: z.ZodOptional<z.ZodString>;
11
- size: z.ZodOptional<z.ZodNumber>;
12
- annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
13
- }, "strip", z.ZodTypeAny, {
14
- name: string;
15
- uri: string;
16
- description?: string | undefined;
17
- mimeType?: string | undefined;
18
- title?: string | undefined;
19
- annotations?: Record<string, string> | undefined;
20
- thumbnail?: string | undefined;
21
- timestamp?: string | undefined;
22
- size?: number | undefined;
23
- }, {
24
- name: string;
25
- uri: string;
26
- description?: string | undefined;
27
- mimeType?: string | undefined;
28
- title?: string | undefined;
29
- annotations?: Record<string, string> | undefined;
30
- thumbnail?: string | undefined;
31
- timestamp?: string | undefined;
32
- size?: number | undefined;
33
- }>;
34
3
  declare const ResourcesReadInputSchema: z.ZodObject<{
35
4
  name: z.ZodString;
36
5
  uri: z.ZodString;
37
6
  }, "strip", z.ZodTypeAny, {
38
- name: string;
39
7
  uri: string;
40
- }, {
41
8
  name: string;
9
+ }, {
42
10
  uri: string;
11
+ name: string;
43
12
  }>;
44
13
  declare const ResourcesReadOutputSchema: z.ZodObject<{
45
14
  name: z.ZodString;
@@ -56,24 +25,24 @@ declare const ResourcesReadOutputSchema: z.ZodObject<{
56
25
  type: z.ZodEnum<["text", "blob"]>;
57
26
  }, "strip", z.ZodTypeAny, {
58
27
  type: "text" | "blob";
59
- name: string;
60
28
  data: string;
61
29
  uri: string;
62
- description?: string | undefined;
30
+ name: string;
63
31
  mimeType?: string | undefined;
64
32
  title?: string | undefined;
33
+ description?: string | undefined;
65
34
  annotations?: Record<string, string> | undefined;
66
35
  thumbnail?: string | undefined;
67
36
  timestamp?: string | undefined;
68
37
  size?: number | undefined;
69
38
  }, {
70
39
  type: "text" | "blob";
71
- name: string;
72
40
  data: string;
73
41
  uri: string;
74
- description?: string | undefined;
42
+ name: string;
75
43
  mimeType?: string | undefined;
76
44
  title?: string | undefined;
45
+ description?: string | undefined;
77
46
  annotations?: Record<string, string> | undefined;
78
47
  thumbnail?: string | undefined;
79
48
  timestamp?: string | undefined;
@@ -107,21 +76,21 @@ declare const ResourceSearchOutputSchema: z.ZodObject<{
107
76
  size: z.ZodOptional<z.ZodNumber>;
108
77
  annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
109
78
  }, "strip", z.ZodTypeAny, {
110
- name: string;
111
79
  uri: string;
112
- description?: string | undefined;
80
+ name: string;
113
81
  mimeType?: string | undefined;
114
82
  title?: string | undefined;
83
+ description?: string | undefined;
115
84
  annotations?: Record<string, string> | undefined;
116
85
  thumbnail?: string | undefined;
117
86
  timestamp?: string | undefined;
118
87
  size?: number | undefined;
119
88
  }, {
120
- name: string;
121
89
  uri: string;
122
- description?: string | undefined;
90
+ name: string;
123
91
  mimeType?: string | undefined;
124
92
  title?: string | undefined;
93
+ description?: string | undefined;
125
94
  annotations?: Record<string, string> | undefined;
126
95
  thumbnail?: string | undefined;
127
96
  timestamp?: string | undefined;
@@ -131,11 +100,11 @@ declare const ResourceSearchOutputSchema: z.ZodObject<{
131
100
  nextCursor: z.ZodOptional<z.ZodString>;
132
101
  }, "strip", z.ZodTypeAny, {
133
102
  items: {
134
- name: string;
135
103
  uri: string;
136
- description?: string | undefined;
104
+ name: string;
137
105
  mimeType?: string | undefined;
138
106
  title?: string | undefined;
107
+ description?: string | undefined;
139
108
  annotations?: Record<string, string> | undefined;
140
109
  thumbnail?: string | undefined;
141
110
  timestamp?: string | undefined;
@@ -145,11 +114,11 @@ declare const ResourceSearchOutputSchema: z.ZodObject<{
145
114
  nextCursor?: string | undefined;
146
115
  }, {
147
116
  items: {
148
- name: string;
149
117
  uri: string;
150
- description?: string | undefined;
118
+ name: string;
151
119
  mimeType?: string | undefined;
152
120
  title?: string | undefined;
121
+ description?: string | undefined;
153
122
  annotations?: Record<string, string> | undefined;
154
123
  thumbnail?: string | undefined;
155
124
  timestamp?: string | undefined;
@@ -178,27 +147,27 @@ declare const ResourceCreateInputSchema: z.ZodObject<{
178
147
  }>;
179
148
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
180
149
  }, "strip", z.ZodTypeAny, {
181
- name: string;
182
- resourceName: string;
183
150
  content: {
184
151
  type: "text" | "blob";
185
152
  data: string;
186
153
  mimeType?: string | undefined;
187
154
  };
155
+ name: string;
156
+ resourceName: string;
157
+ title?: string | undefined;
188
158
  description?: string | undefined;
189
159
  metadata?: Record<string, any> | undefined;
190
- title?: string | undefined;
191
160
  }, {
192
- name: string;
193
- resourceName: string;
194
161
  content: {
195
162
  type: "text" | "blob";
196
163
  data: string;
197
164
  mimeType?: string | undefined;
198
165
  };
166
+ name: string;
167
+ resourceName: string;
168
+ title?: string | undefined;
199
169
  description?: string | undefined;
200
170
  metadata?: Record<string, any> | undefined;
201
- title?: string | undefined;
202
171
  }>;
203
172
  declare const ResourceCreateOutputSchema: z.ZodObject<{
204
173
  name: z.ZodString;
@@ -211,21 +180,21 @@ declare const ResourceCreateOutputSchema: z.ZodObject<{
211
180
  size: z.ZodOptional<z.ZodNumber>;
212
181
  annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
213
182
  }, "strip", z.ZodTypeAny, {
214
- name: string;
215
183
  uri: string;
216
- description?: string | undefined;
184
+ name: string;
217
185
  mimeType?: string | undefined;
218
186
  title?: string | undefined;
187
+ description?: string | undefined;
219
188
  annotations?: Record<string, string> | undefined;
220
189
  thumbnail?: string | undefined;
221
190
  timestamp?: string | undefined;
222
191
  size?: number | undefined;
223
192
  }, {
224
- name: string;
225
193
  uri: string;
226
- description?: string | undefined;
194
+ name: string;
227
195
  mimeType?: string | undefined;
228
196
  title?: string | undefined;
197
+ description?: string | undefined;
229
198
  annotations?: Record<string, string> | undefined;
230
199
  thumbnail?: string | undefined;
231
200
  timestamp?: string | undefined;
@@ -252,29 +221,29 @@ declare const ResourceUpdateInputSchema: z.ZodObject<{
252
221
  }>>;
253
222
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
254
223
  }, "strip", z.ZodTypeAny, {
255
- name: string;
256
224
  uri: string;
257
- description?: string | undefined;
258
- resourceName?: string | undefined;
259
- metadata?: Record<string, any> | undefined;
225
+ name: string;
260
226
  content?: {
261
227
  type: "text" | "blob";
262
228
  data: string;
263
229
  mimeType?: string | undefined;
264
230
  } | undefined;
265
231
  title?: string | undefined;
266
- }, {
267
- name: string;
268
- uri: string;
269
232
  description?: string | undefined;
270
- resourceName?: string | undefined;
271
233
  metadata?: Record<string, any> | undefined;
234
+ resourceName?: string | undefined;
235
+ }, {
236
+ uri: string;
237
+ name: string;
272
238
  content?: {
273
239
  type: "text" | "blob";
274
240
  data: string;
275
241
  mimeType?: string | undefined;
276
242
  } | undefined;
277
243
  title?: string | undefined;
244
+ description?: string | undefined;
245
+ metadata?: Record<string, any> | undefined;
246
+ resourceName?: string | undefined;
278
247
  }>;
279
248
  declare const ResourceUpdateOutputSchema: z.ZodObject<{
280
249
  name: z.ZodString;
@@ -287,21 +256,21 @@ declare const ResourceUpdateOutputSchema: z.ZodObject<{
287
256
  size: z.ZodOptional<z.ZodNumber>;
288
257
  annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
289
258
  }, "strip", z.ZodTypeAny, {
290
- name: string;
291
259
  uri: string;
292
- description?: string | undefined;
260
+ name: string;
293
261
  mimeType?: string | undefined;
294
262
  title?: string | undefined;
263
+ description?: string | undefined;
295
264
  annotations?: Record<string, string> | undefined;
296
265
  thumbnail?: string | undefined;
297
266
  timestamp?: string | undefined;
298
267
  size?: number | undefined;
299
268
  }, {
300
- name: string;
301
269
  uri: string;
302
- description?: string | undefined;
270
+ name: string;
303
271
  mimeType?: string | undefined;
304
272
  title?: string | undefined;
273
+ description?: string | undefined;
305
274
  annotations?: Record<string, string> | undefined;
306
275
  thumbnail?: string | undefined;
307
276
  timestamp?: string | undefined;
@@ -312,12 +281,12 @@ declare const ResourceDeleteInputSchema: z.ZodObject<{
312
281
  uri: z.ZodString;
313
282
  force: z.ZodOptional<z.ZodBoolean>;
314
283
  }, "strip", z.ZodTypeAny, {
315
- name: string;
316
284
  uri: string;
285
+ name: string;
317
286
  force?: boolean | undefined;
318
287
  }, {
319
- name: string;
320
288
  uri: string;
289
+ name: string;
321
290
  force?: boolean | undefined;
322
291
  }>;
323
292
  declare const ResourceDeleteOutputSchema: z.ZodObject<{
@@ -339,16 +308,16 @@ declare const ResourcesListOutputSchema: z.ZodObject<{
339
308
  hasDelete: z.ZodOptional<z.ZodBoolean>;
340
309
  }, "strip", z.ZodTypeAny, {
341
310
  name: string;
342
- description: string;
343
311
  title: string;
312
+ description: string;
344
313
  icon: string;
345
314
  hasCreate?: boolean | undefined;
346
315
  hasUpdate?: boolean | undefined;
347
316
  hasDelete?: boolean | undefined;
348
317
  }, {
349
318
  name: string;
350
- description: string;
351
319
  title: string;
320
+ description: string;
352
321
  icon: string;
353
322
  hasCreate?: boolean | undefined;
354
323
  hasUpdate?: boolean | undefined;
@@ -357,8 +326,8 @@ declare const ResourcesListOutputSchema: z.ZodObject<{
357
326
  }, "strip", z.ZodTypeAny, {
358
327
  resources: {
359
328
  name: string;
360
- description: string;
361
329
  title: string;
330
+ description: string;
362
331
  icon: string;
363
332
  hasCreate?: boolean | undefined;
364
333
  hasUpdate?: boolean | undefined;
@@ -367,15 +336,15 @@ declare const ResourcesListOutputSchema: z.ZodObject<{
367
336
  }, {
368
337
  resources: {
369
338
  name: string;
370
- description: string;
371
339
  title: string;
340
+ description: string;
372
341
  icon: string;
373
342
  hasCreate?: boolean | undefined;
374
343
  hasUpdate?: boolean | undefined;
375
344
  hasDelete?: boolean | undefined;
376
345
  }[];
377
346
  }>;
378
- type Resource = z.infer<typeof ResourceSchema>;
347
+ type Resource = z.infer<typeof ResourceCreateOutputSchema>;
379
348
  type ResourcesReadInput = z.infer<typeof ResourcesReadInputSchema>;
380
349
  type ResourcesReadOutput = z.infer<typeof ResourcesReadOutputSchema>;
381
350
  type ResourcesSearchInput = z.infer<typeof ResourceSearchInputSchema>;
@@ -390,4 +359,4 @@ type ResourcesListInput = z.infer<typeof ResourcesListInputSchema>;
390
359
  type ResourcesListOutput = z.infer<typeof ResourcesListOutputSchema>;
391
360
  declare const mimeType: (filePathOrExtension: string) => string;
392
361
 
393
- export { type Resource, type ResourceCreateInput, ResourceCreateInputSchema, type ResourceCreateOutput, ResourceCreateOutputSchema, type ResourceDeleteInput, ResourceDeleteInputSchema, type ResourceDeleteOutput, ResourceDeleteOutputSchema, ResourceSchema, ResourceSearchInputSchema, ResourceSearchOutputSchema, type ResourceUpdateInput, ResourceUpdateInputSchema, type ResourceUpdateOutput, ResourceUpdateOutputSchema, type ResourcesListInput, ResourcesListInputSchema, type ResourcesListOutput, ResourcesListOutputSchema, type ResourcesReadInput, ResourcesReadInputSchema, type ResourcesReadOutput, ResourcesReadOutputSchema, type ResourcesSearchInput, type ResourcesSearchOutput, mimeType };
362
+ export { type Resource, type ResourceCreateInput, ResourceCreateInputSchema, type ResourceCreateOutput, ResourceCreateOutputSchema, type ResourceDeleteInput, ResourceDeleteInputSchema, type ResourceDeleteOutput, ResourceDeleteOutputSchema, ResourceSearchInputSchema, ResourceSearchOutputSchema, type ResourceUpdateInput, ResourceUpdateInputSchema, type ResourceUpdateOutput, ResourceUpdateOutputSchema, type ResourcesListInput, ResourcesListInputSchema, type ResourcesListOutput, ResourcesListOutputSchema, type ResourcesReadInput, ResourcesReadInputSchema, type ResourcesReadOutput, ResourcesReadOutputSchema, type ResourcesSearchInput, type ResourcesSearchOutput, mimeType };
package/dist/resources.js CHANGED
@@ -1,4 +1,4 @@
1
- export { ResourceCreateInputSchema, ResourceCreateOutputSchema, ResourceDeleteInputSchema, ResourceDeleteOutputSchema, ResourceSchema, ResourceSearchInputSchema, ResourceSearchOutputSchema, ResourceUpdateInputSchema, ResourceUpdateOutputSchema, ResourcesListInputSchema, ResourcesListOutputSchema, ResourcesReadInputSchema, ResourcesReadOutputSchema, mimeType } from './chunk-73FIKR3X.js';
1
+ export { ResourceCreateInputSchema, ResourceCreateOutputSchema, ResourceDeleteInputSchema, ResourceDeleteOutputSchema, ResourceSearchInputSchema, ResourceSearchOutputSchema, ResourceUpdateInputSchema, ResourceUpdateOutputSchema, ResourcesListInputSchema, ResourcesListOutputSchema, ResourcesReadInputSchema, ResourcesReadOutputSchema, mimeType } from './chunk-NKUMVYKI.js';
2
2
  import './chunk-I7BWSAN6.js';
3
3
  //# sourceMappingURL=resources.js.map
4
4
  //# sourceMappingURL=resources.js.map
package/dist/views.d.ts CHANGED
@@ -14,13 +14,13 @@ declare const ViewsListOutputSchema: z.ZodObject<{
14
14
  prompt: z.ZodOptional<z.ZodString>;
15
15
  installBehavior: z.ZodOptional<z.ZodEnum<["none", "open", "autoPin"]>>;
16
16
  }, "strip", z.ZodTypeAny, {
17
- tools: string[];
18
17
  title: string;
18
+ tools: string[];
19
19
  icon: string;
20
- id?: string | undefined;
21
- name?: string | undefined;
22
20
  url?: string | undefined;
21
+ name?: string | undefined;
23
22
  description?: string | undefined;
23
+ id?: string | undefined;
24
24
  resourceName?: string | undefined;
25
25
  mimeTypePattern?: string | undefined;
26
26
  prompt?: string | undefined;
@@ -28,25 +28,25 @@ declare const ViewsListOutputSchema: z.ZodObject<{
28
28
  }, {
29
29
  title: string;
30
30
  icon: string;
31
- id?: string | undefined;
32
- name?: string | undefined;
33
31
  url?: string | undefined;
32
+ name?: string | undefined;
34
33
  description?: string | undefined;
35
- resourceName?: string | undefined;
36
34
  tools?: string[] | undefined;
35
+ id?: string | undefined;
36
+ resourceName?: string | undefined;
37
37
  mimeTypePattern?: string | undefined;
38
38
  prompt?: string | undefined;
39
39
  installBehavior?: "open" | "none" | "autoPin" | undefined;
40
40
  }>, "many">;
41
41
  }, "strip", z.ZodTypeAny, {
42
42
  views: {
43
- tools: string[];
44
43
  title: string;
44
+ tools: string[];
45
45
  icon: string;
46
- id?: string | undefined;
47
- name?: string | undefined;
48
46
  url?: string | undefined;
47
+ name?: string | undefined;
49
48
  description?: string | undefined;
49
+ id?: string | undefined;
50
50
  resourceName?: string | undefined;
51
51
  mimeTypePattern?: string | undefined;
52
52
  prompt?: string | undefined;
@@ -56,12 +56,12 @@ declare const ViewsListOutputSchema: z.ZodObject<{
56
56
  views: {
57
57
  title: string;
58
58
  icon: string;
59
- id?: string | undefined;
60
- name?: string | undefined;
61
59
  url?: string | undefined;
60
+ name?: string | undefined;
62
61
  description?: string | undefined;
63
- resourceName?: string | undefined;
64
62
  tools?: string[] | undefined;
63
+ id?: string | undefined;
64
+ resourceName?: string | undefined;
65
65
  mimeTypePattern?: string | undefined;
66
66
  prompt?: string | undefined;
67
67
  installBehavior?: "open" | "none" | "autoPin" | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decocms/runtime",
3
- "version": "0.24.0",
3
+ "version": "0.25.0",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "build": "tsup",
@@ -24,54 +24,67 @@
24
24
  "types": "./dist/index.d.ts",
25
25
  "files": [
26
26
  "dist/**/*",
27
+ "src/**/*",
27
28
  "config-schema.json"
28
29
  ],
29
30
  "exports": {
30
31
  ".": {
32
+ "source": "./src/index.ts",
31
33
  "types": "./dist/index.d.ts",
32
34
  "default": "./dist/index.js"
33
35
  },
34
36
  "./proxy": {
37
+ "source": "./src/proxy.ts",
35
38
  "types": "./dist/proxy.d.ts",
36
39
  "default": "./dist/proxy.js"
37
40
  },
38
41
  "./admin": {
42
+ "source": "./src/admin.ts",
39
43
  "types": "./dist/admin.d.ts",
40
44
  "default": "./dist/admin.js"
41
45
  },
42
46
  "./client": {
47
+ "source": "./src/client.ts",
43
48
  "types": "./dist/client.d.ts",
44
49
  "default": "./dist/client.js"
45
50
  },
46
51
  "./mastra": {
52
+ "source": "./src/mastra.ts",
47
53
  "types": "./dist/mastra.d.ts",
48
54
  "default": "./dist/mastra.js"
49
55
  },
50
56
  "./drizzle": {
57
+ "source": "./src/drizzle.ts",
51
58
  "types": "./dist/drizzle.d.ts",
52
59
  "default": "./dist/drizzle.js"
53
60
  },
54
61
  "./d1": {
62
+ "source": "./src/d1-store.ts",
55
63
  "types": "./dist/d1-store.d.ts",
56
64
  "default": "./dist/d1-store.js"
57
65
  },
58
66
  "./resources": {
67
+ "source": "./src/resources.ts",
59
68
  "types": "./dist/resources.d.ts",
60
69
  "default": "./dist/resources.js"
61
70
  },
62
71
  "./views": {
72
+ "source": "./src/views.ts",
63
73
  "types": "./dist/views.d.ts",
64
74
  "default": "./dist/views.js"
65
75
  },
66
76
  "./mcp-client": {
77
+ "source": "./src/mcp-client.ts",
67
78
  "types": "./dist/mcp-client.d.ts",
68
79
  "default": "./dist/mcp-client.js"
69
80
  },
70
81
  "./bindings": {
82
+ "source": "./src/bindings/index.ts",
71
83
  "types": "./dist/bindings/index.d.ts",
72
84
  "default": "./dist/bindings/index.js"
73
85
  },
74
86
  "./deconfig": {
87
+ "source": "./src/bindings/deconfig/index.ts",
75
88
  "types": "./dist/bindings/deconfig/index.d.ts",
76
89
  "default": "./dist/bindings/deconfig/index.js"
77
90
  }
package/src/admin.ts ADDED
@@ -0,0 +1,16 @@
1
+ import { createChannel } from "bidc";
2
+
3
+ export const requestMissingScopes = ({ scopes }: { scopes: string[] }) => {
4
+ try {
5
+ const channel = createChannel();
6
+ channel.send({
7
+ type: "request_missing_scopes",
8
+ payload: {
9
+ scopes,
10
+ },
11
+ });
12
+ channel.cleanup();
13
+ } catch (error) {
14
+ console.error("Failed to request missing scopes", error);
15
+ }
16
+ };