@voltro/protocol 0.53.0 → 0.55.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/CHANGELOG.md +335 -0
- package/dist/index.d.ts +165 -13
- package/dist/index.js +494 -463
- package/dist/rest.d.ts +37 -6
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import { A as e, B as t, C as n, D as r, E as i, F as a, G as o, H as s, I as
|
|
2
|
-
import { a as
|
|
3
|
-
import { Context as
|
|
4
|
-
import { Rpc as
|
|
1
|
+
import { A as e, B as t, C as n, D as r, E as i, F as a, G as o, H as s, I as ee, L as te, M as ne, N as c, O as re, P as ie, R as ae, S as oe, T as se, U as ce, V as le, W as ue, _ as de, a as l, b as fe, c as pe, d as me, f as he, g as ge, h as u, i as _e, j as ve, k as ye, l as be, m as xe, n as Se, o as Ce, p as we, r as Te, s as Ee, t as De, u as Oe, v as d, w as ke, x as Ae, y as je, z as Me } from "./scopes-B0kGvAnI.js";
|
|
2
|
+
import { a as Ne, c as Pe, i as Fe, n as Ie, o as Le, r as Re, s as ze, t as Be } from "./serverErrorBus-BeN9pOpY.js";
|
|
3
|
+
import { Context as Ve, Layer as He, Schema as f } from "effect";
|
|
4
|
+
import { Rpc as p } from "@effect/rpc";
|
|
5
5
|
//#region src/rowPatch.ts
|
|
6
|
-
var
|
|
7
|
-
key:
|
|
8
|
-
value:
|
|
9
|
-
}).pipe(
|
|
10
|
-
op:
|
|
11
|
-
path:
|
|
12
|
-
value:
|
|
13
|
-
}),
|
|
14
|
-
op:
|
|
15
|
-
path:
|
|
16
|
-
value:
|
|
17
|
-
}),
|
|
18
|
-
op:
|
|
19
|
-
path:
|
|
20
|
-
}),
|
|
21
|
-
op:
|
|
22
|
-
path:
|
|
23
|
-
value:
|
|
24
|
-
key:
|
|
25
|
-
value:
|
|
6
|
+
var Ue = f.Union(f.String, f.Number), m = f.Record({
|
|
7
|
+
key: f.String,
|
|
8
|
+
value: f.Unknown
|
|
9
|
+
}).pipe(f.filter((e) => "id" in e, { message: () => "patch row must carry an id" })), h = f.Union(f.Struct({
|
|
10
|
+
op: f.Literal("add"),
|
|
11
|
+
path: f.String,
|
|
12
|
+
value: m
|
|
13
|
+
}), f.Struct({
|
|
14
|
+
op: f.Literal("replace"),
|
|
15
|
+
path: f.String,
|
|
16
|
+
value: m
|
|
17
|
+
}), f.Struct({
|
|
18
|
+
op: f.Literal("remove"),
|
|
19
|
+
path: f.String
|
|
20
|
+
}), f.Struct({
|
|
21
|
+
op: f.Literal("mergeCells"),
|
|
22
|
+
path: f.String,
|
|
23
|
+
value: f.Record({
|
|
24
|
+
key: f.String,
|
|
25
|
+
value: f.Unknown
|
|
26
26
|
})
|
|
27
|
-
})),
|
|
28
|
-
ops:
|
|
29
|
-
order:
|
|
30
|
-
}),
|
|
27
|
+
})), We = f.Struct({
|
|
28
|
+
ops: f.Array(h),
|
|
29
|
+
order: f.Array(Ue)
|
|
30
|
+
}), g = (e) => `/${String(e).replace(/~/g, "~0").replace(/\//g, "~1")}`, Ge = (e) => (e.startsWith("/") ? e.slice(1) : e).replace(/~1/g, "/").replace(/~0/g, "~"), _ = (e) => {
|
|
31
31
|
let t = Object.keys(e).sort(), n = {};
|
|
32
32
|
for (let r of t) n[r] = e[r];
|
|
33
33
|
return JSON.stringify(n);
|
|
34
|
-
},
|
|
34
|
+
}, v = (e, t) => _(e) === _(t), Ke = (e, t) => {
|
|
35
35
|
if (e instanceof Uint8Array && t instanceof Uint8Array) {
|
|
36
36
|
if (e.length !== t.length) return !1;
|
|
37
37
|
for (let n = 0; n < e.length; n += 1) if (e[n] !== t[n]) return !1;
|
|
38
38
|
return !0;
|
|
39
39
|
}
|
|
40
|
-
return
|
|
40
|
+
return _({
|
|
41
41
|
id: 0,
|
|
42
42
|
v: e
|
|
43
|
-
}) ===
|
|
43
|
+
}) === _({
|
|
44
44
|
id: 0,
|
|
45
45
|
v: t
|
|
46
46
|
});
|
|
47
|
-
},
|
|
47
|
+
}, qe = (e, t, n = {}) => {
|
|
48
48
|
let r = /* @__PURE__ */ new Map();
|
|
49
49
|
for (let t of e) r.set(t.id, t);
|
|
50
|
-
let i = [], a = [], o = /* @__PURE__ */ new Set(), s = n.crdt,
|
|
50
|
+
let i = [], a = [], o = /* @__PURE__ */ new Set(), s = n.crdt, ee = (e, t) => {
|
|
51
51
|
if (s === void 0 || s.columns.size === 0) return;
|
|
52
52
|
let n = {}, r = !1;
|
|
53
53
|
for (let i of s.columns) {
|
|
54
|
-
if (!(i in t) ||
|
|
54
|
+
if (!(i in t) || Ke(e[i], t[i])) continue;
|
|
55
55
|
let a = s.incremental(i, e[i], t[i]);
|
|
56
56
|
if (a === void 0) return;
|
|
57
57
|
n[i] = a, r = !0;
|
|
@@ -69,43 +69,43 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
69
69
|
let t = r.get(e.id);
|
|
70
70
|
if (t === void 0) i.push({
|
|
71
71
|
op: "add",
|
|
72
|
-
path:
|
|
72
|
+
path: g(e.id),
|
|
73
73
|
value: e
|
|
74
74
|
});
|
|
75
|
-
else if (!
|
|
76
|
-
let n =
|
|
75
|
+
else if (!v(t, e)) {
|
|
76
|
+
let n = ee(t, e);
|
|
77
77
|
n === void 0 ? i.push({
|
|
78
78
|
op: "replace",
|
|
79
|
-
path:
|
|
79
|
+
path: g(e.id),
|
|
80
80
|
value: e
|
|
81
|
-
}) : (
|
|
81
|
+
}) : (v(Object.fromEntries(Object.entries(t).filter(([e]) => !s.columns.has(e))), n.scalars) || i.push({
|
|
82
82
|
op: "replace",
|
|
83
|
-
path:
|
|
83
|
+
path: g(e.id),
|
|
84
84
|
value: n.scalars
|
|
85
85
|
}), i.push({
|
|
86
86
|
op: "mergeCells",
|
|
87
|
-
path:
|
|
87
|
+
path: g(e.id),
|
|
88
88
|
value: n.merges
|
|
89
89
|
}));
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
92
|
for (let t of e) o.has(t.id) || i.push({
|
|
93
93
|
op: "remove",
|
|
94
|
-
path:
|
|
94
|
+
path: g(t.id)
|
|
95
95
|
});
|
|
96
96
|
return {
|
|
97
97
|
ops: i,
|
|
98
98
|
order: a
|
|
99
99
|
};
|
|
100
|
-
},
|
|
100
|
+
}, Je = (e) => e.every((e) => {
|
|
101
101
|
let t = e.id;
|
|
102
102
|
return typeof t == "string" || typeof t == "number";
|
|
103
|
-
}),
|
|
103
|
+
}), Ye = (e, t, n = {}) => {
|
|
104
104
|
let r = /* @__PURE__ */ new Map();
|
|
105
105
|
for (let t of e) r.set(t.id, t);
|
|
106
106
|
for (let e of t.ops) {
|
|
107
107
|
if (e.op === "mergeCells") {
|
|
108
|
-
let t =
|
|
108
|
+
let t = Ge(e.path), i = r.get(t) ?? r.get(Number(t)), a = r.has(t) ? t : Number(t);
|
|
109
109
|
if (i === void 0) continue;
|
|
110
110
|
let o = { ...i };
|
|
111
111
|
for (let [t, r] of Object.entries(e.value)) o[t] = n.mergeCell === void 0 ? r : n.mergeCell(t, i[t], r);
|
|
@@ -120,56 +120,56 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
120
120
|
t !== void 0 && i.push(t);
|
|
121
121
|
}
|
|
122
122
|
return i;
|
|
123
|
-
},
|
|
124
|
-
_tag:
|
|
125
|
-
revision:
|
|
123
|
+
}, y = (e) => f.Union(f.Struct({
|
|
124
|
+
_tag: f.Literal("snapshot"),
|
|
125
|
+
revision: f.Number,
|
|
126
126
|
data: e,
|
|
127
|
-
computed:
|
|
128
|
-
}),
|
|
129
|
-
_tag:
|
|
130
|
-
revision:
|
|
131
|
-
emittedAt:
|
|
132
|
-
patch:
|
|
133
|
-
}),
|
|
134
|
-
_tag:
|
|
135
|
-
error:
|
|
136
|
-
revision:
|
|
137
|
-
})),
|
|
127
|
+
computed: f.optional(f.Boolean)
|
|
128
|
+
}), f.Struct({
|
|
129
|
+
_tag: f.Literal("delta"),
|
|
130
|
+
revision: f.Number,
|
|
131
|
+
emittedAt: f.Number,
|
|
132
|
+
patch: We
|
|
133
|
+
}), f.Struct({
|
|
134
|
+
_tag: f.Literal("error"),
|
|
135
|
+
error: f.Unknown,
|
|
136
|
+
revision: f.optional(f.Number)
|
|
137
|
+
})), b = (e, t) => {
|
|
138
138
|
let n = `${e ?? "this procedure"} input`;
|
|
139
139
|
return t === !0 ? `${n} (guarded — the guard did NOT run: the payload failed to decode first, so this says nothing about access)` : n;
|
|
140
|
-
},
|
|
140
|
+
}, Xe = (e) => {
|
|
141
141
|
let t = e.ast;
|
|
142
142
|
return t._tag === "TypeLiteral" && (t.propertySignatures?.length ?? 0) === 0 && (t.indexSignatures?.length ?? 0) === 0;
|
|
143
|
-
},
|
|
144
|
-
let r =
|
|
143
|
+
}, x = (e, t, n) => {
|
|
144
|
+
let r = b(t, n), i = e.annotations({
|
|
145
145
|
parseOptions: { onExcessProperty: "error" },
|
|
146
146
|
parseIssueTitle: () => r
|
|
147
147
|
});
|
|
148
|
-
return
|
|
149
|
-
},
|
|
150
|
-
rule:
|
|
151
|
-
params:
|
|
152
|
-
key:
|
|
153
|
-
value:
|
|
148
|
+
return Xe(e) ? f.filter((e) => typeof e == "object" && e && Object.keys(e).length > 0 ? `this procedure declares no input; received: ${Object.keys(e).join(", ")}` : void 0)(i).annotations({ identifier: r }) : i;
|
|
149
|
+
}, S = class extends f.TaggedError()("BusinessRuleViolation", {
|
|
150
|
+
rule: f.String,
|
|
151
|
+
params: f.optional(f.Record({
|
|
152
|
+
key: f.String,
|
|
153
|
+
value: f.Unknown
|
|
154
154
|
})),
|
|
155
|
-
field:
|
|
156
|
-
message:
|
|
157
|
-
severity:
|
|
158
|
-
}) {},
|
|
159
|
-
field:
|
|
160
|
-
message:
|
|
161
|
-
params:
|
|
162
|
-
key:
|
|
163
|
-
value:
|
|
155
|
+
field: f.optional(f.String),
|
|
156
|
+
message: f.optional(f.String),
|
|
157
|
+
severity: f.Literal("error", "warning")
|
|
158
|
+
}) {}, C = f.Struct({
|
|
159
|
+
field: f.String,
|
|
160
|
+
message: f.String,
|
|
161
|
+
params: f.optional(f.Record({
|
|
162
|
+
key: f.String,
|
|
163
|
+
value: f.Unknown
|
|
164
164
|
}))
|
|
165
|
-
}),
|
|
166
|
-
field:
|
|
167
|
-
message:
|
|
168
|
-
params:
|
|
169
|
-
key:
|
|
170
|
-
value:
|
|
165
|
+
}), w = class extends f.TaggedError()("ValidationError", {
|
|
166
|
+
field: f.String,
|
|
167
|
+
message: f.String,
|
|
168
|
+
params: f.optional(f.Record({
|
|
169
|
+
key: f.String,
|
|
170
|
+
value: f.Unknown
|
|
171
171
|
}))
|
|
172
|
-
}) {},
|
|
172
|
+
}) {}, Ze = class extends f.TaggedError()("ValidationErrors", { issues: f.Array(C).pipe(f.minItems(1)) }) {}, Qe = (e) => {
|
|
173
173
|
if (typeof e != "object" || !e) return [];
|
|
174
174
|
let t = e._tag;
|
|
175
175
|
if (t === "ValidationError") {
|
|
@@ -195,53 +195,53 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
195
195
|
}];
|
|
196
196
|
}
|
|
197
197
|
return [];
|
|
198
|
-
},
|
|
199
|
-
approvalId:
|
|
200
|
-
procedure:
|
|
201
|
-
expiresAt:
|
|
202
|
-
requiredScopes:
|
|
203
|
-
reason:
|
|
204
|
-
created:
|
|
205
|
-
}) {},
|
|
206
|
-
approvalId:
|
|
207
|
-
subjectId:
|
|
208
|
-
}) {}, nt = class extends
|
|
209
|
-
approvalId:
|
|
210
|
-
decidedBy:
|
|
211
|
-
note:
|
|
212
|
-
}) {}, T = class extends
|
|
213
|
-
approvalId:
|
|
214
|
-
expiredAt:
|
|
215
|
-
}) {}, rt = class extends
|
|
216
|
-
approvalId:
|
|
217
|
-
status:
|
|
218
|
-
}) {}, it = class extends
|
|
219
|
-
approvalId:
|
|
220
|
-
required:
|
|
221
|
-
message:
|
|
222
|
-
}) {}, E = class extends
|
|
223
|
-
procedure:
|
|
224
|
-
message:
|
|
225
|
-
}) {}, at =
|
|
226
|
-
id:
|
|
227
|
-
procedure:
|
|
228
|
-
kind:
|
|
229
|
-
requestedBy:
|
|
230
|
-
status:
|
|
231
|
-
reason:
|
|
232
|
-
requiredScopes:
|
|
233
|
-
requestedAt:
|
|
234
|
-
expiresAt:
|
|
235
|
-
decidedBy:
|
|
236
|
-
decidedAt:
|
|
237
|
-
note:
|
|
238
|
-
relation:
|
|
239
|
-
}), D = "channel:",
|
|
240
|
-
if (!
|
|
198
|
+
}, $e = class extends f.TaggedError()("ApprovalRequired", {
|
|
199
|
+
approvalId: f.String,
|
|
200
|
+
procedure: f.String,
|
|
201
|
+
expiresAt: f.String,
|
|
202
|
+
requiredScopes: f.Array(f.String),
|
|
203
|
+
reason: f.NullOr(f.String),
|
|
204
|
+
created: f.Boolean
|
|
205
|
+
}) {}, et = class extends f.TaggedError()("ApprovalNotFound", { approvalId: f.String }) {}, tt = class extends f.TaggedError()("ApprovalSelfApproval", {
|
|
206
|
+
approvalId: f.String,
|
|
207
|
+
subjectId: f.NullOr(f.String)
|
|
208
|
+
}) {}, nt = class extends f.TaggedError()("ApprovalRejected", {
|
|
209
|
+
approvalId: f.String,
|
|
210
|
+
decidedBy: f.NullOr(f.String),
|
|
211
|
+
note: f.NullOr(f.String)
|
|
212
|
+
}) {}, T = class extends f.TaggedError()("ApprovalExpired", {
|
|
213
|
+
approvalId: f.String,
|
|
214
|
+
expiredAt: f.String
|
|
215
|
+
}) {}, rt = class extends f.TaggedError()("ApprovalNotPending", {
|
|
216
|
+
approvalId: f.String,
|
|
217
|
+
status: f.String
|
|
218
|
+
}) {}, it = class extends f.TaggedError()("ApprovalForbidden", {
|
|
219
|
+
approvalId: f.String,
|
|
220
|
+
required: f.NullOr(f.String),
|
|
221
|
+
message: f.String
|
|
222
|
+
}) {}, E = class extends f.TaggedError()("ApprovalUnavailable", {
|
|
223
|
+
procedure: f.String,
|
|
224
|
+
message: f.String
|
|
225
|
+
}) {}, at = f.Union($e, nt, T, E), ot = f.Union(et, tt, T, rt, it, E), st = f.Struct({
|
|
226
|
+
id: f.String,
|
|
227
|
+
procedure: f.String,
|
|
228
|
+
kind: f.Literal("mutation", "action"),
|
|
229
|
+
requestedBy: f.NullOr(f.String),
|
|
230
|
+
status: f.Literal("pending", "approved", "rejected", "expired", "consumed"),
|
|
231
|
+
reason: f.NullOr(f.String),
|
|
232
|
+
requiredScopes: f.Array(f.String),
|
|
233
|
+
requestedAt: f.String,
|
|
234
|
+
expiresAt: f.String,
|
|
235
|
+
decidedBy: f.NullOr(f.String),
|
|
236
|
+
decidedAt: f.NullOr(f.String),
|
|
237
|
+
note: f.NullOr(f.String),
|
|
238
|
+
relation: f.Literal("to-decide", "requested")
|
|
239
|
+
}), D = "channel:", ct = Symbol.for("@voltro/protocol/reactivityChannels"), O = globalThis, k = O[ct] ?? (O[ct] = /* @__PURE__ */ new Map()), lt = /^[a-z][a-z0-9-]*(\.[a-z0-9-]+)*$/, ut = (e) => {
|
|
240
|
+
if (!lt.test(e)) throw Error(`reactivityChannel('${e}'): invalid channel name.\n Use lowercase kebab segments separated by dots — \`presence\`, \`job-queue\`,
|
|
241
241
|
\`billing.usage\`. A \`:\` is refused because it is the namespace separator in
|
|
242
242
|
the routing key (\`${D}<name>\`), and an uppercase letter is\n refused because a key that differs only by case reads as one channel and
|
|
243
243
|
routes as two.`);
|
|
244
|
-
let t =
|
|
244
|
+
let t = k.get(e);
|
|
245
245
|
if (t !== void 0) return t;
|
|
246
246
|
let n = `${D}${e}`, r = Object.freeze({
|
|
247
247
|
kind: "reactivity-channel",
|
|
@@ -249,15 +249,15 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
249
249
|
key: n,
|
|
250
250
|
toString: () => n
|
|
251
251
|
});
|
|
252
|
-
return
|
|
253
|
-
},
|
|
254
|
-
let t =
|
|
255
|
-
for (let r of e) for (let e of
|
|
252
|
+
return k.set(e, r), r;
|
|
253
|
+
}, A = (e) => typeof e == "object" && !!e && e.kind === "reactivity-channel", j = (e) => e.startsWith(D), M = () => new Set([...k.values()].map((e) => e.key)), N = (e) => A(e) ? e.key : e, P = (e) => e === void 0 ? [] : Array.isArray(e) ? e.map(N) : [N(e)], F = (e) => e === void 0 ? void 0 : Array.isArray(e) ? e.map(N) : N(e), dt = (e) => {
|
|
254
|
+
let t = M(), n = [];
|
|
255
|
+
for (let r of e) for (let e of P(r.source)) !j(e) || t.has(e) || n.push({
|
|
256
256
|
procedure: r.name,
|
|
257
257
|
key: e
|
|
258
258
|
});
|
|
259
259
|
return n;
|
|
260
|
-
},
|
|
260
|
+
}, ft = (e, t) => {
|
|
261
261
|
let n = e?.injectExternalChange;
|
|
262
262
|
return n !== void 0 && (n.call(e, {
|
|
263
263
|
table: t.key,
|
|
@@ -266,8 +266,8 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
266
266
|
old: {},
|
|
267
267
|
origin: "inline"
|
|
268
268
|
}), !0);
|
|
269
|
-
},
|
|
270
|
-
if (
|
|
269
|
+
}, pt = (e) => e.internal !== !0, I = (e) => {
|
|
270
|
+
if (mt(e), Array.isArray(e.guards) && e.guards.length === 0) throw Error(`${e.name}: \`guards: []\` is empty, so it enforces nothing — but it reads\n at the call site as if this procedure were protected. Omit the field for an
|
|
271
271
|
unguarded procedure, or list the scopes required to call it.`);
|
|
272
272
|
let t = typeof e.source == "string" ? [e.source] : Array.isArray(e.source) ? e.source : void 0;
|
|
273
273
|
if (t !== void 0 && (t.length === 0 || t.some((e) => String(e).trim() === ""))) throw Error(`${e.name}: \`source\` is empty, so this query declares reactivity and\n subscribes to nothing — it serves one snapshot and never updates again,
|
|
@@ -284,7 +284,7 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
284
284
|
let n = [e.publicApi === void 0 ? void 0 : "publicApi", e.exposeAsTool === void 0 ? void 0 : "exposeAsTool"].filter((e) => e !== void 0);
|
|
285
285
|
if (n.length === 0) return e;
|
|
286
286
|
throw Error(`${e.name}: \`internal: true\` cannot be combined with ${n.map((e) => `\`${e}\``).join(" or ")}. \`internal\` takes the procedure OFF the wire; those put it back ON a different one (${n.includes("publicApi") ? "a REST route" : "an agent tool"}), and that surface is projected without consulting the flag — so the procedure would be unreachable from your client and reachable from the internet. Drop \`internal: true\` if the wider surface is intended, or remove the ${n.join(" / ")} annotation if it is not.`);
|
|
287
|
-
},
|
|
287
|
+
}, mt = (e) => {
|
|
288
288
|
let t = e.requiresApproval;
|
|
289
289
|
if (t !== void 0) {
|
|
290
290
|
if (!Array.isArray(t.approvers) || t.approvers.length === 0) throw Error(`${e.name}: \`requiresApproval.approvers\` is empty, so NOBODY can approve this\n procedure and every call would park forever. Name the scope(s) an approver must hold
|
|
@@ -294,48 +294,48 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
294
294
|
human from every other, and the second-pair-of-eyes control would enforce nothing.
|
|
295
295
|
Give the procedure a \`guards:\` decision, or drop \`requiresApproval\`.`);
|
|
296
296
|
}
|
|
297
|
-
},
|
|
297
|
+
}, ht = (e) => e.action !== void 0 && e.resourceType !== void 0, gt = (e) => e.openAccess !== void 0 || e.guards !== void 0 && e.guards.length > 0, L = (e, t, n) => {
|
|
298
298
|
if (n === void 0) return t;
|
|
299
299
|
if (n.trim() === "") throw Error(`${e}: \`openAccess\` needs a REASON, not an empty string. It is the sentence a\n reviewer reads to decide whether this procedure should really be callable
|
|
300
300
|
without an authorization check — e.g. \`openAccess: 'public pricing, no caller data'\`.`);
|
|
301
301
|
if (t !== void 0 && t.length > 0) throw Error(`${e}: \`openAccess\` and \`guards\` are two different access decisions, so\n declaring both says the procedure is protected AND open. Keep the guards if a
|
|
302
302
|
caller must hold a scope; drop them if anyone may call it.`);
|
|
303
|
-
return [
|
|
304
|
-
},
|
|
303
|
+
return [d(n.trim())];
|
|
304
|
+
}, R = (e) => I({
|
|
305
305
|
kind: "query",
|
|
306
306
|
name: e.name,
|
|
307
307
|
input: e.input,
|
|
308
308
|
output: e.output,
|
|
309
|
-
error: e.error ??
|
|
310
|
-
source:
|
|
309
|
+
error: e.error ?? f.Never,
|
|
310
|
+
source: F(e.source),
|
|
311
311
|
cache: e.cache,
|
|
312
|
-
guards:
|
|
312
|
+
guards: L(e.name, e.guards, e.openAccess),
|
|
313
313
|
openAccess: e.openAccess,
|
|
314
314
|
publicApi: e.publicApi,
|
|
315
315
|
exposeAsTool: e.exposeAsTool,
|
|
316
316
|
internal: e.internal,
|
|
317
317
|
overridesPlugin: e.overridesPlugin
|
|
318
|
-
}),
|
|
318
|
+
}), z = (e) => I({
|
|
319
319
|
kind: "mutation",
|
|
320
320
|
name: e.name,
|
|
321
321
|
input: e.input,
|
|
322
322
|
output: e.output,
|
|
323
|
-
error: e.error ??
|
|
323
|
+
error: e.error ?? f.Never,
|
|
324
324
|
target: e.target,
|
|
325
|
-
guards:
|
|
325
|
+
guards: L(e.name, e.guards, e.openAccess),
|
|
326
326
|
openAccess: e.openAccess,
|
|
327
327
|
publicApi: e.publicApi,
|
|
328
328
|
exposeAsTool: e.exposeAsTool,
|
|
329
329
|
requiresApproval: e.requiresApproval,
|
|
330
330
|
internal: e.internal,
|
|
331
331
|
overridesPlugin: e.overridesPlugin
|
|
332
|
-
}),
|
|
332
|
+
}), B = (e) => I({
|
|
333
333
|
kind: "action",
|
|
334
334
|
name: e.name,
|
|
335
335
|
input: e.input,
|
|
336
336
|
output: e.output,
|
|
337
|
-
error: e.error ??
|
|
338
|
-
guards:
|
|
337
|
+
error: e.error ?? f.Never,
|
|
338
|
+
guards: L(e.name, e.guards, e.openAccess),
|
|
339
339
|
openAccess: e.openAccess,
|
|
340
340
|
source: e.source,
|
|
341
341
|
target: e.target,
|
|
@@ -344,50 +344,53 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
344
344
|
requiresApproval: e.requiresApproval,
|
|
345
345
|
internal: e.internal,
|
|
346
346
|
overridesPlugin: e.overridesPlugin
|
|
347
|
-
}),
|
|
347
|
+
}), _t = (e) => I({
|
|
348
348
|
kind: "stream",
|
|
349
349
|
name: e.name,
|
|
350
350
|
input: e.input,
|
|
351
351
|
element: e.element,
|
|
352
|
-
error: e.error ??
|
|
352
|
+
error: e.error ?? f.Never,
|
|
353
353
|
internal: e.internal,
|
|
354
354
|
overridesPlugin: e.overridesPlugin,
|
|
355
|
-
guards:
|
|
355
|
+
guards: L(e.name, e.guards, e.openAccess),
|
|
356
356
|
openAccess: e.openAccess
|
|
357
|
-
}),
|
|
357
|
+
}), V = (e, t) => t && t.length > 0 ? f.Union(e, ...t) : e, H = (e) => e !== void 0 && e.some((e) => !u(e)), vt = (e, t) => H(t) ? f.Union(e, l, c) : e, yt = (e) => f.Union(e, S), bt = (e) => f.Union(e, w, Ze), xt = (e, t) => t === void 0 ? e : f.Union(e, at), U = (e, t) => {
|
|
358
358
|
if (t === "stream") return e.error;
|
|
359
|
-
let n =
|
|
360
|
-
return t === "query" ? n : bt(
|
|
361
|
-
},
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
359
|
+
let n = vt(e.error, e.guards);
|
|
360
|
+
return t === "query" ? n : xt(bt(t === "mutation" ? yt(n) : n), e.requiresApproval);
|
|
361
|
+
}, St = (e, t) => ({
|
|
362
|
+
...e,
|
|
363
|
+
name: t
|
|
364
|
+
}), Ct = (e, t) => p.make(e.name, {
|
|
365
|
+
payload: x(e.input, e.name, H(e.guards)),
|
|
366
|
+
success: y(e.output),
|
|
367
|
+
error: V(U(e, "query"), t),
|
|
365
368
|
stream: !0
|
|
366
|
-
}),
|
|
367
|
-
payload:
|
|
369
|
+
}), wt = (e, t) => p.make(e.name, {
|
|
370
|
+
payload: x(e.input, e.name, H(e.guards)),
|
|
368
371
|
success: e.output,
|
|
369
|
-
error:
|
|
370
|
-
}),
|
|
371
|
-
payload:
|
|
372
|
+
error: V(U(e, "mutation"), t)
|
|
373
|
+
}), Tt = (e, t) => p.make(e.name, {
|
|
374
|
+
payload: x(e.input, e.name, H(e.guards)),
|
|
372
375
|
success: e.output,
|
|
373
|
-
error:
|
|
374
|
-
}),
|
|
375
|
-
payload:
|
|
376
|
+
error: V(U(e, "action"), t)
|
|
377
|
+
}), Et = (e, t) => p.make(e.name, {
|
|
378
|
+
payload: x(e.input, e.name, H(e.guards)),
|
|
376
379
|
success: e.element,
|
|
377
|
-
error:
|
|
380
|
+
error: V(e.error, t),
|
|
378
381
|
stream: !0
|
|
379
|
-
}),
|
|
382
|
+
}), Dt = (e) => {
|
|
380
383
|
if (typeof e != "object" || !e) return;
|
|
381
384
|
let t = e._tag;
|
|
382
385
|
return typeof t == "string" ? t : void 0;
|
|
383
|
-
},
|
|
386
|
+
}, Ot = (e) => {
|
|
384
387
|
switch (e.kind) {
|
|
385
|
-
case "query": return
|
|
386
|
-
case "mutation": return
|
|
387
|
-
case "action": return
|
|
388
|
-
case "stream": return
|
|
388
|
+
case "query": return Ct(e);
|
|
389
|
+
case "mutation": return wt(e);
|
|
390
|
+
case "action": return Tt(e);
|
|
391
|
+
case "stream": return Et(e);
|
|
389
392
|
}
|
|
390
|
-
},
|
|
393
|
+
}, kt = (e) => {
|
|
391
394
|
let t = e.input, n = t === void 0 ? {} : { input: t }, r = e.output, i = r === void 0 ? {} : { output: r };
|
|
392
395
|
if (e.kind === "query") return {
|
|
393
396
|
kind: "query",
|
|
@@ -425,10 +428,11 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
425
428
|
..."path" in e && e.path !== void 0 ? { path: e.path } : {},
|
|
426
429
|
..."by" in e && e.by !== void 0 ? { by: e.by } : {},
|
|
427
430
|
..."match" in e && e.match !== void 0 ? { match: e.match } : {},
|
|
428
|
-
..."shapeItem" in e && e.shapeItem !== void 0 ? { shapeItem: e.shapeItem } : {}
|
|
431
|
+
..."shapeItem" in e && e.shapeItem !== void 0 ? { shapeItem: e.shapeItem } : {},
|
|
432
|
+
..."relations" in e && e.relations !== void 0 ? { relations: e.relations } : {}
|
|
429
433
|
}))
|
|
430
434
|
};
|
|
431
|
-
},
|
|
435
|
+
}, At = 7500, jt = (e) => typeof e == "object" && !!e && e.kind === "event", Mt = (e) => {
|
|
432
436
|
if (e.name.length === 0) throw Error("defineEvent: `name` must not be empty");
|
|
433
437
|
if (/\s/.test(e.name)) throw Error(`defineEvent("${e.name}"): \`name\` must not contain whitespace.\n The name is used as a broker subject segment. NATS refuses a subject with
|
|
434
438
|
whitespace and delivers nothing — silently, and only on that broker, so an
|
|
@@ -457,75 +461,75 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
457
461
|
name: e.name,
|
|
458
462
|
key: e.key,
|
|
459
463
|
payload: e.payload,
|
|
460
|
-
guards: e.openAccess === void 0 ? e.guards : [
|
|
464
|
+
guards: e.openAccess === void 0 ? e.guards : [d(e.openAccess.trim())],
|
|
461
465
|
openAccess: e.openAccess,
|
|
462
466
|
rewind: e.rewind,
|
|
463
467
|
webhook: e.webhook,
|
|
464
468
|
delivery: e.delivery
|
|
465
469
|
};
|
|
466
|
-
},
|
|
467
|
-
_tag:
|
|
468
|
-
origin:
|
|
469
|
-
n:
|
|
470
|
-
emittedAt:
|
|
470
|
+
}, Nt = (e) => f.Struct({
|
|
471
|
+
_tag: f.Literal("event"),
|
|
472
|
+
origin: f.String,
|
|
473
|
+
n: f.Number,
|
|
474
|
+
emittedAt: f.Number,
|
|
471
475
|
payload: e
|
|
472
|
-
}),
|
|
473
|
-
_tag:
|
|
474
|
-
missed:
|
|
475
|
-
reason:
|
|
476
|
-
}),
|
|
477
|
-
origin:
|
|
478
|
-
n:
|
|
479
|
-
}),
|
|
476
|
+
}), Pt = f.Struct({
|
|
477
|
+
_tag: f.Literal("gap"),
|
|
478
|
+
missed: f.Number,
|
|
479
|
+
reason: f.Literal("buffer", "resume")
|
|
480
|
+
}), Ft = f.Struct({ _tag: f.Literal("attached") }), It = (e) => f.Union(Ft, Nt(e), Pt), Lt = f.Struct({
|
|
481
|
+
origin: f.String,
|
|
482
|
+
n: f.Number
|
|
483
|
+
}), Rt = (e) => f.Struct({
|
|
480
484
|
key: e,
|
|
481
|
-
resume:
|
|
482
|
-
}),
|
|
483
|
-
let n = e.guards !== void 0 && e.guards.some((e) => !
|
|
484
|
-
return
|
|
485
|
-
payload:
|
|
486
|
-
success:
|
|
485
|
+
resume: f.optional(f.Array(Lt))
|
|
486
|
+
}), zt = (e, t) => {
|
|
487
|
+
let n = e.guards !== void 0 && e.guards.some((e) => !u(e)) ? f.Union(l, c) : f.Never, r = t && t.length > 0 ? f.Union(n, ...t) : n;
|
|
488
|
+
return p.make(e.name, {
|
|
489
|
+
payload: x(Rt(e.key), e.name, H(e.guards)),
|
|
490
|
+
success: It(e.payload),
|
|
487
491
|
error: r,
|
|
488
492
|
stream: !0
|
|
489
493
|
});
|
|
490
|
-
},
|
|
491
|
-
event:
|
|
492
|
-
message:
|
|
493
|
-
}) {},
|
|
494
|
-
event:
|
|
495
|
-
message:
|
|
496
|
-
}) {},
|
|
497
|
-
event:
|
|
498
|
-
bytes:
|
|
499
|
-
limit:
|
|
500
|
-
}) {},
|
|
494
|
+
}, Bt = class extends f.TaggedError()("EventPayloadInvalid", {
|
|
495
|
+
event: f.String,
|
|
496
|
+
message: f.String
|
|
497
|
+
}) {}, Vt = class extends f.TaggedError()("EventKeyInvalid", {
|
|
498
|
+
event: f.String,
|
|
499
|
+
message: f.String
|
|
500
|
+
}) {}, Ht = class extends f.TaggedError()("EventPayloadTooLarge", {
|
|
501
|
+
event: f.String,
|
|
502
|
+
bytes: f.Number,
|
|
503
|
+
limit: f.Number
|
|
504
|
+
}) {}, Ut = (e) => {
|
|
501
505
|
if (typeof e != "object" || !e) return JSON.stringify(e) ?? "null";
|
|
502
506
|
let t = Object.entries(e).filter(([, e]) => e !== void 0).sort(([e], [t]) => e < t ? -1 : +(e > t));
|
|
503
507
|
return JSON.stringify(t);
|
|
504
|
-
},
|
|
508
|
+
}, Wt = "\0", Gt = (e, t, n) => [
|
|
505
509
|
e ?? "~",
|
|
506
510
|
t,
|
|
507
|
-
|
|
508
|
-
].join("\0"),
|
|
511
|
+
Ut(n)
|
|
512
|
+
].join("\0"), Kt = (e) => {
|
|
509
513
|
let [t = "~", n = "", r = ""] = e.split("\0");
|
|
510
514
|
return {
|
|
511
515
|
tenantId: t === "~" ? null : t,
|
|
512
516
|
event: n,
|
|
513
517
|
key: r
|
|
514
518
|
};
|
|
515
|
-
},
|
|
519
|
+
}, qt = (e) => e.split("\0").join(" · "), Jt = (e) => e, Yt = (e) => e, Xt = (e) => {
|
|
516
520
|
let t = e.alias?.trim(), n = e.instance?.trim(), r = t !== void 0 && t !== "" ? t : e.base;
|
|
517
521
|
return n !== void 0 && n !== "" ? `${r}#${n}` : r;
|
|
518
|
-
},
|
|
522
|
+
}, Zt = (e) => {
|
|
519
523
|
if (e.length !== 0) return (t, n) => e.reduceRight((e, t) => t(e, n), t);
|
|
520
|
-
},
|
|
521
|
-
let n =
|
|
524
|
+
}, Qt = (e, t) => {
|
|
525
|
+
let n = Ve.GenericTag(e);
|
|
522
526
|
return {
|
|
523
527
|
Tag: n,
|
|
524
|
-
Live:
|
|
528
|
+
Live: He.succeed(n, t)
|
|
525
529
|
};
|
|
526
|
-
},
|
|
530
|
+
}, $t = (e, t, n) => {
|
|
527
531
|
if (!t) return { ok: !0 };
|
|
528
|
-
let r =
|
|
532
|
+
let r = W(n);
|
|
529
533
|
if (!r) return {
|
|
530
534
|
ok: !1,
|
|
531
535
|
reason: `cannot parse runningVersion "${n}"`
|
|
@@ -533,12 +537,12 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
533
537
|
let i = t.trim();
|
|
534
538
|
if (i === "*" || i === "") return { ok: !0 };
|
|
535
539
|
let a = i.split(/\s+/).filter((e) => e.length > 0);
|
|
536
|
-
for (let i of a) if (!
|
|
540
|
+
for (let i of a) if (!en(i, r)) return {
|
|
537
541
|
ok: !1,
|
|
538
542
|
reason: `plugin "${e}" requires framework ${t}, running ${n}`
|
|
539
543
|
};
|
|
540
544
|
return { ok: !0 };
|
|
541
|
-
},
|
|
545
|
+
}, W = (e) => {
|
|
542
546
|
let t = /^(\d+)\.(\d+)\.(\d+)(?:-([0-9a-zA-Z.-]+))?$/.exec(e.trim());
|
|
543
547
|
return t ? {
|
|
544
548
|
major: Number(t[1]),
|
|
@@ -546,228 +550,255 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
546
550
|
patch: Number(t[3]),
|
|
547
551
|
pre: t[4] ?? ""
|
|
548
552
|
} : null;
|
|
549
|
-
},
|
|
553
|
+
}, G = (e, t) => e.major === t.major ? e.minor === t.minor ? e.patch === t.patch ? e.pre && !t.pre ? -1 : !e.pre && t.pre ? 1 : e.pre && t.pre ? e.pre < t.pre ? -1 : +(e.pre > t.pre) : 0 : e.patch - t.patch : e.minor - t.minor : e.major - t.major, en = (e, t) => {
|
|
550
554
|
if (e === "*") return !0;
|
|
551
555
|
if (e.startsWith("^")) {
|
|
552
|
-
let n =
|
|
553
|
-
return !n || t.major !== n.major ? !1 :
|
|
556
|
+
let n = W(e.slice(1));
|
|
557
|
+
return !n || t.major !== n.major ? !1 : G(t, n) >= 0;
|
|
554
558
|
}
|
|
555
559
|
if (e.startsWith("~")) {
|
|
556
|
-
let n =
|
|
557
|
-
return !n || t.major !== n.major || t.minor !== n.minor ? !1 :
|
|
560
|
+
let n = W(e.slice(1));
|
|
561
|
+
return !n || t.major !== n.major || t.minor !== n.minor ? !1 : G(t, n) >= 0;
|
|
558
562
|
}
|
|
559
563
|
let n = /^(>=|<=|>|<)(.+)$/.exec(e);
|
|
560
564
|
if (n) {
|
|
561
|
-
let e = n[1], r =
|
|
565
|
+
let e = n[1], r = W(n[2]);
|
|
562
566
|
if (!r) return !1;
|
|
563
|
-
let i =
|
|
567
|
+
let i = G(t, r);
|
|
564
568
|
if (e === ">=") return i >= 0;
|
|
565
569
|
if (e === "<=") return i <= 0;
|
|
566
570
|
if (e === ">") return i > 0;
|
|
567
571
|
if (e === "<") return i < 0;
|
|
568
572
|
}
|
|
569
|
-
let r =
|
|
570
|
-
return r ?
|
|
571
|
-
},
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
}
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
}),
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
}),
|
|
657
|
-
id:
|
|
658
|
-
|
|
659
|
-
payload:
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
eventId:
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
573
|
+
let r = W(e);
|
|
574
|
+
return r ? G(t, r) === 0 : !1;
|
|
575
|
+
}, tn = (e) => {
|
|
576
|
+
let t = e.startsWith("@") ? e.replace(/^@[^/]+\//, "") : e;
|
|
577
|
+
return (t.startsWith("plugin-") ? t.slice(7) : t).replace(/-([a-zA-Z0-9])/g, (e, t) => t.toUpperCase());
|
|
578
|
+
}, nn = (e) => {
|
|
579
|
+
let t = e.startsWith("@") ? e.replace(/^@[^/]+\//, "") : e;
|
|
580
|
+
return (t.startsWith("plugin-") ? t.slice(7) : t).replace(/#/g, "--").replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
|
|
581
|
+
}, rn = Symbol.for("@voltro/protocol/pluginAliases"), K = () => {
|
|
582
|
+
let e = globalThis, t = e[rn];
|
|
583
|
+
if (t instanceof Map) return t;
|
|
584
|
+
let n = /* @__PURE__ */ new Map();
|
|
585
|
+
return e[rn] = n, n;
|
|
586
|
+
}, an = (e) => {
|
|
587
|
+
let t = K();
|
|
588
|
+
for (let [n, r] of Object.entries(e)) {
|
|
589
|
+
if (r === "") continue;
|
|
590
|
+
let e = t.get(n);
|
|
591
|
+
e === void 0 ? t.set(n, /* @__PURE__ */ new Set([r])) : e.add(r);
|
|
592
|
+
}
|
|
593
|
+
}, on = () => {
|
|
594
|
+
K().clear();
|
|
595
|
+
}, sn = (e, t) => {
|
|
596
|
+
let n = K().get(e);
|
|
597
|
+
if (n === void 0 || n.size === 0) return `${tn(e)}.${t}`;
|
|
598
|
+
if (n.size === 1) return `${[...n][0]}.${t}`;
|
|
599
|
+
let r = [...n].filter((e) => !e.includes("#"));
|
|
600
|
+
if (r.length === 1) return `${r[0]}.${t}`;
|
|
601
|
+
throw Error(`[voltro] ${e} is installed more than once (${[...n].sort().join(", ")}) and no single install is the primary one, so a plugin hook cannot tell which of them it addresses. Call the route by its full tag instead — e.g. useSubscription(api, '${[...n].sort()[0]}.${t}').`);
|
|
602
|
+
}, q = f.Literal("running", "succeeded", "failed", "cancelled", "suspended"), cn = f.Literal("cancel", "terminate", "abandon"), ln = f.Struct({
|
|
603
|
+
mode: f.String,
|
|
604
|
+
dueAt: f.NullOr(f.Number),
|
|
605
|
+
retryAfterMs: f.NullOr(f.Number),
|
|
606
|
+
intentId: f.NullOr(f.String)
|
|
607
|
+
}), un = f.Struct({
|
|
608
|
+
id: f.String,
|
|
609
|
+
workflowName: f.String,
|
|
610
|
+
executionId: f.NullOr(f.String),
|
|
611
|
+
status: f.Literal("running", "queued", "dropped", "skipped"),
|
|
612
|
+
deferral: f.optional(ln)
|
|
613
|
+
}), J = f.Struct({
|
|
614
|
+
id: f.String,
|
|
615
|
+
tag: f.String,
|
|
616
|
+
executionId: f.String,
|
|
617
|
+
status: q,
|
|
618
|
+
payload: f.Unknown,
|
|
619
|
+
workflowVersion: f.NullOr(f.String),
|
|
620
|
+
workflowPatches: f.NullOr(f.Unknown),
|
|
621
|
+
output: f.NullOr(f.Unknown),
|
|
622
|
+
subject: f.NullOr(f.Unknown),
|
|
623
|
+
source: f.NullOr(f.String),
|
|
624
|
+
errorTag: f.NullOr(f.String),
|
|
625
|
+
errorMessage: f.NullOr(f.String),
|
|
626
|
+
cancelled: f.Boolean,
|
|
627
|
+
startedAt: f.Date,
|
|
628
|
+
completedAt: f.NullOr(f.Date),
|
|
629
|
+
durationMs: f.NullOr(f.Number),
|
|
630
|
+
traceId: f.NullOr(f.String),
|
|
631
|
+
parentExecutionId: f.NullOr(f.String),
|
|
632
|
+
parentClosePolicy: f.NullOr(cn)
|
|
633
|
+
}), dn = f.Struct({
|
|
634
|
+
tag: f.optional(f.String),
|
|
635
|
+
status: f.optional(q),
|
|
636
|
+
limit: f.optional(f.Number)
|
|
637
|
+
}), fn = f.Struct({
|
|
638
|
+
id: f.String,
|
|
639
|
+
runId: f.String,
|
|
640
|
+
stepName: f.String,
|
|
641
|
+
attempt: f.Number,
|
|
642
|
+
status: f.Literal("running", "succeeded", "failed"),
|
|
643
|
+
input: f.NullOr(f.Unknown),
|
|
644
|
+
retryPolicy: f.NullOr(f.Unknown),
|
|
645
|
+
output: f.NullOr(f.Unknown),
|
|
646
|
+
errorTag: f.NullOr(f.String),
|
|
647
|
+
errorMessage: f.NullOr(f.String),
|
|
648
|
+
errorCause: f.NullOr(f.Unknown),
|
|
649
|
+
startedAt: f.Date,
|
|
650
|
+
completedAt: f.NullOr(f.Date),
|
|
651
|
+
durationMs: f.NullOr(f.Number)
|
|
652
|
+
}), pn = f.Struct({
|
|
653
|
+
id: f.String,
|
|
654
|
+
runId: f.String,
|
|
655
|
+
eventType: f.String,
|
|
656
|
+
payload: f.NullOr(f.Unknown),
|
|
657
|
+
occurredAt: f.Date,
|
|
658
|
+
stepName: f.NullOr(f.String),
|
|
659
|
+
attempt: f.NullOr(f.Number)
|
|
660
|
+
}), mn = f.Struct({
|
|
661
|
+
id: f.String,
|
|
662
|
+
name: f.String,
|
|
663
|
+
payload: f.Unknown,
|
|
664
|
+
source: f.String,
|
|
665
|
+
subject: f.NullOr(f.Unknown),
|
|
666
|
+
traceId: f.NullOr(f.String),
|
|
667
|
+
occurredAt: f.Date
|
|
668
|
+
}), hn = f.Struct({
|
|
669
|
+
id: f.String,
|
|
670
|
+
eventId: f.String,
|
|
671
|
+
eventName: f.String,
|
|
672
|
+
triggerId: f.String,
|
|
673
|
+
workflowName: f.String,
|
|
674
|
+
executionId: f.NullOr(f.String),
|
|
675
|
+
status: f.Literal("starting", "started", "skipped", "failed"),
|
|
676
|
+
idempotencyKey: f.String,
|
|
677
|
+
skipped: f.Boolean,
|
|
678
|
+
errorMessage: f.NullOr(f.String),
|
|
679
|
+
createdAt: f.Date,
|
|
680
|
+
completedAt: f.NullOr(f.Date)
|
|
681
|
+
}), gn = f.Struct({ id: f.String }), Y = f.Struct({ runId: f.String }), _n = f.Struct({
|
|
682
|
+
name: f.optional(f.String),
|
|
683
|
+
limit: f.optional(f.Number)
|
|
684
|
+
}), vn = f.Struct({ eventId: f.String }), X = f.Struct({
|
|
685
|
+
workflowName: f.String,
|
|
686
|
+
executionId: f.String
|
|
687
|
+
}), yn = f.Struct({
|
|
688
|
+
id: f.String,
|
|
689
|
+
signalName: f.String,
|
|
690
|
+
payload: f.optional(f.Unknown)
|
|
691
|
+
}), bn = f.Struct({
|
|
692
|
+
id: f.String,
|
|
693
|
+
updateName: f.String,
|
|
694
|
+
payload: f.optional(f.Unknown),
|
|
695
|
+
timeoutMs: f.optional(f.Number)
|
|
696
|
+
}), xn = f.Struct({
|
|
697
|
+
eventId: f.String,
|
|
698
|
+
updateId: f.String,
|
|
699
|
+
completedEventId: f.String,
|
|
700
|
+
result: f.Unknown
|
|
701
|
+
}), Sn = R({
|
|
671
702
|
name: "__voltro.workflow.run",
|
|
672
703
|
source: "_voltro_workflow_runs",
|
|
673
|
-
input:
|
|
674
|
-
output:
|
|
675
|
-
}),
|
|
704
|
+
input: gn,
|
|
705
|
+
output: f.Array(J)
|
|
706
|
+
}), Cn = R({
|
|
676
707
|
name: "__voltro.workflow.runs",
|
|
677
708
|
source: "_voltro_workflow_runs",
|
|
678
|
-
input:
|
|
679
|
-
output:
|
|
680
|
-
}),
|
|
709
|
+
input: dn,
|
|
710
|
+
output: f.Array(J)
|
|
711
|
+
}), wn = R({
|
|
681
712
|
name: "__voltro.workflow.run.steps",
|
|
682
713
|
source: "_voltro_workflow_run_steps",
|
|
683
|
-
input:
|
|
684
|
-
output:
|
|
685
|
-
}),
|
|
714
|
+
input: Y,
|
|
715
|
+
output: f.Array(fn)
|
|
716
|
+
}), Tn = R({
|
|
686
717
|
name: "__voltro.workflow.run.events",
|
|
687
718
|
source: "_voltro_workflow_run_events",
|
|
688
|
-
input:
|
|
689
|
-
output:
|
|
690
|
-
}),
|
|
719
|
+
input: Y,
|
|
720
|
+
output: f.Array(pn)
|
|
721
|
+
}), En = R({
|
|
691
722
|
name: "__voltro.workflow.domainEvents",
|
|
692
723
|
source: "_voltro_workflow_events",
|
|
693
|
-
input:
|
|
694
|
-
output:
|
|
695
|
-
}),
|
|
724
|
+
input: _n,
|
|
725
|
+
output: f.Array(mn)
|
|
726
|
+
}), Dn = R({
|
|
696
727
|
name: "__voltro.workflow.event.deliveries",
|
|
697
728
|
source: "_voltro_workflow_event_deliveries",
|
|
698
|
-
input:
|
|
699
|
-
output:
|
|
700
|
-
}),
|
|
729
|
+
input: vn,
|
|
730
|
+
output: f.Array(hn)
|
|
731
|
+
}), On = B({
|
|
701
732
|
name: "__voltro.workflow.cancel",
|
|
702
|
-
input:
|
|
703
|
-
output:
|
|
704
|
-
}),
|
|
733
|
+
input: X,
|
|
734
|
+
output: f.Struct({ ok: f.Boolean })
|
|
735
|
+
}), kn = B({
|
|
705
736
|
name: "__voltro.workflow.resume",
|
|
706
|
-
input:
|
|
707
|
-
output:
|
|
708
|
-
}),
|
|
737
|
+
input: X,
|
|
738
|
+
output: f.Struct({ ok: f.Boolean })
|
|
739
|
+
}), An = B({
|
|
709
740
|
name: "__voltro.workflow.signal",
|
|
710
|
-
input:
|
|
711
|
-
output:
|
|
712
|
-
}),
|
|
741
|
+
input: yn,
|
|
742
|
+
output: f.Struct({ eventId: f.String })
|
|
743
|
+
}), jn = B({
|
|
713
744
|
name: "__voltro.workflow.update",
|
|
714
|
-
input:
|
|
715
|
-
output:
|
|
716
|
-
}),
|
|
717
|
-
id:
|
|
718
|
-
tag:
|
|
719
|
-
label:
|
|
720
|
-
undone:
|
|
721
|
-
crossesAction:
|
|
722
|
-
createdAt:
|
|
723
|
-
}),
|
|
724
|
-
invocationId:
|
|
725
|
-
reason:
|
|
726
|
-
}) {},
|
|
727
|
-
name:
|
|
745
|
+
input: bn,
|
|
746
|
+
output: xn
|
|
747
|
+
}), Mn = "__voltro.undo.log", Nn = "__voltro.undo.apply", Pn = "__voltro.undo.redo", Fn = f.Struct({
|
|
748
|
+
id: f.String,
|
|
749
|
+
tag: f.String,
|
|
750
|
+
label: f.NullOr(f.String),
|
|
751
|
+
undone: f.Boolean,
|
|
752
|
+
crossesAction: f.Boolean,
|
|
753
|
+
createdAt: f.String
|
|
754
|
+
}), In = class extends f.TaggedError()("UndoNotFound", { invocationId: f.String }) {}, Ln = class extends f.TaggedError()("UndoForbidden", { invocationId: f.String }) {}, Rn = class extends f.TaggedError()("UndoConflict", {
|
|
755
|
+
invocationId: f.String,
|
|
756
|
+
reason: f.Literal("conflict", "action")
|
|
757
|
+
}) {}, zn = f.Union(In, Ln, Rn), Bn = R({
|
|
758
|
+
name: Mn,
|
|
728
759
|
source: "_voltro_undo_log",
|
|
729
|
-
input:
|
|
730
|
-
output:
|
|
760
|
+
input: f.Struct({ limit: f.optional(f.Number) }),
|
|
761
|
+
output: f.Array(Fn),
|
|
731
762
|
openAccess: "subject-scoped by construction: lists only the calling subject's own undoable actions"
|
|
732
|
-
}),
|
|
733
|
-
name:
|
|
734
|
-
input:
|
|
735
|
-
output:
|
|
736
|
-
error:
|
|
763
|
+
}), Vn = z({
|
|
764
|
+
name: Nn,
|
|
765
|
+
input: f.Struct({ invocationId: f.String }),
|
|
766
|
+
output: f.Struct({ ok: f.Boolean }),
|
|
767
|
+
error: zn,
|
|
737
768
|
openAccess: "subject-scoped by construction: undo is per-actor — another subject's invocation fails typed with UndoForbidden"
|
|
738
|
-
}),
|
|
739
|
-
name:
|
|
740
|
-
input:
|
|
741
|
-
output:
|
|
742
|
-
error:
|
|
769
|
+
}), Hn = z({
|
|
770
|
+
name: Pn,
|
|
771
|
+
input: f.Struct({ invocationId: f.String }),
|
|
772
|
+
output: f.Struct({ ok: f.Boolean }),
|
|
773
|
+
error: zn,
|
|
743
774
|
openAccess: "subject-scoped by construction: redo is per-actor — another subject's invocation fails typed with UndoForbidden"
|
|
744
|
-
}),
|
|
745
|
-
table:
|
|
746
|
-
reason:
|
|
747
|
-
}) {},
|
|
748
|
-
operation:
|
|
749
|
-
table:
|
|
750
|
-
cause:
|
|
751
|
-
}) {},
|
|
752
|
-
table:
|
|
753
|
-
summary:
|
|
754
|
-
issues:
|
|
755
|
-
path:
|
|
756
|
-
message:
|
|
775
|
+
}), Un = class extends f.TaggedError()("TenantScopeViolation", {
|
|
776
|
+
table: f.String,
|
|
777
|
+
reason: f.String
|
|
778
|
+
}) {}, Wn = class extends f.TaggedError()("StoreOperationFailed", {
|
|
779
|
+
operation: f.String,
|
|
780
|
+
table: f.String,
|
|
781
|
+
cause: f.String
|
|
782
|
+
}) {}, Gn = class extends f.TaggedError()("TableValidationFailed", {
|
|
783
|
+
table: f.String,
|
|
784
|
+
summary: f.String,
|
|
785
|
+
issues: f.Array(f.Struct({
|
|
786
|
+
path: f.String,
|
|
787
|
+
message: f.String
|
|
757
788
|
}))
|
|
758
|
-
}) {},
|
|
759
|
-
table:
|
|
760
|
-
id:
|
|
761
|
-
reason:
|
|
762
|
-
}) {},
|
|
763
|
-
table:
|
|
764
|
-
columns:
|
|
765
|
-
}) {},
|
|
766
|
-
kind:
|
|
767
|
-
table:
|
|
768
|
-
operation:
|
|
769
|
-
constraint:
|
|
770
|
-
column:
|
|
789
|
+
}) {}, Kn = class extends f.TaggedError()("TenantRowNotFound", {
|
|
790
|
+
table: f.String,
|
|
791
|
+
id: f.String,
|
|
792
|
+
reason: f.String
|
|
793
|
+
}) {}, qn = class extends f.TaggedError()("ServerOnlyColumnWrite", {
|
|
794
|
+
table: f.String,
|
|
795
|
+
columns: f.Array(f.String)
|
|
796
|
+
}) {}, Jn = class extends f.TaggedError()("ConstraintViolation", {
|
|
797
|
+
kind: f.Literal("foreignKey", "foreignKeyInUse", "unique", "notNull", "check"),
|
|
798
|
+
table: f.String,
|
|
799
|
+
operation: f.String,
|
|
800
|
+
constraint: f.optional(f.String),
|
|
801
|
+
column: f.optional(f.String)
|
|
771
802
|
}) {
|
|
772
803
|
get message() {
|
|
773
804
|
let e = this.constraint ?? this.column, t = e === void 0 ? `on ${this.table}` : `${e} on ${this.table}`;
|
|
@@ -779,85 +810,85 @@ var He = p.Union(p.String, p.Number), Ue = p.Record({
|
|
|
779
810
|
case "check": return `check constraint ${t}: the row does not satisfy it`;
|
|
780
811
|
}
|
|
781
812
|
}
|
|
782
|
-
},
|
|
783
|
-
name:
|
|
813
|
+
}, Yn = "__voltro.approvals.pending", Xn = "__voltro.approvals.decide", Zn = R({
|
|
814
|
+
name: Yn,
|
|
784
815
|
source: "_voltro_approvals",
|
|
785
|
-
input:
|
|
786
|
-
output:
|
|
816
|
+
input: f.Struct({ limit: f.optional(f.Number) }),
|
|
817
|
+
output: f.Array(st),
|
|
787
818
|
openAccess: "the answer is scoped to the caller — a row appears only if they requested it or hold its recorded approver scopes, so an anonymous caller sees nothing"
|
|
788
|
-
}),
|
|
789
|
-
name:
|
|
790
|
-
input:
|
|
791
|
-
approvalId:
|
|
792
|
-
decision:
|
|
793
|
-
note:
|
|
819
|
+
}), Qn = z({
|
|
820
|
+
name: Xn,
|
|
821
|
+
input: f.Struct({
|
|
822
|
+
approvalId: f.String,
|
|
823
|
+
decision: f.Literal("approve", "reject"),
|
|
824
|
+
note: f.optional(f.String)
|
|
794
825
|
}),
|
|
795
|
-
output:
|
|
796
|
-
approvalId:
|
|
797
|
-
status:
|
|
826
|
+
output: f.Struct({
|
|
827
|
+
approvalId: f.String,
|
|
828
|
+
status: f.Literal("approved", "rejected")
|
|
798
829
|
}),
|
|
799
830
|
error: ot,
|
|
800
831
|
openAccess: "the approver authority is the PENDING ROW's own recorded scopes (plus an unconditional self-approval refusal), checked in-handler — a descriptor-level scope would have to be the union of every approval-requiring procedure in the app"
|
|
801
|
-
}),
|
|
802
|
-
connectionId:
|
|
832
|
+
}), $n = "__voltro.connections.list", er = "__voltro.connections.start", Z = "__voltro.connections.submitToken", tr = "__voltro.connections.disconnect", Q = f.Literal("oauth2", "pat"), nr = f.Literal("disconnected", "connected", "expired", "revoked", "error"), rr = f.Struct({
|
|
833
|
+
connectionId: f.String,
|
|
803
834
|
kind: Q,
|
|
804
|
-
label:
|
|
805
|
-
status:
|
|
806
|
-
accountId:
|
|
807
|
-
accountLabel:
|
|
808
|
-
scopes:
|
|
809
|
-
expiresAt:
|
|
810
|
-
lastError:
|
|
811
|
-
connectedAt:
|
|
812
|
-
}),
|
|
813
|
-
connectionId:
|
|
835
|
+
label: f.String,
|
|
836
|
+
status: nr,
|
|
837
|
+
accountId: f.NullOr(f.String),
|
|
838
|
+
accountLabel: f.NullOr(f.String),
|
|
839
|
+
scopes: f.Array(f.String),
|
|
840
|
+
expiresAt: f.NullOr(f.String),
|
|
841
|
+
lastError: f.NullOr(f.String),
|
|
842
|
+
connectedAt: f.NullOr(f.String)
|
|
843
|
+
}), ir = class extends f.TaggedError()("ConnectionNotDeclared", { connectionId: f.String }) {}, ar = class extends f.TaggedError()("ConnectionSubjectRequired", { connectionId: f.String }) {}, or = class extends f.TaggedError()("ConnectionKindMismatch", {
|
|
844
|
+
connectionId: f.String,
|
|
814
845
|
expected: Q,
|
|
815
846
|
actual: Q
|
|
816
|
-
}) {},
|
|
817
|
-
connectionId:
|
|
818
|
-
reason:
|
|
819
|
-
transient:
|
|
820
|
-
}) {}, $ =
|
|
821
|
-
name:
|
|
847
|
+
}) {}, sr = class extends f.TaggedError()("ConnectionHandshakeFailed", {
|
|
848
|
+
connectionId: f.String,
|
|
849
|
+
reason: f.String,
|
|
850
|
+
transient: f.Boolean
|
|
851
|
+
}) {}, $ = f.Union(ir, ar, or, sr), cr = R({
|
|
852
|
+
name: $n,
|
|
822
853
|
source: "_voltro_connections",
|
|
823
|
-
input:
|
|
824
|
-
output:
|
|
854
|
+
input: f.Struct({}),
|
|
855
|
+
output: f.Array(rr),
|
|
825
856
|
openAccess: "self-scoped read: projects the declared connections for the calling subject only (its own connect/disconnect state)"
|
|
826
|
-
}),
|
|
827
|
-
name:
|
|
828
|
-
input:
|
|
829
|
-
connectionId:
|
|
830
|
-
redirectTo:
|
|
857
|
+
}), lr = B({
|
|
858
|
+
name: er,
|
|
859
|
+
input: f.Struct({
|
|
860
|
+
connectionId: f.String,
|
|
861
|
+
redirectTo: f.optional(f.String)
|
|
831
862
|
}),
|
|
832
|
-
output:
|
|
833
|
-
authorizeUrl:
|
|
834
|
-
state:
|
|
863
|
+
output: f.Struct({
|
|
864
|
+
authorizeUrl: f.String,
|
|
865
|
+
state: f.String
|
|
835
866
|
}),
|
|
836
867
|
error: $,
|
|
837
868
|
openAccess: "self-service: begins an oauth handshake that stores a credential for the calling subject only; anonymous callers fail typed with ConnectionSubjectRequired"
|
|
838
|
-
}),
|
|
839
|
-
name:
|
|
840
|
-
input:
|
|
841
|
-
connectionId:
|
|
842
|
-
token:
|
|
869
|
+
}), ur = z({
|
|
870
|
+
name: Z,
|
|
871
|
+
input: f.Struct({
|
|
872
|
+
connectionId: f.String,
|
|
873
|
+
token: f.String
|
|
843
874
|
}),
|
|
844
|
-
output:
|
|
875
|
+
output: f.Struct({ ok: f.Boolean }),
|
|
845
876
|
error: $,
|
|
846
877
|
openAccess: "self-service: stores a pasted token as the calling subject's own credential; anonymous callers fail typed with ConnectionSubjectRequired"
|
|
847
|
-
}),
|
|
848
|
-
name:
|
|
849
|
-
input:
|
|
850
|
-
output:
|
|
878
|
+
}), dr = z({
|
|
879
|
+
name: tr,
|
|
880
|
+
input: f.Struct({ connectionId: f.String }),
|
|
881
|
+
output: f.Struct({ ok: f.Boolean }),
|
|
851
882
|
error: $,
|
|
852
883
|
openAccess: "self-service: deletes only the calling subject's own credential row for this connection"
|
|
853
|
-
}),
|
|
884
|
+
}), fr = (e) => {
|
|
854
885
|
let t = e instanceof Date ? e.getTime() : typeof e == "number" ? e : typeof e == "string" ? new Date(e).getTime() : 0;
|
|
855
886
|
return Number.isNaN(t) ? 0 : t;
|
|
856
|
-
},
|
|
887
|
+
}, pr = 4001, mr = /* @__PURE__ */ new Set(["/rpc", "/ws"]), hr = (e) => {
|
|
857
888
|
if (!e.path.startsWith("/")) throw Error(`defineWebSocket: path must be absolute, got '${e.path}'`);
|
|
858
|
-
if (
|
|
889
|
+
if (mr.has(e.path)) throw Error(`defineWebSocket: '${e.path}' is the framework's own socket surface — mount the gateway elsewhere`);
|
|
859
890
|
if (e.auth !== "subject" && e.auth !== "public") throw Error(`defineWebSocket: auth must be 'subject' or 'public' (explicitly — an unauthenticated socket has to be a decision somebody wrote down), got '${String(e.auth)}'`);
|
|
860
891
|
return e;
|
|
861
|
-
},
|
|
892
|
+
}, gr = 1;
|
|
862
893
|
//#endregion
|
|
863
|
-
export {
|
|
894
|
+
export { De as ADMIN_SCOPE, Se as APIKEY_ISSUE_ORG_SCOPE, Te as APIKEY_ISSUE_OTHER_SCOPE, _e as APIKEY_ISSUE_SELF_SCOPE, Xn as APPROVALS_DECIDE_TAG, Yn as APPROVALS_PENDING_TAG, ot as ApprovalDecisionErrors, at as ApprovalErrors, T as ApprovalExpired, it as ApprovalForbidden, et as ApprovalNotFound, rt as ApprovalNotPending, nt as ApprovalRejected, $e as ApprovalRequired, tt as ApprovalSelfApproval, E as ApprovalUnavailable, ke as AuthMiddleware, S as BusinessRuleViolation, $n as CONNECTIONS_LIST_TAG, tr as CONNECTION_DISCONNECT_TAG, er as CONNECTION_START_TAG, Z as CONNECTION_SUBMIT_TOKEN_TAG, sr as ConnectionHandshakeFailed, se as ConnectionInfo, i as ConnectionInfoMiddleware, Q as ConnectionKind, or as ConnectionKindMismatch, ir as ConnectionNotDeclared, rr as ConnectionState, nr as ConnectionStatus, ar as ConnectionSubjectRequired, Jn as ConstraintViolation, r as DEFAULT_SCOPE_CACHE_MAX_ENTRIES, re as DEFAULT_SCOPE_CACHE_TTL_MS, Wt as EVENT_ROUTE_SEP, Vt as EventKeyInvalid, Bt as EventPayloadInvalid, Ht as EventPayloadTooLarge, pr as GATEWAY_CREDENTIAL_EXPIRED_CLOSE_CODE, ye as IMPERSONATION_METADATA_KEY, At as MAX_EVENT_ENVELOPE_BYTES, gr as PROTOCOL_VERSION, st as PendingApproval, D as REACTIVITY_CHANNEL_PREFIX, l as ScopeError, qn as ServerOnlyColumnWrite, Wn as StoreOperationFailed, e as Subject, ve as SubjectIdentity, ne as SubjectService, Gn as TableValidationFailed, Kn as TenantRowNotFound, Un as TenantScopeViolation, Nn as UNDO_APPLY_TAG, Mn as UNDO_LOG_TAG, Pn as UNDO_REDO_TAG, c as Unauthenticated, Rn as UndoConflict, Ln as UndoForbidden, Fn as UndoLogEntry, In as UndoNotFound, w as ValidationError, Ze as ValidationErrors, C as ValidationIssue, X as WorkflowControlInputSchema, mn as WorkflowDomainEventRowSchema, _n as WorkflowDomainEventsInputSchema, vn as WorkflowEventDeliveriesInputSchema, hn as WorkflowEventDeliveryRowSchema, cn as WorkflowParentClosePolicySchema, pn as WorkflowRunEventRowSchema, un as WorkflowRunHandleSchema, gn as WorkflowRunRefSchema, J as WorkflowRunRowSchema, q as WorkflowRunStatusSchema, fn as WorkflowRunStepRowSchema, Y as WorkflowRunTableRefSchema, dn as WorkflowRunsInputSchema, yn as WorkflowSignalInputSchema, ln as WorkflowStartDeferralSchema, bn as WorkflowUpdateInputSchema, xn as WorkflowUpdateResultSchema, Tt as actionToRpc, Ce as advisoryResourceGuardWarning, ie as anonymousSubject, Ye as applyRowPatch, a as applyScopeDecision, Qn as approvalsDecideDescriptor, Zn as approvalsPendingQueryDescriptor, ee as assertAuthenticated, Re as beginIdempotent, $t as checkFrameworkCompat, Ee as checkGuards, pe as checkGuardsEffect, te as composeAuthStrategies, Zt as composeRpcInterceptors, dr as connectionDisconnectDescriptor, lr as connectionStartDescriptor, ur as connectionSubmitTokenDescriptor, cr as connectionsListQueryDescriptor, M as declaredReactivityChannelKeys, B as defineAction, Mt as defineEvent, z as defineMutation, Jt as definePlugin, Yt as definePluginRoute, Qt as definePluginService, R as defineQuery, _t as defineStream, hr as defineWebSocket, qe as diffRows, be as effectiveScopes, Ut as encodeEventKey, Dt as errorTag, Ft as eventAttached, Nt as eventEnvelope, Pt as eventGap, Lt as eventResumePoint, Gt as eventRoute, It as eventStreamEvent, Rt as eventSubscribeInput, zt as eventToRpc, Fe as failIdempotent, Qe as fieldIssuesOf, Oe as findAdvisoryResourceGuards, Ne as finishIdempotent, qt as formatEventRoute, me as getPolicyGuardResolver, he as getResourceScopeResolver, gt as hasAccessDecision, ae as hasCallbackRoutes, we as hasEffectiveScope, H as hasEnforcedGuard, xe as hasScope, g as idToPath, Le as idempotencyScope, b as inputLabel, jt as isEventDescriptor, Je as isIdKeyed, u as isOpenAccess, ge as isPolicyCheck, ht as isPolicyGuard, A as isReactivityChannel, j as isReactivityChannelKey, Me as isSystemSubject, pt as isWireReachable, t as makeScopeCache, ze as memoryIdempotencyStore, de as missingAccessDecision, wt as mutationToRpc, kt as normalizeDescriptor, F as normalizeSource, d as openAccessSpec, Kt as parseEventRoute, Ge as pathToId, tn as pluginAlias, Xt as pluginInstanceName, nn as pluginSlug, sn as pluginTag, ft as publishReactivity, Be as publishServerError, Ct as queryToRpc, le as rawImpersonationMark, ut as reactivityChannel, an as registerPluginAliases, je as requireScope, on as resetPluginAliases, h as rowPatchOpSchema, We as rowPatchSchema, s as scopeCacheKey, fe as setEffectiveScopes, Ae as setPolicyGuardResolver, oe as setResourceScopeResolver, P as sourceKeys, Et as streamToRpc, x as strictInput, ce as subjectIdentity, n as subjectScopes, Ie as subscribeServerErrors, y as subscriptionEvent, ue as systemSubject, o as tenantScopedSubject, Ot as toRpc, fr as tsMs, dt as undeclaredChannelKeys, Vn as undoApplyDescriptor, Bn as undoLogQueryDescriptor, Hn as undoRedoDescriptor, U as wireErrorUnion, St as withRpcTag, On as workflowCancelDescriptor, En as workflowDomainEventsQueryDescriptor, Dn as workflowEventDeliveriesQueryDescriptor, kn as workflowResumeDescriptor, Tn as workflowRunEventsQueryDescriptor, Sn as workflowRunQueryDescriptor, wn as workflowRunStepsQueryDescriptor, Cn as workflowRunsQueryDescriptor, An as workflowSignalDescriptor, jn as workflowUpdateDescriptor, Pe as wsMutationIdempotencyScope };
|