@avaprotocol/sdk-js 1.6.6 → 1.6.7
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 +8 -0
- package/dist/index.d.ts +5 -17
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +793 -492
- package/dist/index.mjs +800 -493
- package/dist/models/node/branch.d.ts +1 -0
- package/dist/models/node/branch.d.ts.map +1 -1
- package/dist/models/node/branch.js +4 -0
- package/dist/models/node/contractRead.d.ts +1 -0
- package/dist/models/node/contractRead.d.ts.map +1 -1
- package/dist/models/node/contractRead.js +11 -0
- package/dist/models/node/contractWrite.d.ts +1 -0
- package/dist/models/node/contractWrite.d.ts.map +1 -1
- package/dist/models/node/contractWrite.js +4 -0
- package/dist/models/node/customCode.d.ts +1 -0
- package/dist/models/node/customCode.d.ts.map +1 -1
- package/dist/models/node/customCode.js +9 -0
- package/dist/models/node/ethTransfer.d.ts +1 -0
- package/dist/models/node/ethTransfer.d.ts.map +1 -1
- package/dist/models/node/ethTransfer.js +4 -0
- package/dist/models/node/factory.d.ts +1 -0
- package/dist/models/node/factory.d.ts.map +1 -1
- package/dist/models/node/factory.js +54 -0
- package/dist/models/node/filter.d.ts +1 -0
- package/dist/models/node/filter.d.ts.map +1 -1
- package/dist/models/node/filter.js +4 -0
- package/dist/models/node/graphqlQuery.d.ts +1 -0
- package/dist/models/node/graphqlQuery.d.ts.map +1 -1
- package/dist/models/node/graphqlQuery.js +4 -0
- package/dist/models/node/loop.d.ts +1 -0
- package/dist/models/node/loop.d.ts.map +1 -1
- package/dist/models/node/loop.js +4 -0
- package/dist/models/node/restApi.d.ts +1 -0
- package/dist/models/node/restApi.d.ts.map +1 -1
- package/dist/models/node/restApi.js +15 -1
- package/dist/models/trigger/block.d.ts +6 -0
- package/dist/models/trigger/block.d.ts.map +1 -1
- package/dist/models/trigger/block.js +9 -0
- package/dist/models/trigger/cron.d.ts +7 -1
- package/dist/models/trigger/cron.d.ts.map +1 -1
- package/dist/models/trigger/cron.js +10 -1
- package/dist/models/trigger/event.d.ts +7 -1
- package/dist/models/trigger/event.d.ts.map +1 -1
- package/dist/models/trigger/event.js +10 -1
- package/dist/models/trigger/factory.d.ts +1 -0
- package/dist/models/trigger/factory.d.ts.map +1 -1
- package/dist/models/trigger/factory.js +42 -0
- package/dist/models/trigger/fixedTime.d.ts +7 -1
- package/dist/models/trigger/fixedTime.d.ts.map +1 -1
- package/dist/models/trigger/fixedTime.js +10 -1
- package/dist/models/trigger/interface.d.ts +1 -1
- package/dist/models/trigger/interface.d.ts.map +1 -1
- package/dist/models/trigger/manual.d.ts +13 -0
- package/dist/models/trigger/manual.d.ts.map +1 -1
- package/dist/models/trigger/manual.js +17 -0
- package/dist/utils.d.ts +34 -0
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +116 -2
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -137,6 +137,9 @@ var require_avs_pb = __commonJS({
|
|
|
137
137
|
goog.exportSymbol("proto.aggregator.LoopNode.Config", null, global);
|
|
138
138
|
goog.exportSymbol("proto.aggregator.LoopNode.Output", null, global);
|
|
139
139
|
goog.exportSymbol("proto.aggregator.LoopNode.RunnerCase", null, global);
|
|
140
|
+
goog.exportSymbol("proto.aggregator.ManualTrigger", null, global);
|
|
141
|
+
goog.exportSymbol("proto.aggregator.ManualTrigger.Config", null, global);
|
|
142
|
+
goog.exportSymbol("proto.aggregator.ManualTrigger.Output", null, global);
|
|
140
143
|
goog.exportSymbol("proto.aggregator.NodeType", null, global);
|
|
141
144
|
goog.exportSymbol("proto.aggregator.NonceRequest", null, global);
|
|
142
145
|
goog.exportSymbol("proto.aggregator.NonceResp", null, global);
|
|
@@ -269,6 +272,27 @@ var require_avs_pb = __commonJS({
|
|
|
269
272
|
if (goog.DEBUG && !COMPILED) {
|
|
270
273
|
proto.aggregator.EventTrigger.TransferLogOutput.displayName = "proto.aggregator.EventTrigger.TransferLogOutput";
|
|
271
274
|
}
|
|
275
|
+
proto.aggregator.ManualTrigger = function(opt_data) {
|
|
276
|
+
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
277
|
+
};
|
|
278
|
+
goog.inherits(proto.aggregator.ManualTrigger, jspb.Message);
|
|
279
|
+
if (goog.DEBUG && !COMPILED) {
|
|
280
|
+
proto.aggregator.ManualTrigger.displayName = "proto.aggregator.ManualTrigger";
|
|
281
|
+
}
|
|
282
|
+
proto.aggregator.ManualTrigger.Config = function(opt_data) {
|
|
283
|
+
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
284
|
+
};
|
|
285
|
+
goog.inherits(proto.aggregator.ManualTrigger.Config, jspb.Message);
|
|
286
|
+
if (goog.DEBUG && !COMPILED) {
|
|
287
|
+
proto.aggregator.ManualTrigger.Config.displayName = "proto.aggregator.ManualTrigger.Config";
|
|
288
|
+
}
|
|
289
|
+
proto.aggregator.ManualTrigger.Output = function(opt_data) {
|
|
290
|
+
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
291
|
+
};
|
|
292
|
+
goog.inherits(proto.aggregator.ManualTrigger.Output, jspb.Message);
|
|
293
|
+
if (goog.DEBUG && !COMPILED) {
|
|
294
|
+
proto.aggregator.ManualTrigger.Output.displayName = "proto.aggregator.ManualTrigger.Output";
|
|
295
|
+
}
|
|
272
296
|
proto.aggregator.TaskTrigger = function(opt_data) {
|
|
273
297
|
jspb.Message.initialize(this, opt_data, 0, -1, null, proto.aggregator.TaskTrigger.oneofGroups_);
|
|
274
298
|
};
|
|
@@ -2359,6 +2383,178 @@ var require_avs_pb = __commonJS({
|
|
|
2359
2383
|
proto.aggregator.EventTrigger.prototype.hasConfig = function() {
|
|
2360
2384
|
return jspb.Message.getField(this, 1) != null;
|
|
2361
2385
|
};
|
|
2386
|
+
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
2387
|
+
proto.aggregator.ManualTrigger.prototype.toObject = function(opt_includeInstance) {
|
|
2388
|
+
return proto.aggregator.ManualTrigger.toObject(opt_includeInstance, this);
|
|
2389
|
+
};
|
|
2390
|
+
proto.aggregator.ManualTrigger.toObject = function(includeInstance, msg) {
|
|
2391
|
+
var f, obj = {
|
|
2392
|
+
config: (f = msg.getConfig()) && proto.aggregator.ManualTrigger.Config.toObject(includeInstance, f)
|
|
2393
|
+
};
|
|
2394
|
+
if (includeInstance) {
|
|
2395
|
+
obj.$jspbMessageInstance = msg;
|
|
2396
|
+
}
|
|
2397
|
+
return obj;
|
|
2398
|
+
};
|
|
2399
|
+
}
|
|
2400
|
+
proto.aggregator.ManualTrigger.deserializeBinary = function(bytes) {
|
|
2401
|
+
var reader = new jspb.BinaryReader(bytes);
|
|
2402
|
+
var msg = new proto.aggregator.ManualTrigger();
|
|
2403
|
+
return proto.aggregator.ManualTrigger.deserializeBinaryFromReader(msg, reader);
|
|
2404
|
+
};
|
|
2405
|
+
proto.aggregator.ManualTrigger.deserializeBinaryFromReader = function(msg, reader) {
|
|
2406
|
+
while (reader.nextField()) {
|
|
2407
|
+
if (reader.isEndGroup()) {
|
|
2408
|
+
break;
|
|
2409
|
+
}
|
|
2410
|
+
var field = reader.getFieldNumber();
|
|
2411
|
+
switch (field) {
|
|
2412
|
+
case 1:
|
|
2413
|
+
var value = new proto.aggregator.ManualTrigger.Config();
|
|
2414
|
+
reader.readMessage(value, proto.aggregator.ManualTrigger.Config.deserializeBinaryFromReader);
|
|
2415
|
+
msg.setConfig(value);
|
|
2416
|
+
break;
|
|
2417
|
+
default:
|
|
2418
|
+
reader.skipField();
|
|
2419
|
+
break;
|
|
2420
|
+
}
|
|
2421
|
+
}
|
|
2422
|
+
return msg;
|
|
2423
|
+
};
|
|
2424
|
+
proto.aggregator.ManualTrigger.prototype.serializeBinary = function() {
|
|
2425
|
+
var writer = new jspb.BinaryWriter();
|
|
2426
|
+
proto.aggregator.ManualTrigger.serializeBinaryToWriter(this, writer);
|
|
2427
|
+
return writer.getResultBuffer();
|
|
2428
|
+
};
|
|
2429
|
+
proto.aggregator.ManualTrigger.serializeBinaryToWriter = function(message, writer) {
|
|
2430
|
+
var f = void 0;
|
|
2431
|
+
f = message.getConfig();
|
|
2432
|
+
if (f != null) {
|
|
2433
|
+
writer.writeMessage(
|
|
2434
|
+
1,
|
|
2435
|
+
f,
|
|
2436
|
+
proto.aggregator.ManualTrigger.Config.serializeBinaryToWriter
|
|
2437
|
+
);
|
|
2438
|
+
}
|
|
2439
|
+
};
|
|
2440
|
+
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
2441
|
+
proto.aggregator.ManualTrigger.Config.prototype.toObject = function(opt_includeInstance) {
|
|
2442
|
+
return proto.aggregator.ManualTrigger.Config.toObject(opt_includeInstance, this);
|
|
2443
|
+
};
|
|
2444
|
+
proto.aggregator.ManualTrigger.Config.toObject = function(includeInstance, msg) {
|
|
2445
|
+
var f, obj = {};
|
|
2446
|
+
if (includeInstance) {
|
|
2447
|
+
obj.$jspbMessageInstance = msg;
|
|
2448
|
+
}
|
|
2449
|
+
return obj;
|
|
2450
|
+
};
|
|
2451
|
+
}
|
|
2452
|
+
proto.aggregator.ManualTrigger.Config.deserializeBinary = function(bytes) {
|
|
2453
|
+
var reader = new jspb.BinaryReader(bytes);
|
|
2454
|
+
var msg = new proto.aggregator.ManualTrigger.Config();
|
|
2455
|
+
return proto.aggregator.ManualTrigger.Config.deserializeBinaryFromReader(msg, reader);
|
|
2456
|
+
};
|
|
2457
|
+
proto.aggregator.ManualTrigger.Config.deserializeBinaryFromReader = function(msg, reader) {
|
|
2458
|
+
while (reader.nextField()) {
|
|
2459
|
+
if (reader.isEndGroup()) {
|
|
2460
|
+
break;
|
|
2461
|
+
}
|
|
2462
|
+
var field = reader.getFieldNumber();
|
|
2463
|
+
switch (field) {
|
|
2464
|
+
default:
|
|
2465
|
+
reader.skipField();
|
|
2466
|
+
break;
|
|
2467
|
+
}
|
|
2468
|
+
}
|
|
2469
|
+
return msg;
|
|
2470
|
+
};
|
|
2471
|
+
proto.aggregator.ManualTrigger.Config.prototype.serializeBinary = function() {
|
|
2472
|
+
var writer = new jspb.BinaryWriter();
|
|
2473
|
+
proto.aggregator.ManualTrigger.Config.serializeBinaryToWriter(this, writer);
|
|
2474
|
+
return writer.getResultBuffer();
|
|
2475
|
+
};
|
|
2476
|
+
proto.aggregator.ManualTrigger.Config.serializeBinaryToWriter = function(message, writer) {
|
|
2477
|
+
var f = void 0;
|
|
2478
|
+
};
|
|
2479
|
+
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
2480
|
+
proto.aggregator.ManualTrigger.Output.prototype.toObject = function(opt_includeInstance) {
|
|
2481
|
+
return proto.aggregator.ManualTrigger.Output.toObject(opt_includeInstance, this);
|
|
2482
|
+
};
|
|
2483
|
+
proto.aggregator.ManualTrigger.Output.toObject = function(includeInstance, msg) {
|
|
2484
|
+
var f, obj = {
|
|
2485
|
+
runAt: jspb.Message.getFieldWithDefault(msg, 1, 0)
|
|
2486
|
+
};
|
|
2487
|
+
if (includeInstance) {
|
|
2488
|
+
obj.$jspbMessageInstance = msg;
|
|
2489
|
+
}
|
|
2490
|
+
return obj;
|
|
2491
|
+
};
|
|
2492
|
+
}
|
|
2493
|
+
proto.aggregator.ManualTrigger.Output.deserializeBinary = function(bytes) {
|
|
2494
|
+
var reader = new jspb.BinaryReader(bytes);
|
|
2495
|
+
var msg = new proto.aggregator.ManualTrigger.Output();
|
|
2496
|
+
return proto.aggregator.ManualTrigger.Output.deserializeBinaryFromReader(msg, reader);
|
|
2497
|
+
};
|
|
2498
|
+
proto.aggregator.ManualTrigger.Output.deserializeBinaryFromReader = function(msg, reader) {
|
|
2499
|
+
while (reader.nextField()) {
|
|
2500
|
+
if (reader.isEndGroup()) {
|
|
2501
|
+
break;
|
|
2502
|
+
}
|
|
2503
|
+
var field = reader.getFieldNumber();
|
|
2504
|
+
switch (field) {
|
|
2505
|
+
case 1:
|
|
2506
|
+
var value = (
|
|
2507
|
+
/** @type {number} */
|
|
2508
|
+
reader.readUint64()
|
|
2509
|
+
);
|
|
2510
|
+
msg.setRunAt(value);
|
|
2511
|
+
break;
|
|
2512
|
+
default:
|
|
2513
|
+
reader.skipField();
|
|
2514
|
+
break;
|
|
2515
|
+
}
|
|
2516
|
+
}
|
|
2517
|
+
return msg;
|
|
2518
|
+
};
|
|
2519
|
+
proto.aggregator.ManualTrigger.Output.prototype.serializeBinary = function() {
|
|
2520
|
+
var writer = new jspb.BinaryWriter();
|
|
2521
|
+
proto.aggregator.ManualTrigger.Output.serializeBinaryToWriter(this, writer);
|
|
2522
|
+
return writer.getResultBuffer();
|
|
2523
|
+
};
|
|
2524
|
+
proto.aggregator.ManualTrigger.Output.serializeBinaryToWriter = function(message, writer) {
|
|
2525
|
+
var f = void 0;
|
|
2526
|
+
f = message.getRunAt();
|
|
2527
|
+
if (f !== 0) {
|
|
2528
|
+
writer.writeUint64(
|
|
2529
|
+
1,
|
|
2530
|
+
f
|
|
2531
|
+
);
|
|
2532
|
+
}
|
|
2533
|
+
};
|
|
2534
|
+
proto.aggregator.ManualTrigger.Output.prototype.getRunAt = function() {
|
|
2535
|
+
return (
|
|
2536
|
+
/** @type {number} */
|
|
2537
|
+
jspb.Message.getFieldWithDefault(this, 1, 0)
|
|
2538
|
+
);
|
|
2539
|
+
};
|
|
2540
|
+
proto.aggregator.ManualTrigger.Output.prototype.setRunAt = function(value) {
|
|
2541
|
+
return jspb.Message.setProto3IntField(this, 1, value);
|
|
2542
|
+
};
|
|
2543
|
+
proto.aggregator.ManualTrigger.prototype.getConfig = function() {
|
|
2544
|
+
return (
|
|
2545
|
+
/** @type{?proto.aggregator.ManualTrigger.Config} */
|
|
2546
|
+
jspb.Message.getWrapperField(this, proto.aggregator.ManualTrigger.Config, 1)
|
|
2547
|
+
);
|
|
2548
|
+
};
|
|
2549
|
+
proto.aggregator.ManualTrigger.prototype.setConfig = function(value) {
|
|
2550
|
+
return jspb.Message.setWrapperField(this, 1, value);
|
|
2551
|
+
};
|
|
2552
|
+
proto.aggregator.ManualTrigger.prototype.clearConfig = function() {
|
|
2553
|
+
return this.setConfig(void 0);
|
|
2554
|
+
};
|
|
2555
|
+
proto.aggregator.ManualTrigger.prototype.hasConfig = function() {
|
|
2556
|
+
return jspb.Message.getField(this, 1) != null;
|
|
2557
|
+
};
|
|
2362
2558
|
proto.aggregator.TaskTrigger.oneofGroups_ = [[2, 3, 4, 5, 6]];
|
|
2363
2559
|
proto.aggregator.TaskTrigger.TriggerTypeCase = {
|
|
2364
2560
|
TRIGGER_TYPE_NOT_SET: 0,
|
|
@@ -3838,7 +4034,7 @@ var require_avs_pb = __commonJS({
|
|
|
3838
4034
|
};
|
|
3839
4035
|
proto.aggregator.RestAPINode.Output.toObject = function(includeInstance, msg) {
|
|
3840
4036
|
var f, obj = {
|
|
3841
|
-
data: (f = msg.getData()) &&
|
|
4037
|
+
data: (f = msg.getData()) && google_protobuf_struct_pb.Value.toObject(includeInstance, f)
|
|
3842
4038
|
};
|
|
3843
4039
|
if (includeInstance) {
|
|
3844
4040
|
obj.$jspbMessageInstance = msg;
|
|
@@ -3859,8 +4055,8 @@ var require_avs_pb = __commonJS({
|
|
|
3859
4055
|
var field = reader.getFieldNumber();
|
|
3860
4056
|
switch (field) {
|
|
3861
4057
|
case 1:
|
|
3862
|
-
var value = new
|
|
3863
|
-
reader.readMessage(value,
|
|
4058
|
+
var value = new google_protobuf_struct_pb.Value();
|
|
4059
|
+
reader.readMessage(value, google_protobuf_struct_pb.Value.deserializeBinaryFromReader);
|
|
3864
4060
|
msg.setData(value);
|
|
3865
4061
|
break;
|
|
3866
4062
|
default:
|
|
@@ -3882,14 +4078,14 @@ var require_avs_pb = __commonJS({
|
|
|
3882
4078
|
writer.writeMessage(
|
|
3883
4079
|
1,
|
|
3884
4080
|
f,
|
|
3885
|
-
|
|
4081
|
+
google_protobuf_struct_pb.Value.serializeBinaryToWriter
|
|
3886
4082
|
);
|
|
3887
4083
|
}
|
|
3888
4084
|
};
|
|
3889
4085
|
proto.aggregator.RestAPINode.Output.prototype.getData = function() {
|
|
3890
4086
|
return (
|
|
3891
|
-
/** @type{?proto.google.protobuf.
|
|
3892
|
-
jspb.Message.getWrapperField(this,
|
|
4087
|
+
/** @type{?proto.google.protobuf.Value} */
|
|
4088
|
+
jspb.Message.getWrapperField(this, google_protobuf_struct_pb.Value, 1)
|
|
3893
4089
|
);
|
|
3894
4090
|
};
|
|
3895
4091
|
proto.aggregator.RestAPINode.Output.prototype.setData = function(value) {
|
|
@@ -11463,13 +11659,14 @@ var require_avs_pb = __commonJS({
|
|
|
11463
11659
|
this.getTriggerConfigMap().clear();
|
|
11464
11660
|
return this;
|
|
11465
11661
|
};
|
|
11466
|
-
proto.aggregator.RunTriggerResp.oneofGroups_ = [[10, 11, 12, 13]];
|
|
11662
|
+
proto.aggregator.RunTriggerResp.oneofGroups_ = [[10, 11, 12, 13, 14]];
|
|
11467
11663
|
proto.aggregator.RunTriggerResp.OutputDataCase = {
|
|
11468
11664
|
OUTPUT_DATA_NOT_SET: 0,
|
|
11469
11665
|
BLOCK_TRIGGER: 10,
|
|
11470
11666
|
FIXED_TIME_TRIGGER: 11,
|
|
11471
11667
|
CRON_TRIGGER: 12,
|
|
11472
|
-
EVENT_TRIGGER: 13
|
|
11668
|
+
EVENT_TRIGGER: 13,
|
|
11669
|
+
MANUAL_TRIGGER: 14
|
|
11473
11670
|
};
|
|
11474
11671
|
proto.aggregator.RunTriggerResp.prototype.getOutputDataCase = function() {
|
|
11475
11672
|
return (
|
|
@@ -11489,7 +11686,8 @@ var require_avs_pb = __commonJS({
|
|
|
11489
11686
|
blockTrigger: (f = msg.getBlockTrigger()) && proto.aggregator.BlockTrigger.Output.toObject(includeInstance, f),
|
|
11490
11687
|
fixedTimeTrigger: (f = msg.getFixedTimeTrigger()) && proto.aggregator.FixedTimeTrigger.Output.toObject(includeInstance, f),
|
|
11491
11688
|
cronTrigger: (f = msg.getCronTrigger()) && proto.aggregator.CronTrigger.Output.toObject(includeInstance, f),
|
|
11492
|
-
eventTrigger: (f = msg.getEventTrigger()) && proto.aggregator.EventTrigger.Output.toObject(includeInstance, f)
|
|
11689
|
+
eventTrigger: (f = msg.getEventTrigger()) && proto.aggregator.EventTrigger.Output.toObject(includeInstance, f),
|
|
11690
|
+
manualTrigger: (f = msg.getManualTrigger()) && proto.aggregator.ManualTrigger.Output.toObject(includeInstance, f)
|
|
11493
11691
|
};
|
|
11494
11692
|
if (includeInstance) {
|
|
11495
11693
|
obj.$jspbMessageInstance = msg;
|
|
@@ -11550,6 +11748,11 @@ var require_avs_pb = __commonJS({
|
|
|
11550
11748
|
reader.readMessage(value, proto.aggregator.EventTrigger.Output.deserializeBinaryFromReader);
|
|
11551
11749
|
msg.setEventTrigger(value);
|
|
11552
11750
|
break;
|
|
11751
|
+
case 14:
|
|
11752
|
+
var value = new proto.aggregator.ManualTrigger.Output();
|
|
11753
|
+
reader.readMessage(value, proto.aggregator.ManualTrigger.Output.deserializeBinaryFromReader);
|
|
11754
|
+
msg.setManualTrigger(value);
|
|
11755
|
+
break;
|
|
11553
11756
|
default:
|
|
11554
11757
|
reader.skipField();
|
|
11555
11758
|
break;
|
|
@@ -11617,6 +11820,14 @@ var require_avs_pb = __commonJS({
|
|
|
11617
11820
|
proto.aggregator.EventTrigger.Output.serializeBinaryToWriter
|
|
11618
11821
|
);
|
|
11619
11822
|
}
|
|
11823
|
+
f = message.getManualTrigger();
|
|
11824
|
+
if (f != null) {
|
|
11825
|
+
writer.writeMessage(
|
|
11826
|
+
14,
|
|
11827
|
+
f,
|
|
11828
|
+
proto.aggregator.ManualTrigger.Output.serializeBinaryToWriter
|
|
11829
|
+
);
|
|
11830
|
+
}
|
|
11620
11831
|
};
|
|
11621
11832
|
proto.aggregator.RunTriggerResp.prototype.getSuccess = function() {
|
|
11622
11833
|
return (
|
|
@@ -11705,6 +11916,21 @@ var require_avs_pb = __commonJS({
|
|
|
11705
11916
|
proto.aggregator.RunTriggerResp.prototype.hasEventTrigger = function() {
|
|
11706
11917
|
return jspb.Message.getField(this, 13) != null;
|
|
11707
11918
|
};
|
|
11919
|
+
proto.aggregator.RunTriggerResp.prototype.getManualTrigger = function() {
|
|
11920
|
+
return (
|
|
11921
|
+
/** @type{?proto.aggregator.ManualTrigger.Output} */
|
|
11922
|
+
jspb.Message.getWrapperField(this, proto.aggregator.ManualTrigger.Output, 14)
|
|
11923
|
+
);
|
|
11924
|
+
};
|
|
11925
|
+
proto.aggregator.RunTriggerResp.prototype.setManualTrigger = function(value) {
|
|
11926
|
+
return jspb.Message.setOneofWrapperField(this, 14, proto.aggregator.RunTriggerResp.oneofGroups_[0], value);
|
|
11927
|
+
};
|
|
11928
|
+
proto.aggregator.RunTriggerResp.prototype.clearManualTrigger = function() {
|
|
11929
|
+
return this.setManualTrigger(void 0);
|
|
11930
|
+
};
|
|
11931
|
+
proto.aggregator.RunTriggerResp.prototype.hasManualTrigger = function() {
|
|
11932
|
+
return jspb.Message.getField(this, 14) != null;
|
|
11933
|
+
};
|
|
11708
11934
|
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
11709
11935
|
proto.aggregator.Evm.prototype.toObject = function(opt_includeInstance) {
|
|
11710
11936
|
return proto.aggregator.Evm.toObject(opt_includeInstance, this);
|
|
@@ -12844,352 +13070,352 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
12844
13070
|
"../../grpc_codegen/avs_grpc_pb.js"(exports) {
|
|
12845
13071
|
"use strict";
|
|
12846
13072
|
var grpc = __require("@grpc/grpc-js");
|
|
12847
|
-
var
|
|
13073
|
+
var avs_pb25 = require_avs_pb();
|
|
12848
13074
|
var google_protobuf_wrappers_pb = __require("google-protobuf/google/protobuf/wrappers_pb.js");
|
|
12849
13075
|
var google_protobuf_timestamp_pb = __require("google-protobuf/google/protobuf/timestamp_pb.js");
|
|
12850
13076
|
var google_protobuf_any_pb = __require("google-protobuf/google/protobuf/any_pb.js");
|
|
12851
13077
|
var google_protobuf_struct_pb = __require("google-protobuf/google/protobuf/struct_pb.js");
|
|
12852
13078
|
function serialize_aggregator_CreateOrUpdateSecretReq(arg) {
|
|
12853
|
-
if (!(arg instanceof
|
|
13079
|
+
if (!(arg instanceof avs_pb25.CreateOrUpdateSecretReq)) {
|
|
12854
13080
|
throw new Error("Expected argument of type aggregator.CreateOrUpdateSecretReq");
|
|
12855
13081
|
}
|
|
12856
13082
|
return Buffer.from(arg.serializeBinary());
|
|
12857
13083
|
}
|
|
12858
13084
|
function deserialize_aggregator_CreateOrUpdateSecretReq(buffer_arg) {
|
|
12859
|
-
return
|
|
13085
|
+
return avs_pb25.CreateOrUpdateSecretReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12860
13086
|
}
|
|
12861
13087
|
function serialize_aggregator_CreateTaskReq(arg) {
|
|
12862
|
-
if (!(arg instanceof
|
|
13088
|
+
if (!(arg instanceof avs_pb25.CreateTaskReq)) {
|
|
12863
13089
|
throw new Error("Expected argument of type aggregator.CreateTaskReq");
|
|
12864
13090
|
}
|
|
12865
13091
|
return Buffer.from(arg.serializeBinary());
|
|
12866
13092
|
}
|
|
12867
13093
|
function deserialize_aggregator_CreateTaskReq(buffer_arg) {
|
|
12868
|
-
return
|
|
13094
|
+
return avs_pb25.CreateTaskReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12869
13095
|
}
|
|
12870
13096
|
function serialize_aggregator_CreateTaskResp(arg) {
|
|
12871
|
-
if (!(arg instanceof
|
|
13097
|
+
if (!(arg instanceof avs_pb25.CreateTaskResp)) {
|
|
12872
13098
|
throw new Error("Expected argument of type aggregator.CreateTaskResp");
|
|
12873
13099
|
}
|
|
12874
13100
|
return Buffer.from(arg.serializeBinary());
|
|
12875
13101
|
}
|
|
12876
13102
|
function deserialize_aggregator_CreateTaskResp(buffer_arg) {
|
|
12877
|
-
return
|
|
13103
|
+
return avs_pb25.CreateTaskResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12878
13104
|
}
|
|
12879
13105
|
function serialize_aggregator_DeleteSecretReq(arg) {
|
|
12880
|
-
if (!(arg instanceof
|
|
13106
|
+
if (!(arg instanceof avs_pb25.DeleteSecretReq)) {
|
|
12881
13107
|
throw new Error("Expected argument of type aggregator.DeleteSecretReq");
|
|
12882
13108
|
}
|
|
12883
13109
|
return Buffer.from(arg.serializeBinary());
|
|
12884
13110
|
}
|
|
12885
13111
|
function deserialize_aggregator_DeleteSecretReq(buffer_arg) {
|
|
12886
|
-
return
|
|
13112
|
+
return avs_pb25.DeleteSecretReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12887
13113
|
}
|
|
12888
13114
|
function serialize_aggregator_Execution(arg) {
|
|
12889
|
-
if (!(arg instanceof
|
|
13115
|
+
if (!(arg instanceof avs_pb25.Execution)) {
|
|
12890
13116
|
throw new Error("Expected argument of type aggregator.Execution");
|
|
12891
13117
|
}
|
|
12892
13118
|
return Buffer.from(arg.serializeBinary());
|
|
12893
13119
|
}
|
|
12894
13120
|
function deserialize_aggregator_Execution(buffer_arg) {
|
|
12895
|
-
return
|
|
13121
|
+
return avs_pb25.Execution.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12896
13122
|
}
|
|
12897
13123
|
function serialize_aggregator_ExecutionReq(arg) {
|
|
12898
|
-
if (!(arg instanceof
|
|
13124
|
+
if (!(arg instanceof avs_pb25.ExecutionReq)) {
|
|
12899
13125
|
throw new Error("Expected argument of type aggregator.ExecutionReq");
|
|
12900
13126
|
}
|
|
12901
13127
|
return Buffer.from(arg.serializeBinary());
|
|
12902
13128
|
}
|
|
12903
13129
|
function deserialize_aggregator_ExecutionReq(buffer_arg) {
|
|
12904
|
-
return
|
|
13130
|
+
return avs_pb25.ExecutionReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12905
13131
|
}
|
|
12906
13132
|
function serialize_aggregator_ExecutionStatusResp(arg) {
|
|
12907
|
-
if (!(arg instanceof
|
|
13133
|
+
if (!(arg instanceof avs_pb25.ExecutionStatusResp)) {
|
|
12908
13134
|
throw new Error("Expected argument of type aggregator.ExecutionStatusResp");
|
|
12909
13135
|
}
|
|
12910
13136
|
return Buffer.from(arg.serializeBinary());
|
|
12911
13137
|
}
|
|
12912
13138
|
function deserialize_aggregator_ExecutionStatusResp(buffer_arg) {
|
|
12913
|
-
return
|
|
13139
|
+
return avs_pb25.ExecutionStatusResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12914
13140
|
}
|
|
12915
13141
|
function serialize_aggregator_GetExecutionCountReq(arg) {
|
|
12916
|
-
if (!(arg instanceof
|
|
13142
|
+
if (!(arg instanceof avs_pb25.GetExecutionCountReq)) {
|
|
12917
13143
|
throw new Error("Expected argument of type aggregator.GetExecutionCountReq");
|
|
12918
13144
|
}
|
|
12919
13145
|
return Buffer.from(arg.serializeBinary());
|
|
12920
13146
|
}
|
|
12921
13147
|
function deserialize_aggregator_GetExecutionCountReq(buffer_arg) {
|
|
12922
|
-
return
|
|
13148
|
+
return avs_pb25.GetExecutionCountReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12923
13149
|
}
|
|
12924
13150
|
function serialize_aggregator_GetExecutionCountResp(arg) {
|
|
12925
|
-
if (!(arg instanceof
|
|
13151
|
+
if (!(arg instanceof avs_pb25.GetExecutionCountResp)) {
|
|
12926
13152
|
throw new Error("Expected argument of type aggregator.GetExecutionCountResp");
|
|
12927
13153
|
}
|
|
12928
13154
|
return Buffer.from(arg.serializeBinary());
|
|
12929
13155
|
}
|
|
12930
13156
|
function deserialize_aggregator_GetExecutionCountResp(buffer_arg) {
|
|
12931
|
-
return
|
|
13157
|
+
return avs_pb25.GetExecutionCountResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12932
13158
|
}
|
|
12933
13159
|
function serialize_aggregator_GetExecutionStatsReq(arg) {
|
|
12934
|
-
if (!(arg instanceof
|
|
13160
|
+
if (!(arg instanceof avs_pb25.GetExecutionStatsReq)) {
|
|
12935
13161
|
throw new Error("Expected argument of type aggregator.GetExecutionStatsReq");
|
|
12936
13162
|
}
|
|
12937
13163
|
return Buffer.from(arg.serializeBinary());
|
|
12938
13164
|
}
|
|
12939
13165
|
function deserialize_aggregator_GetExecutionStatsReq(buffer_arg) {
|
|
12940
|
-
return
|
|
13166
|
+
return avs_pb25.GetExecutionStatsReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12941
13167
|
}
|
|
12942
13168
|
function serialize_aggregator_GetExecutionStatsResp(arg) {
|
|
12943
|
-
if (!(arg instanceof
|
|
13169
|
+
if (!(arg instanceof avs_pb25.GetExecutionStatsResp)) {
|
|
12944
13170
|
throw new Error("Expected argument of type aggregator.GetExecutionStatsResp");
|
|
12945
13171
|
}
|
|
12946
13172
|
return Buffer.from(arg.serializeBinary());
|
|
12947
13173
|
}
|
|
12948
13174
|
function deserialize_aggregator_GetExecutionStatsResp(buffer_arg) {
|
|
12949
|
-
return
|
|
13175
|
+
return avs_pb25.GetExecutionStatsResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12950
13176
|
}
|
|
12951
13177
|
function serialize_aggregator_GetKeyReq(arg) {
|
|
12952
|
-
if (!(arg instanceof
|
|
13178
|
+
if (!(arg instanceof avs_pb25.GetKeyReq)) {
|
|
12953
13179
|
throw new Error("Expected argument of type aggregator.GetKeyReq");
|
|
12954
13180
|
}
|
|
12955
13181
|
return Buffer.from(arg.serializeBinary());
|
|
12956
13182
|
}
|
|
12957
13183
|
function deserialize_aggregator_GetKeyReq(buffer_arg) {
|
|
12958
|
-
return
|
|
13184
|
+
return avs_pb25.GetKeyReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12959
13185
|
}
|
|
12960
13186
|
function serialize_aggregator_GetSignatureFormatReq(arg) {
|
|
12961
|
-
if (!(arg instanceof
|
|
13187
|
+
if (!(arg instanceof avs_pb25.GetSignatureFormatReq)) {
|
|
12962
13188
|
throw new Error("Expected argument of type aggregator.GetSignatureFormatReq");
|
|
12963
13189
|
}
|
|
12964
13190
|
return Buffer.from(arg.serializeBinary());
|
|
12965
13191
|
}
|
|
12966
13192
|
function deserialize_aggregator_GetSignatureFormatReq(buffer_arg) {
|
|
12967
|
-
return
|
|
13193
|
+
return avs_pb25.GetSignatureFormatReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12968
13194
|
}
|
|
12969
13195
|
function serialize_aggregator_GetSignatureFormatResp(arg) {
|
|
12970
|
-
if (!(arg instanceof
|
|
13196
|
+
if (!(arg instanceof avs_pb25.GetSignatureFormatResp)) {
|
|
12971
13197
|
throw new Error("Expected argument of type aggregator.GetSignatureFormatResp");
|
|
12972
13198
|
}
|
|
12973
13199
|
return Buffer.from(arg.serializeBinary());
|
|
12974
13200
|
}
|
|
12975
13201
|
function deserialize_aggregator_GetSignatureFormatResp(buffer_arg) {
|
|
12976
|
-
return
|
|
13202
|
+
return avs_pb25.GetSignatureFormatResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12977
13203
|
}
|
|
12978
13204
|
function serialize_aggregator_GetWalletReq(arg) {
|
|
12979
|
-
if (!(arg instanceof
|
|
13205
|
+
if (!(arg instanceof avs_pb25.GetWalletReq)) {
|
|
12980
13206
|
throw new Error("Expected argument of type aggregator.GetWalletReq");
|
|
12981
13207
|
}
|
|
12982
13208
|
return Buffer.from(arg.serializeBinary());
|
|
12983
13209
|
}
|
|
12984
13210
|
function deserialize_aggregator_GetWalletReq(buffer_arg) {
|
|
12985
|
-
return
|
|
13211
|
+
return avs_pb25.GetWalletReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12986
13212
|
}
|
|
12987
13213
|
function serialize_aggregator_GetWalletResp(arg) {
|
|
12988
|
-
if (!(arg instanceof
|
|
13214
|
+
if (!(arg instanceof avs_pb25.GetWalletResp)) {
|
|
12989
13215
|
throw new Error("Expected argument of type aggregator.GetWalletResp");
|
|
12990
13216
|
}
|
|
12991
13217
|
return Buffer.from(arg.serializeBinary());
|
|
12992
13218
|
}
|
|
12993
13219
|
function deserialize_aggregator_GetWalletResp(buffer_arg) {
|
|
12994
|
-
return
|
|
13220
|
+
return avs_pb25.GetWalletResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
12995
13221
|
}
|
|
12996
13222
|
function serialize_aggregator_GetWorkflowCountReq(arg) {
|
|
12997
|
-
if (!(arg instanceof
|
|
13223
|
+
if (!(arg instanceof avs_pb25.GetWorkflowCountReq)) {
|
|
12998
13224
|
throw new Error("Expected argument of type aggregator.GetWorkflowCountReq");
|
|
12999
13225
|
}
|
|
13000
13226
|
return Buffer.from(arg.serializeBinary());
|
|
13001
13227
|
}
|
|
13002
13228
|
function deserialize_aggregator_GetWorkflowCountReq(buffer_arg) {
|
|
13003
|
-
return
|
|
13229
|
+
return avs_pb25.GetWorkflowCountReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13004
13230
|
}
|
|
13005
13231
|
function serialize_aggregator_GetWorkflowCountResp(arg) {
|
|
13006
|
-
if (!(arg instanceof
|
|
13232
|
+
if (!(arg instanceof avs_pb25.GetWorkflowCountResp)) {
|
|
13007
13233
|
throw new Error("Expected argument of type aggregator.GetWorkflowCountResp");
|
|
13008
13234
|
}
|
|
13009
13235
|
return Buffer.from(arg.serializeBinary());
|
|
13010
13236
|
}
|
|
13011
13237
|
function deserialize_aggregator_GetWorkflowCountResp(buffer_arg) {
|
|
13012
|
-
return
|
|
13238
|
+
return avs_pb25.GetWorkflowCountResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13013
13239
|
}
|
|
13014
13240
|
function serialize_aggregator_IdReq(arg) {
|
|
13015
|
-
if (!(arg instanceof
|
|
13241
|
+
if (!(arg instanceof avs_pb25.IdReq)) {
|
|
13016
13242
|
throw new Error("Expected argument of type aggregator.IdReq");
|
|
13017
13243
|
}
|
|
13018
13244
|
return Buffer.from(arg.serializeBinary());
|
|
13019
13245
|
}
|
|
13020
13246
|
function deserialize_aggregator_IdReq(buffer_arg) {
|
|
13021
|
-
return
|
|
13247
|
+
return avs_pb25.IdReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13022
13248
|
}
|
|
13023
13249
|
function serialize_aggregator_KeyResp(arg) {
|
|
13024
|
-
if (!(arg instanceof
|
|
13250
|
+
if (!(arg instanceof avs_pb25.KeyResp)) {
|
|
13025
13251
|
throw new Error("Expected argument of type aggregator.KeyResp");
|
|
13026
13252
|
}
|
|
13027
13253
|
return Buffer.from(arg.serializeBinary());
|
|
13028
13254
|
}
|
|
13029
13255
|
function deserialize_aggregator_KeyResp(buffer_arg) {
|
|
13030
|
-
return
|
|
13256
|
+
return avs_pb25.KeyResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13031
13257
|
}
|
|
13032
13258
|
function serialize_aggregator_ListExecutionsReq(arg) {
|
|
13033
|
-
if (!(arg instanceof
|
|
13259
|
+
if (!(arg instanceof avs_pb25.ListExecutionsReq)) {
|
|
13034
13260
|
throw new Error("Expected argument of type aggregator.ListExecutionsReq");
|
|
13035
13261
|
}
|
|
13036
13262
|
return Buffer.from(arg.serializeBinary());
|
|
13037
13263
|
}
|
|
13038
13264
|
function deserialize_aggregator_ListExecutionsReq(buffer_arg) {
|
|
13039
|
-
return
|
|
13265
|
+
return avs_pb25.ListExecutionsReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13040
13266
|
}
|
|
13041
13267
|
function serialize_aggregator_ListExecutionsResp(arg) {
|
|
13042
|
-
if (!(arg instanceof
|
|
13268
|
+
if (!(arg instanceof avs_pb25.ListExecutionsResp)) {
|
|
13043
13269
|
throw new Error("Expected argument of type aggregator.ListExecutionsResp");
|
|
13044
13270
|
}
|
|
13045
13271
|
return Buffer.from(arg.serializeBinary());
|
|
13046
13272
|
}
|
|
13047
13273
|
function deserialize_aggregator_ListExecutionsResp(buffer_arg) {
|
|
13048
|
-
return
|
|
13274
|
+
return avs_pb25.ListExecutionsResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13049
13275
|
}
|
|
13050
13276
|
function serialize_aggregator_ListSecretsReq(arg) {
|
|
13051
|
-
if (!(arg instanceof
|
|
13277
|
+
if (!(arg instanceof avs_pb25.ListSecretsReq)) {
|
|
13052
13278
|
throw new Error("Expected argument of type aggregator.ListSecretsReq");
|
|
13053
13279
|
}
|
|
13054
13280
|
return Buffer.from(arg.serializeBinary());
|
|
13055
13281
|
}
|
|
13056
13282
|
function deserialize_aggregator_ListSecretsReq(buffer_arg) {
|
|
13057
|
-
return
|
|
13283
|
+
return avs_pb25.ListSecretsReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13058
13284
|
}
|
|
13059
13285
|
function serialize_aggregator_ListSecretsResp(arg) {
|
|
13060
|
-
if (!(arg instanceof
|
|
13286
|
+
if (!(arg instanceof avs_pb25.ListSecretsResp)) {
|
|
13061
13287
|
throw new Error("Expected argument of type aggregator.ListSecretsResp");
|
|
13062
13288
|
}
|
|
13063
13289
|
return Buffer.from(arg.serializeBinary());
|
|
13064
13290
|
}
|
|
13065
13291
|
function deserialize_aggregator_ListSecretsResp(buffer_arg) {
|
|
13066
|
-
return
|
|
13292
|
+
return avs_pb25.ListSecretsResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13067
13293
|
}
|
|
13068
13294
|
function serialize_aggregator_ListTasksReq(arg) {
|
|
13069
|
-
if (!(arg instanceof
|
|
13295
|
+
if (!(arg instanceof avs_pb25.ListTasksReq)) {
|
|
13070
13296
|
throw new Error("Expected argument of type aggregator.ListTasksReq");
|
|
13071
13297
|
}
|
|
13072
13298
|
return Buffer.from(arg.serializeBinary());
|
|
13073
13299
|
}
|
|
13074
13300
|
function deserialize_aggregator_ListTasksReq(buffer_arg) {
|
|
13075
|
-
return
|
|
13301
|
+
return avs_pb25.ListTasksReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13076
13302
|
}
|
|
13077
13303
|
function serialize_aggregator_ListTasksResp(arg) {
|
|
13078
|
-
if (!(arg instanceof
|
|
13304
|
+
if (!(arg instanceof avs_pb25.ListTasksResp)) {
|
|
13079
13305
|
throw new Error("Expected argument of type aggregator.ListTasksResp");
|
|
13080
13306
|
}
|
|
13081
13307
|
return Buffer.from(arg.serializeBinary());
|
|
13082
13308
|
}
|
|
13083
13309
|
function deserialize_aggregator_ListTasksResp(buffer_arg) {
|
|
13084
|
-
return
|
|
13310
|
+
return avs_pb25.ListTasksResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13085
13311
|
}
|
|
13086
13312
|
function serialize_aggregator_ListWalletReq(arg) {
|
|
13087
|
-
if (!(arg instanceof
|
|
13313
|
+
if (!(arg instanceof avs_pb25.ListWalletReq)) {
|
|
13088
13314
|
throw new Error("Expected argument of type aggregator.ListWalletReq");
|
|
13089
13315
|
}
|
|
13090
13316
|
return Buffer.from(arg.serializeBinary());
|
|
13091
13317
|
}
|
|
13092
13318
|
function deserialize_aggregator_ListWalletReq(buffer_arg) {
|
|
13093
|
-
return
|
|
13319
|
+
return avs_pb25.ListWalletReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13094
13320
|
}
|
|
13095
13321
|
function serialize_aggregator_ListWalletResp(arg) {
|
|
13096
|
-
if (!(arg instanceof
|
|
13322
|
+
if (!(arg instanceof avs_pb25.ListWalletResp)) {
|
|
13097
13323
|
throw new Error("Expected argument of type aggregator.ListWalletResp");
|
|
13098
13324
|
}
|
|
13099
13325
|
return Buffer.from(arg.serializeBinary());
|
|
13100
13326
|
}
|
|
13101
13327
|
function deserialize_aggregator_ListWalletResp(buffer_arg) {
|
|
13102
|
-
return
|
|
13328
|
+
return avs_pb25.ListWalletResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13103
13329
|
}
|
|
13104
13330
|
function serialize_aggregator_NonceRequest(arg) {
|
|
13105
|
-
if (!(arg instanceof
|
|
13331
|
+
if (!(arg instanceof avs_pb25.NonceRequest)) {
|
|
13106
13332
|
throw new Error("Expected argument of type aggregator.NonceRequest");
|
|
13107
13333
|
}
|
|
13108
13334
|
return Buffer.from(arg.serializeBinary());
|
|
13109
13335
|
}
|
|
13110
13336
|
function deserialize_aggregator_NonceRequest(buffer_arg) {
|
|
13111
|
-
return
|
|
13337
|
+
return avs_pb25.NonceRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13112
13338
|
}
|
|
13113
13339
|
function serialize_aggregator_NonceResp(arg) {
|
|
13114
|
-
if (!(arg instanceof
|
|
13340
|
+
if (!(arg instanceof avs_pb25.NonceResp)) {
|
|
13115
13341
|
throw new Error("Expected argument of type aggregator.NonceResp");
|
|
13116
13342
|
}
|
|
13117
13343
|
return Buffer.from(arg.serializeBinary());
|
|
13118
13344
|
}
|
|
13119
13345
|
function deserialize_aggregator_NonceResp(buffer_arg) {
|
|
13120
|
-
return
|
|
13346
|
+
return avs_pb25.NonceResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13121
13347
|
}
|
|
13122
13348
|
function serialize_aggregator_RunNodeWithInputsReq(arg) {
|
|
13123
|
-
if (!(arg instanceof
|
|
13349
|
+
if (!(arg instanceof avs_pb25.RunNodeWithInputsReq)) {
|
|
13124
13350
|
throw new Error("Expected argument of type aggregator.RunNodeWithInputsReq");
|
|
13125
13351
|
}
|
|
13126
13352
|
return Buffer.from(arg.serializeBinary());
|
|
13127
13353
|
}
|
|
13128
13354
|
function deserialize_aggregator_RunNodeWithInputsReq(buffer_arg) {
|
|
13129
|
-
return
|
|
13355
|
+
return avs_pb25.RunNodeWithInputsReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13130
13356
|
}
|
|
13131
13357
|
function serialize_aggregator_RunNodeWithInputsResp(arg) {
|
|
13132
|
-
if (!(arg instanceof
|
|
13358
|
+
if (!(arg instanceof avs_pb25.RunNodeWithInputsResp)) {
|
|
13133
13359
|
throw new Error("Expected argument of type aggregator.RunNodeWithInputsResp");
|
|
13134
13360
|
}
|
|
13135
13361
|
return Buffer.from(arg.serializeBinary());
|
|
13136
13362
|
}
|
|
13137
13363
|
function deserialize_aggregator_RunNodeWithInputsResp(buffer_arg) {
|
|
13138
|
-
return
|
|
13364
|
+
return avs_pb25.RunNodeWithInputsResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13139
13365
|
}
|
|
13140
13366
|
function serialize_aggregator_RunTriggerReq(arg) {
|
|
13141
|
-
if (!(arg instanceof
|
|
13367
|
+
if (!(arg instanceof avs_pb25.RunTriggerReq)) {
|
|
13142
13368
|
throw new Error("Expected argument of type aggregator.RunTriggerReq");
|
|
13143
13369
|
}
|
|
13144
13370
|
return Buffer.from(arg.serializeBinary());
|
|
13145
13371
|
}
|
|
13146
13372
|
function deserialize_aggregator_RunTriggerReq(buffer_arg) {
|
|
13147
|
-
return
|
|
13373
|
+
return avs_pb25.RunTriggerReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13148
13374
|
}
|
|
13149
13375
|
function serialize_aggregator_RunTriggerResp(arg) {
|
|
13150
|
-
if (!(arg instanceof
|
|
13376
|
+
if (!(arg instanceof avs_pb25.RunTriggerResp)) {
|
|
13151
13377
|
throw new Error("Expected argument of type aggregator.RunTriggerResp");
|
|
13152
13378
|
}
|
|
13153
13379
|
return Buffer.from(arg.serializeBinary());
|
|
13154
13380
|
}
|
|
13155
13381
|
function deserialize_aggregator_RunTriggerResp(buffer_arg) {
|
|
13156
|
-
return
|
|
13382
|
+
return avs_pb25.RunTriggerResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13157
13383
|
}
|
|
13158
13384
|
function serialize_aggregator_SetWalletReq(arg) {
|
|
13159
|
-
if (!(arg instanceof
|
|
13385
|
+
if (!(arg instanceof avs_pb25.SetWalletReq)) {
|
|
13160
13386
|
throw new Error("Expected argument of type aggregator.SetWalletReq");
|
|
13161
13387
|
}
|
|
13162
13388
|
return Buffer.from(arg.serializeBinary());
|
|
13163
13389
|
}
|
|
13164
13390
|
function deserialize_aggregator_SetWalletReq(buffer_arg) {
|
|
13165
|
-
return
|
|
13391
|
+
return avs_pb25.SetWalletReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13166
13392
|
}
|
|
13167
13393
|
function serialize_aggregator_Task(arg) {
|
|
13168
|
-
if (!(arg instanceof
|
|
13394
|
+
if (!(arg instanceof avs_pb25.Task)) {
|
|
13169
13395
|
throw new Error("Expected argument of type aggregator.Task");
|
|
13170
13396
|
}
|
|
13171
13397
|
return Buffer.from(arg.serializeBinary());
|
|
13172
13398
|
}
|
|
13173
13399
|
function deserialize_aggregator_Task(buffer_arg) {
|
|
13174
|
-
return
|
|
13400
|
+
return avs_pb25.Task.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13175
13401
|
}
|
|
13176
13402
|
function serialize_aggregator_UserTriggerTaskReq(arg) {
|
|
13177
|
-
if (!(arg instanceof
|
|
13403
|
+
if (!(arg instanceof avs_pb25.UserTriggerTaskReq)) {
|
|
13178
13404
|
throw new Error("Expected argument of type aggregator.UserTriggerTaskReq");
|
|
13179
13405
|
}
|
|
13180
13406
|
return Buffer.from(arg.serializeBinary());
|
|
13181
13407
|
}
|
|
13182
13408
|
function deserialize_aggregator_UserTriggerTaskReq(buffer_arg) {
|
|
13183
|
-
return
|
|
13409
|
+
return avs_pb25.UserTriggerTaskReq.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13184
13410
|
}
|
|
13185
13411
|
function serialize_aggregator_UserTriggerTaskResp(arg) {
|
|
13186
|
-
if (!(arg instanceof
|
|
13412
|
+
if (!(arg instanceof avs_pb25.UserTriggerTaskResp)) {
|
|
13187
13413
|
throw new Error("Expected argument of type aggregator.UserTriggerTaskResp");
|
|
13188
13414
|
}
|
|
13189
13415
|
return Buffer.from(arg.serializeBinary());
|
|
13190
13416
|
}
|
|
13191
13417
|
function deserialize_aggregator_UserTriggerTaskResp(buffer_arg) {
|
|
13192
|
-
return
|
|
13418
|
+
return avs_pb25.UserTriggerTaskResp.deserializeBinary(new Uint8Array(buffer_arg));
|
|
13193
13419
|
}
|
|
13194
13420
|
function serialize_google_protobuf_BoolValue(arg) {
|
|
13195
13421
|
if (!(arg instanceof google_protobuf_wrappers_pb.BoolValue)) {
|
|
@@ -13206,8 +13432,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13206
13432
|
path: "/aggregator.Aggregator/GetKey",
|
|
13207
13433
|
requestStream: false,
|
|
13208
13434
|
responseStream: false,
|
|
13209
|
-
requestType:
|
|
13210
|
-
responseType:
|
|
13435
|
+
requestType: avs_pb25.GetKeyReq,
|
|
13436
|
+
responseType: avs_pb25.KeyResp,
|
|
13211
13437
|
requestSerialize: serialize_aggregator_GetKeyReq,
|
|
13212
13438
|
requestDeserialize: deserialize_aggregator_GetKeyReq,
|
|
13213
13439
|
responseSerialize: serialize_aggregator_KeyResp,
|
|
@@ -13218,8 +13444,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13218
13444
|
path: "/aggregator.Aggregator/GetSignatureFormat",
|
|
13219
13445
|
requestStream: false,
|
|
13220
13446
|
responseStream: false,
|
|
13221
|
-
requestType:
|
|
13222
|
-
responseType:
|
|
13447
|
+
requestType: avs_pb25.GetSignatureFormatReq,
|
|
13448
|
+
responseType: avs_pb25.GetSignatureFormatResp,
|
|
13223
13449
|
requestSerialize: serialize_aggregator_GetSignatureFormatReq,
|
|
13224
13450
|
requestDeserialize: deserialize_aggregator_GetSignatureFormatReq,
|
|
13225
13451
|
responseSerialize: serialize_aggregator_GetSignatureFormatResp,
|
|
@@ -13230,8 +13456,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13230
13456
|
path: "/aggregator.Aggregator/GetNonce",
|
|
13231
13457
|
requestStream: false,
|
|
13232
13458
|
responseStream: false,
|
|
13233
|
-
requestType:
|
|
13234
|
-
responseType:
|
|
13459
|
+
requestType: avs_pb25.NonceRequest,
|
|
13460
|
+
responseType: avs_pb25.NonceResp,
|
|
13235
13461
|
requestSerialize: serialize_aggregator_NonceRequest,
|
|
13236
13462
|
requestDeserialize: deserialize_aggregator_NonceRequest,
|
|
13237
13463
|
responseSerialize: serialize_aggregator_NonceResp,
|
|
@@ -13241,8 +13467,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13241
13467
|
path: "/aggregator.Aggregator/GetWallet",
|
|
13242
13468
|
requestStream: false,
|
|
13243
13469
|
responseStream: false,
|
|
13244
|
-
requestType:
|
|
13245
|
-
responseType:
|
|
13470
|
+
requestType: avs_pb25.GetWalletReq,
|
|
13471
|
+
responseType: avs_pb25.GetWalletResp,
|
|
13246
13472
|
requestSerialize: serialize_aggregator_GetWalletReq,
|
|
13247
13473
|
requestDeserialize: deserialize_aggregator_GetWalletReq,
|
|
13248
13474
|
responseSerialize: serialize_aggregator_GetWalletResp,
|
|
@@ -13252,8 +13478,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13252
13478
|
path: "/aggregator.Aggregator/SetWallet",
|
|
13253
13479
|
requestStream: false,
|
|
13254
13480
|
responseStream: false,
|
|
13255
|
-
requestType:
|
|
13256
|
-
responseType:
|
|
13481
|
+
requestType: avs_pb25.SetWalletReq,
|
|
13482
|
+
responseType: avs_pb25.GetWalletResp,
|
|
13257
13483
|
requestSerialize: serialize_aggregator_SetWalletReq,
|
|
13258
13484
|
requestDeserialize: deserialize_aggregator_SetWalletReq,
|
|
13259
13485
|
responseSerialize: serialize_aggregator_GetWalletResp,
|
|
@@ -13263,8 +13489,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13263
13489
|
path: "/aggregator.Aggregator/ListWallets",
|
|
13264
13490
|
requestStream: false,
|
|
13265
13491
|
responseStream: false,
|
|
13266
|
-
requestType:
|
|
13267
|
-
responseType:
|
|
13492
|
+
requestType: avs_pb25.ListWalletReq,
|
|
13493
|
+
responseType: avs_pb25.ListWalletResp,
|
|
13268
13494
|
requestSerialize: serialize_aggregator_ListWalletReq,
|
|
13269
13495
|
requestDeserialize: deserialize_aggregator_ListWalletReq,
|
|
13270
13496
|
responseSerialize: serialize_aggregator_ListWalletResp,
|
|
@@ -13275,8 +13501,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13275
13501
|
path: "/aggregator.Aggregator/CreateTask",
|
|
13276
13502
|
requestStream: false,
|
|
13277
13503
|
responseStream: false,
|
|
13278
|
-
requestType:
|
|
13279
|
-
responseType:
|
|
13504
|
+
requestType: avs_pb25.CreateTaskReq,
|
|
13505
|
+
responseType: avs_pb25.CreateTaskResp,
|
|
13280
13506
|
requestSerialize: serialize_aggregator_CreateTaskReq,
|
|
13281
13507
|
requestDeserialize: deserialize_aggregator_CreateTaskReq,
|
|
13282
13508
|
responseSerialize: serialize_aggregator_CreateTaskResp,
|
|
@@ -13286,8 +13512,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13286
13512
|
path: "/aggregator.Aggregator/ListTasks",
|
|
13287
13513
|
requestStream: false,
|
|
13288
13514
|
responseStream: false,
|
|
13289
|
-
requestType:
|
|
13290
|
-
responseType:
|
|
13515
|
+
requestType: avs_pb25.ListTasksReq,
|
|
13516
|
+
responseType: avs_pb25.ListTasksResp,
|
|
13291
13517
|
requestSerialize: serialize_aggregator_ListTasksReq,
|
|
13292
13518
|
requestDeserialize: deserialize_aggregator_ListTasksReq,
|
|
13293
13519
|
responseSerialize: serialize_aggregator_ListTasksResp,
|
|
@@ -13297,8 +13523,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13297
13523
|
path: "/aggregator.Aggregator/GetTask",
|
|
13298
13524
|
requestStream: false,
|
|
13299
13525
|
responseStream: false,
|
|
13300
|
-
requestType:
|
|
13301
|
-
responseType:
|
|
13526
|
+
requestType: avs_pb25.IdReq,
|
|
13527
|
+
responseType: avs_pb25.Task,
|
|
13302
13528
|
requestSerialize: serialize_aggregator_IdReq,
|
|
13303
13529
|
requestDeserialize: deserialize_aggregator_IdReq,
|
|
13304
13530
|
responseSerialize: serialize_aggregator_Task,
|
|
@@ -13308,8 +13534,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13308
13534
|
path: "/aggregator.Aggregator/ListExecutions",
|
|
13309
13535
|
requestStream: false,
|
|
13310
13536
|
responseStream: false,
|
|
13311
|
-
requestType:
|
|
13312
|
-
responseType:
|
|
13537
|
+
requestType: avs_pb25.ListExecutionsReq,
|
|
13538
|
+
responseType: avs_pb25.ListExecutionsResp,
|
|
13313
13539
|
requestSerialize: serialize_aggregator_ListExecutionsReq,
|
|
13314
13540
|
requestDeserialize: deserialize_aggregator_ListExecutionsReq,
|
|
13315
13541
|
responseSerialize: serialize_aggregator_ListExecutionsResp,
|
|
@@ -13319,8 +13545,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13319
13545
|
path: "/aggregator.Aggregator/GetExecution",
|
|
13320
13546
|
requestStream: false,
|
|
13321
13547
|
responseStream: false,
|
|
13322
|
-
requestType:
|
|
13323
|
-
responseType:
|
|
13548
|
+
requestType: avs_pb25.ExecutionReq,
|
|
13549
|
+
responseType: avs_pb25.Execution,
|
|
13324
13550
|
requestSerialize: serialize_aggregator_ExecutionReq,
|
|
13325
13551
|
requestDeserialize: deserialize_aggregator_ExecutionReq,
|
|
13326
13552
|
responseSerialize: serialize_aggregator_Execution,
|
|
@@ -13330,8 +13556,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13330
13556
|
path: "/aggregator.Aggregator/GetExecutionStatus",
|
|
13331
13557
|
requestStream: false,
|
|
13332
13558
|
responseStream: false,
|
|
13333
|
-
requestType:
|
|
13334
|
-
responseType:
|
|
13559
|
+
requestType: avs_pb25.ExecutionReq,
|
|
13560
|
+
responseType: avs_pb25.ExecutionStatusResp,
|
|
13335
13561
|
requestSerialize: serialize_aggregator_ExecutionReq,
|
|
13336
13562
|
requestDeserialize: deserialize_aggregator_ExecutionReq,
|
|
13337
13563
|
responseSerialize: serialize_aggregator_ExecutionStatusResp,
|
|
@@ -13341,7 +13567,7 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13341
13567
|
path: "/aggregator.Aggregator/CancelTask",
|
|
13342
13568
|
requestStream: false,
|
|
13343
13569
|
responseStream: false,
|
|
13344
|
-
requestType:
|
|
13570
|
+
requestType: avs_pb25.IdReq,
|
|
13345
13571
|
responseType: google_protobuf_wrappers_pb.BoolValue,
|
|
13346
13572
|
requestSerialize: serialize_aggregator_IdReq,
|
|
13347
13573
|
requestDeserialize: deserialize_aggregator_IdReq,
|
|
@@ -13352,7 +13578,7 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13352
13578
|
path: "/aggregator.Aggregator/DeleteTask",
|
|
13353
13579
|
requestStream: false,
|
|
13354
13580
|
responseStream: false,
|
|
13355
|
-
requestType:
|
|
13581
|
+
requestType: avs_pb25.IdReq,
|
|
13356
13582
|
responseType: google_protobuf_wrappers_pb.BoolValue,
|
|
13357
13583
|
requestSerialize: serialize_aggregator_IdReq,
|
|
13358
13584
|
requestDeserialize: deserialize_aggregator_IdReq,
|
|
@@ -13363,8 +13589,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13363
13589
|
path: "/aggregator.Aggregator/TriggerTask",
|
|
13364
13590
|
requestStream: false,
|
|
13365
13591
|
responseStream: false,
|
|
13366
|
-
requestType:
|
|
13367
|
-
responseType:
|
|
13592
|
+
requestType: avs_pb25.UserTriggerTaskReq,
|
|
13593
|
+
responseType: avs_pb25.UserTriggerTaskResp,
|
|
13368
13594
|
requestSerialize: serialize_aggregator_UserTriggerTaskReq,
|
|
13369
13595
|
requestDeserialize: deserialize_aggregator_UserTriggerTaskReq,
|
|
13370
13596
|
responseSerialize: serialize_aggregator_UserTriggerTaskResp,
|
|
@@ -13377,7 +13603,7 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13377
13603
|
path: "/aggregator.Aggregator/CreateSecret",
|
|
13378
13604
|
requestStream: false,
|
|
13379
13605
|
responseStream: false,
|
|
13380
|
-
requestType:
|
|
13606
|
+
requestType: avs_pb25.CreateOrUpdateSecretReq,
|
|
13381
13607
|
responseType: google_protobuf_wrappers_pb.BoolValue,
|
|
13382
13608
|
requestSerialize: serialize_aggregator_CreateOrUpdateSecretReq,
|
|
13383
13609
|
requestDeserialize: deserialize_aggregator_CreateOrUpdateSecretReq,
|
|
@@ -13388,7 +13614,7 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13388
13614
|
path: "/aggregator.Aggregator/DeleteSecret",
|
|
13389
13615
|
requestStream: false,
|
|
13390
13616
|
responseStream: false,
|
|
13391
|
-
requestType:
|
|
13617
|
+
requestType: avs_pb25.DeleteSecretReq,
|
|
13392
13618
|
responseType: google_protobuf_wrappers_pb.BoolValue,
|
|
13393
13619
|
requestSerialize: serialize_aggregator_DeleteSecretReq,
|
|
13394
13620
|
requestDeserialize: deserialize_aggregator_DeleteSecretReq,
|
|
@@ -13401,8 +13627,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13401
13627
|
path: "/aggregator.Aggregator/ListSecrets",
|
|
13402
13628
|
requestStream: false,
|
|
13403
13629
|
responseStream: false,
|
|
13404
|
-
requestType:
|
|
13405
|
-
responseType:
|
|
13630
|
+
requestType: avs_pb25.ListSecretsReq,
|
|
13631
|
+
responseType: avs_pb25.ListSecretsResp,
|
|
13406
13632
|
requestSerialize: serialize_aggregator_ListSecretsReq,
|
|
13407
13633
|
requestDeserialize: deserialize_aggregator_ListSecretsReq,
|
|
13408
13634
|
responseSerialize: serialize_aggregator_ListSecretsResp,
|
|
@@ -13414,7 +13640,7 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13414
13640
|
path: "/aggregator.Aggregator/UpdateSecret",
|
|
13415
13641
|
requestStream: false,
|
|
13416
13642
|
responseStream: false,
|
|
13417
|
-
requestType:
|
|
13643
|
+
requestType: avs_pb25.CreateOrUpdateSecretReq,
|
|
13418
13644
|
responseType: google_protobuf_wrappers_pb.BoolValue,
|
|
13419
13645
|
requestSerialize: serialize_aggregator_CreateOrUpdateSecretReq,
|
|
13420
13646
|
requestDeserialize: deserialize_aggregator_CreateOrUpdateSecretReq,
|
|
@@ -13431,8 +13657,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13431
13657
|
path: "/aggregator.Aggregator/GetWorkflowCount",
|
|
13432
13658
|
requestStream: false,
|
|
13433
13659
|
responseStream: false,
|
|
13434
|
-
requestType:
|
|
13435
|
-
responseType:
|
|
13660
|
+
requestType: avs_pb25.GetWorkflowCountReq,
|
|
13661
|
+
responseType: avs_pb25.GetWorkflowCountResp,
|
|
13436
13662
|
requestSerialize: serialize_aggregator_GetWorkflowCountReq,
|
|
13437
13663
|
requestDeserialize: deserialize_aggregator_GetWorkflowCountReq,
|
|
13438
13664
|
responseSerialize: serialize_aggregator_GetWorkflowCountResp,
|
|
@@ -13446,8 +13672,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13446
13672
|
path: "/aggregator.Aggregator/GetExecutionCount",
|
|
13447
13673
|
requestStream: false,
|
|
13448
13674
|
responseStream: false,
|
|
13449
|
-
requestType:
|
|
13450
|
-
responseType:
|
|
13675
|
+
requestType: avs_pb25.GetExecutionCountReq,
|
|
13676
|
+
responseType: avs_pb25.GetExecutionCountResp,
|
|
13451
13677
|
requestSerialize: serialize_aggregator_GetExecutionCountReq,
|
|
13452
13678
|
requestDeserialize: deserialize_aggregator_GetExecutionCountReq,
|
|
13453
13679
|
responseSerialize: serialize_aggregator_GetExecutionCountResp,
|
|
@@ -13460,8 +13686,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13460
13686
|
path: "/aggregator.Aggregator/GetExecutionStats",
|
|
13461
13687
|
requestStream: false,
|
|
13462
13688
|
responseStream: false,
|
|
13463
|
-
requestType:
|
|
13464
|
-
responseType:
|
|
13689
|
+
requestType: avs_pb25.GetExecutionStatsReq,
|
|
13690
|
+
responseType: avs_pb25.GetExecutionStatsResp,
|
|
13465
13691
|
requestSerialize: serialize_aggregator_GetExecutionStatsReq,
|
|
13466
13692
|
requestDeserialize: deserialize_aggregator_GetExecutionStatsReq,
|
|
13467
13693
|
responseSerialize: serialize_aggregator_GetExecutionStatsResp,
|
|
@@ -13472,8 +13698,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13472
13698
|
path: "/aggregator.Aggregator/RunNodeWithInputs",
|
|
13473
13699
|
requestStream: false,
|
|
13474
13700
|
responseStream: false,
|
|
13475
|
-
requestType:
|
|
13476
|
-
responseType:
|
|
13701
|
+
requestType: avs_pb25.RunNodeWithInputsReq,
|
|
13702
|
+
responseType: avs_pb25.RunNodeWithInputsResp,
|
|
13477
13703
|
requestSerialize: serialize_aggregator_RunNodeWithInputsReq,
|
|
13478
13704
|
requestDeserialize: deserialize_aggregator_RunNodeWithInputsReq,
|
|
13479
13705
|
responseSerialize: serialize_aggregator_RunNodeWithInputsResp,
|
|
@@ -13484,8 +13710,8 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13484
13710
|
path: "/aggregator.Aggregator/RunTrigger",
|
|
13485
13711
|
requestStream: false,
|
|
13486
13712
|
responseStream: false,
|
|
13487
|
-
requestType:
|
|
13488
|
-
responseType:
|
|
13713
|
+
requestType: avs_pb25.RunTriggerReq,
|
|
13714
|
+
responseType: avs_pb25.RunTriggerResp,
|
|
13489
13715
|
requestSerialize: serialize_aggregator_RunTriggerReq,
|
|
13490
13716
|
requestDeserialize: deserialize_aggregator_RunTriggerReq,
|
|
13491
13717
|
responseSerialize: serialize_aggregator_RunTriggerResp,
|
|
@@ -13498,12 +13724,11 @@ var require_avs_grpc_pb = __commonJS({
|
|
|
13498
13724
|
|
|
13499
13725
|
// src/index.ts
|
|
13500
13726
|
var import_avs_grpc_pb = __toESM(require_avs_grpc_pb());
|
|
13501
|
-
var
|
|
13502
|
-
import _5 from "lodash";
|
|
13727
|
+
var avs_pb24 = __toESM(require_avs_pb());
|
|
13503
13728
|
import { credentials, Metadata } from "@grpc/grpc-js";
|
|
13504
13729
|
|
|
13505
13730
|
// src/models/workflow.ts
|
|
13506
|
-
var
|
|
13731
|
+
var avs_pb19 = __toESM(require_avs_pb());
|
|
13507
13732
|
import _4 from "lodash";
|
|
13508
13733
|
|
|
13509
13734
|
// src/models/edge.ts
|
|
@@ -13527,6 +13752,9 @@ var Edge = class _Edge {
|
|
|
13527
13752
|
};
|
|
13528
13753
|
var edge_default = Edge;
|
|
13529
13754
|
|
|
13755
|
+
// src/models/trigger/factory.ts
|
|
13756
|
+
var avs_pb7 = __toESM(require_avs_pb());
|
|
13757
|
+
|
|
13530
13758
|
// src/models/trigger/block.ts
|
|
13531
13759
|
var avs_pb2 = __toESM(require_avs_pb());
|
|
13532
13760
|
|
|
@@ -13597,6 +13825,15 @@ var BlockTrigger2 = class _BlockTrigger extends interface_default {
|
|
|
13597
13825
|
getOutput() {
|
|
13598
13826
|
return this.output;
|
|
13599
13827
|
}
|
|
13828
|
+
/**
|
|
13829
|
+
* Extract output data from RunTriggerResp for block triggers
|
|
13830
|
+
* @param outputData - The RunTriggerResp containing block trigger output
|
|
13831
|
+
* @returns Plain JavaScript object with block trigger data
|
|
13832
|
+
*/
|
|
13833
|
+
static fromOutputData(outputData) {
|
|
13834
|
+
const blockOutput = outputData.getBlockTrigger();
|
|
13835
|
+
return blockOutput?.toObject() || null;
|
|
13836
|
+
}
|
|
13600
13837
|
};
|
|
13601
13838
|
var block_default = BlockTrigger2;
|
|
13602
13839
|
|
|
@@ -13639,13 +13876,22 @@ var CronTrigger2 = class _CronTrigger extends interface_default {
|
|
|
13639
13876
|
});
|
|
13640
13877
|
}
|
|
13641
13878
|
/**
|
|
13642
|
-
* Convert raw data from
|
|
13879
|
+
* Convert raw data from runTrigger response to CronOutput format
|
|
13643
13880
|
* @param rawData - The raw data from the gRPC response
|
|
13644
13881
|
* @returns {CronTriggerOutput | undefined} - The converted data
|
|
13645
13882
|
*/
|
|
13646
13883
|
getOutput() {
|
|
13647
13884
|
return this.output;
|
|
13648
13885
|
}
|
|
13886
|
+
/**
|
|
13887
|
+
* Extract output data from RunTriggerResp for cron triggers
|
|
13888
|
+
* @param outputData - The RunTriggerResp containing cron trigger output
|
|
13889
|
+
* @returns Plain JavaScript object with cron trigger data
|
|
13890
|
+
*/
|
|
13891
|
+
static fromOutputData(outputData) {
|
|
13892
|
+
const cronOutput = outputData.getCronTrigger();
|
|
13893
|
+
return cronOutput?.toObject() || null;
|
|
13894
|
+
}
|
|
13649
13895
|
};
|
|
13650
13896
|
var cron_default = CronTrigger2;
|
|
13651
13897
|
|
|
@@ -13713,13 +13959,22 @@ var EventTrigger2 = class _EventTrigger extends interface_default {
|
|
|
13713
13959
|
});
|
|
13714
13960
|
}
|
|
13715
13961
|
/**
|
|
13716
|
-
* Convert raw data from
|
|
13962
|
+
* Convert raw data from runTrigger response to EventOutput format
|
|
13717
13963
|
* @param rawData - The raw data from the gRPC response
|
|
13718
13964
|
* @returns {EventTriggerOutput | undefined} - The converted data
|
|
13719
13965
|
*/
|
|
13720
13966
|
getOutput() {
|
|
13721
13967
|
return this.output;
|
|
13722
13968
|
}
|
|
13969
|
+
/**
|
|
13970
|
+
* Extract output data from RunTriggerResp for event triggers
|
|
13971
|
+
* @param outputData - The RunTriggerResp containing event trigger output
|
|
13972
|
+
* @returns Plain JavaScript object with event trigger data
|
|
13973
|
+
*/
|
|
13974
|
+
static fromOutputData(outputData) {
|
|
13975
|
+
const eventOutput = outputData.getEventTrigger();
|
|
13976
|
+
return eventOutput?.toObject() || null;
|
|
13977
|
+
}
|
|
13723
13978
|
};
|
|
13724
13979
|
var event_default = EventTrigger2;
|
|
13725
13980
|
|
|
@@ -13762,13 +14017,22 @@ var FixedTimeTrigger2 = class _FixedTimeTrigger extends interface_default {
|
|
|
13762
14017
|
});
|
|
13763
14018
|
}
|
|
13764
14019
|
/**
|
|
13765
|
-
* Convert raw data from
|
|
14020
|
+
* Convert raw data from runTrigger response to FixedTimeOutput format
|
|
13766
14021
|
* @param rawData - The raw data from the gRPC response
|
|
13767
14022
|
* @returns {FixedTimeTriggerOutput | undefined} - The converted data
|
|
13768
14023
|
*/
|
|
13769
14024
|
getOutput() {
|
|
13770
14025
|
return this.output;
|
|
13771
14026
|
}
|
|
14027
|
+
/**
|
|
14028
|
+
* Extract output data from RunTriggerResp for fixed time triggers
|
|
14029
|
+
* @param outputData - The RunTriggerResp containing fixed time trigger output
|
|
14030
|
+
* @returns Plain JavaScript object with fixed time trigger data
|
|
14031
|
+
*/
|
|
14032
|
+
static fromOutputData(outputData) {
|
|
14033
|
+
const fixedTimeOutput = outputData.getFixedTimeTrigger();
|
|
14034
|
+
return fixedTimeOutput?.toObject() || null;
|
|
14035
|
+
}
|
|
13772
14036
|
};
|
|
13773
14037
|
var fixedTime_default = FixedTimeTrigger2;
|
|
13774
14038
|
|
|
@@ -13798,11 +14062,97 @@ var ManualTrigger = class _ManualTrigger extends interface_default {
|
|
|
13798
14062
|
getInputVariables() {
|
|
13799
14063
|
return this.data;
|
|
13800
14064
|
}
|
|
14065
|
+
/**
|
|
14066
|
+
* Convert raw data from runTrigger response to ManualOutput format
|
|
14067
|
+
* @param rawData - The raw data from the gRPC response
|
|
14068
|
+
* @returns {ManualTriggerOutput | undefined} - The converted data
|
|
14069
|
+
*/
|
|
14070
|
+
getOutput() {
|
|
14071
|
+
return this.output;
|
|
14072
|
+
}
|
|
14073
|
+
/**
|
|
14074
|
+
* Extract output data from RunTriggerResp for manual triggers
|
|
14075
|
+
* @param outputData - The RunTriggerResp containing manual trigger output
|
|
14076
|
+
* @returns Plain JavaScript object with manual trigger data
|
|
14077
|
+
*/
|
|
14078
|
+
static fromOutputData(outputData) {
|
|
14079
|
+
const manualOutput = outputData.getManualTrigger();
|
|
14080
|
+
return manualOutput?.toObject() || null;
|
|
14081
|
+
}
|
|
13801
14082
|
};
|
|
13802
14083
|
var manual_default = ManualTrigger;
|
|
13803
14084
|
|
|
13804
14085
|
// src/models/trigger/factory.ts
|
|
13805
14086
|
import { TriggerType as TriggerType6 } from "@avaprotocol/types";
|
|
14087
|
+
|
|
14088
|
+
// src/utils.ts
|
|
14089
|
+
import {
|
|
14090
|
+
Value as ProtobufValue,
|
|
14091
|
+
Struct as ProtobufStruct,
|
|
14092
|
+
ListValue as ProtobufListValue
|
|
14093
|
+
} from "google-protobuf/google/protobuf/struct_pb";
|
|
14094
|
+
function convertProtobufValueToJs(value) {
|
|
14095
|
+
if (!value) {
|
|
14096
|
+
return void 0;
|
|
14097
|
+
}
|
|
14098
|
+
switch (value.getKindCase()) {
|
|
14099
|
+
case ProtobufValue.KindCase.NULL_VALUE:
|
|
14100
|
+
return null;
|
|
14101
|
+
case ProtobufValue.KindCase.NUMBER_VALUE:
|
|
14102
|
+
return value.getNumberValue();
|
|
14103
|
+
case ProtobufValue.KindCase.STRING_VALUE:
|
|
14104
|
+
return value.getStringValue();
|
|
14105
|
+
case ProtobufValue.KindCase.BOOL_VALUE:
|
|
14106
|
+
return value.getBoolValue();
|
|
14107
|
+
case ProtobufValue.KindCase.STRUCT_VALUE: {
|
|
14108
|
+
const struct = value.getStructValue();
|
|
14109
|
+
if (!struct) return {};
|
|
14110
|
+
const jsObj = {};
|
|
14111
|
+
const fields = struct.getFieldsMap();
|
|
14112
|
+
fields.forEach((val, key) => {
|
|
14113
|
+
jsObj[key] = convertProtobufValueToJs(val);
|
|
14114
|
+
});
|
|
14115
|
+
return jsObj;
|
|
14116
|
+
}
|
|
14117
|
+
case ProtobufValue.KindCase.LIST_VALUE: {
|
|
14118
|
+
const list = value.getListValue();
|
|
14119
|
+
if (!list) return [];
|
|
14120
|
+
return list.getValuesList().map((item) => convertProtobufValueToJs(item));
|
|
14121
|
+
}
|
|
14122
|
+
case ProtobufValue.KindCase.KIND_NOT_SET:
|
|
14123
|
+
default:
|
|
14124
|
+
return void 0;
|
|
14125
|
+
}
|
|
14126
|
+
}
|
|
14127
|
+
function convertJSValueToProtobuf(value) {
|
|
14128
|
+
const protobufValue = new ProtobufValue();
|
|
14129
|
+
if (value === null || value === void 0) {
|
|
14130
|
+
protobufValue.setNullValue(0);
|
|
14131
|
+
} else if (typeof value === "number") {
|
|
14132
|
+
protobufValue.setNumberValue(value);
|
|
14133
|
+
} else if (typeof value === "string") {
|
|
14134
|
+
protobufValue.setStringValue(value);
|
|
14135
|
+
} else if (typeof value === "boolean") {
|
|
14136
|
+
protobufValue.setBoolValue(value);
|
|
14137
|
+
} else if (Array.isArray(value)) {
|
|
14138
|
+
const listValue = new ProtobufListValue();
|
|
14139
|
+
const convertedValues = value.map((item) => convertJSValueToProtobuf(item));
|
|
14140
|
+
listValue.setValuesList(convertedValues);
|
|
14141
|
+
protobufValue.setListValue(listValue);
|
|
14142
|
+
} else if (typeof value === "object") {
|
|
14143
|
+
const structValue = new ProtobufStruct();
|
|
14144
|
+
const fieldsMap = structValue.getFieldsMap();
|
|
14145
|
+
Object.entries(value).forEach(([key, val]) => {
|
|
14146
|
+
fieldsMap.set(key, convertJSValueToProtobuf(val));
|
|
14147
|
+
});
|
|
14148
|
+
protobufValue.setStructValue(structValue);
|
|
14149
|
+
} else {
|
|
14150
|
+
protobufValue.setStringValue(String(value));
|
|
14151
|
+
}
|
|
14152
|
+
return protobufValue;
|
|
14153
|
+
}
|
|
14154
|
+
|
|
14155
|
+
// src/models/trigger/factory.ts
|
|
13806
14156
|
var TriggerFactory = class {
|
|
13807
14157
|
/**
|
|
13808
14158
|
* Static factory method to create Trigger instances
|
|
@@ -13845,14 +14195,51 @@ var TriggerFactory = class {
|
|
|
13845
14195
|
throw new Error("Unknown trigger type");
|
|
13846
14196
|
}
|
|
13847
14197
|
}
|
|
14198
|
+
static fromOutputData(outputData) {
|
|
14199
|
+
let triggerOutput = null;
|
|
14200
|
+
let rawData = null;
|
|
14201
|
+
switch (outputData.getOutputDataCase()) {
|
|
14202
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.BLOCK_TRIGGER:
|
|
14203
|
+
triggerOutput = outputData.getBlockTrigger();
|
|
14204
|
+
break;
|
|
14205
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.FIXED_TIME_TRIGGER:
|
|
14206
|
+
triggerOutput = outputData.getFixedTimeTrigger();
|
|
14207
|
+
break;
|
|
14208
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.CRON_TRIGGER:
|
|
14209
|
+
triggerOutput = outputData.getCronTrigger();
|
|
14210
|
+
break;
|
|
14211
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.EVENT_TRIGGER:
|
|
14212
|
+
triggerOutput = outputData.getEventTrigger();
|
|
14213
|
+
break;
|
|
14214
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.MANUAL_TRIGGER:
|
|
14215
|
+
triggerOutput = outputData.getManualTrigger();
|
|
14216
|
+
break;
|
|
14217
|
+
case avs_pb7.RunTriggerResp.OutputDataCase.OUTPUT_DATA_NOT_SET:
|
|
14218
|
+
default:
|
|
14219
|
+
throw new Error(
|
|
14220
|
+
`Unsupported output data case: ${outputData.getOutputDataCase()}`
|
|
14221
|
+
);
|
|
14222
|
+
}
|
|
14223
|
+
if (!triggerOutput) {
|
|
14224
|
+
return null;
|
|
14225
|
+
}
|
|
14226
|
+
if (typeof triggerOutput.getData === "function") {
|
|
14227
|
+
rawData = triggerOutput.getData();
|
|
14228
|
+
if (rawData) {
|
|
14229
|
+
return convertProtobufValueToJs(rawData);
|
|
14230
|
+
}
|
|
14231
|
+
}
|
|
14232
|
+
return triggerOutput.toObject();
|
|
14233
|
+
}
|
|
13848
14234
|
};
|
|
13849
14235
|
var factory_default = TriggerFactory;
|
|
13850
14236
|
|
|
13851
14237
|
// src/models/node/factory.ts
|
|
14238
|
+
var avs_pb18 = __toESM(require_avs_pb());
|
|
13852
14239
|
import _3 from "lodash";
|
|
13853
14240
|
|
|
13854
14241
|
// src/models/node/interface.ts
|
|
13855
|
-
var
|
|
14242
|
+
var avs_pb8 = __toESM(require_avs_pb());
|
|
13856
14243
|
import { NodeType, NodeTypeGoConverter } from "@avaprotocol/types";
|
|
13857
14244
|
import _2 from "lodash";
|
|
13858
14245
|
var Node = class {
|
|
@@ -13863,9 +14250,9 @@ var Node = class {
|
|
|
13863
14250
|
this.data = props.data;
|
|
13864
14251
|
}
|
|
13865
14252
|
toRequest() {
|
|
13866
|
-
const request = new
|
|
14253
|
+
const request = new avs_pb8.TaskNode();
|
|
13867
14254
|
const raw = request.serializeBinary();
|
|
13868
|
-
const parsed =
|
|
14255
|
+
const parsed = avs_pb8.TaskNode.deserializeBinary(raw);
|
|
13869
14256
|
if (!_2.isEqual(request, parsed)) {
|
|
13870
14257
|
throw new Error("Invalid request object");
|
|
13871
14258
|
}
|
|
@@ -13875,7 +14262,7 @@ var Node = class {
|
|
|
13875
14262
|
var interface_default2 = Node;
|
|
13876
14263
|
|
|
13877
14264
|
// src/models/node/contractWrite.ts
|
|
13878
|
-
var
|
|
14265
|
+
var avs_pb9 = __toESM(require_avs_pb());
|
|
13879
14266
|
import { NodeType as NodeType2 } from "@avaprotocol/types";
|
|
13880
14267
|
var ContractWriteNode2 = class _ContractWriteNode extends interface_default2 {
|
|
13881
14268
|
constructor(props) {
|
|
@@ -13890,11 +14277,11 @@ var ContractWriteNode2 = class _ContractWriteNode extends interface_default2 {
|
|
|
13890
14277
|
});
|
|
13891
14278
|
}
|
|
13892
14279
|
toRequest() {
|
|
13893
|
-
const request = new
|
|
14280
|
+
const request = new avs_pb9.TaskNode();
|
|
13894
14281
|
request.setId(this.id);
|
|
13895
14282
|
request.setName(this.name);
|
|
13896
|
-
const nodeData = new
|
|
13897
|
-
const config = new
|
|
14283
|
+
const nodeData = new avs_pb9.ContractWriteNode();
|
|
14284
|
+
const config = new avs_pb9.ContractWriteNode.Config();
|
|
13898
14285
|
config.setContractAddress(this.data.contractAddress);
|
|
13899
14286
|
config.setCallData(this.data.callData);
|
|
13900
14287
|
config.setContractAbi(this.data.contractAbi);
|
|
@@ -13902,11 +14289,15 @@ var ContractWriteNode2 = class _ContractWriteNode extends interface_default2 {
|
|
|
13902
14289
|
request.setContractWrite(nodeData);
|
|
13903
14290
|
return request;
|
|
13904
14291
|
}
|
|
14292
|
+
static fromOutputData(outputData) {
|
|
14293
|
+
const contractWriteOutput = outputData.getContractWrite();
|
|
14294
|
+
return contractWriteOutput?.toObject() || null;
|
|
14295
|
+
}
|
|
13905
14296
|
};
|
|
13906
14297
|
var contractWrite_default = ContractWriteNode2;
|
|
13907
14298
|
|
|
13908
14299
|
// src/models/node/customCode.ts
|
|
13909
|
-
var
|
|
14300
|
+
var avs_pb10 = __toESM(require_avs_pb());
|
|
13910
14301
|
import { NodeType as NodeType3 } from "@avaprotocol/types";
|
|
13911
14302
|
var CustomCodeNode2 = class _CustomCodeNode extends interface_default2 {
|
|
13912
14303
|
constructor(props) {
|
|
@@ -13921,22 +14312,29 @@ var CustomCodeNode2 = class _CustomCodeNode extends interface_default2 {
|
|
|
13921
14312
|
});
|
|
13922
14313
|
}
|
|
13923
14314
|
toRequest() {
|
|
13924
|
-
const request = new
|
|
14315
|
+
const request = new avs_pb10.TaskNode();
|
|
13925
14316
|
request.setId(this.id);
|
|
13926
14317
|
request.setName(this.name);
|
|
13927
|
-
const nodeData = new
|
|
13928
|
-
const config = new
|
|
14318
|
+
const nodeData = new avs_pb10.CustomCodeNode();
|
|
14319
|
+
const config = new avs_pb10.CustomCodeNode.Config();
|
|
13929
14320
|
config.setLang(this.data.lang);
|
|
13930
14321
|
config.setSource(this.data.source);
|
|
13931
14322
|
nodeData.setConfig(config);
|
|
13932
14323
|
request.setCustomCode(nodeData);
|
|
13933
14324
|
return request;
|
|
13934
14325
|
}
|
|
14326
|
+
static fromOutputData(outputData) {
|
|
14327
|
+
const customCodeOutput = outputData.getCustomCode();
|
|
14328
|
+
if (customCodeOutput?.getData()) {
|
|
14329
|
+
return convertProtobufValueToJs(customCodeOutput.getData());
|
|
14330
|
+
}
|
|
14331
|
+
return null;
|
|
14332
|
+
}
|
|
13935
14333
|
};
|
|
13936
14334
|
var customCode_default = CustomCodeNode2;
|
|
13937
14335
|
|
|
13938
14336
|
// src/models/node/graphqlQuery.ts
|
|
13939
|
-
var
|
|
14337
|
+
var avs_pb11 = __toESM(require_avs_pb());
|
|
13940
14338
|
import { NodeType as NodeType4 } from "@avaprotocol/types";
|
|
13941
14339
|
var GraphQLQueryNode2 = class _GraphQLQueryNode extends interface_default2 {
|
|
13942
14340
|
constructor(props) {
|
|
@@ -13955,11 +14353,11 @@ var GraphQLQueryNode2 = class _GraphQLQueryNode extends interface_default2 {
|
|
|
13955
14353
|
});
|
|
13956
14354
|
}
|
|
13957
14355
|
toRequest() {
|
|
13958
|
-
const request = new
|
|
14356
|
+
const request = new avs_pb11.TaskNode();
|
|
13959
14357
|
request.setId(this.id);
|
|
13960
14358
|
request.setName(this.name);
|
|
13961
|
-
const nodeData = new
|
|
13962
|
-
const config = new
|
|
14359
|
+
const nodeData = new avs_pb11.GraphQLQueryNode();
|
|
14360
|
+
const config = new avs_pb11.GraphQLQueryNode.Config();
|
|
13963
14361
|
config.setUrl(this.data.url);
|
|
13964
14362
|
config.setQuery(this.data.query);
|
|
13965
14363
|
if (this.data.variablesMap && this.data.variablesMap.length > 0) {
|
|
@@ -13972,12 +14370,18 @@ var GraphQLQueryNode2 = class _GraphQLQueryNode extends interface_default2 {
|
|
|
13972
14370
|
request.setGraphqlQuery(nodeData);
|
|
13973
14371
|
return request;
|
|
13974
14372
|
}
|
|
14373
|
+
static fromOutputData(outputData) {
|
|
14374
|
+
const graphqlOutput = outputData.getGraphql();
|
|
14375
|
+
return graphqlOutput?.toObject() || null;
|
|
14376
|
+
}
|
|
13975
14377
|
};
|
|
13976
14378
|
var graphqlQuery_default = GraphQLQueryNode2;
|
|
13977
14379
|
|
|
13978
14380
|
// src/models/node/restApi.ts
|
|
13979
|
-
var
|
|
13980
|
-
import {
|
|
14381
|
+
var avs_pb12 = __toESM(require_avs_pb());
|
|
14382
|
+
import {
|
|
14383
|
+
NodeType as NodeType5
|
|
14384
|
+
} from "@avaprotocol/types";
|
|
13981
14385
|
var RestAPINode2 = class _RestAPINode extends interface_default2 {
|
|
13982
14386
|
constructor(props) {
|
|
13983
14387
|
super({ ...props, type: NodeType5.RestAPI, data: props.data });
|
|
@@ -13991,29 +14395,43 @@ var RestAPINode2 = class _RestAPINode extends interface_default2 {
|
|
|
13991
14395
|
});
|
|
13992
14396
|
}
|
|
13993
14397
|
toRequest() {
|
|
13994
|
-
const request = new
|
|
14398
|
+
const request = new avs_pb12.TaskNode();
|
|
13995
14399
|
request.setId(this.id);
|
|
13996
14400
|
request.setName(this.name);
|
|
13997
|
-
const nodeData = new
|
|
13998
|
-
const config = new
|
|
14401
|
+
const nodeData = new avs_pb12.RestAPINode();
|
|
14402
|
+
const config = new avs_pb12.RestAPINode.Config();
|
|
13999
14403
|
config.setUrl(this.data.url);
|
|
14000
14404
|
config.setMethod(this.data.method);
|
|
14001
14405
|
config.setBody(this.data.body || "");
|
|
14002
14406
|
if (this.data.headersMap && this.data.headersMap.length > 0) {
|
|
14003
14407
|
const headersMap = config.getHeadersMap();
|
|
14004
|
-
this.data.headersMap.forEach(
|
|
14005
|
-
|
|
14006
|
-
|
|
14408
|
+
this.data.headersMap.forEach(
|
|
14409
|
+
([key, value]) => {
|
|
14410
|
+
headersMap.set(key, value);
|
|
14411
|
+
}
|
|
14412
|
+
);
|
|
14007
14413
|
}
|
|
14008
14414
|
nodeData.setConfig(config);
|
|
14009
14415
|
request.setRestApi(nodeData);
|
|
14010
14416
|
return request;
|
|
14011
14417
|
}
|
|
14418
|
+
static fromOutputData(outputData) {
|
|
14419
|
+
const restApiOutput = outputData.getRestApi();
|
|
14420
|
+
if (!restApiOutput) {
|
|
14421
|
+
console.log("Debug RestAPI: No restApiOutput found");
|
|
14422
|
+
return null;
|
|
14423
|
+
}
|
|
14424
|
+
const rawData = restApiOutput.getData();
|
|
14425
|
+
if (rawData) {
|
|
14426
|
+
return convertProtobufValueToJs(rawData);
|
|
14427
|
+
}
|
|
14428
|
+
return restApiOutput.toObject();
|
|
14429
|
+
}
|
|
14012
14430
|
};
|
|
14013
14431
|
var restApi_default = RestAPINode2;
|
|
14014
14432
|
|
|
14015
14433
|
// src/models/node/contractRead.ts
|
|
14016
|
-
var
|
|
14434
|
+
var avs_pb13 = __toESM(require_avs_pb());
|
|
14017
14435
|
import { NodeType as NodeType6 } from "@avaprotocol/types";
|
|
14018
14436
|
var ContractReadNode2 = class _ContractReadNode extends interface_default2 {
|
|
14019
14437
|
constructor(props) {
|
|
@@ -14028,11 +14446,11 @@ var ContractReadNode2 = class _ContractReadNode extends interface_default2 {
|
|
|
14028
14446
|
});
|
|
14029
14447
|
}
|
|
14030
14448
|
toRequest() {
|
|
14031
|
-
const request = new
|
|
14449
|
+
const request = new avs_pb13.TaskNode();
|
|
14032
14450
|
request.setId(this.id);
|
|
14033
14451
|
request.setName(this.name);
|
|
14034
|
-
const nodeData = new
|
|
14035
|
-
const config = new
|
|
14452
|
+
const nodeData = new avs_pb13.ContractReadNode();
|
|
14453
|
+
const config = new avs_pb13.ContractReadNode.Config();
|
|
14036
14454
|
config.setContractAddress(this.data.contractAddress);
|
|
14037
14455
|
config.setCallData(this.data.callData);
|
|
14038
14456
|
config.setContractAbi(this.data.contractAbi);
|
|
@@ -14040,11 +14458,21 @@ var ContractReadNode2 = class _ContractReadNode extends interface_default2 {
|
|
|
14040
14458
|
request.setContractRead(nodeData);
|
|
14041
14459
|
return request;
|
|
14042
14460
|
}
|
|
14461
|
+
static fromOutputData(outputData) {
|
|
14462
|
+
const contractReadOutput = outputData.getContractRead();
|
|
14463
|
+
if (contractReadOutput && contractReadOutput.getDataList()) {
|
|
14464
|
+
const dataList = contractReadOutput.getDataList();
|
|
14465
|
+
return {
|
|
14466
|
+
dataList: dataList.map((value) => convertProtobufValueToJs(value))
|
|
14467
|
+
};
|
|
14468
|
+
}
|
|
14469
|
+
return null;
|
|
14470
|
+
}
|
|
14043
14471
|
};
|
|
14044
14472
|
var contractRead_default = ContractReadNode2;
|
|
14045
14473
|
|
|
14046
14474
|
// src/models/node/ethTransfer.ts
|
|
14047
|
-
var
|
|
14475
|
+
var avs_pb14 = __toESM(require_avs_pb());
|
|
14048
14476
|
import { NodeType as NodeType7 } from "@avaprotocol/types";
|
|
14049
14477
|
var ETHTransferNode2 = class _ETHTransferNode extends interface_default2 {
|
|
14050
14478
|
constructor(props) {
|
|
@@ -14059,23 +14487,27 @@ var ETHTransferNode2 = class _ETHTransferNode extends interface_default2 {
|
|
|
14059
14487
|
});
|
|
14060
14488
|
}
|
|
14061
14489
|
toRequest() {
|
|
14062
|
-
const request = new
|
|
14490
|
+
const request = new avs_pb14.TaskNode();
|
|
14063
14491
|
request.setId(this.id);
|
|
14064
14492
|
request.setName(this.name);
|
|
14065
|
-
const nodeData = new
|
|
14066
|
-
const config = new
|
|
14493
|
+
const nodeData = new avs_pb14.ETHTransferNode();
|
|
14494
|
+
const config = new avs_pb14.ETHTransferNode.Config();
|
|
14067
14495
|
config.setDestination(this.data.destination);
|
|
14068
14496
|
config.setAmount(this.data.amount);
|
|
14069
14497
|
nodeData.setConfig(config);
|
|
14070
14498
|
request.setEthTransfer(nodeData);
|
|
14071
14499
|
return request;
|
|
14072
14500
|
}
|
|
14501
|
+
static fromOutputData(outputData) {
|
|
14502
|
+
const ethTransferOutput = outputData.getEthTransfer();
|
|
14503
|
+
return ethTransferOutput?.toObject() || null;
|
|
14504
|
+
}
|
|
14073
14505
|
};
|
|
14074
14506
|
var ethTransfer_default = ETHTransferNode2;
|
|
14075
14507
|
|
|
14076
14508
|
// src/models/node/branch.ts
|
|
14077
14509
|
import { NodeType as NodeType8 } from "@avaprotocol/types";
|
|
14078
|
-
var
|
|
14510
|
+
var avs_pb15 = __toESM(require_avs_pb());
|
|
14079
14511
|
var BranchNode2 = class _BranchNode extends interface_default2 {
|
|
14080
14512
|
constructor(props) {
|
|
14081
14513
|
super({ ...props, type: NodeType8.Branch, data: props.data });
|
|
@@ -14089,15 +14521,15 @@ var BranchNode2 = class _BranchNode extends interface_default2 {
|
|
|
14089
14521
|
});
|
|
14090
14522
|
}
|
|
14091
14523
|
toRequest() {
|
|
14092
|
-
const request = new
|
|
14524
|
+
const request = new avs_pb15.TaskNode();
|
|
14093
14525
|
request.setId(this.id);
|
|
14094
14526
|
request.setName(this.name);
|
|
14095
|
-
const nodeData = new
|
|
14096
|
-
const config = new
|
|
14527
|
+
const nodeData = new avs_pb15.BranchNode();
|
|
14528
|
+
const config = new avs_pb15.BranchNode.Config();
|
|
14097
14529
|
if (this.data.conditionsList && this.data.conditionsList.length > 0) {
|
|
14098
14530
|
const conditionsList = this.data.conditionsList.map(
|
|
14099
14531
|
(condition) => {
|
|
14100
|
-
const conditionObj = new
|
|
14532
|
+
const conditionObj = new avs_pb15.BranchNode.Condition();
|
|
14101
14533
|
conditionObj.setId(condition.id);
|
|
14102
14534
|
conditionObj.setType(condition.type);
|
|
14103
14535
|
conditionObj.setExpression(condition.expression);
|
|
@@ -14110,12 +14542,16 @@ var BranchNode2 = class _BranchNode extends interface_default2 {
|
|
|
14110
14542
|
request.setBranch(nodeData);
|
|
14111
14543
|
return request;
|
|
14112
14544
|
}
|
|
14545
|
+
static fromOutputData(outputData) {
|
|
14546
|
+
const branchOutput = outputData.getBranch();
|
|
14547
|
+
return branchOutput?.toObject() || null;
|
|
14548
|
+
}
|
|
14113
14549
|
// TODO: do we need a getConditionId() to avoid exporting BranchNodeData?
|
|
14114
14550
|
};
|
|
14115
14551
|
var branch_default = BranchNode2;
|
|
14116
14552
|
|
|
14117
14553
|
// src/models/node/filter.ts
|
|
14118
|
-
var
|
|
14554
|
+
var avs_pb16 = __toESM(require_avs_pb());
|
|
14119
14555
|
import { NodeType as NodeType9 } from "@avaprotocol/types";
|
|
14120
14556
|
var FilterNode2 = class _FilterNode extends interface_default2 {
|
|
14121
14557
|
constructor(props) {
|
|
@@ -14130,22 +14566,26 @@ var FilterNode2 = class _FilterNode extends interface_default2 {
|
|
|
14130
14566
|
});
|
|
14131
14567
|
}
|
|
14132
14568
|
toRequest() {
|
|
14133
|
-
const request = new
|
|
14569
|
+
const request = new avs_pb16.TaskNode();
|
|
14134
14570
|
request.setId(this.id);
|
|
14135
14571
|
request.setName(this.name);
|
|
14136
|
-
const nodeData = new
|
|
14137
|
-
const config = new
|
|
14572
|
+
const nodeData = new avs_pb16.FilterNode();
|
|
14573
|
+
const config = new avs_pb16.FilterNode.Config();
|
|
14138
14574
|
config.setExpression(this.data.expression);
|
|
14139
14575
|
config.setSourceId(this.data.sourceId || "");
|
|
14140
14576
|
nodeData.setConfig(config);
|
|
14141
14577
|
request.setFilter(nodeData);
|
|
14142
14578
|
return request;
|
|
14143
14579
|
}
|
|
14580
|
+
static fromOutputData(outputData) {
|
|
14581
|
+
const filterOutput = outputData.getFilter();
|
|
14582
|
+
return filterOutput?.toObject() || null;
|
|
14583
|
+
}
|
|
14144
14584
|
};
|
|
14145
14585
|
var filter_default = FilterNode2;
|
|
14146
14586
|
|
|
14147
14587
|
// src/models/node/loop.ts
|
|
14148
|
-
var
|
|
14588
|
+
var avs_pb17 = __toESM(require_avs_pb());
|
|
14149
14589
|
import { NodeType as NodeType10 } from "@avaprotocol/types";
|
|
14150
14590
|
var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
14151
14591
|
constructor(props) {
|
|
@@ -14176,29 +14616,29 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14176
14616
|
});
|
|
14177
14617
|
}
|
|
14178
14618
|
toRequest() {
|
|
14179
|
-
const node = new
|
|
14180
|
-
const loopNode = new
|
|
14619
|
+
const node = new avs_pb17.TaskNode();
|
|
14620
|
+
const loopNode = new avs_pb17.LoopNode();
|
|
14181
14621
|
node.setId(this.id);
|
|
14182
14622
|
node.setName(this.name);
|
|
14183
14623
|
const data = this.data;
|
|
14184
|
-
const config = new
|
|
14624
|
+
const config = new avs_pb17.LoopNode.Config();
|
|
14185
14625
|
config.setSourceId(data.sourceId || "");
|
|
14186
14626
|
config.setIterVal(data.iterVal || "");
|
|
14187
14627
|
config.setIterKey(data.iterKey || "");
|
|
14188
14628
|
loopNode.setConfig(config);
|
|
14189
14629
|
if (data.ethTransfer) {
|
|
14190
|
-
const ethTransfer = new
|
|
14630
|
+
const ethTransfer = new avs_pb17.ETHTransferNode();
|
|
14191
14631
|
if (data.ethTransfer.config) {
|
|
14192
|
-
const config2 = new
|
|
14632
|
+
const config2 = new avs_pb17.ETHTransferNode.Config();
|
|
14193
14633
|
config2.setDestination(data.ethTransfer.config.destination);
|
|
14194
14634
|
config2.setAmount(data.ethTransfer.config.amount);
|
|
14195
14635
|
ethTransfer.setConfig(config2);
|
|
14196
14636
|
}
|
|
14197
14637
|
loopNode.setEthTransfer(ethTransfer);
|
|
14198
14638
|
} else if (data.contractWrite) {
|
|
14199
|
-
const contractWrite = new
|
|
14639
|
+
const contractWrite = new avs_pb17.ContractWriteNode();
|
|
14200
14640
|
if (data.contractWrite.config) {
|
|
14201
|
-
const config2 = new
|
|
14641
|
+
const config2 = new avs_pb17.ContractWriteNode.Config();
|
|
14202
14642
|
config2.setContractAddress(data.contractWrite.config.contractAddress);
|
|
14203
14643
|
config2.setCallData(data.contractWrite.config.callData);
|
|
14204
14644
|
config2.setContractAbi(data.contractWrite.config.contractAbi);
|
|
@@ -14206,9 +14646,9 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14206
14646
|
}
|
|
14207
14647
|
loopNode.setContractWrite(contractWrite);
|
|
14208
14648
|
} else if (data.contractRead) {
|
|
14209
|
-
const contractRead = new
|
|
14649
|
+
const contractRead = new avs_pb17.ContractReadNode();
|
|
14210
14650
|
if (data.contractRead.config) {
|
|
14211
|
-
const config2 = new
|
|
14651
|
+
const config2 = new avs_pb17.ContractReadNode.Config();
|
|
14212
14652
|
config2.setContractAddress(data.contractRead.config.contractAddress);
|
|
14213
14653
|
config2.setCallData(data.contractRead.config.callData);
|
|
14214
14654
|
config2.setContractAbi(data.contractRead.config.contractAbi);
|
|
@@ -14216,9 +14656,9 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14216
14656
|
}
|
|
14217
14657
|
loopNode.setContractRead(contractRead);
|
|
14218
14658
|
} else if (data.graphqlDataQuery) {
|
|
14219
|
-
const graphqlQuery = new
|
|
14659
|
+
const graphqlQuery = new avs_pb17.GraphQLQueryNode();
|
|
14220
14660
|
if (data.graphqlDataQuery.config) {
|
|
14221
|
-
const config2 = new
|
|
14661
|
+
const config2 = new avs_pb17.GraphQLQueryNode.Config();
|
|
14222
14662
|
config2.setUrl(data.graphqlDataQuery.config.url);
|
|
14223
14663
|
config2.setQuery(data.graphqlDataQuery.config.query);
|
|
14224
14664
|
if (data.graphqlDataQuery.config.variablesMap && data.graphqlDataQuery.config.variablesMap.length > 0) {
|
|
@@ -14230,9 +14670,9 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14230
14670
|
}
|
|
14231
14671
|
loopNode.setGraphqlDataQuery(graphqlQuery);
|
|
14232
14672
|
} else if (data.restApi) {
|
|
14233
|
-
const restApi = new
|
|
14673
|
+
const restApi = new avs_pb17.RestAPINode();
|
|
14234
14674
|
if (data.restApi.config) {
|
|
14235
|
-
const config2 = new
|
|
14675
|
+
const config2 = new avs_pb17.RestAPINode.Config();
|
|
14236
14676
|
config2.setUrl(data.restApi.config.url);
|
|
14237
14677
|
config2.setMethod(data.restApi.config.method);
|
|
14238
14678
|
config2.setBody(data.restApi.config.body || "");
|
|
@@ -14245,9 +14685,9 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14245
14685
|
}
|
|
14246
14686
|
loopNode.setRestApi(restApi);
|
|
14247
14687
|
} else if (data.customCode) {
|
|
14248
|
-
const customCode = new
|
|
14688
|
+
const customCode = new avs_pb17.CustomCodeNode();
|
|
14249
14689
|
if (data.customCode.config) {
|
|
14250
|
-
const config2 = new
|
|
14690
|
+
const config2 = new avs_pb17.CustomCodeNode.Config();
|
|
14251
14691
|
config2.setLang(data.customCode.config.lang);
|
|
14252
14692
|
config2.setSource(data.customCode.config.source);
|
|
14253
14693
|
customCode.setConfig(config2);
|
|
@@ -14257,6 +14697,10 @@ var LoopNode2 = class _LoopNode extends interface_default2 {
|
|
|
14257
14697
|
node.setLoop(loopNode);
|
|
14258
14698
|
return node;
|
|
14259
14699
|
}
|
|
14700
|
+
static fromOutputData(outputData) {
|
|
14701
|
+
const loopOutput = outputData.getLoop();
|
|
14702
|
+
return loopOutput?.toObject() || null;
|
|
14703
|
+
}
|
|
14260
14704
|
};
|
|
14261
14705
|
var loop_default = LoopNode2;
|
|
14262
14706
|
|
|
@@ -14319,6 +14763,52 @@ var NodeFactory = class {
|
|
|
14319
14763
|
throw new Error(`Unsupported node type: ${raw.getName()}`);
|
|
14320
14764
|
}
|
|
14321
14765
|
}
|
|
14766
|
+
static fromOutputData(outputData) {
|
|
14767
|
+
let nodeOutput = null;
|
|
14768
|
+
let rawData = null;
|
|
14769
|
+
switch (outputData.getOutputDataCase()) {
|
|
14770
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.REST_API:
|
|
14771
|
+
nodeOutput = outputData.getRestApi();
|
|
14772
|
+
break;
|
|
14773
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.CUSTOM_CODE:
|
|
14774
|
+
nodeOutput = outputData.getCustomCode();
|
|
14775
|
+
break;
|
|
14776
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.CONTRACT_READ:
|
|
14777
|
+
nodeOutput = outputData.getContractRead();
|
|
14778
|
+
break;
|
|
14779
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.CONTRACT_WRITE:
|
|
14780
|
+
nodeOutput = outputData.getContractWrite();
|
|
14781
|
+
break;
|
|
14782
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.ETH_TRANSFER:
|
|
14783
|
+
nodeOutput = outputData.getEthTransfer();
|
|
14784
|
+
break;
|
|
14785
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.GRAPHQL:
|
|
14786
|
+
nodeOutput = outputData.getGraphql();
|
|
14787
|
+
break;
|
|
14788
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.BRANCH:
|
|
14789
|
+
nodeOutput = outputData.getBranch();
|
|
14790
|
+
break;
|
|
14791
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.FILTER:
|
|
14792
|
+
nodeOutput = outputData.getFilter();
|
|
14793
|
+
break;
|
|
14794
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.LOOP:
|
|
14795
|
+
nodeOutput = outputData.getLoop();
|
|
14796
|
+
break;
|
|
14797
|
+
case avs_pb18.RunNodeWithInputsResp.OutputDataCase.OUTPUT_DATA_NOT_SET:
|
|
14798
|
+
default:
|
|
14799
|
+
throw new Error(`Unsupported output data case: ${outputData.getOutputDataCase()}`);
|
|
14800
|
+
}
|
|
14801
|
+
if (!nodeOutput) {
|
|
14802
|
+
return null;
|
|
14803
|
+
}
|
|
14804
|
+
if (typeof nodeOutput.getData === "function") {
|
|
14805
|
+
rawData = nodeOutput.getData();
|
|
14806
|
+
if (rawData) {
|
|
14807
|
+
return convertProtobufValueToJs(rawData);
|
|
14808
|
+
}
|
|
14809
|
+
}
|
|
14810
|
+
return nodeOutput.toObject();
|
|
14811
|
+
}
|
|
14322
14812
|
};
|
|
14323
14813
|
var factory_default2 = NodeFactory;
|
|
14324
14814
|
|
|
@@ -14326,11 +14816,11 @@ var factory_default2 = NodeFactory;
|
|
|
14326
14816
|
import { WorkflowStatus } from "@avaprotocol/types";
|
|
14327
14817
|
function convertStatusToString(status) {
|
|
14328
14818
|
const conversionMap = {
|
|
14329
|
-
[
|
|
14330
|
-
[
|
|
14331
|
-
[
|
|
14332
|
-
[
|
|
14333
|
-
[
|
|
14819
|
+
[avs_pb19.TaskStatus.ACTIVE]: WorkflowStatus.Active,
|
|
14820
|
+
[avs_pb19.TaskStatus.COMPLETED]: WorkflowStatus.Completed,
|
|
14821
|
+
[avs_pb19.TaskStatus.FAILED]: WorkflowStatus.Failed,
|
|
14822
|
+
[avs_pb19.TaskStatus.CANCELED]: WorkflowStatus.Canceled,
|
|
14823
|
+
[avs_pb19.TaskStatus.EXECUTING]: WorkflowStatus.Executing
|
|
14334
14824
|
};
|
|
14335
14825
|
return conversionMap[status];
|
|
14336
14826
|
}
|
|
@@ -14418,7 +14908,7 @@ var Workflow = class _Workflow {
|
|
|
14418
14908
|
});
|
|
14419
14909
|
}
|
|
14420
14910
|
toRequest() {
|
|
14421
|
-
const request = new
|
|
14911
|
+
const request = new avs_pb19.CreateTaskReq();
|
|
14422
14912
|
request.setSmartWalletAddress(this.smartWalletAddress);
|
|
14423
14913
|
request.setTrigger(this.trigger.toRequest());
|
|
14424
14914
|
_4.map(this.nodes, (node) => request.addNodes(node.toRequest()));
|
|
@@ -14435,19 +14925,19 @@ var Workflow = class _Workflow {
|
|
|
14435
14925
|
var workflow_default = Workflow;
|
|
14436
14926
|
|
|
14437
14927
|
// src/models/execution.ts
|
|
14438
|
-
var
|
|
14928
|
+
var avs_pb22 = __toESM(require_avs_pb());
|
|
14439
14929
|
|
|
14440
14930
|
// src/models/trigger/reason.ts
|
|
14441
|
-
var
|
|
14931
|
+
var avs_pb20 = __toESM(require_avs_pb());
|
|
14442
14932
|
import { TriggerType as TriggerType8 } from "@avaprotocol/types";
|
|
14443
14933
|
var convertTriggerType = (grpcType) => {
|
|
14444
14934
|
const conversionMap = {
|
|
14445
|
-
[
|
|
14446
|
-
[
|
|
14447
|
-
[
|
|
14448
|
-
[
|
|
14449
|
-
[
|
|
14450
|
-
[
|
|
14935
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_FIXED_TIME]: TriggerType8.FixedTime,
|
|
14936
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_CRON]: TriggerType8.Cron,
|
|
14937
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_BLOCK]: TriggerType8.Block,
|
|
14938
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_EVENT]: TriggerType8.Event,
|
|
14939
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_MANUAL]: TriggerType8.Manual,
|
|
14940
|
+
[avs_pb20.TriggerType.TRIGGER_TYPE_UNSPECIFIED]: TriggerType8.Unspecified
|
|
14451
14941
|
};
|
|
14452
14942
|
return conversionMap[grpcType];
|
|
14453
14943
|
};
|
|
@@ -14487,28 +14977,28 @@ var TriggerReason2 = class _TriggerReason {
|
|
|
14487
14977
|
});
|
|
14488
14978
|
}
|
|
14489
14979
|
toRequest() {
|
|
14490
|
-
const request = new
|
|
14980
|
+
const request = new avs_pb20.TriggerReason();
|
|
14491
14981
|
switch (this.type) {
|
|
14492
14982
|
case TriggerType8.FixedTime:
|
|
14493
|
-
request.setType(
|
|
14983
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_FIXED_TIME);
|
|
14494
14984
|
if (this.epoch) {
|
|
14495
14985
|
request.setEpoch(this.epoch);
|
|
14496
14986
|
}
|
|
14497
14987
|
break;
|
|
14498
14988
|
case TriggerType8.Cron:
|
|
14499
|
-
request.setType(
|
|
14989
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_CRON);
|
|
14500
14990
|
if (this.epoch) {
|
|
14501
14991
|
request.setEpoch(this.epoch);
|
|
14502
14992
|
}
|
|
14503
14993
|
break;
|
|
14504
14994
|
case TriggerType8.Block:
|
|
14505
|
-
request.setType(
|
|
14995
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_BLOCK);
|
|
14506
14996
|
if (this.blockNumber) {
|
|
14507
14997
|
request.setBlockNumber(this.blockNumber);
|
|
14508
14998
|
}
|
|
14509
14999
|
break;
|
|
14510
15000
|
case TriggerType8.Event:
|
|
14511
|
-
request.setType(
|
|
15001
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_EVENT);
|
|
14512
15002
|
if (this.blockNumber) {
|
|
14513
15003
|
request.setBlockNumber(this.blockNumber);
|
|
14514
15004
|
}
|
|
@@ -14520,10 +15010,10 @@ var TriggerReason2 = class _TriggerReason {
|
|
|
14520
15010
|
}
|
|
14521
15011
|
break;
|
|
14522
15012
|
case TriggerType8.Manual:
|
|
14523
|
-
request.setType(
|
|
15013
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_MANUAL);
|
|
14524
15014
|
break;
|
|
14525
15015
|
case TriggerType8.Unspecified:
|
|
14526
|
-
request.setType(
|
|
15016
|
+
request.setType(avs_pb20.TriggerType.TRIGGER_TYPE_UNSPECIFIED);
|
|
14527
15017
|
break;
|
|
14528
15018
|
default:
|
|
14529
15019
|
throw new Error("Unsupported trigger type");
|
|
@@ -14534,45 +15024,7 @@ var TriggerReason2 = class _TriggerReason {
|
|
|
14534
15024
|
var reason_default = TriggerReason2;
|
|
14535
15025
|
|
|
14536
15026
|
// src/models/step.ts
|
|
14537
|
-
var
|
|
14538
|
-
|
|
14539
|
-
// src/utils.ts
|
|
14540
|
-
import { Value as ProtobufValue } from "google-protobuf/google/protobuf/struct_pb";
|
|
14541
|
-
function convertProtobufValueToJs(value) {
|
|
14542
|
-
if (!value) {
|
|
14543
|
-
return void 0;
|
|
14544
|
-
}
|
|
14545
|
-
switch (value.getKindCase()) {
|
|
14546
|
-
case ProtobufValue.KindCase.NULL_VALUE:
|
|
14547
|
-
return null;
|
|
14548
|
-
case ProtobufValue.KindCase.NUMBER_VALUE:
|
|
14549
|
-
return value.getNumberValue();
|
|
14550
|
-
case ProtobufValue.KindCase.STRING_VALUE:
|
|
14551
|
-
return value.getStringValue();
|
|
14552
|
-
case ProtobufValue.KindCase.BOOL_VALUE:
|
|
14553
|
-
return value.getBoolValue();
|
|
14554
|
-
case ProtobufValue.KindCase.STRUCT_VALUE: {
|
|
14555
|
-
const struct = value.getStructValue();
|
|
14556
|
-
if (!struct) return {};
|
|
14557
|
-
const jsObj = {};
|
|
14558
|
-
const fields = struct.getFieldsMap();
|
|
14559
|
-
fields.forEach((val, key) => {
|
|
14560
|
-
jsObj[key] = convertProtobufValueToJs(val);
|
|
14561
|
-
});
|
|
14562
|
-
return jsObj;
|
|
14563
|
-
}
|
|
14564
|
-
case ProtobufValue.KindCase.LIST_VALUE: {
|
|
14565
|
-
const list = value.getListValue();
|
|
14566
|
-
if (!list) return [];
|
|
14567
|
-
return list.getValuesList().map((item) => convertProtobufValueToJs(item));
|
|
14568
|
-
}
|
|
14569
|
-
case ProtobufValue.KindCase.KIND_NOT_SET:
|
|
14570
|
-
default:
|
|
14571
|
-
return void 0;
|
|
14572
|
-
}
|
|
14573
|
-
}
|
|
14574
|
-
|
|
14575
|
-
// src/models/step.ts
|
|
15027
|
+
var avs_pb21 = __toESM(require_avs_pb());
|
|
14576
15028
|
var Step = class _Step {
|
|
14577
15029
|
// Changed to any
|
|
14578
15030
|
constructor(props) {
|
|
@@ -14589,37 +15041,37 @@ var Step = class _Step {
|
|
|
14589
15041
|
const outputDataType = step.getOutputDataCase();
|
|
14590
15042
|
let nodeOutputMessage;
|
|
14591
15043
|
switch (outputDataType) {
|
|
14592
|
-
case
|
|
15044
|
+
case avs_pb21.Execution.Step.OutputDataCase.OUTPUT_DATA_NOT_SET:
|
|
14593
15045
|
return null;
|
|
14594
|
-
case
|
|
15046
|
+
case avs_pb21.Execution.Step.OutputDataCase.ETH_TRANSFER:
|
|
14595
15047
|
return step.getEthTransfer()?.toObject();
|
|
14596
15048
|
// Specific structure, not google.protobuf.Value
|
|
14597
|
-
case
|
|
15049
|
+
case avs_pb21.Execution.Step.OutputDataCase.GRAPHQL:
|
|
14598
15050
|
nodeOutputMessage = step.getGraphql();
|
|
14599
15051
|
return nodeOutputMessage && nodeOutputMessage.hasData() ? nodeOutputMessage.getData() : void 0;
|
|
14600
|
-
case
|
|
15052
|
+
case avs_pb21.Execution.Step.OutputDataCase.CONTRACT_READ:
|
|
14601
15053
|
nodeOutputMessage = step.getContractRead();
|
|
14602
15054
|
if (nodeOutputMessage) {
|
|
14603
15055
|
return nodeOutputMessage.getDataList().map((val) => convertProtobufValueToJs(val));
|
|
14604
15056
|
}
|
|
14605
15057
|
return [];
|
|
14606
15058
|
// Default to empty array if no data
|
|
14607
|
-
case
|
|
15059
|
+
case avs_pb21.Execution.Step.OutputDataCase.CONTRACT_WRITE:
|
|
14608
15060
|
return step.getContractWrite()?.toObject();
|
|
14609
15061
|
// Specific structure
|
|
14610
|
-
case
|
|
15062
|
+
case avs_pb21.Execution.Step.OutputDataCase.CUSTOM_CODE:
|
|
14611
15063
|
nodeOutputMessage = step.getCustomCode();
|
|
14612
15064
|
return nodeOutputMessage && nodeOutputMessage.hasData() ? convertProtobufValueToJs(nodeOutputMessage.getData()) : void 0;
|
|
14613
|
-
case
|
|
15065
|
+
case avs_pb21.Execution.Step.OutputDataCase.REST_API:
|
|
14614
15066
|
nodeOutputMessage = step.getRestApi();
|
|
14615
15067
|
return nodeOutputMessage && nodeOutputMessage.hasData() ? nodeOutputMessage.getData() : void 0;
|
|
14616
|
-
case
|
|
15068
|
+
case avs_pb21.Execution.Step.OutputDataCase.BRANCH:
|
|
14617
15069
|
return step.getBranch()?.toObject();
|
|
14618
15070
|
// Specific structure
|
|
14619
|
-
case
|
|
15071
|
+
case avs_pb21.Execution.Step.OutputDataCase.FILTER:
|
|
14620
15072
|
nodeOutputMessage = step.getFilter();
|
|
14621
15073
|
return nodeOutputMessage && nodeOutputMessage.hasData() ? nodeOutputMessage.getData() : void 0;
|
|
14622
|
-
case
|
|
15074
|
+
case avs_pb21.Execution.Step.OutputDataCase.LOOP:
|
|
14623
15075
|
return step.getLoop()?.getData();
|
|
14624
15076
|
default:
|
|
14625
15077
|
console.warn(
|
|
@@ -14661,19 +15113,19 @@ var Execution3 = class _Execution {
|
|
|
14661
15113
|
const triggerOutputDataType = execution.getOutputDataCase();
|
|
14662
15114
|
let triggerOutputData;
|
|
14663
15115
|
switch (triggerOutputDataType) {
|
|
14664
|
-
case
|
|
15116
|
+
case avs_pb22.Execution.OutputDataCase.BLOCK_TRIGGER:
|
|
14665
15117
|
const blockOutput = execution.getBlockTrigger()?.toObject();
|
|
14666
15118
|
triggerOutputData = blockOutput ? { blockNumber: blockOutput.blockNumber } : void 0;
|
|
14667
15119
|
break;
|
|
14668
|
-
case
|
|
15120
|
+
case avs_pb22.Execution.OutputDataCase.FIXED_TIME_TRIGGER:
|
|
14669
15121
|
const fixedTimeOutput = execution.getFixedTimeTrigger()?.toObject();
|
|
14670
15122
|
triggerOutputData = fixedTimeOutput ? { epoch: fixedTimeOutput.epoch } : void 0;
|
|
14671
15123
|
break;
|
|
14672
|
-
case
|
|
15124
|
+
case avs_pb22.Execution.OutputDataCase.CRON_TRIGGER:
|
|
14673
15125
|
const cronOutput = execution.getCronTrigger()?.toObject();
|
|
14674
15126
|
triggerOutputData = cronOutput ? { epoch: cronOutput.epoch, scheduleMatched: cronOutput.scheduleMatched } : void 0;
|
|
14675
15127
|
break;
|
|
14676
|
-
case
|
|
15128
|
+
case avs_pb22.Execution.OutputDataCase.EVENT_TRIGGER:
|
|
14677
15129
|
const eventTrigger = execution.getEventTrigger();
|
|
14678
15130
|
if (eventTrigger) {
|
|
14679
15131
|
if (eventTrigger.hasEvmLog()) {
|
|
@@ -14683,7 +15135,7 @@ var Execution3 = class _Execution {
|
|
|
14683
15135
|
}
|
|
14684
15136
|
}
|
|
14685
15137
|
break;
|
|
14686
|
-
case
|
|
15138
|
+
case avs_pb22.Execution.OutputDataCase.OUTPUT_DATA_NOT_SET:
|
|
14687
15139
|
triggerOutputData = void 0;
|
|
14688
15140
|
break;
|
|
14689
15141
|
}
|
|
@@ -14704,7 +15156,7 @@ var Execution3 = class _Execution {
|
|
|
14704
15156
|
var execution_default = Execution3;
|
|
14705
15157
|
|
|
14706
15158
|
// src/models/secret.ts
|
|
14707
|
-
var
|
|
15159
|
+
var avs_pb23 = __toESM(require_avs_pb());
|
|
14708
15160
|
var Secret = class {
|
|
14709
15161
|
constructor(props) {
|
|
14710
15162
|
this.name = props.name;
|
|
@@ -14717,7 +15169,7 @@ var Secret = class {
|
|
|
14717
15169
|
this.description = props.description;
|
|
14718
15170
|
}
|
|
14719
15171
|
toRequest() {
|
|
14720
|
-
const request = new
|
|
15172
|
+
const request = new avs_pb23.CreateOrUpdateSecretReq();
|
|
14721
15173
|
request.setName(this.name);
|
|
14722
15174
|
if (this.secret) {
|
|
14723
15175
|
request.setSecret(this.secret);
|
|
@@ -14772,7 +15224,7 @@ var BaseClient = class {
|
|
|
14772
15224
|
* @returns {Promise<GetSignatureFormatResponse>} - The response containing the signature format
|
|
14773
15225
|
*/
|
|
14774
15226
|
async getSignatureFormat(wallet) {
|
|
14775
|
-
const request = new
|
|
15227
|
+
const request = new avs_pb24.GetSignatureFormatReq();
|
|
14776
15228
|
request.setWallet(wallet);
|
|
14777
15229
|
const result = await this.sendGrpcRequest("getSignatureFormat", request);
|
|
14778
15230
|
return { message: result.getMessage() };
|
|
@@ -14787,7 +15239,7 @@ var BaseClient = class {
|
|
|
14787
15239
|
message,
|
|
14788
15240
|
apiKey
|
|
14789
15241
|
}) {
|
|
14790
|
-
const request = new
|
|
15242
|
+
const request = new avs_pb24.GetKeyReq();
|
|
14791
15243
|
request.setMessage(message);
|
|
14792
15244
|
request.setSignature(apiKey);
|
|
14793
15245
|
const result = await this.sendGrpcRequest("getKey", request);
|
|
@@ -14803,7 +15255,7 @@ var BaseClient = class {
|
|
|
14803
15255
|
message,
|
|
14804
15256
|
signature
|
|
14805
15257
|
}) {
|
|
14806
|
-
const request = new
|
|
15258
|
+
const request = new avs_pb24.GetKeyReq();
|
|
14807
15259
|
request.setMessage(message);
|
|
14808
15260
|
request.setSignature(signature);
|
|
14809
15261
|
const result = await this.sendGrpcRequest(
|
|
@@ -14842,112 +15294,32 @@ var BaseClient = class {
|
|
|
14842
15294
|
return this.factoryAddress;
|
|
14843
15295
|
}
|
|
14844
15296
|
/**
|
|
14845
|
-
* Send a gRPC request with
|
|
14846
|
-
* @param method - The method name
|
|
14847
|
-
* @param request - The request
|
|
14848
|
-
* @param options -
|
|
14849
|
-
* @returns {Promise<TResponse>} - The response from the
|
|
15297
|
+
* Send a gRPC request with authentication and error handling
|
|
15298
|
+
* @param method - The method name to call
|
|
15299
|
+
* @param request - The request object
|
|
15300
|
+
* @param options - Request options
|
|
15301
|
+
* @returns {Promise<TResponse>} - The response from the server
|
|
14850
15302
|
*/
|
|
14851
15303
|
sendGrpcRequest(method, request, options) {
|
|
14852
|
-
const metadata = _5.cloneDeep(this.metadata);
|
|
14853
|
-
if (options?.authKey) {
|
|
14854
|
-
metadata.set(AUTH_KEY_HEADER, options.authKey);
|
|
14855
|
-
} else if (this.authKey) {
|
|
14856
|
-
metadata.set(AUTH_KEY_HEADER, this.authKey);
|
|
14857
|
-
}
|
|
14858
15304
|
return new Promise((resolve, reject) => {
|
|
14859
|
-
|
|
15305
|
+
const metadata = new Metadata();
|
|
15306
|
+
const authKey = options?.authKey || this.authKey;
|
|
15307
|
+
if (authKey) {
|
|
15308
|
+
metadata.set(AUTH_KEY_HEADER, authKey);
|
|
15309
|
+
}
|
|
15310
|
+
this.rpcClient[method](
|
|
14860
15311
|
request,
|
|
14861
15312
|
metadata,
|
|
14862
15313
|
(error, response) => {
|
|
14863
|
-
if (error)
|
|
14864
|
-
|
|
15314
|
+
if (error) {
|
|
15315
|
+
reject(error);
|
|
15316
|
+
} else {
|
|
15317
|
+
resolve(response);
|
|
15318
|
+
}
|
|
14865
15319
|
}
|
|
14866
15320
|
);
|
|
14867
15321
|
});
|
|
14868
15322
|
}
|
|
14869
|
-
/**
|
|
14870
|
-
* Convert a protobuf Value to a JavaScript value
|
|
14871
|
-
* @param value - The protobuf Value object
|
|
14872
|
-
* @returns {any} - The converted JavaScript value
|
|
14873
|
-
*/
|
|
14874
|
-
convertProtobufValueToJS(value) {
|
|
14875
|
-
if (!value) return null;
|
|
14876
|
-
if (value.hasNullValue && value.hasNullValue()) {
|
|
14877
|
-
return null;
|
|
14878
|
-
}
|
|
14879
|
-
if (value.hasNumberValue && value.hasNumberValue()) {
|
|
14880
|
-
return value.getNumberValue();
|
|
14881
|
-
}
|
|
14882
|
-
if (value.hasStringValue && value.hasStringValue()) {
|
|
14883
|
-
return value.getStringValue();
|
|
14884
|
-
}
|
|
14885
|
-
if (value.hasBoolValue && value.hasBoolValue()) {
|
|
14886
|
-
return value.getBoolValue();
|
|
14887
|
-
}
|
|
14888
|
-
if (value.hasStructValue && value.hasStructValue()) {
|
|
14889
|
-
const struct = value.getStructValue();
|
|
14890
|
-
const result = {};
|
|
14891
|
-
if (struct && struct.getFieldsMap) {
|
|
14892
|
-
const fieldsMap = struct.getFieldsMap();
|
|
14893
|
-
fieldsMap.forEach((fieldValue, key) => {
|
|
14894
|
-
result[key] = this.convertProtobufValueToJS(fieldValue);
|
|
14895
|
-
});
|
|
14896
|
-
}
|
|
14897
|
-
return result;
|
|
14898
|
-
}
|
|
14899
|
-
if (value.hasListValue && value.hasListValue()) {
|
|
14900
|
-
const list = value.getListValue();
|
|
14901
|
-
if (list && list.getValuesList) {
|
|
14902
|
-
return list.getValuesList().map((item) => this.convertProtobufValueToJS(item));
|
|
14903
|
-
}
|
|
14904
|
-
return [];
|
|
14905
|
-
}
|
|
14906
|
-
if (typeof value.getNumberValue === "function") {
|
|
14907
|
-
return value.getNumberValue();
|
|
14908
|
-
}
|
|
14909
|
-
if (typeof value.getStringValue === "function") {
|
|
14910
|
-
return value.getStringValue();
|
|
14911
|
-
}
|
|
14912
|
-
if (typeof value.getBoolValue === "function") {
|
|
14913
|
-
return value.getBoolValue();
|
|
14914
|
-
}
|
|
14915
|
-
return value;
|
|
14916
|
-
}
|
|
14917
|
-
/**
|
|
14918
|
-
* Convert a JavaScript value to a protobuf Value
|
|
14919
|
-
* @param value - The JavaScript value to convert
|
|
14920
|
-
* @returns {any} - The protobuf Value object
|
|
14921
|
-
*/
|
|
14922
|
-
convertJSValueToProtobuf(value) {
|
|
14923
|
-
const protobufValue = new (__require("google-protobuf/google/protobuf/struct_pb")).Value();
|
|
14924
|
-
if (value === null || value === void 0) {
|
|
14925
|
-
protobufValue.setNullValue(0);
|
|
14926
|
-
} else if (typeof value === "number") {
|
|
14927
|
-
protobufValue.setNumberValue(value);
|
|
14928
|
-
} else if (typeof value === "string") {
|
|
14929
|
-
protobufValue.setStringValue(value);
|
|
14930
|
-
} else if (typeof value === "boolean") {
|
|
14931
|
-
protobufValue.setBoolValue(value);
|
|
14932
|
-
} else if (Array.isArray(value)) {
|
|
14933
|
-
const listValue = new (__require("google-protobuf/google/protobuf/struct_pb")).ListValue();
|
|
14934
|
-
const convertedValues = value.map(
|
|
14935
|
-
(item) => this.convertJSValueToProtobuf(item)
|
|
14936
|
-
);
|
|
14937
|
-
listValue.setValuesList(convertedValues);
|
|
14938
|
-
protobufValue.setListValue(listValue);
|
|
14939
|
-
} else if (typeof value === "object") {
|
|
14940
|
-
const structValue = new (__require("google-protobuf/google/protobuf/struct_pb")).Struct();
|
|
14941
|
-
const fieldsMap = structValue.getFieldsMap();
|
|
14942
|
-
Object.entries(value).forEach(([key, val]) => {
|
|
14943
|
-
fieldsMap.set(key, this.convertJSValueToProtobuf(val));
|
|
14944
|
-
});
|
|
14945
|
-
protobufValue.setStructValue(structValue);
|
|
14946
|
-
} else {
|
|
14947
|
-
protobufValue.setStringValue(String(value));
|
|
14948
|
-
}
|
|
14949
|
-
return protobufValue;
|
|
14950
|
-
}
|
|
14951
15323
|
};
|
|
14952
15324
|
var Client = class extends BaseClient {
|
|
14953
15325
|
constructor(config) {
|
|
@@ -14959,7 +15331,7 @@ var Client = class extends BaseClient {
|
|
|
14959
15331
|
* @returns {Promise<SmartWallet[]>} - The list of SmartWallet objects
|
|
14960
15332
|
*/
|
|
14961
15333
|
async getWallets(options) {
|
|
14962
|
-
const request = new
|
|
15334
|
+
const request = new avs_pb24.ListWalletReq();
|
|
14963
15335
|
const result = await this.sendGrpcRequest("listWallets", request, options);
|
|
14964
15336
|
return result.getItemsList().map((item) => item.toObject());
|
|
14965
15337
|
}
|
|
@@ -14971,7 +15343,7 @@ var Client = class extends BaseClient {
|
|
|
14971
15343
|
* @returns {Promise<SmartWallet>} - The added SmartWallet object
|
|
14972
15344
|
*/
|
|
14973
15345
|
async getWallet({ salt, factoryAddress }, options) {
|
|
14974
|
-
const request = new
|
|
15346
|
+
const request = new avs_pb24.GetWalletReq();
|
|
14975
15347
|
request.setSalt(salt);
|
|
14976
15348
|
if (factoryAddress) {
|
|
14977
15349
|
request.setFactoryAddress(factoryAddress);
|
|
@@ -15000,7 +15372,7 @@ var Client = class extends BaseClient {
|
|
|
15000
15372
|
* @returns {Promise<SmartWallet>} - The updated SmartWallet object
|
|
15001
15373
|
*/
|
|
15002
15374
|
async setWallet({ salt, factoryAddress }, { isHidden }, requestOptions) {
|
|
15003
|
-
const request = new
|
|
15375
|
+
const request = new avs_pb24.SetWalletReq();
|
|
15004
15376
|
request.setSalt(salt);
|
|
15005
15377
|
if (factoryAddress) {
|
|
15006
15378
|
request.setFactoryAddress(factoryAddress);
|
|
@@ -15048,7 +15420,7 @@ var Client = class extends BaseClient {
|
|
|
15048
15420
|
* @returns {Promise<{ items: Workflow[]; pageInfo: PageInfo }>} - The list of Workflow objects with nested pagination metadata
|
|
15049
15421
|
*/
|
|
15050
15422
|
async getWorkflows(addresses, options) {
|
|
15051
|
-
const request = new
|
|
15423
|
+
const request = new avs_pb24.ListTasksReq();
|
|
15052
15424
|
for (const a of addresses) {
|
|
15053
15425
|
request.addSmartWalletAddress(a);
|
|
15054
15426
|
}
|
|
@@ -15087,7 +15459,7 @@ var Client = class extends BaseClient {
|
|
|
15087
15459
|
* @returns {Promise<number>} - The count of workflows
|
|
15088
15460
|
*/
|
|
15089
15461
|
async getWorkflowCount(addresses, options) {
|
|
15090
|
-
const request = new
|
|
15462
|
+
const request = new avs_pb24.GetWorkflowCountReq();
|
|
15091
15463
|
request.setAddressesList(addresses);
|
|
15092
15464
|
const result = await this.sendGrpcRequest("getWorkflowCount", request, options);
|
|
15093
15465
|
return result.getTotal();
|
|
@@ -15103,7 +15475,7 @@ var Client = class extends BaseClient {
|
|
|
15103
15475
|
* @returns {Promise<{ items: Execution[]; pageInfo: PageInfo }>} - The list of Execution objects with nested pagination metadata
|
|
15104
15476
|
*/
|
|
15105
15477
|
async getExecutions(workflows, options) {
|
|
15106
|
-
const request = new
|
|
15478
|
+
const request = new avs_pb24.ListExecutionsReq();
|
|
15107
15479
|
for (const w of workflows) {
|
|
15108
15480
|
request.addTaskIds(w);
|
|
15109
15481
|
}
|
|
@@ -15137,7 +15509,7 @@ var Client = class extends BaseClient {
|
|
|
15137
15509
|
* @returns {Promise<Execution>} - The Execution object
|
|
15138
15510
|
*/
|
|
15139
15511
|
async getExecution(workflowId, executionId, options) {
|
|
15140
|
-
const request = new
|
|
15512
|
+
const request = new avs_pb24.ExecutionReq();
|
|
15141
15513
|
request.setTaskId(workflowId);
|
|
15142
15514
|
request.setExecutionId(executionId);
|
|
15143
15515
|
const result = await this.sendGrpcRequest("getExecution", request, options);
|
|
@@ -15150,7 +15522,7 @@ var Client = class extends BaseClient {
|
|
|
15150
15522
|
* @returns {Promise<number>} - The count of executions
|
|
15151
15523
|
*/
|
|
15152
15524
|
async getExecutionCount(workflows, options) {
|
|
15153
|
-
const request = new
|
|
15525
|
+
const request = new avs_pb24.GetExecutionCountReq();
|
|
15154
15526
|
request.setWorkflowIdsList(workflows);
|
|
15155
15527
|
const result = await this.sendGrpcRequest("getExecutionCount", request, options);
|
|
15156
15528
|
return result.getTotal();
|
|
@@ -15163,7 +15535,7 @@ var Client = class extends BaseClient {
|
|
|
15163
15535
|
* @returns {Promise<ExecutionStatus>} - The status of the execution
|
|
15164
15536
|
*/
|
|
15165
15537
|
async getExecutionStatus(workflowId, executionId, options) {
|
|
15166
|
-
const request = new
|
|
15538
|
+
const request = new avs_pb24.ExecutionReq();
|
|
15167
15539
|
request.setTaskId(workflowId);
|
|
15168
15540
|
request.setExecutionId(executionId);
|
|
15169
15541
|
const result = await this.sendGrpcRequest("getExecutionStatus", request, options);
|
|
@@ -15176,7 +15548,7 @@ var Client = class extends BaseClient {
|
|
|
15176
15548
|
* @returns {Promise<Workflow>} - The Workflow object
|
|
15177
15549
|
*/
|
|
15178
15550
|
async getWorkflow(id, options) {
|
|
15179
|
-
const request = new
|
|
15551
|
+
const request = new avs_pb24.IdReq();
|
|
15180
15552
|
request.setId(id);
|
|
15181
15553
|
const result = await this.sendGrpcRequest(
|
|
15182
15554
|
"getTask",
|
|
@@ -15199,7 +15571,7 @@ var Client = class extends BaseClient {
|
|
|
15199
15571
|
reason,
|
|
15200
15572
|
isBlocking = false
|
|
15201
15573
|
}, options) {
|
|
15202
|
-
const request = new
|
|
15574
|
+
const request = new avs_pb24.UserTriggerTaskReq();
|
|
15203
15575
|
request.setTaskId(id);
|
|
15204
15576
|
request.setReason(new reason_default(reason).toRequest());
|
|
15205
15577
|
request.setIsBlocking(isBlocking);
|
|
@@ -15213,7 +15585,7 @@ var Client = class extends BaseClient {
|
|
|
15213
15585
|
* @returns {Promise<boolean>} - Whether the workflow was successfully canceled
|
|
15214
15586
|
*/
|
|
15215
15587
|
async cancelWorkflow(id, options) {
|
|
15216
|
-
const request = new
|
|
15588
|
+
const request = new avs_pb24.IdReq();
|
|
15217
15589
|
request.setId(id);
|
|
15218
15590
|
const result = await this.sendGrpcRequest(
|
|
15219
15591
|
"cancelTask",
|
|
@@ -15229,7 +15601,7 @@ var Client = class extends BaseClient {
|
|
|
15229
15601
|
* @returns {Promise<boolean>} - Whether the workflow was successfully deleted
|
|
15230
15602
|
*/
|
|
15231
15603
|
async deleteWorkflow(id, options) {
|
|
15232
|
-
const request = new
|
|
15604
|
+
const request = new avs_pb24.IdReq();
|
|
15233
15605
|
request.setId(id);
|
|
15234
15606
|
const result = await this.sendGrpcRequest(
|
|
15235
15607
|
"deleteTask",
|
|
@@ -15249,7 +15621,7 @@ var Client = class extends BaseClient {
|
|
|
15249
15621
|
* @returns {Promise<boolean>} - True if the secret was created successfully
|
|
15250
15622
|
*/
|
|
15251
15623
|
async createSecret(name, value, options) {
|
|
15252
|
-
const request = new
|
|
15624
|
+
const request = new avs_pb24.CreateOrUpdateSecretReq();
|
|
15253
15625
|
request.setName(name);
|
|
15254
15626
|
request.setSecret(value);
|
|
15255
15627
|
if (options?.workflowId) {
|
|
@@ -15272,7 +15644,7 @@ var Client = class extends BaseClient {
|
|
|
15272
15644
|
* @returns {Promise<boolean>} - True if the secret was updated successfully
|
|
15273
15645
|
*/
|
|
15274
15646
|
async updateSecret(name, value, options) {
|
|
15275
|
-
const request = new
|
|
15647
|
+
const request = new avs_pb24.CreateOrUpdateSecretReq();
|
|
15276
15648
|
request.setName(name);
|
|
15277
15649
|
request.setSecret(value);
|
|
15278
15650
|
if (options?.workflowId) {
|
|
@@ -15299,7 +15671,7 @@ var Client = class extends BaseClient {
|
|
|
15299
15671
|
* @returns {Promise<{ items: SecretProps[]; pageInfo: PageInfo }>} - The list of Secret objects with nested pagination metadata
|
|
15300
15672
|
*/
|
|
15301
15673
|
async getSecrets(options) {
|
|
15302
|
-
const request = new
|
|
15674
|
+
const request = new avs_pb24.ListSecretsReq();
|
|
15303
15675
|
if (options?.workflowId) {
|
|
15304
15676
|
request.setWorkflowId(options.workflowId);
|
|
15305
15677
|
}
|
|
@@ -15354,7 +15726,7 @@ var Client = class extends BaseClient {
|
|
|
15354
15726
|
* @returns {Promise<boolean>} - True if the secret was deleted successfully
|
|
15355
15727
|
*/
|
|
15356
15728
|
async deleteSecret(name, options) {
|
|
15357
|
-
const request = new
|
|
15729
|
+
const request = new avs_pb24.DeleteSecretReq();
|
|
15358
15730
|
request.setName(name);
|
|
15359
15731
|
if (options?.workflowId) {
|
|
15360
15732
|
request.setWorkflowId(options.workflowId);
|
|
@@ -15375,80 +15747,40 @@ var Client = class extends BaseClient {
|
|
|
15375
15747
|
* @returns {Promise<RunNodeWithInputsResponse>} - The response from running the node
|
|
15376
15748
|
*/
|
|
15377
15749
|
async runNodeWithInputs({ nodeType, nodeConfig, inputVariables = {} }, options) {
|
|
15378
|
-
|
|
15379
|
-
|
|
15380
|
-
|
|
15381
|
-
|
|
15382
|
-
|
|
15383
|
-
|
|
15384
|
-
|
|
15385
|
-
|
|
15386
|
-
if (triggerTypes.includes(nodeType)) {
|
|
15387
|
-
return {
|
|
15388
|
-
success: false,
|
|
15389
|
-
error: `Trigger type "${nodeType}" should use the runTrigger() method instead of runNodeWithInputs()`,
|
|
15390
|
-
nodeId: ""
|
|
15391
|
-
};
|
|
15392
|
-
}
|
|
15393
|
-
const request = new avs_pb22.RunNodeWithInputsReq();
|
|
15394
|
-
const protobufNodeType = NodeTypeGoConverter2.fromGoString(nodeType);
|
|
15395
|
-
request.setNodeType(protobufNodeType);
|
|
15396
|
-
const nodeConfigMap = request.getNodeConfigMap();
|
|
15397
|
-
for (const [key, value] of Object.entries(nodeConfig)) {
|
|
15398
|
-
nodeConfigMap.set(key, this.convertJSValueToProtobuf(value));
|
|
15399
|
-
}
|
|
15400
|
-
if (inputVariables && Object.keys(inputVariables).length > 0) {
|
|
15401
|
-
const inputVarsMap = request.getInputVariablesMap();
|
|
15402
|
-
for (const [key, value] of Object.entries(inputVariables)) {
|
|
15403
|
-
inputVarsMap.set(key, this.convertJSValueToProtobuf(value));
|
|
15404
|
-
}
|
|
15405
|
-
}
|
|
15406
|
-
const result = await this.sendGrpcRequest("runNodeWithInputs", request, options);
|
|
15407
|
-
let data;
|
|
15408
|
-
const outputCase = result.getOutputDataCase();
|
|
15409
|
-
if (outputCase !== avs_pb22.RunNodeWithInputsResp.OutputDataCase.OUTPUT_DATA_NOT_SET) {
|
|
15410
|
-
switch (outputCase) {
|
|
15411
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.ETH_TRANSFER:
|
|
15412
|
-
data = result.getEthTransfer()?.toObject();
|
|
15413
|
-
break;
|
|
15414
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.GRAPHQL:
|
|
15415
|
-
data = result.getGraphql()?.toObject();
|
|
15416
|
-
break;
|
|
15417
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.CONTRACT_READ:
|
|
15418
|
-
data = result.getContractRead()?.toObject();
|
|
15419
|
-
break;
|
|
15420
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.CONTRACT_WRITE:
|
|
15421
|
-
data = result.getContractWrite()?.toObject();
|
|
15422
|
-
break;
|
|
15423
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.CUSTOM_CODE:
|
|
15424
|
-
data = result.getCustomCode()?.toObject();
|
|
15425
|
-
break;
|
|
15426
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.REST_API:
|
|
15427
|
-
data = result.getRestApi()?.toObject();
|
|
15428
|
-
break;
|
|
15429
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.BRANCH:
|
|
15430
|
-
data = result.getBranch()?.toObject();
|
|
15431
|
-
break;
|
|
15432
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.FILTER:
|
|
15433
|
-
data = result.getFilter()?.toObject();
|
|
15434
|
-
break;
|
|
15435
|
-
case avs_pb22.RunNodeWithInputsResp.OutputDataCase.LOOP:
|
|
15436
|
-
data = result.getLoop()?.toObject();
|
|
15437
|
-
break;
|
|
15438
|
-
}
|
|
15439
|
-
}
|
|
15440
|
-
return {
|
|
15441
|
-
success: result.getSuccess(),
|
|
15442
|
-
data,
|
|
15443
|
-
error: result.getError(),
|
|
15444
|
-
nodeId: result.getNodeId()
|
|
15445
|
-
};
|
|
15446
|
-
} catch (error) {
|
|
15750
|
+
const triggerTypes = [
|
|
15751
|
+
TriggerType9.Block,
|
|
15752
|
+
TriggerType9.FixedTime,
|
|
15753
|
+
TriggerType9.Cron,
|
|
15754
|
+
TriggerType9.Event,
|
|
15755
|
+
TriggerType9.Manual
|
|
15756
|
+
];
|
|
15757
|
+
if (triggerTypes.includes(nodeType)) {
|
|
15447
15758
|
return {
|
|
15448
15759
|
success: false,
|
|
15449
|
-
error:
|
|
15760
|
+
error: `Trigger type "${nodeType}" should use the runTrigger() method instead of runNodeWithInputs()`,
|
|
15761
|
+
nodeId: ""
|
|
15450
15762
|
};
|
|
15451
15763
|
}
|
|
15764
|
+
const request = new avs_pb24.RunNodeWithInputsReq();
|
|
15765
|
+
const protobufNodeType = NodeTypeGoConverter2.fromGoString(nodeType);
|
|
15766
|
+
request.setNodeType(protobufNodeType);
|
|
15767
|
+
const nodeConfigMap = request.getNodeConfigMap();
|
|
15768
|
+
for (const [key, value] of Object.entries(nodeConfig)) {
|
|
15769
|
+
nodeConfigMap.set(key, convertJSValueToProtobuf(value));
|
|
15770
|
+
}
|
|
15771
|
+
if (inputVariables && Object.keys(inputVariables).length > 0) {
|
|
15772
|
+
const inputVarsMap = request.getInputVariablesMap();
|
|
15773
|
+
for (const [key, value] of Object.entries(inputVariables)) {
|
|
15774
|
+
inputVarsMap.set(key, convertJSValueToProtobuf(value));
|
|
15775
|
+
}
|
|
15776
|
+
}
|
|
15777
|
+
const result = await this.sendGrpcRequest("runNodeWithInputs", request, options);
|
|
15778
|
+
return {
|
|
15779
|
+
success: result.getSuccess(),
|
|
15780
|
+
data: factory_default2.fromOutputData(result),
|
|
15781
|
+
error: result.getError(),
|
|
15782
|
+
nodeId: result.getNodeId()
|
|
15783
|
+
};
|
|
15452
15784
|
}
|
|
15453
15785
|
/**
|
|
15454
15786
|
* Run a trigger for testing purposes
|
|
@@ -15459,45 +15791,20 @@ var Client = class extends BaseClient {
|
|
|
15459
15791
|
* @returns {Promise<RunTriggerResponse>} - The response from running the trigger
|
|
15460
15792
|
*/
|
|
15461
15793
|
async runTrigger({ triggerType, triggerConfig }, options) {
|
|
15462
|
-
|
|
15463
|
-
|
|
15464
|
-
|
|
15465
|
-
|
|
15466
|
-
|
|
15467
|
-
|
|
15468
|
-
|
|
15469
|
-
|
|
15470
|
-
|
|
15471
|
-
|
|
15472
|
-
|
|
15473
|
-
|
|
15474
|
-
|
|
15475
|
-
|
|
15476
|
-
data = result.getBlockTrigger()?.toObject();
|
|
15477
|
-
break;
|
|
15478
|
-
case avs_pb22.RunTriggerResp.OutputDataCase.FIXED_TIME_TRIGGER:
|
|
15479
|
-
data = result.getFixedTimeTrigger()?.toObject();
|
|
15480
|
-
break;
|
|
15481
|
-
case avs_pb22.RunTriggerResp.OutputDataCase.CRON_TRIGGER:
|
|
15482
|
-
data = result.getCronTrigger()?.toObject();
|
|
15483
|
-
break;
|
|
15484
|
-
case avs_pb22.RunTriggerResp.OutputDataCase.EVENT_TRIGGER:
|
|
15485
|
-
data = result.getEventTrigger()?.toObject();
|
|
15486
|
-
break;
|
|
15487
|
-
}
|
|
15488
|
-
}
|
|
15489
|
-
return {
|
|
15490
|
-
success: result.getSuccess(),
|
|
15491
|
-
data,
|
|
15492
|
-
error: result.getError(),
|
|
15493
|
-
triggerId: result.getTriggerId()
|
|
15494
|
-
};
|
|
15495
|
-
} catch (error) {
|
|
15496
|
-
return {
|
|
15497
|
-
success: false,
|
|
15498
|
-
error: error.message || "An error occurred"
|
|
15499
|
-
};
|
|
15500
|
-
}
|
|
15794
|
+
const request = new avs_pb24.RunTriggerReq();
|
|
15795
|
+
const protobufTriggerType = TriggerTypeGoConverter.fromGoString(triggerType);
|
|
15796
|
+
request.setTriggerType(protobufTriggerType);
|
|
15797
|
+
const triggerConfigMap = request.getTriggerConfigMap();
|
|
15798
|
+
for (const [key, value] of Object.entries(triggerConfig)) {
|
|
15799
|
+
triggerConfigMap.set(key, convertJSValueToProtobuf(value));
|
|
15800
|
+
}
|
|
15801
|
+
const result = await this.sendGrpcRequest("runTrigger", request, options);
|
|
15802
|
+
return {
|
|
15803
|
+
success: result.getSuccess(),
|
|
15804
|
+
data: factory_default.fromOutputData(result),
|
|
15805
|
+
error: result.getError(),
|
|
15806
|
+
triggerId: result.getTriggerId()
|
|
15807
|
+
};
|
|
15501
15808
|
}
|
|
15502
15809
|
};
|
|
15503
15810
|
export {
|