@oomol-lab/open-flow 0.1.0-beta.20 → 0.1.0-beta.21
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/dist/browser/{createResourceDialog-DlrAMxmo.js → createResourceDialog-CjuJryCv.js} +13 -13
- package/dist/browser/{flowChanges-jX3KYcb0.js → flowChanges-Tg1duLry.js} +2269 -2208
- package/dist/browser/{flowWorkspace-BIYwslVl.js → flowWorkspace-CoK10XHY.js} +306 -306
- package/dist/browser/{inputValues-BWfRHJWC.js → inputValues-CDiBMKu8.js} +1 -1
- package/dist/browser/workbench.js +23 -23
- package/dist/browser/{workbenchSelect-CwP6rphY.js → workbenchSelect-DEmv7SLW.js} +1 -1
- package/dist/common/control-api-conformance.js +871 -810
- package/dist/common/control-api.js +249 -188
- package/dist/common/flow-encoding.d.ts +6 -0
- package/dist/common/flow-encoding.js +1323 -1171
- package/dist/common/flow-semantics.js +1872 -1811
- package/dist/common/mcp.js +176 -115
- package/dist/common/provider-triggers.js +1307 -1246
- package/package.json +1 -1
|
@@ -3583,7 +3583,7 @@ var A = /*@__PURE__*/ b("ZodType", (e, t) => (go(), w.init(e, t), e.def = t, e.t
|
|
|
3583
3583
|
return ws(this, e);
|
|
3584
3584
|
},
|
|
3585
3585
|
array() {
|
|
3586
|
-
return
|
|
3586
|
+
return I(this);
|
|
3587
3587
|
},
|
|
3588
3588
|
or(e) {
|
|
3589
3589
|
return R([this, e]);
|
|
@@ -3948,16 +3948,16 @@ function Jo(e) {
|
|
|
3948
3948
|
var Yo = /*@__PURE__*/ b("ZodUnknown", (e, t) => {
|
|
3949
3949
|
tr.init(e, t), A.init(e, t), e._zod.processJSONSchema = (e, t, n) => void 0;
|
|
3950
3950
|
});
|
|
3951
|
-
function
|
|
3951
|
+
function F() {
|
|
3952
3952
|
return /* @__PURE__ */ zi(Yo);
|
|
3953
3953
|
}
|
|
3954
|
-
var
|
|
3954
|
+
var Xo = /*@__PURE__*/ b("ZodNever", (e, t) => {
|
|
3955
3955
|
nr.init(e, t), A.init(e, t), e._zod.processJSONSchema = (t, n, r) => ka(e, t, n, r);
|
|
3956
3956
|
});
|
|
3957
|
-
function
|
|
3958
|
-
return /* @__PURE__ */ Bi(
|
|
3957
|
+
function Zo(e) {
|
|
3958
|
+
return /* @__PURE__ */ Bi(Xo, e);
|
|
3959
3959
|
}
|
|
3960
|
-
var
|
|
3960
|
+
var Qo = /*@__PURE__*/ b("ZodArray", (e, t) => {
|
|
3961
3961
|
_o(), ir.init(e, t), A.init(e, t), e._zod.processJSONSchema = (t, n, r) => Pa(e, t, n, r), e.element = t.element;
|
|
3962
3962
|
}, {
|
|
3963
3963
|
min(e, t) {
|
|
@@ -3976,10 +3976,10 @@ var $o = /*@__PURE__*/ b("ZodArray", (e, t) => {
|
|
|
3976
3976
|
return this.element;
|
|
3977
3977
|
}
|
|
3978
3978
|
});
|
|
3979
|
-
function
|
|
3980
|
-
return /* @__PURE__ */ sa(
|
|
3979
|
+
function I(e, t) {
|
|
3980
|
+
return /* @__PURE__ */ sa(Qo, e, t);
|
|
3981
3981
|
}
|
|
3982
|
-
var
|
|
3982
|
+
var $o = /*@__PURE__*/ b("ZodObject", (e, t) => {
|
|
3983
3983
|
_o(), dr.init(e, t), A.init(e, t), e._zod.processJSONSchema = (t, n, r) => Ia(e, t, n, r), Me(e, "shape", (e) => e._zod.def.shape, !1);
|
|
3984
3984
|
}, {
|
|
3985
3985
|
keyof() {
|
|
@@ -3994,19 +3994,19 @@ var es = /*@__PURE__*/ b("ZodObject", (e, t) => {
|
|
|
3994
3994
|
passthrough() {
|
|
3995
3995
|
return this.clone({
|
|
3996
3996
|
...this._zod.def,
|
|
3997
|
-
catchall:
|
|
3997
|
+
catchall: F()
|
|
3998
3998
|
});
|
|
3999
3999
|
},
|
|
4000
4000
|
loose() {
|
|
4001
4001
|
return this.clone({
|
|
4002
4002
|
...this._zod.def,
|
|
4003
|
-
catchall:
|
|
4003
|
+
catchall: F()
|
|
4004
4004
|
});
|
|
4005
4005
|
},
|
|
4006
4006
|
strict() {
|
|
4007
4007
|
return this.clone({
|
|
4008
4008
|
...this._zod.def,
|
|
4009
|
-
catchall:
|
|
4009
|
+
catchall: Zo()
|
|
4010
4010
|
});
|
|
4011
4011
|
},
|
|
4012
4012
|
strip() {
|
|
@@ -4040,18 +4040,18 @@ var es = /*@__PURE__*/ b("ZodObject", (e, t) => {
|
|
|
4040
4040
|
return me(Cs, this, e[0]);
|
|
4041
4041
|
}
|
|
4042
4042
|
});
|
|
4043
|
-
function
|
|
4044
|
-
return new
|
|
4043
|
+
function L(e, t) {
|
|
4044
|
+
return new $o({
|
|
4045
4045
|
type: "object",
|
|
4046
4046
|
shape: e ?? {},
|
|
4047
4047
|
...g(t)
|
|
4048
4048
|
});
|
|
4049
4049
|
}
|
|
4050
|
-
function
|
|
4051
|
-
return new
|
|
4050
|
+
function es(e, t) {
|
|
4051
|
+
return new $o({
|
|
4052
4052
|
type: "object",
|
|
4053
4053
|
shape: e,
|
|
4054
|
-
catchall:
|
|
4054
|
+
catchall: Zo(),
|
|
4055
4055
|
...g(t)
|
|
4056
4056
|
});
|
|
4057
4057
|
}
|
|
@@ -4311,19 +4311,19 @@ function Is(e) {
|
|
|
4311
4311
|
N(),
|
|
4312
4312
|
P(),
|
|
4313
4313
|
Jo(),
|
|
4314
|
-
|
|
4314
|
+
I(t),
|
|
4315
4315
|
z(j(), t)
|
|
4316
4316
|
]));
|
|
4317
4317
|
return t;
|
|
4318
4318
|
}
|
|
4319
4319
|
//#endregion
|
|
4320
4320
|
//#region src/control/common/resultQuery.ts
|
|
4321
|
-
var Ls =
|
|
4321
|
+
var Ls = es({
|
|
4322
4322
|
pointer: j().max(4096).default(""),
|
|
4323
4323
|
offset: N().int().nonnegative().default(0),
|
|
4324
4324
|
limit: N().int().min(1).max(100).default(20),
|
|
4325
4325
|
maxBytes: N().int().min(1).max(1048576).default(15e3)
|
|
4326
|
-
}), Rs = Is(), zs =
|
|
4326
|
+
}), Rs = Is(), zs = es({
|
|
4327
4327
|
pointer: j(),
|
|
4328
4328
|
type: B([
|
|
4329
4329
|
"object",
|
|
@@ -4339,24 +4339,24 @@ var Ls = L({
|
|
|
4339
4339
|
}), Bs = zs.extend({
|
|
4340
4340
|
offset: N().int().nonnegative(),
|
|
4341
4341
|
nextOffset: N().int().positive().optional(),
|
|
4342
|
-
entries:
|
|
4343
|
-
}), Vs =
|
|
4342
|
+
entries: I(zs).optional()
|
|
4343
|
+
}), Vs = es({
|
|
4344
4344
|
resultId: j().min(1),
|
|
4345
4345
|
callId: j().min(1),
|
|
4346
4346
|
toolId: j().min(1),
|
|
4347
|
-
source: rs("kind", [
|
|
4347
|
+
source: rs("kind", [es({
|
|
4348
4348
|
kind: V("connector"),
|
|
4349
4349
|
action: j().min(1)
|
|
4350
|
-
}),
|
|
4350
|
+
}), es({ kind: V("code") })]),
|
|
4351
4351
|
bytes: N().int().nonnegative(),
|
|
4352
4352
|
digest: j().regex(/^[a-f0-9]{64}$/),
|
|
4353
4353
|
createdAt: j().datetime()
|
|
4354
|
-
}), Hs =
|
|
4354
|
+
}), Hs = es({
|
|
4355
4355
|
version: V(1),
|
|
4356
4356
|
runId: j(),
|
|
4357
|
-
results:
|
|
4357
|
+
results: I(Vs),
|
|
4358
4358
|
nextAfter: j().optional()
|
|
4359
|
-
}), Us =
|
|
4359
|
+
}), Us = es({
|
|
4360
4360
|
version: V(1),
|
|
4361
4361
|
runId: j(),
|
|
4362
4362
|
result: Vs,
|
|
@@ -4853,86 +4853,86 @@ function hc(e, t = 0) {
|
|
|
4853
4853
|
}
|
|
4854
4854
|
//#endregion
|
|
4855
4855
|
//#region src/flow/common/changeSchema.ts
|
|
4856
|
-
var Y = j(), X = Is(), gc =
|
|
4856
|
+
var Y = j(), X = Is(), gc = I(Y), _c = L({
|
|
4857
4857
|
description: Y.optional(),
|
|
4858
4858
|
jsonSchema: X,
|
|
4859
4859
|
nullable: P(),
|
|
4860
4860
|
handle: Y
|
|
4861
|
-
}), Z = _c.extend({ value: X.optional() }), vc =
|
|
4861
|
+
}), Z = _c.extend({ value: X.optional() }), vc = L({
|
|
4862
4862
|
collapsed: P().optional(),
|
|
4863
4863
|
group: Y
|
|
4864
|
-
}), yc =
|
|
4864
|
+
}), yc = L({
|
|
4865
4865
|
kind: V("node"),
|
|
4866
4866
|
nodeId: Y,
|
|
4867
4867
|
output: Y
|
|
4868
|
-
}), bc =
|
|
4868
|
+
}), bc = L({
|
|
4869
4869
|
kind: V("flow"),
|
|
4870
4870
|
input: Y
|
|
4871
4871
|
}), xc = R([
|
|
4872
4872
|
yc,
|
|
4873
4873
|
bc,
|
|
4874
|
-
|
|
4874
|
+
L({
|
|
4875
4875
|
kind: V("binding"),
|
|
4876
4876
|
bindingId: Y
|
|
4877
4877
|
})
|
|
4878
|
-
]), Sc = R([
|
|
4878
|
+
]), Sc = R([L({
|
|
4879
4879
|
kind: V("value"),
|
|
4880
4880
|
value: X
|
|
4881
|
-
}),
|
|
4881
|
+
}), L({
|
|
4882
4882
|
kind: V("sources"),
|
|
4883
|
-
sources:
|
|
4883
|
+
sources: I(xc)
|
|
4884
4884
|
})]), Cc = z(Y, Sc), wc = {
|
|
4885
|
-
inputs:
|
|
4886
|
-
outputs:
|
|
4887
|
-
}, Tc =
|
|
4885
|
+
inputs: I(R([Z, vc])),
|
|
4886
|
+
outputs: I(R([_c, vc]))
|
|
4887
|
+
}, Tc = L({
|
|
4888
4888
|
kind: V("connector"),
|
|
4889
4889
|
action: Y,
|
|
4890
4890
|
connectionId: Y.optional(),
|
|
4891
|
-
connections:
|
|
4891
|
+
connections: I(L({
|
|
4892
4892
|
connectionId: Y,
|
|
4893
4893
|
alias: Y.optional()
|
|
4894
4894
|
}))
|
|
4895
|
-
}), Ec =
|
|
4895
|
+
}), Ec = L({
|
|
4896
4896
|
...wc,
|
|
4897
4897
|
name: Y,
|
|
4898
4898
|
moduleId: Y,
|
|
4899
|
-
capabilities:
|
|
4900
|
-
}), Dc = R([
|
|
4899
|
+
capabilities: I(Tc).optional()
|
|
4900
|
+
}), Dc = R([L({
|
|
4901
4901
|
kind: V("value"),
|
|
4902
4902
|
value: X
|
|
4903
|
-
}),
|
|
4903
|
+
}), L({
|
|
4904
4904
|
kind: V("input"),
|
|
4905
4905
|
input: Y
|
|
4906
|
-
})]), Oc = R([Dc,
|
|
4906
|
+
})]), Oc = R([Dc, L({ kind: V("model") })]), kc = L({
|
|
4907
4907
|
...wc,
|
|
4908
4908
|
name: Y,
|
|
4909
4909
|
executor: R([
|
|
4910
|
-
|
|
4910
|
+
L({
|
|
4911
4911
|
kind: V("connector"),
|
|
4912
4912
|
action: Y,
|
|
4913
4913
|
connectionId: Y.optional()
|
|
4914
4914
|
}),
|
|
4915
|
-
|
|
4915
|
+
L({
|
|
4916
4916
|
kind: V("llm"),
|
|
4917
4917
|
mode: B(["chat", "json"])
|
|
4918
4918
|
}),
|
|
4919
|
-
|
|
4919
|
+
L({
|
|
4920
4920
|
kind: V("agent"),
|
|
4921
4921
|
code: P().optional(),
|
|
4922
4922
|
model: Y,
|
|
4923
4923
|
prompt: Dc,
|
|
4924
4924
|
system: Y,
|
|
4925
4925
|
maxRounds: N(),
|
|
4926
|
-
tools:
|
|
4926
|
+
tools: I(L({
|
|
4927
4927
|
id: Y,
|
|
4928
4928
|
name: Y,
|
|
4929
4929
|
description: Y,
|
|
4930
4930
|
action: Y,
|
|
4931
4931
|
connectionId: Y.optional(),
|
|
4932
4932
|
approval: P(),
|
|
4933
|
-
inputs:
|
|
4933
|
+
inputs: I(Z.extend({ source: Oc }))
|
|
4934
4934
|
})),
|
|
4935
|
-
notification:
|
|
4935
|
+
notification: L({
|
|
4936
4936
|
taskId: Y,
|
|
4937
4937
|
messageHandle: Y,
|
|
4938
4938
|
inputs: z(Y, Dc)
|
|
@@ -4941,10 +4941,10 @@ var Y = j(), X = Is(), gc = F(Y), _c = I({
|
|
|
4941
4941
|
])
|
|
4942
4942
|
}), Ac = {
|
|
4943
4943
|
input: Z,
|
|
4944
|
-
cases:
|
|
4944
|
+
cases: I(L({
|
|
4945
4945
|
output: Y,
|
|
4946
4946
|
relation: B(["all", "any"]),
|
|
4947
|
-
expressions:
|
|
4947
|
+
expressions: I(L({
|
|
4948
4948
|
input: Y,
|
|
4949
4949
|
operator: B([
|
|
4950
4950
|
"!=",
|
|
@@ -4975,14 +4975,14 @@ var Y = j(), X = Is(), gc = F(Y), _c = I({
|
|
|
4975
4975
|
}, jc = {
|
|
4976
4976
|
actions: R([ss([V("continue")]), ss([V("approve"), V("reject")])]),
|
|
4977
4977
|
prompt: Y,
|
|
4978
|
-
notification:
|
|
4978
|
+
notification: L({
|
|
4979
4979
|
inputs: Cc,
|
|
4980
4980
|
messageHandle: Y,
|
|
4981
4981
|
taskId: Y
|
|
4982
4982
|
}).optional()
|
|
4983
4983
|
}, Mc = {
|
|
4984
|
-
inputsDef:
|
|
4985
|
-
options:
|
|
4984
|
+
inputsDef: I(Z),
|
|
4985
|
+
options: L({
|
|
4986
4986
|
allowedMethods: gc.optional(),
|
|
4987
4987
|
allowedOrigins: gc.optional(),
|
|
4988
4988
|
noResponseBody: P().optional(),
|
|
@@ -4990,11 +4990,11 @@ var Y = j(), X = Is(), gc = F(Y), _c = I({
|
|
|
4990
4990
|
responseHeaders: z(Y, Y).optional(),
|
|
4991
4991
|
responseStatusCode: N().optional()
|
|
4992
4992
|
}).optional()
|
|
4993
|
-
}, Nc =
|
|
4993
|
+
}, Nc = I(R([L({
|
|
4994
4994
|
type: V("cron"),
|
|
4995
4995
|
expression: Y,
|
|
4996
4996
|
timezone: Y
|
|
4997
|
-
}),
|
|
4997
|
+
}), L({
|
|
4998
4998
|
type: V("every"),
|
|
4999
4999
|
unit: B([
|
|
5000
5000
|
"day",
|
|
@@ -5013,18 +5013,18 @@ var Y = j(), X = Is(), gc = F(Y), _c = I({
|
|
|
5013
5013
|
name: Y,
|
|
5014
5014
|
payloadSchema: X,
|
|
5015
5015
|
provider: Y
|
|
5016
|
-
}, Fc =
|
|
5017
|
-
body:
|
|
5016
|
+
}, Fc = L({
|
|
5017
|
+
body: L({
|
|
5018
5018
|
allowArray: P(),
|
|
5019
5019
|
allowEmpty: P(),
|
|
5020
|
-
formats:
|
|
5020
|
+
formats: I(B([
|
|
5021
5021
|
"form",
|
|
5022
5022
|
"json",
|
|
5023
5023
|
"multipart",
|
|
5024
5024
|
"text"
|
|
5025
5025
|
]))
|
|
5026
5026
|
}),
|
|
5027
|
-
methods:
|
|
5027
|
+
methods: I(B([
|
|
5028
5028
|
"DELETE",
|
|
5029
5029
|
"GET",
|
|
5030
5030
|
"HEAD",
|
|
@@ -5044,106 +5044,106 @@ var Y = j(), X = Is(), gc = F(Y), _c = I({
|
|
|
5044
5044
|
icon: Y.optional(),
|
|
5045
5045
|
timeoutMs: N().optional()
|
|
5046
5046
|
}, Rc = R([
|
|
5047
|
-
|
|
5047
|
+
L({
|
|
5048
5048
|
...Lc,
|
|
5049
5049
|
kind: V("condition"),
|
|
5050
5050
|
...Ac
|
|
5051
5051
|
}),
|
|
5052
|
-
|
|
5052
|
+
L({
|
|
5053
5053
|
...Lc,
|
|
5054
|
-
inputs:
|
|
5054
|
+
inputs: F().transform(() => ({})).default({}),
|
|
5055
5055
|
kind: V("value"),
|
|
5056
|
-
values:
|
|
5056
|
+
values: I(Z)
|
|
5057
5057
|
}),
|
|
5058
|
-
|
|
5058
|
+
L({
|
|
5059
5059
|
...Lc,
|
|
5060
5060
|
kind: V("subflow"),
|
|
5061
5061
|
subflowId: Y
|
|
5062
5062
|
}),
|
|
5063
|
-
|
|
5063
|
+
L({
|
|
5064
5064
|
...Lc,
|
|
5065
5065
|
kind: V("task"),
|
|
5066
5066
|
task: Ec,
|
|
5067
|
-
additionalInputs:
|
|
5067
|
+
additionalInputs: I(Z).optional()
|
|
5068
5068
|
}),
|
|
5069
|
-
|
|
5069
|
+
L({
|
|
5070
5070
|
...Lc,
|
|
5071
5071
|
kind: V("task"),
|
|
5072
5072
|
taskId: Y,
|
|
5073
|
-
additionalInputs:
|
|
5073
|
+
additionalInputs: I(Z).optional()
|
|
5074
5074
|
}),
|
|
5075
|
-
|
|
5075
|
+
L({
|
|
5076
5076
|
...Lc,
|
|
5077
5077
|
kind: V("wait"),
|
|
5078
5078
|
input: Z,
|
|
5079
5079
|
...jc
|
|
5080
5080
|
}).omit({ timeoutMs: !0 }),
|
|
5081
|
-
|
|
5081
|
+
L({
|
|
5082
5082
|
...Ic,
|
|
5083
5083
|
kind: V("manual")
|
|
5084
5084
|
}),
|
|
5085
|
-
|
|
5085
|
+
L({
|
|
5086
5086
|
...Ic,
|
|
5087
5087
|
kind: V("webhook"),
|
|
5088
5088
|
...Mc
|
|
5089
5089
|
}),
|
|
5090
|
-
|
|
5090
|
+
L({
|
|
5091
5091
|
...Ic,
|
|
5092
5092
|
kind: V("cron"),
|
|
5093
5093
|
cronTimes: Nc
|
|
5094
5094
|
}),
|
|
5095
|
-
|
|
5095
|
+
L({
|
|
5096
5096
|
...Ic,
|
|
5097
5097
|
kind: V("poll"),
|
|
5098
5098
|
bindingId: Y,
|
|
5099
5099
|
config: z(Y, X),
|
|
5100
|
-
definition:
|
|
5100
|
+
definition: L({
|
|
5101
5101
|
...Pc,
|
|
5102
5102
|
type: V("poll")
|
|
5103
5103
|
}),
|
|
5104
5104
|
pollTimes: Nc
|
|
5105
5105
|
}),
|
|
5106
|
-
|
|
5106
|
+
L({
|
|
5107
5107
|
...Ic,
|
|
5108
5108
|
kind: V("integration"),
|
|
5109
5109
|
bindingId: Y,
|
|
5110
5110
|
config: z(Y, X),
|
|
5111
|
-
definition:
|
|
5111
|
+
definition: L({
|
|
5112
5112
|
...Pc,
|
|
5113
5113
|
type: V("integration"),
|
|
5114
5114
|
endpoint: Fc
|
|
5115
5115
|
})
|
|
5116
5116
|
})
|
|
5117
|
-
]), zc = R([
|
|
5117
|
+
]), zc = R([L({ kind: V("flow") }), L({
|
|
5118
5118
|
kind: V("subflow"),
|
|
5119
5119
|
id: Y
|
|
5120
|
-
})]), Bc =
|
|
5120
|
+
})]), Bc = L({
|
|
5121
5121
|
source: Y,
|
|
5122
5122
|
target: Y,
|
|
5123
5123
|
sourceHandle: Y.optional()
|
|
5124
5124
|
}), Q = {
|
|
5125
5125
|
nodeId: Y,
|
|
5126
5126
|
target: zc
|
|
5127
|
-
}, Vc =
|
|
5127
|
+
}, Vc = L({
|
|
5128
5128
|
name: Y,
|
|
5129
|
-
inputs:
|
|
5130
|
-
outputs:
|
|
5131
|
-
}), Hc =
|
|
5129
|
+
inputs: I(Z),
|
|
5130
|
+
outputs: I(_c.extend({ sources: I(R([yc, bc])) }))
|
|
5131
|
+
}), Hc = L({
|
|
5132
5132
|
nodes: z(Y, Rc),
|
|
5133
|
-
edges:
|
|
5134
|
-
}), Uc =
|
|
5133
|
+
edges: I(Bc).default([])
|
|
5134
|
+
}), Uc = L({
|
|
5135
5135
|
kind: B(["connection", "variable"]),
|
|
5136
5136
|
target: Y
|
|
5137
|
-
}), Wc =
|
|
5137
|
+
}), Wc = L({
|
|
5138
5138
|
name: Y,
|
|
5139
5139
|
imports: gc,
|
|
5140
5140
|
source: Y
|
|
5141
|
-
}), Gc =
|
|
5141
|
+
}), Gc = L({
|
|
5142
5142
|
bindings: z(Y, Uc),
|
|
5143
5143
|
graph: Hc,
|
|
5144
5144
|
subflows: z(Y, Vc.extend({ graph: Hc })),
|
|
5145
5145
|
tasks: z(Y, kc)
|
|
5146
|
-
}), Kc =
|
|
5146
|
+
}), Kc = L({
|
|
5147
5147
|
modelVersion: V(1),
|
|
5148
5148
|
document: Gc,
|
|
5149
5149
|
modules: z(Y, Wc)
|
|
@@ -5179,7 +5179,7 @@ var Jc = {
|
|
|
5179
5179
|
node: Rc
|
|
5180
5180
|
},
|
|
5181
5181
|
"graph.node.delete": Q,
|
|
5182
|
-
"graph.node.field.set": R([
|
|
5182
|
+
"graph.node.field.set": R([L({
|
|
5183
5183
|
...Q,
|
|
5184
5184
|
kind: V("graph.node.field.set"),
|
|
5185
5185
|
field: B([
|
|
@@ -5189,7 +5189,7 @@ var Jc = {
|
|
|
5189
5189
|
]),
|
|
5190
5190
|
before: Y.optional(),
|
|
5191
5191
|
value: Y.optional()
|
|
5192
|
-
}),
|
|
5192
|
+
}), L({
|
|
5193
5193
|
...Q,
|
|
5194
5194
|
kind: V("graph.node.field.set"),
|
|
5195
5195
|
field: V("timeoutMs"),
|
|
@@ -5204,35 +5204,35 @@ var Jc = {
|
|
|
5204
5204
|
},
|
|
5205
5205
|
"graph.node.additional-inputs.set": {
|
|
5206
5206
|
...Q,
|
|
5207
|
-
before:
|
|
5208
|
-
value:
|
|
5207
|
+
before: I(Z).optional(),
|
|
5208
|
+
value: I(Z).optional()
|
|
5209
5209
|
},
|
|
5210
5210
|
"graph.node.condition.set": {
|
|
5211
5211
|
...Q,
|
|
5212
|
-
before:
|
|
5213
|
-
value:
|
|
5212
|
+
before: L(Ac),
|
|
5213
|
+
value: L(Ac)
|
|
5214
5214
|
},
|
|
5215
5215
|
"graph.node.values.set": {
|
|
5216
5216
|
...Q,
|
|
5217
|
-
before:
|
|
5218
|
-
value:
|
|
5217
|
+
before: I(Z),
|
|
5218
|
+
value: I(Z)
|
|
5219
5219
|
},
|
|
5220
5220
|
"graph.node.wait.set": {
|
|
5221
5221
|
...Q,
|
|
5222
|
-
target:
|
|
5223
|
-
before:
|
|
5224
|
-
value:
|
|
5222
|
+
target: L({ kind: V("flow") }),
|
|
5223
|
+
before: L(jc),
|
|
5224
|
+
value: L(jc)
|
|
5225
5225
|
},
|
|
5226
5226
|
"graph.node.webhook.set": {
|
|
5227
5227
|
...Q,
|
|
5228
|
-
target:
|
|
5229
|
-
before:
|
|
5230
|
-
value:
|
|
5228
|
+
target: L({ kind: V("flow") }),
|
|
5229
|
+
before: L(Mc),
|
|
5230
|
+
value: L(Mc)
|
|
5231
5231
|
},
|
|
5232
5232
|
"graph.node.task.ports.set": {
|
|
5233
5233
|
...Q,
|
|
5234
|
-
before:
|
|
5235
|
-
value:
|
|
5234
|
+
before: L(wc),
|
|
5235
|
+
value: L(wc)
|
|
5236
5236
|
},
|
|
5237
5237
|
"graph.node.task.name.set": {
|
|
5238
5238
|
...Q,
|
|
@@ -5241,8 +5241,8 @@ var Jc = {
|
|
|
5241
5241
|
},
|
|
5242
5242
|
"graph.node.task.capabilities.set": {
|
|
5243
5243
|
...Q,
|
|
5244
|
-
before:
|
|
5245
|
-
value:
|
|
5244
|
+
before: I(Tc).optional(),
|
|
5245
|
+
value: I(Tc).optional()
|
|
5246
5246
|
},
|
|
5247
5247
|
"graph.trigger.config.set": {
|
|
5248
5248
|
nodeId: Y,
|
|
@@ -5308,13 +5308,74 @@ var Jc = {
|
|
|
5308
5308
|
value: Y
|
|
5309
5309
|
}
|
|
5310
5310
|
};
|
|
5311
|
-
|
|
5311
|
+
I(R([...new Map(Object.entries(Jc).map(([e, t]) => [e, t instanceof A ? t : L({
|
|
5312
5312
|
kind: V(e),
|
|
5313
5313
|
...t
|
|
5314
5314
|
})])).values()])).min(1), new TextEncoder();
|
|
5315
|
+
var Yc = z(j(), F()), Xc = L({
|
|
5316
|
+
jsonSchema: F(),
|
|
5317
|
+
nullable: P(),
|
|
5318
|
+
value: F().optional(),
|
|
5319
|
+
description: j().optional()
|
|
5320
|
+
}).strict(), Zc = z(j(), Xc), Qc = R([L({
|
|
5321
|
+
kind: V("value"),
|
|
5322
|
+
value: F()
|
|
5323
|
+
}).strict(), L({
|
|
5324
|
+
kind: V("sources"),
|
|
5325
|
+
sources: I(L({
|
|
5326
|
+
kind: V("node"),
|
|
5327
|
+
nodeId: j(),
|
|
5328
|
+
output: j()
|
|
5329
|
+
}).strict())
|
|
5330
|
+
}).strict()]), $c = {
|
|
5331
|
+
name: j().optional(),
|
|
5332
|
+
description: j().optional(),
|
|
5333
|
+
icon: j().optional()
|
|
5334
|
+
}, el = R([
|
|
5335
|
+
L({
|
|
5336
|
+
...$c,
|
|
5337
|
+
kind: V("cron"),
|
|
5338
|
+
cronTimes: I(F())
|
|
5339
|
+
}).strict(),
|
|
5340
|
+
L({
|
|
5341
|
+
...$c,
|
|
5342
|
+
kind: V("manual")
|
|
5343
|
+
}).strict(),
|
|
5344
|
+
L({
|
|
5345
|
+
...$c,
|
|
5346
|
+
kind: V("task"),
|
|
5347
|
+
concurrency: V(1).optional(),
|
|
5348
|
+
inputs: z(j(), Qc),
|
|
5349
|
+
task: L({
|
|
5350
|
+
name: j(),
|
|
5351
|
+
moduleId: j(),
|
|
5352
|
+
inputs: Zc,
|
|
5353
|
+
outputs: z(j(), Xc.omit({ value: !0 }))
|
|
5354
|
+
}).strict()
|
|
5355
|
+
}).strict()
|
|
5356
|
+
]);
|
|
5357
|
+
L({
|
|
5358
|
+
name: j(),
|
|
5359
|
+
graph: L({ nodes: z(j(), el) }).strict()
|
|
5360
|
+
}).strict(), L({
|
|
5361
|
+
kind: V("open-flow-project-revision"),
|
|
5362
|
+
version: V(1),
|
|
5363
|
+
modelVersion: V(1),
|
|
5364
|
+
modules: z(j(), L({
|
|
5365
|
+
name: j(),
|
|
5366
|
+
source: j(),
|
|
5367
|
+
imports: I(j())
|
|
5368
|
+
}).strict()),
|
|
5369
|
+
document: L({
|
|
5370
|
+
bindings: Yc,
|
|
5371
|
+
flows: Yc,
|
|
5372
|
+
subflows: Yc,
|
|
5373
|
+
tasks: Yc
|
|
5374
|
+
}).strict()
|
|
5375
|
+
}).strict();
|
|
5315
5376
|
//#endregion
|
|
5316
5377
|
//#region src/control/common/revisionDecoders.ts
|
|
5317
|
-
function
|
|
5378
|
+
function tl(e) {
|
|
5318
5379
|
let t = W(e), n = t.parentRevisionId;
|
|
5319
5380
|
return t.version != 1 || n !== null && typeof n != "string" ? U() : {
|
|
5320
5381
|
actorId: G(t.actorId),
|
|
@@ -5327,18 +5388,18 @@ function Yc(e) {
|
|
|
5327
5388
|
version: 1
|
|
5328
5389
|
};
|
|
5329
5390
|
}
|
|
5330
|
-
function
|
|
5391
|
+
function nl(e) {
|
|
5331
5392
|
let t = W(e);
|
|
5332
5393
|
try {
|
|
5333
5394
|
return {
|
|
5334
|
-
...
|
|
5395
|
+
...tl(t),
|
|
5335
5396
|
content: qc(t.content)
|
|
5336
5397
|
};
|
|
5337
5398
|
} catch {
|
|
5338
5399
|
return U();
|
|
5339
5400
|
}
|
|
5340
5401
|
}
|
|
5341
|
-
function
|
|
5402
|
+
function rl(e) {
|
|
5342
5403
|
let t = W(e);
|
|
5343
5404
|
return K(t, [
|
|
5344
5405
|
"revision",
|
|
@@ -5352,24 +5413,24 @@ function Zc(e) {
|
|
|
5352
5413
|
version: 1
|
|
5353
5414
|
};
|
|
5354
5415
|
}
|
|
5355
|
-
function
|
|
5416
|
+
function il(e) {
|
|
5356
5417
|
let t = W(e);
|
|
5357
5418
|
return t.version == 1 ? {
|
|
5358
|
-
revision:
|
|
5419
|
+
revision: tl(t.revision),
|
|
5359
5420
|
version: 1
|
|
5360
5421
|
} : U();
|
|
5361
5422
|
}
|
|
5362
|
-
function
|
|
5423
|
+
function al(e) {
|
|
5363
5424
|
let t = W(e);
|
|
5364
5425
|
return t.version != 1 || t.kind != "snapshot" ? U() : {
|
|
5365
|
-
draft:
|
|
5426
|
+
draft: nl(t.draft),
|
|
5366
5427
|
kind: "snapshot",
|
|
5367
5428
|
version: 1
|
|
5368
5429
|
};
|
|
5369
5430
|
}
|
|
5370
5431
|
//#endregion
|
|
5371
5432
|
//#region src/control/common/runDecoders.ts
|
|
5372
|
-
var
|
|
5433
|
+
var ol = /* @__PURE__ */ new Set([
|
|
5373
5434
|
"canceled",
|
|
5374
5435
|
"completed",
|
|
5375
5436
|
"failed",
|
|
@@ -5379,10 +5440,10 @@ var el = /* @__PURE__ */ new Set([
|
|
|
5379
5440
|
"starting",
|
|
5380
5441
|
"waiting"
|
|
5381
5442
|
]);
|
|
5382
|
-
function
|
|
5383
|
-
return typeof e == "string" &&
|
|
5443
|
+
function sl(e) {
|
|
5444
|
+
return typeof e == "string" && ol.has(e) ? e : U();
|
|
5384
5445
|
}
|
|
5385
|
-
function
|
|
5446
|
+
function cl(e) {
|
|
5386
5447
|
let t = W(e), n = t.source, r = t.startedAt, i = t.finishedAt;
|
|
5387
5448
|
return t.version != 1 || n != "draft" && n != "live" && n != "trigger" || r != null && typeof r != "string" || i != null && typeof i != "string" ? U() : {
|
|
5388
5449
|
createdAt: G(t.createdAt),
|
|
@@ -5392,11 +5453,11 @@ function nl(e) {
|
|
|
5392
5453
|
runId: G(t.runId),
|
|
5393
5454
|
source: n,
|
|
5394
5455
|
...r == null ? {} : { startedAt: r },
|
|
5395
|
-
status:
|
|
5456
|
+
status: sl(t.status),
|
|
5396
5457
|
version: 1
|
|
5397
5458
|
};
|
|
5398
5459
|
}
|
|
5399
|
-
function
|
|
5460
|
+
function ll(e) {
|
|
5400
5461
|
let t = W(e);
|
|
5401
5462
|
K(t, [
|
|
5402
5463
|
"actions",
|
|
@@ -5416,12 +5477,12 @@ function rl(e) {
|
|
|
5416
5477
|
waitingSince: G(t.waitingSince)
|
|
5417
5478
|
};
|
|
5418
5479
|
}
|
|
5419
|
-
function
|
|
5420
|
-
let t = W(e), n =
|
|
5480
|
+
function ul(e) {
|
|
5481
|
+
let t = W(e), n = cl(t), r = t.eventsExpiresAt;
|
|
5421
5482
|
if (r != null && typeof r != "string" || n.status != "waiting" && t.waiting !== void 0) return U();
|
|
5422
5483
|
let i = n.status == "waiting" ? {
|
|
5423
5484
|
status: "waiting",
|
|
5424
|
-
waiting:
|
|
5485
|
+
waiting: ll(t.waiting)
|
|
5425
5486
|
} : { status: n.status }, a = {
|
|
5426
5487
|
...n,
|
|
5427
5488
|
closureDigest: G(t.closureDigest),
|
|
@@ -5451,17 +5512,17 @@ function il(e) {
|
|
|
5451
5512
|
};
|
|
5452
5513
|
}
|
|
5453
5514
|
}
|
|
5454
|
-
function
|
|
5515
|
+
function dl(e) {
|
|
5455
5516
|
let t = W(e), n = t.nextCursor;
|
|
5456
5517
|
return t.version != 1 || !Array.isArray(t.runs) || n != null && typeof n != "string" ? U() : {
|
|
5457
5518
|
flowId: G(t.flowId),
|
|
5458
5519
|
...n == null ? {} : { nextCursor: n },
|
|
5459
|
-
runs: t.runs.map(
|
|
5520
|
+
runs: t.runs.map(cl),
|
|
5460
5521
|
version: 1
|
|
5461
5522
|
};
|
|
5462
5523
|
}
|
|
5463
|
-
function
|
|
5464
|
-
let t = W(e), n =
|
|
5524
|
+
function fl(e) {
|
|
5525
|
+
let t = W(e), n = sl(t.status);
|
|
5465
5526
|
return t.version != 1 || typeof t.cancelAccepted != "boolean" || n == "queued" || n == "starting" || n == "running" || n == "waiting" ? U() : {
|
|
5466
5527
|
cancelAccepted: t.cancelAccepted,
|
|
5467
5528
|
runId: G(t.runId),
|
|
@@ -5469,7 +5530,7 @@ function ol(e) {
|
|
|
5469
5530
|
version: 1
|
|
5470
5531
|
};
|
|
5471
5532
|
}
|
|
5472
|
-
function
|
|
5533
|
+
function pl(e) {
|
|
5473
5534
|
let t = W(e);
|
|
5474
5535
|
K(t, [
|
|
5475
5536
|
"action",
|
|
@@ -5486,12 +5547,12 @@ function sl(e) {
|
|
|
5486
5547
|
resolutionAccepted: t.resolutionAccepted,
|
|
5487
5548
|
resolvedAt: r,
|
|
5488
5549
|
runId: G(t.runId),
|
|
5489
|
-
status:
|
|
5550
|
+
status: sl(t.status),
|
|
5490
5551
|
version: 1,
|
|
5491
5552
|
waitId: G(t.waitId)
|
|
5492
5553
|
};
|
|
5493
5554
|
}
|
|
5494
|
-
function
|
|
5555
|
+
function ml(e) {
|
|
5495
5556
|
let t = W(e), n = t.status;
|
|
5496
5557
|
if (t.version != 1) return U();
|
|
5497
5558
|
let r = {
|
|
@@ -5534,7 +5595,7 @@ function cl(e) {
|
|
|
5534
5595
|
}
|
|
5535
5596
|
//#endregion
|
|
5536
5597
|
//#region src/control/common/triggerDecoders.ts
|
|
5537
|
-
function
|
|
5598
|
+
function hl(e) {
|
|
5538
5599
|
let t = W(e), n = t.type;
|
|
5539
5600
|
return n != "integration" && n != "poll" ? U() : {
|
|
5540
5601
|
description: typeof t.description == "string" ? t.description : U(),
|
|
@@ -5545,8 +5606,8 @@ function ll(e) {
|
|
|
5545
5606
|
type: n
|
|
5546
5607
|
};
|
|
5547
5608
|
}
|
|
5548
|
-
function
|
|
5549
|
-
let t = W(e), n =
|
|
5609
|
+
function gl(e) {
|
|
5610
|
+
let t = W(e), n = hl(t), r = {
|
|
5550
5611
|
configSchema: J(t.configSchema),
|
|
5551
5612
|
definitionVersion: q(t.definitionVersion),
|
|
5552
5613
|
description: n.description,
|
|
@@ -5589,18 +5650,18 @@ function ul(e) {
|
|
|
5589
5650
|
type: "integration"
|
|
5590
5651
|
};
|
|
5591
5652
|
}
|
|
5592
|
-
var
|
|
5653
|
+
var _l = /* @__PURE__ */ new Set([
|
|
5593
5654
|
"cron",
|
|
5594
5655
|
"integration",
|
|
5595
5656
|
"poll",
|
|
5596
5657
|
"webhook"
|
|
5597
|
-
]),
|
|
5658
|
+
]), vl = /* @__PURE__ */ new Set([
|
|
5598
5659
|
"failed",
|
|
5599
5660
|
"healthy",
|
|
5600
5661
|
"initializing",
|
|
5601
5662
|
"needs_reauth",
|
|
5602
5663
|
"suspended"
|
|
5603
|
-
]),
|
|
5664
|
+
]), yl = /* @__PURE__ */ new Set([
|
|
5604
5665
|
"delivery.failed",
|
|
5605
5666
|
"health.failed",
|
|
5606
5667
|
"health.needs_reauth",
|
|
@@ -5609,11 +5670,11 @@ var dl = /* @__PURE__ */ new Set([
|
|
|
5609
5670
|
"operator.paused",
|
|
5610
5671
|
"operator.resumed"
|
|
5611
5672
|
]);
|
|
5612
|
-
function
|
|
5673
|
+
function bl(e) {
|
|
5613
5674
|
let t = W(e), n = t.health, r = t.listener == null ? void 0 : W(t.listener);
|
|
5614
5675
|
if (r != null && r.health != "healthy" && r.health != "failed" && r.health != "needs_reauth") return U();
|
|
5615
5676
|
let i = t.kind, a = t.operatorState, o = q(t.runtimeVersion);
|
|
5616
|
-
return t.version != 1 || typeof n != "string" || !
|
|
5677
|
+
return t.version != 1 || typeof n != "string" || !vl.has(n) || typeof i != "string" || !_l.has(i) || a != "active" && a != "paused" || o <= 0 ? U() : {
|
|
5617
5678
|
...t.currentPublicationId == null ? {} : { currentPublicationId: G(t.currentPublicationId) },
|
|
5618
5679
|
...t.currentRevisionId == null ? {} : { currentRevisionId: G(t.currentRevisionId) },
|
|
5619
5680
|
...t.endpointUrl == null ? {} : { endpointUrl: G(t.endpointUrl) },
|
|
@@ -5632,16 +5693,16 @@ function ml(e) {
|
|
|
5632
5693
|
version: 1
|
|
5633
5694
|
};
|
|
5634
5695
|
}
|
|
5635
|
-
function
|
|
5696
|
+
function xl(e) {
|
|
5636
5697
|
let t = W(e);
|
|
5637
5698
|
return t.version == 1 ? {
|
|
5638
|
-
binding:
|
|
5699
|
+
binding: bl(t.binding),
|
|
5639
5700
|
version: 1
|
|
5640
5701
|
} : U();
|
|
5641
5702
|
}
|
|
5642
|
-
function
|
|
5703
|
+
function Sl(e) {
|
|
5643
5704
|
let t = W(e), n = t.kind;
|
|
5644
|
-
if (typeof n != "string" || !
|
|
5705
|
+
if (typeof n != "string" || !yl.has(n)) return U();
|
|
5645
5706
|
let r = $s(t.errorCode), i = $s(t.errorMessage);
|
|
5646
5707
|
return i != null && i.length > 512 ? U() : {
|
|
5647
5708
|
activityId: G(t.activityId),
|
|
@@ -5651,15 +5712,15 @@ function gl(e) {
|
|
|
5651
5712
|
kind: n
|
|
5652
5713
|
};
|
|
5653
5714
|
}
|
|
5654
|
-
function
|
|
5715
|
+
function Cl(e) {
|
|
5655
5716
|
let t = W(e), n = $s(t.nextCursor);
|
|
5656
5717
|
return t.version != 1 || !Array.isArray(t.activities) ? U() : {
|
|
5657
|
-
activities: t.activities.map(
|
|
5718
|
+
activities: t.activities.map(Sl),
|
|
5658
5719
|
...n == null ? {} : { nextCursor: n },
|
|
5659
5720
|
version: 1
|
|
5660
5721
|
};
|
|
5661
5722
|
}
|
|
5662
|
-
function
|
|
5723
|
+
function wl(e) {
|
|
5663
5724
|
let t = W(e), n = q(t.filtered);
|
|
5664
5725
|
return t.version != 1 || !Array.isArray(t.events) || typeof t.hasMore != "boolean" || n < 0 ? U() : {
|
|
5665
5726
|
events: t.events.map((e) => {
|
|
@@ -5673,7 +5734,7 @@ function vl(e) {
|
|
|
5673
5734
|
}
|
|
5674
5735
|
//#endregion
|
|
5675
5736
|
//#region src/control/common/random.ts
|
|
5676
|
-
function
|
|
5737
|
+
function Tl() {
|
|
5677
5738
|
let e = globalThis.crypto;
|
|
5678
5739
|
if (e != null) {
|
|
5679
5740
|
try {
|
|
@@ -5690,7 +5751,7 @@ function yl() {
|
|
|
5690
5751
|
}
|
|
5691
5752
|
//#endregion
|
|
5692
5753
|
//#region src/control/common/api.ts
|
|
5693
|
-
function
|
|
5754
|
+
function El(e) {
|
|
5694
5755
|
let t = W(e), n = q(t.sequence);
|
|
5695
5756
|
if (n < 0) return U();
|
|
5696
5757
|
let r = {
|
|
@@ -5718,7 +5779,7 @@ function bl(e) {
|
|
|
5718
5779
|
payload: {
|
|
5719
5780
|
flowId: G(i.flowId),
|
|
5720
5781
|
scopeId: G(i.scopeId),
|
|
5721
|
-
progress:
|
|
5782
|
+
progress: Dl(i.progress)
|
|
5722
5783
|
}
|
|
5723
5784
|
};
|
|
5724
5785
|
case "run.waiting": return {
|
|
@@ -5821,7 +5882,7 @@ function bl(e) {
|
|
|
5821
5882
|
kind: a,
|
|
5822
5883
|
payload: {
|
|
5823
5884
|
...e,
|
|
5824
|
-
progress:
|
|
5885
|
+
progress: Dl(i.progress)
|
|
5825
5886
|
}
|
|
5826
5887
|
};
|
|
5827
5888
|
case "node.artifact": {
|
|
@@ -5847,14 +5908,14 @@ function bl(e) {
|
|
|
5847
5908
|
default: return U();
|
|
5848
5909
|
}
|
|
5849
5910
|
}
|
|
5850
|
-
function
|
|
5911
|
+
function Dl(e) {
|
|
5851
5912
|
return typeof e == "number" && Number.isFinite(e) && e >= 0 && e <= 100 ? e : U();
|
|
5852
5913
|
}
|
|
5853
|
-
function
|
|
5914
|
+
function Ol(e) {
|
|
5854
5915
|
let t = W(e), n = t.eventsExpiresAt, r = q(t.nextAfter);
|
|
5855
5916
|
return t.version != 1 || !Array.isArray(t.events) || typeof t.done != "boolean" || typeof t.historyComplete != "boolean" || n != null && typeof n != "string" || r < 0 ? U() : {
|
|
5856
5917
|
done: t.done,
|
|
5857
|
-
events: t.events.map(
|
|
5918
|
+
events: t.events.map(El),
|
|
5858
5919
|
...n == null ? {} : { eventsExpiresAt: n },
|
|
5859
5920
|
historyComplete: t.historyComplete,
|
|
5860
5921
|
nextAfter: r,
|
|
@@ -5863,10 +5924,10 @@ function Sl(e) {
|
|
|
5863
5924
|
};
|
|
5864
5925
|
}
|
|
5865
5926
|
var $ = encodeURIComponent;
|
|
5866
|
-
function
|
|
5867
|
-
return `${e}-${
|
|
5927
|
+
function kl(e) {
|
|
5928
|
+
return `${e}-${Tl()}`;
|
|
5868
5929
|
}
|
|
5869
|
-
var
|
|
5930
|
+
var Al = class {
|
|
5870
5931
|
constructor(e) {
|
|
5871
5932
|
this.requestControl = e;
|
|
5872
5933
|
}
|
|
@@ -5896,7 +5957,7 @@ var wl = class {
|
|
|
5896
5957
|
let t = W(await this.request(`/v1/variables/${$(e)}`, { method: "DELETE" }));
|
|
5897
5958
|
if (K(t, ["version"]), t.version != 1) return U();
|
|
5898
5959
|
}
|
|
5899
|
-
async createFlow(e, t = `flow-${
|
|
5960
|
+
async createFlow(e, t = `flow-${Tl()}`) {
|
|
5900
5961
|
return cc(await this.request("/v1/flows", {
|
|
5901
5962
|
body: JSON.stringify({
|
|
5902
5963
|
name: e,
|
|
@@ -5923,43 +5984,43 @@ var wl = class {
|
|
|
5923
5984
|
}
|
|
5924
5985
|
async listTriggerKeys(e) {
|
|
5925
5986
|
let t = W(await this.request("/v1/trigger-keys", { signal: e }));
|
|
5926
|
-
return t.version != 1 || !Array.isArray(t.keys) ? U() : t.keys.map(
|
|
5987
|
+
return t.version != 1 || !Array.isArray(t.keys) ? U() : t.keys.map(hl);
|
|
5927
5988
|
}
|
|
5928
5989
|
async listTriggerDefinitions(e) {
|
|
5929
5990
|
let t = W(await this.request("/v1/trigger-keys/catalog", { signal: e }));
|
|
5930
|
-
return t.version != 1 || !Array.isArray(t.definitions) ? U() : t.definitions.map(
|
|
5991
|
+
return t.version != 1 || !Array.isArray(t.definitions) ? U() : t.definitions.map(gl);
|
|
5931
5992
|
}
|
|
5932
5993
|
async getTriggerKey(e, t) {
|
|
5933
5994
|
let n = W(await this.request(`/v1/trigger-keys/${$(e)}`, { signal: t }));
|
|
5934
|
-
return n.version == 1 ?
|
|
5995
|
+
return n.version == 1 ? gl(n.definition) : U();
|
|
5935
5996
|
}
|
|
5936
5997
|
async listFlowTriggerBindings(e, t) {
|
|
5937
5998
|
let n = W(await this.request(`/v1/flows/${$(e)}/triggers`, { signal: t }));
|
|
5938
|
-
return n.version != 1 || G(n.flowId) != e || !Array.isArray(n.bindings) ? U() : n.bindings.map(
|
|
5999
|
+
return n.version != 1 || G(n.flowId) != e || !Array.isArray(n.bindings) ? U() : n.bindings.map(bl);
|
|
5939
6000
|
}
|
|
5940
6001
|
async getFlowTriggerBinding(e, t) {
|
|
5941
|
-
return
|
|
6002
|
+
return xl(await this.request(`/v1/flows/${$(e)}/triggers/${$(t)}`));
|
|
5942
6003
|
}
|
|
5943
6004
|
async listFlowTriggerActivities(e, t, n = {}) {
|
|
5944
6005
|
let r = new URLSearchParams();
|
|
5945
6006
|
n.cursor != null && r.set("cursor", n.cursor), n.limit != null && r.set("limit", String(n.limit));
|
|
5946
6007
|
let i = r.size == 0 ? "" : `?${r}`;
|
|
5947
|
-
return
|
|
6008
|
+
return Cl(await this.request(`/v1/flows/${$(e)}/triggers/${$(t)}/activities${i}`));
|
|
5948
6009
|
}
|
|
5949
6010
|
async pauseFlowTrigger(e, t) {
|
|
5950
|
-
return
|
|
6011
|
+
return bl(await this.request(`/v1/flows/${$(e)}/triggers/${$(t)}/pause`, {
|
|
5951
6012
|
body: JSON.stringify({ version: 1 }),
|
|
5952
6013
|
method: "POST"
|
|
5953
6014
|
}));
|
|
5954
6015
|
}
|
|
5955
6016
|
async resumeFlowTrigger(e, t) {
|
|
5956
|
-
return
|
|
6017
|
+
return bl(await this.request(`/v1/flows/${$(e)}/triggers/${$(t)}/resume`, {
|
|
5957
6018
|
body: JSON.stringify({ version: 1 }),
|
|
5958
6019
|
method: "POST"
|
|
5959
6020
|
}));
|
|
5960
6021
|
}
|
|
5961
6022
|
async testFlowPollTrigger(e, t) {
|
|
5962
|
-
return
|
|
6023
|
+
return wl(await this.request(`/v1/flows/${$(e)}/triggers/${$(t)}/test`, {
|
|
5963
6024
|
body: JSON.stringify({ version: 1 }),
|
|
5964
6025
|
method: "POST"
|
|
5965
6026
|
}));
|
|
@@ -5975,24 +6036,24 @@ var wl = class {
|
|
|
5975
6036
|
]), t.version != 1) return U();
|
|
5976
6037
|
let n = {
|
|
5977
6038
|
flow: cc(t.flow),
|
|
5978
|
-
draft:
|
|
6039
|
+
draft: nl(t.draft),
|
|
5979
6040
|
live: pc(t.live),
|
|
5980
|
-
presentation:
|
|
6041
|
+
presentation: rl(t.presentation),
|
|
5981
6042
|
version: 1
|
|
5982
6043
|
};
|
|
5983
6044
|
return n.flow.flowId != e || n.draft.flowId != e || n.live.flowId != e || n.flow.draftRevisionId != n.draft.revisionId ? U() : n;
|
|
5984
6045
|
}
|
|
5985
6046
|
async getPresentation(e) {
|
|
5986
|
-
return
|
|
6047
|
+
return rl(await this.request(`/v1/flows/${$(e)}/presentation`));
|
|
5987
6048
|
}
|
|
5988
6049
|
async getDraft(e) {
|
|
5989
|
-
return
|
|
6050
|
+
return nl(await this.request(`/v1/flows/${$(e)}/draft`));
|
|
5990
6051
|
}
|
|
5991
6052
|
async syncDraft(e) {
|
|
5992
|
-
return
|
|
6053
|
+
return al(await this.request(`/v1/flows/${$(e)}/draft/sync`));
|
|
5993
6054
|
}
|
|
5994
6055
|
async getRevision(e, t) {
|
|
5995
|
-
return
|
|
6056
|
+
return nl(await this.request(`/v1/flows/${$(e)}/revisions/${$(t)}`));
|
|
5996
6057
|
}
|
|
5997
6058
|
async listConnectorProviders(e, t) {
|
|
5998
6059
|
let n = W(await this.request(`/v1/connector/providers${t == null ? "" : `?flowId=${$(t)}`}`, { signal: e }));
|
|
@@ -6035,8 +6096,8 @@ var wl = class {
|
|
|
6035
6096
|
return U();
|
|
6036
6097
|
}
|
|
6037
6098
|
}
|
|
6038
|
-
async changeDraft(e, t, n, r =
|
|
6039
|
-
return
|
|
6099
|
+
async changeDraft(e, t, n, r = kl("change")) {
|
|
6100
|
+
return il(await this.request(`/v1/flows/${$(e)}/draft/changes`, {
|
|
6040
6101
|
body: JSON.stringify({
|
|
6041
6102
|
expectedRevisionId: t,
|
|
6042
6103
|
operations: n,
|
|
@@ -6065,27 +6126,27 @@ var wl = class {
|
|
|
6065
6126
|
return mc(await this.request(`/v1/flows/${$(e)}/publications${i}`, { signal: n }));
|
|
6066
6127
|
}
|
|
6067
6128
|
async createDraftRun(e, t, n) {
|
|
6068
|
-
let r =
|
|
6129
|
+
let r = ul(await this.request(`/v1/flows/${$(e)}/revisions/${$(t)}/runs`, {
|
|
6069
6130
|
body: JSON.stringify({
|
|
6070
6131
|
engineContract: "open-flow-engine/v2",
|
|
6071
6132
|
inputs: n.inputs ?? {},
|
|
6072
6133
|
trigger: n.trigger,
|
|
6073
6134
|
version: 1
|
|
6074
6135
|
}),
|
|
6075
|
-
headers: { "idempotency-key": n.idempotencyKey ??
|
|
6136
|
+
headers: { "idempotency-key": n.idempotencyKey ?? kl("run") },
|
|
6076
6137
|
method: "POST"
|
|
6077
6138
|
}));
|
|
6078
6139
|
return r.source == "draft" ? r : U();
|
|
6079
6140
|
}
|
|
6080
6141
|
async createLiveRun(e, t) {
|
|
6081
|
-
let n =
|
|
6142
|
+
let n = ul(await this.request("/v1/runs", {
|
|
6082
6143
|
body: JSON.stringify({
|
|
6083
6144
|
inputs: t.inputs ?? {},
|
|
6084
6145
|
trigger: t.trigger,
|
|
6085
6146
|
publicationId: e,
|
|
6086
6147
|
version: 1
|
|
6087
6148
|
}),
|
|
6088
|
-
headers: { "idempotency-key": t.idempotencyKey ??
|
|
6149
|
+
headers: { "idempotency-key": t.idempotencyKey ?? kl("run") },
|
|
6089
6150
|
method: "POST"
|
|
6090
6151
|
}));
|
|
6091
6152
|
return n.source == "live" ? n : U();
|
|
@@ -6107,7 +6168,7 @@ var wl = class {
|
|
|
6107
6168
|
expectedLivePublicationId: n,
|
|
6108
6169
|
version: 1
|
|
6109
6170
|
}),
|
|
6110
|
-
headers: { "idempotency-key": r.idempotencyKey ??
|
|
6171
|
+
headers: { "idempotency-key": r.idempotencyKey ?? kl("publication") },
|
|
6111
6172
|
method: "POST"
|
|
6112
6173
|
}));
|
|
6113
6174
|
}
|
|
@@ -6120,24 +6181,24 @@ var wl = class {
|
|
|
6120
6181
|
expectedLivePublicationId: n,
|
|
6121
6182
|
version: 1
|
|
6122
6183
|
}),
|
|
6123
|
-
headers: { "idempotency-key": r.idempotencyKey ??
|
|
6184
|
+
headers: { "idempotency-key": r.idempotencyKey ?? kl("publication") },
|
|
6124
6185
|
method: "POST"
|
|
6125
6186
|
}));
|
|
6126
6187
|
}
|
|
6127
6188
|
async getRun(e, t) {
|
|
6128
|
-
return
|
|
6189
|
+
return ul(await this.request(`/v1/runs/${$(e)}`, { signal: t }));
|
|
6129
6190
|
}
|
|
6130
6191
|
async listRuns(e, t = {}) {
|
|
6131
6192
|
let n = new URLSearchParams();
|
|
6132
6193
|
t.cursor != null && n.set("cursor", t.cursor), t.limit != null && n.set("limit", String(t.limit)), t.status != null && n.set("status", t.status);
|
|
6133
6194
|
let r = n.size == 0 ? "" : `?${n}`;
|
|
6134
|
-
return
|
|
6195
|
+
return dl(await this.request(`/v1/flows/${$(e)}/runs${r}`));
|
|
6135
6196
|
}
|
|
6136
6197
|
async getRunEvents(e, t = {}, n) {
|
|
6137
6198
|
let r = new URLSearchParams();
|
|
6138
6199
|
t.after != null && r.set("after", String(t.after)), t.limit != null && r.set("limit", String(t.limit));
|
|
6139
6200
|
let i = r.size == 0 ? "" : `?${r}`;
|
|
6140
|
-
return
|
|
6201
|
+
return Ol(await this.request(`/v1/runs/${$(e)}/events${i}`, { signal: n }));
|
|
6141
6202
|
}
|
|
6142
6203
|
async listRunResults(e, t, n) {
|
|
6143
6204
|
return Gs(await this.request(`/v1/runs/${$(e)}/results${t == null ? "" : `?after=${encodeURIComponent(t)}`}`, { signal: n }));
|
|
@@ -6150,16 +6211,16 @@ var wl = class {
|
|
|
6150
6211
|
return (await this.response(`/v1/runs/${$(e)}/results/${$(t)}/content`, { signal: n })).blob();
|
|
6151
6212
|
}
|
|
6152
6213
|
async getRunResult(e, t) {
|
|
6153
|
-
return
|
|
6214
|
+
return ml(await this.request(`/v1/runs/${$(e)}/result`, { signal: t }));
|
|
6154
6215
|
}
|
|
6155
6216
|
async cancelRun(e) {
|
|
6156
|
-
return
|
|
6217
|
+
return fl(await this.request(`/v1/runs/${$(e)}/cancel`, {
|
|
6157
6218
|
body: JSON.stringify({ version: 1 }),
|
|
6158
6219
|
method: "POST"
|
|
6159
6220
|
}));
|
|
6160
6221
|
}
|
|
6161
6222
|
async resolveRunWait(e, t, n) {
|
|
6162
|
-
return
|
|
6223
|
+
return pl(await this.request(`/v1/runs/${$(e)}/waits/${$(t)}/resolve`, {
|
|
6163
6224
|
body: JSON.stringify({
|
|
6164
6225
|
action: n,
|
|
6165
6226
|
version: 1
|
|
@@ -6200,4 +6261,4 @@ var wl = class {
|
|
|
6200
6261
|
}
|
|
6201
6262
|
};
|
|
6202
6263
|
//#endregion
|
|
6203
|
-
export { Qs as ApiError,
|
|
6264
|
+
export { Qs as ApiError, Al as ControlClient, H as controlErrorCode, Zs as controlErrorMetadata, Gs as decodeResultList, Ks as decodeResultRead, El as decodeRunEvent, Ws as parseResultQuery, Xs as readResult };
|