@devrev/typescript-sdk 1.1.71 → 1.1.72

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.
@@ -2,7 +2,7 @@
2
2
  // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
3
  // versions:
4
4
  // protoc-gen-ts_proto v1.176.0
5
- // protoc v4.25.2
5
+ // protoc v6.31.0
6
6
  // source: schema.proto
7
7
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
8
8
  if (k2 === undefined) k2 = k;
@@ -28,7 +28,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
28
28
  return result;
29
29
  };
30
30
  Object.defineProperty(exports, "__esModule", { value: true });
31
- exports.OperationOutput = exports.PortOutput = exports.OutputValue = exports.ExecuteOperationResult = exports.ExecuteOperationInput = exports.OperationMetadata = exports.Error = exports.executeOperationResult_SerializationFormatToJSON = exports.executeOperationResult_SerializationFormatFromJSON = exports.ExecuteOperationResult_SerializationFormat = exports.operationMetadata_TypeToJSON = exports.operationMetadata_TypeFromJSON = exports.OperationMetadata_Type = exports.error_TypeToJSON = exports.error_TypeFromJSON = exports.Error_Type = exports.protobufPackage = void 0;
31
+ exports.ExternalImpersonationScopeEntry = exports.ExternalScopeEntry = exports.ExternalOperationScopes = exports.OperationOutput = exports.LogDetails = exports.LogEntry_AttributesEntry = exports.LogEntry = exports.PortOutput = exports.OutputValue = exports.ExecuteOperationResult = exports.ExecuteOperationInput = exports.BlockCallback = exports.OperationMetadata = exports.Error = exports.operationOutput_ExecutionStatusToJSON = exports.operationOutput_ExecutionStatusFromJSON = exports.OperationOutput_ExecutionStatus = exports.logEntry_LevelToJSON = exports.logEntry_LevelFromJSON = exports.LogEntry_Level = exports.executeOperationResult_SerializationFormatToJSON = exports.executeOperationResult_SerializationFormatFromJSON = exports.ExecuteOperationResult_SerializationFormat = exports.blockCallback_StatusToJSON = exports.blockCallback_StatusFromJSON = exports.BlockCallback_Status = exports.operationMetadata_TypeToJSON = exports.operationMetadata_TypeFromJSON = exports.OperationMetadata_Type = exports.error_TypeToJSON = exports.error_TypeFromJSON = exports.Error_Type = exports.protobufPackage = void 0;
32
32
  /* eslint-disable */
33
33
  const _m0 = __importStar(require("protobufjs/minimal"));
34
34
  const struct_pb_1 = require("./struct.pb");
@@ -107,6 +107,45 @@ function operationMetadata_TypeToJSON(object) {
107
107
  }
108
108
  }
109
109
  exports.operationMetadata_TypeToJSON = operationMetadata_TypeToJSON;
110
+ var BlockCallback_Status;
111
+ (function (BlockCallback_Status) {
112
+ BlockCallback_Status[BlockCallback_Status["Unknown"] = 0] = "Unknown";
113
+ BlockCallback_Status[BlockCallback_Status["Completed"] = 1] = "Completed";
114
+ BlockCallback_Status[BlockCallback_Status["Errored"] = 2] = "Errored";
115
+ BlockCallback_Status[BlockCallback_Status["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
116
+ })(BlockCallback_Status = exports.BlockCallback_Status || (exports.BlockCallback_Status = {}));
117
+ function blockCallback_StatusFromJSON(object) {
118
+ switch (object) {
119
+ case 0:
120
+ case 'Unknown':
121
+ return BlockCallback_Status.Unknown;
122
+ case 1:
123
+ case 'Completed':
124
+ return BlockCallback_Status.Completed;
125
+ case 2:
126
+ case 'Errored':
127
+ return BlockCallback_Status.Errored;
128
+ case -1:
129
+ case 'UNRECOGNIZED':
130
+ default:
131
+ return BlockCallback_Status.UNRECOGNIZED;
132
+ }
133
+ }
134
+ exports.blockCallback_StatusFromJSON = blockCallback_StatusFromJSON;
135
+ function blockCallback_StatusToJSON(object) {
136
+ switch (object) {
137
+ case BlockCallback_Status.Unknown:
138
+ return 'Unknown';
139
+ case BlockCallback_Status.Completed:
140
+ return 'Completed';
141
+ case BlockCallback_Status.Errored:
142
+ return 'Errored';
143
+ case BlockCallback_Status.UNRECOGNIZED:
144
+ default:
145
+ return 'UNRECOGNIZED';
146
+ }
147
+ }
148
+ exports.blockCallback_StatusToJSON = blockCallback_StatusToJSON;
110
149
  var ExecuteOperationResult_SerializationFormat;
111
150
  (function (ExecuteOperationResult_SerializationFormat) {
112
151
  ExecuteOperationResult_SerializationFormat[ExecuteOperationResult_SerializationFormat["Unknown"] = 0] = "Unknown";
@@ -146,6 +185,106 @@ function executeOperationResult_SerializationFormatToJSON(object) {
146
185
  }
147
186
  }
148
187
  exports.executeOperationResult_SerializationFormatToJSON = executeOperationResult_SerializationFormatToJSON;
188
+ var LogEntry_Level;
189
+ (function (LogEntry_Level) {
190
+ LogEntry_Level[LogEntry_Level["UNKNOWN"] = 0] = "UNKNOWN";
191
+ LogEntry_Level[LogEntry_Level["DEBUG"] = 1] = "DEBUG";
192
+ LogEntry_Level[LogEntry_Level["INFO"] = 2] = "INFO";
193
+ LogEntry_Level[LogEntry_Level["WARN"] = 3] = "WARN";
194
+ LogEntry_Level[LogEntry_Level["ERROR"] = 4] = "ERROR";
195
+ LogEntry_Level[LogEntry_Level["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
196
+ })(LogEntry_Level = exports.LogEntry_Level || (exports.LogEntry_Level = {}));
197
+ function logEntry_LevelFromJSON(object) {
198
+ switch (object) {
199
+ case 0:
200
+ case 'UNKNOWN':
201
+ return LogEntry_Level.UNKNOWN;
202
+ case 1:
203
+ case 'DEBUG':
204
+ return LogEntry_Level.DEBUG;
205
+ case 2:
206
+ case 'INFO':
207
+ return LogEntry_Level.INFO;
208
+ case 3:
209
+ case 'WARN':
210
+ return LogEntry_Level.WARN;
211
+ case 4:
212
+ case 'ERROR':
213
+ return LogEntry_Level.ERROR;
214
+ case -1:
215
+ case 'UNRECOGNIZED':
216
+ default:
217
+ return LogEntry_Level.UNRECOGNIZED;
218
+ }
219
+ }
220
+ exports.logEntry_LevelFromJSON = logEntry_LevelFromJSON;
221
+ function logEntry_LevelToJSON(object) {
222
+ switch (object) {
223
+ case LogEntry_Level.UNKNOWN:
224
+ return 'UNKNOWN';
225
+ case LogEntry_Level.DEBUG:
226
+ return 'DEBUG';
227
+ case LogEntry_Level.INFO:
228
+ return 'INFO';
229
+ case LogEntry_Level.WARN:
230
+ return 'WARN';
231
+ case LogEntry_Level.ERROR:
232
+ return 'ERROR';
233
+ case LogEntry_Level.UNRECOGNIZED:
234
+ default:
235
+ return 'UNRECOGNIZED';
236
+ }
237
+ }
238
+ exports.logEntry_LevelToJSON = logEntry_LevelToJSON;
239
+ /** Status of the operation execution. */
240
+ var OperationOutput_ExecutionStatus;
241
+ (function (OperationOutput_ExecutionStatus) {
242
+ OperationOutput_ExecutionStatus[OperationOutput_ExecutionStatus["Unknown"] = 0] = "Unknown";
243
+ /** Completed - Operation has completed successfully. */
244
+ OperationOutput_ExecutionStatus[OperationOutput_ExecutionStatus["Completed"] = 1] = "Completed";
245
+ /** Waiting - Operation is in progress. */
246
+ OperationOutput_ExecutionStatus[OperationOutput_ExecutionStatus["Waiting"] = 2] = "Waiting";
247
+ /** Errored - Operation failed. */
248
+ OperationOutput_ExecutionStatus[OperationOutput_ExecutionStatus["Errored"] = 3] = "Errored";
249
+ OperationOutput_ExecutionStatus[OperationOutput_ExecutionStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
250
+ })(OperationOutput_ExecutionStatus = exports.OperationOutput_ExecutionStatus || (exports.OperationOutput_ExecutionStatus = {}));
251
+ function operationOutput_ExecutionStatusFromJSON(object) {
252
+ switch (object) {
253
+ case 0:
254
+ case 'Unknown':
255
+ return OperationOutput_ExecutionStatus.Unknown;
256
+ case 1:
257
+ case 'Completed':
258
+ return OperationOutput_ExecutionStatus.Completed;
259
+ case 2:
260
+ case 'Waiting':
261
+ return OperationOutput_ExecutionStatus.Waiting;
262
+ case 3:
263
+ case 'Errored':
264
+ return OperationOutput_ExecutionStatus.Errored;
265
+ case -1:
266
+ case 'UNRECOGNIZED':
267
+ default:
268
+ return OperationOutput_ExecutionStatus.UNRECOGNIZED;
269
+ }
270
+ }
271
+ exports.operationOutput_ExecutionStatusFromJSON = operationOutput_ExecutionStatusFromJSON;
272
+ function operationOutput_ExecutionStatusToJSON(object) {
273
+ switch (object) {
274
+ case OperationOutput_ExecutionStatus.Unknown:
275
+ return 'Unknown';
276
+ case OperationOutput_ExecutionStatus.Completed:
277
+ return 'Completed';
278
+ case OperationOutput_ExecutionStatus.Waiting:
279
+ return 'Waiting';
280
+ case OperationOutput_ExecutionStatus.Errored:
281
+ return 'Errored';
282
+ case OperationOutput_ExecutionStatus.UNRECOGNIZED:
283
+ default:
284
+ return 'UNRECOGNIZED';
285
+ }
286
+ }
287
+ exports.operationOutput_ExecutionStatusToJSON = operationOutput_ExecutionStatusToJSON;
149
288
  function createBaseError() {
150
289
  return { message: '', type: 0 };
151
290
  }
@@ -214,7 +353,7 @@ exports.Error = {
214
353
  },
215
354
  };
216
355
  function createBaseOperationMetadata() {
217
- return { namespace: '', slug: '', type: 0 };
356
+ return { namespace: '', slug: '', type: 0, mcp_server_url: undefined };
218
357
  }
219
358
  exports.OperationMetadata = {
220
359
  encode(message, writer = _m0.Writer.create()) {
@@ -227,6 +366,9 @@ exports.OperationMetadata = {
227
366
  if (message.type !== 0) {
228
367
  writer.uint32(24).int32(message.type);
229
368
  }
369
+ if (message.mcp_server_url !== undefined) {
370
+ writer.uint32(34).string(message.mcp_server_url);
371
+ }
230
372
  return writer;
231
373
  },
232
374
  decode(input, length) {
@@ -254,6 +396,12 @@ exports.OperationMetadata = {
254
396
  }
255
397
  message.type = reader.int32();
256
398
  continue;
399
+ case 4:
400
+ if (tag !== 34) {
401
+ break;
402
+ }
403
+ message.mcp_server_url = reader.string();
404
+ continue;
257
405
  }
258
406
  if ((tag & 7) === 4 || tag === 0) {
259
407
  break;
@@ -271,6 +419,9 @@ exports.OperationMetadata = {
271
419
  type: isSet(object.type)
272
420
  ? operationMetadata_TypeFromJSON(object.type)
273
421
  : 0,
422
+ mcp_server_url: isSet(object.mcp_server_url)
423
+ ? globalThis.String(object.mcp_server_url)
424
+ : undefined,
274
425
  };
275
426
  },
276
427
  toJSON(message) {
@@ -284,22 +435,121 @@ exports.OperationMetadata = {
284
435
  if (message.type !== 0) {
285
436
  obj.type = operationMetadata_TypeToJSON(message.type);
286
437
  }
438
+ if (message.mcp_server_url !== undefined) {
439
+ obj.mcp_server_url = message.mcp_server_url;
440
+ }
287
441
  return obj;
288
442
  },
289
443
  create(base) {
290
444
  return exports.OperationMetadata.fromPartial(base !== null && base !== void 0 ? base : {});
291
445
  },
292
446
  fromPartial(object) {
293
- var _a, _b, _c;
447
+ var _a, _b, _c, _d;
294
448
  const message = createBaseOperationMetadata();
295
449
  message.namespace = (_a = object.namespace) !== null && _a !== void 0 ? _a : '';
296
450
  message.slug = (_b = object.slug) !== null && _b !== void 0 ? _b : '';
297
451
  message.type = (_c = object.type) !== null && _c !== void 0 ? _c : 0;
452
+ message.mcp_server_url = (_d = object.mcp_server_url) !== null && _d !== void 0 ? _d : undefined;
453
+ return message;
454
+ },
455
+ };
456
+ function createBaseBlockCallback() {
457
+ return { status: 0, scope_variables: undefined, run_scope_id: '' };
458
+ }
459
+ exports.BlockCallback = {
460
+ encode(message, writer = _m0.Writer.create()) {
461
+ if (message.status !== 0) {
462
+ writer.uint32(8).int32(message.status);
463
+ }
464
+ if (message.scope_variables !== undefined) {
465
+ struct_pb_1.Struct.encode(struct_pb_1.Struct.wrap(message.scope_variables), writer.uint32(18).fork()).ldelim();
466
+ }
467
+ if (message.run_scope_id !== '') {
468
+ writer.uint32(26).string(message.run_scope_id);
469
+ }
470
+ return writer;
471
+ },
472
+ decode(input, length) {
473
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
474
+ let end = length === undefined ? reader.len : reader.pos + length;
475
+ const message = createBaseBlockCallback();
476
+ while (reader.pos < end) {
477
+ const tag = reader.uint32();
478
+ switch (tag >>> 3) {
479
+ case 1:
480
+ if (tag !== 8) {
481
+ break;
482
+ }
483
+ message.status = reader.int32();
484
+ continue;
485
+ case 2:
486
+ if (tag !== 18) {
487
+ break;
488
+ }
489
+ message.scope_variables = struct_pb_1.Struct.unwrap(struct_pb_1.Struct.decode(reader, reader.uint32()));
490
+ continue;
491
+ case 3:
492
+ if (tag !== 26) {
493
+ break;
494
+ }
495
+ message.run_scope_id = reader.string();
496
+ continue;
497
+ }
498
+ if ((tag & 7) === 4 || tag === 0) {
499
+ break;
500
+ }
501
+ reader.skipType(tag & 7);
502
+ }
503
+ return message;
504
+ },
505
+ fromJSON(object) {
506
+ return {
507
+ status: isSet(object.status)
508
+ ? blockCallback_StatusFromJSON(object.status)
509
+ : 0,
510
+ scope_variables: isObject(object.scope_variables)
511
+ ? object.scope_variables
512
+ : undefined,
513
+ run_scope_id: isSet(object.run_scope_id)
514
+ ? globalThis.String(object.run_scope_id)
515
+ : '',
516
+ };
517
+ },
518
+ toJSON(message) {
519
+ const obj = {};
520
+ if (message.status !== 0) {
521
+ obj.status = blockCallback_StatusToJSON(message.status);
522
+ }
523
+ if (message.scope_variables !== undefined) {
524
+ obj.scope_variables = message.scope_variables;
525
+ }
526
+ if (message.run_scope_id !== '') {
527
+ obj.run_scope_id = message.run_scope_id;
528
+ }
529
+ return obj;
530
+ },
531
+ create(base) {
532
+ return exports.BlockCallback.fromPartial(base !== null && base !== void 0 ? base : {});
533
+ },
534
+ fromPartial(object) {
535
+ var _a, _b, _c;
536
+ const message = createBaseBlockCallback();
537
+ message.status = (_a = object.status) !== null && _a !== void 0 ? _a : 0;
538
+ message.scope_variables = (_b = object.scope_variables) !== null && _b !== void 0 ? _b : undefined;
539
+ message.run_scope_id = (_c = object.run_scope_id) !== null && _c !== void 0 ? _c : '';
298
540
  return message;
299
541
  },
300
542
  };
301
543
  function createBaseExecuteOperationInput() {
302
- return { metadata: undefined, input_port_name: '', data: undefined };
544
+ return {
545
+ metadata: undefined,
546
+ input_port_name: '',
547
+ data: undefined,
548
+ operation_method: '',
549
+ input_configuration: undefined,
550
+ state: undefined,
551
+ block_callback: undefined,
552
+ };
303
553
  }
304
554
  exports.ExecuteOperationInput = {
305
555
  encode(message, writer = _m0.Writer.create()) {
@@ -312,6 +562,18 @@ exports.ExecuteOperationInput = {
312
562
  if (message.data !== undefined) {
313
563
  struct_pb_1.Value.encode(struct_pb_1.Value.wrap(message.data), writer.uint32(26).fork()).ldelim();
314
564
  }
565
+ if (message.operation_method !== '') {
566
+ writer.uint32(34).string(message.operation_method);
567
+ }
568
+ if (message.input_configuration !== undefined) {
569
+ struct_pb_1.Struct.encode(struct_pb_1.Struct.wrap(message.input_configuration), writer.uint32(42).fork()).ldelim();
570
+ }
571
+ if (message.state !== undefined) {
572
+ struct_pb_1.Value.encode(struct_pb_1.Value.wrap(message.state), writer.uint32(50).fork()).ldelim();
573
+ }
574
+ if (message.block_callback !== undefined) {
575
+ exports.BlockCallback.encode(message.block_callback, writer.uint32(58).fork()).ldelim();
576
+ }
315
577
  return writer;
316
578
  },
317
579
  decode(input, length) {
@@ -339,6 +601,30 @@ exports.ExecuteOperationInput = {
339
601
  }
340
602
  message.data = struct_pb_1.Value.unwrap(struct_pb_1.Value.decode(reader, reader.uint32()));
341
603
  continue;
604
+ case 4:
605
+ if (tag !== 34) {
606
+ break;
607
+ }
608
+ message.operation_method = reader.string();
609
+ continue;
610
+ case 5:
611
+ if (tag !== 42) {
612
+ break;
613
+ }
614
+ message.input_configuration = struct_pb_1.Struct.unwrap(struct_pb_1.Struct.decode(reader, reader.uint32()));
615
+ continue;
616
+ case 6:
617
+ if (tag !== 50) {
618
+ break;
619
+ }
620
+ message.state = struct_pb_1.Value.unwrap(struct_pb_1.Value.decode(reader, reader.uint32()));
621
+ continue;
622
+ case 7:
623
+ if (tag !== 58) {
624
+ break;
625
+ }
626
+ message.block_callback = exports.BlockCallback.decode(reader, reader.uint32());
627
+ continue;
342
628
  }
343
629
  if ((tag & 7) === 4 || tag === 0) {
344
630
  break;
@@ -356,6 +642,16 @@ exports.ExecuteOperationInput = {
356
642
  ? globalThis.String(object.input_port_name)
357
643
  : '',
358
644
  data: isSet(object === null || object === void 0 ? void 0 : object.data) ? object.data : undefined,
645
+ operation_method: isSet(object.operation_method)
646
+ ? globalThis.String(object.operation_method)
647
+ : '',
648
+ input_configuration: isObject(object.input_configuration)
649
+ ? object.input_configuration
650
+ : undefined,
651
+ state: isSet(object === null || object === void 0 ? void 0 : object.state) ? object.state : undefined,
652
+ block_callback: isSet(object.block_callback)
653
+ ? exports.BlockCallback.fromJSON(object.block_callback)
654
+ : undefined,
359
655
  };
360
656
  },
361
657
  toJSON(message) {
@@ -369,13 +665,25 @@ exports.ExecuteOperationInput = {
369
665
  if (message.data !== undefined) {
370
666
  obj.data = message.data;
371
667
  }
668
+ if (message.operation_method !== '') {
669
+ obj.operation_method = message.operation_method;
670
+ }
671
+ if (message.input_configuration !== undefined) {
672
+ obj.input_configuration = message.input_configuration;
673
+ }
674
+ if (message.state !== undefined) {
675
+ obj.state = message.state;
676
+ }
677
+ if (message.block_callback !== undefined) {
678
+ obj.block_callback = exports.BlockCallback.toJSON(message.block_callback);
679
+ }
372
680
  return obj;
373
681
  },
374
682
  create(base) {
375
683
  return exports.ExecuteOperationInput.fromPartial(base !== null && base !== void 0 ? base : {});
376
684
  },
377
685
  fromPartial(object) {
378
- var _a, _b;
686
+ var _a, _b, _c, _d, _e;
379
687
  const message = createBaseExecuteOperationInput();
380
688
  message.metadata =
381
689
  object.metadata !== undefined && object.metadata !== null
@@ -383,6 +691,13 @@ exports.ExecuteOperationInput = {
383
691
  : undefined;
384
692
  message.input_port_name = (_a = object.input_port_name) !== null && _a !== void 0 ? _a : '';
385
693
  message.data = (_b = object.data) !== null && _b !== void 0 ? _b : undefined;
694
+ message.operation_method = (_c = object.operation_method) !== null && _c !== void 0 ? _c : '';
695
+ message.input_configuration = (_d = object.input_configuration) !== null && _d !== void 0 ? _d : undefined;
696
+ message.state = (_e = object.state) !== null && _e !== void 0 ? _e : undefined;
697
+ message.block_callback =
698
+ object.block_callback !== undefined && object.block_callback !== null
699
+ ? exports.BlockCallback.fromPartial(object.block_callback)
700
+ : undefined;
386
701
  return message;
387
702
  },
388
703
  };
@@ -586,8 +901,329 @@ exports.PortOutput = {
586
901
  return message;
587
902
  },
588
903
  };
904
+ function createBaseLogEntry() {
905
+ return {
906
+ level: 0,
907
+ message: '',
908
+ timestamp: undefined,
909
+ attributes: {},
910
+ workflow_id: undefined,
911
+ workflow_step_id: undefined,
912
+ workflow_run_id: undefined,
913
+ workflow_step_run_id: undefined,
914
+ };
915
+ }
916
+ exports.LogEntry = {
917
+ encode(message, writer = _m0.Writer.create()) {
918
+ if (message.level !== 0) {
919
+ writer.uint32(8).int32(message.level);
920
+ }
921
+ if (message.message !== '') {
922
+ writer.uint32(18).string(message.message);
923
+ }
924
+ if (message.timestamp !== undefined) {
925
+ writer.uint32(26).string(message.timestamp);
926
+ }
927
+ Object.entries(message.attributes).forEach(([key, value]) => {
928
+ exports.LogEntry_AttributesEntry.encode({ key: key, value }, writer.uint32(34).fork()).ldelim();
929
+ });
930
+ if (message.workflow_id !== undefined) {
931
+ writer.uint32(42).string(message.workflow_id);
932
+ }
933
+ if (message.workflow_step_id !== undefined) {
934
+ writer.uint32(50).string(message.workflow_step_id);
935
+ }
936
+ if (message.workflow_run_id !== undefined) {
937
+ writer.uint32(58).string(message.workflow_run_id);
938
+ }
939
+ if (message.workflow_step_run_id !== undefined) {
940
+ writer.uint32(66).string(message.workflow_step_run_id);
941
+ }
942
+ return writer;
943
+ },
944
+ decode(input, length) {
945
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
946
+ let end = length === undefined ? reader.len : reader.pos + length;
947
+ const message = createBaseLogEntry();
948
+ while (reader.pos < end) {
949
+ const tag = reader.uint32();
950
+ switch (tag >>> 3) {
951
+ case 1:
952
+ if (tag !== 8) {
953
+ break;
954
+ }
955
+ message.level = reader.int32();
956
+ continue;
957
+ case 2:
958
+ if (tag !== 18) {
959
+ break;
960
+ }
961
+ message.message = reader.string();
962
+ continue;
963
+ case 3:
964
+ if (tag !== 26) {
965
+ break;
966
+ }
967
+ message.timestamp = reader.string();
968
+ continue;
969
+ case 4:
970
+ if (tag !== 34) {
971
+ break;
972
+ }
973
+ const entry4 = exports.LogEntry_AttributesEntry.decode(reader, reader.uint32());
974
+ if (entry4.value !== undefined) {
975
+ message.attributes[entry4.key] = entry4.value;
976
+ }
977
+ continue;
978
+ case 5:
979
+ if (tag !== 42) {
980
+ break;
981
+ }
982
+ message.workflow_id = reader.string();
983
+ continue;
984
+ case 6:
985
+ if (tag !== 50) {
986
+ break;
987
+ }
988
+ message.workflow_step_id = reader.string();
989
+ continue;
990
+ case 7:
991
+ if (tag !== 58) {
992
+ break;
993
+ }
994
+ message.workflow_run_id = reader.string();
995
+ continue;
996
+ case 8:
997
+ if (tag !== 66) {
998
+ break;
999
+ }
1000
+ message.workflow_step_run_id = reader.string();
1001
+ continue;
1002
+ }
1003
+ if ((tag & 7) === 4 || tag === 0) {
1004
+ break;
1005
+ }
1006
+ reader.skipType(tag & 7);
1007
+ }
1008
+ return message;
1009
+ },
1010
+ fromJSON(object) {
1011
+ return {
1012
+ level: isSet(object.level) ? logEntry_LevelFromJSON(object.level) : 0,
1013
+ message: isSet(object.message) ? globalThis.String(object.message) : '',
1014
+ timestamp: isSet(object.timestamp)
1015
+ ? globalThis.String(object.timestamp)
1016
+ : undefined,
1017
+ attributes: isObject(object.attributes)
1018
+ ? Object.entries(object.attributes).reduce((acc, [key, value]) => {
1019
+ acc[key] = String(value);
1020
+ return acc;
1021
+ }, {})
1022
+ : {},
1023
+ workflow_id: isSet(object.workflow_id)
1024
+ ? globalThis.String(object.workflow_id)
1025
+ : undefined,
1026
+ workflow_step_id: isSet(object.workflow_step_id)
1027
+ ? globalThis.String(object.workflow_step_id)
1028
+ : undefined,
1029
+ workflow_run_id: isSet(object.workflow_run_id)
1030
+ ? globalThis.String(object.workflow_run_id)
1031
+ : undefined,
1032
+ workflow_step_run_id: isSet(object.workflow_step_run_id)
1033
+ ? globalThis.String(object.workflow_step_run_id)
1034
+ : undefined,
1035
+ };
1036
+ },
1037
+ toJSON(message) {
1038
+ const obj = {};
1039
+ if (message.level !== 0) {
1040
+ obj.level = logEntry_LevelToJSON(message.level);
1041
+ }
1042
+ if (message.message !== '') {
1043
+ obj.message = message.message;
1044
+ }
1045
+ if (message.timestamp !== undefined) {
1046
+ obj.timestamp = message.timestamp;
1047
+ }
1048
+ if (message.attributes) {
1049
+ const entries = Object.entries(message.attributes);
1050
+ if (entries.length > 0) {
1051
+ obj.attributes = {};
1052
+ entries.forEach(([k, v]) => {
1053
+ obj.attributes[k] = v;
1054
+ });
1055
+ }
1056
+ }
1057
+ if (message.workflow_id !== undefined) {
1058
+ obj.workflow_id = message.workflow_id;
1059
+ }
1060
+ if (message.workflow_step_id !== undefined) {
1061
+ obj.workflow_step_id = message.workflow_step_id;
1062
+ }
1063
+ if (message.workflow_run_id !== undefined) {
1064
+ obj.workflow_run_id = message.workflow_run_id;
1065
+ }
1066
+ if (message.workflow_step_run_id !== undefined) {
1067
+ obj.workflow_step_run_id = message.workflow_step_run_id;
1068
+ }
1069
+ return obj;
1070
+ },
1071
+ create(base) {
1072
+ return exports.LogEntry.fromPartial(base !== null && base !== void 0 ? base : {});
1073
+ },
1074
+ fromPartial(object) {
1075
+ var _a, _b, _c, _d, _e, _f, _g, _h;
1076
+ const message = createBaseLogEntry();
1077
+ message.level = (_a = object.level) !== null && _a !== void 0 ? _a : 0;
1078
+ message.message = (_b = object.message) !== null && _b !== void 0 ? _b : '';
1079
+ message.timestamp = (_c = object.timestamp) !== null && _c !== void 0 ? _c : undefined;
1080
+ message.attributes = Object.entries((_d = object.attributes) !== null && _d !== void 0 ? _d : {}).reduce((acc, [key, value]) => {
1081
+ if (value !== undefined) {
1082
+ acc[key] = globalThis.String(value);
1083
+ }
1084
+ return acc;
1085
+ }, {});
1086
+ message.workflow_id = (_e = object.workflow_id) !== null && _e !== void 0 ? _e : undefined;
1087
+ message.workflow_step_id = (_f = object.workflow_step_id) !== null && _f !== void 0 ? _f : undefined;
1088
+ message.workflow_run_id = (_g = object.workflow_run_id) !== null && _g !== void 0 ? _g : undefined;
1089
+ message.workflow_step_run_id = (_h = object.workflow_step_run_id) !== null && _h !== void 0 ? _h : undefined;
1090
+ return message;
1091
+ },
1092
+ };
1093
+ function createBaseLogEntry_AttributesEntry() {
1094
+ return { key: '', value: '' };
1095
+ }
1096
+ exports.LogEntry_AttributesEntry = {
1097
+ encode(message, writer = _m0.Writer.create()) {
1098
+ if (message.key !== '') {
1099
+ writer.uint32(10).string(message.key);
1100
+ }
1101
+ if (message.value !== '') {
1102
+ writer.uint32(18).string(message.value);
1103
+ }
1104
+ return writer;
1105
+ },
1106
+ decode(input, length) {
1107
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
1108
+ let end = length === undefined ? reader.len : reader.pos + length;
1109
+ const message = createBaseLogEntry_AttributesEntry();
1110
+ while (reader.pos < end) {
1111
+ const tag = reader.uint32();
1112
+ switch (tag >>> 3) {
1113
+ case 1:
1114
+ if (tag !== 10) {
1115
+ break;
1116
+ }
1117
+ message.key = reader.string();
1118
+ continue;
1119
+ case 2:
1120
+ if (tag !== 18) {
1121
+ break;
1122
+ }
1123
+ message.value = reader.string();
1124
+ continue;
1125
+ }
1126
+ if ((tag & 7) === 4 || tag === 0) {
1127
+ break;
1128
+ }
1129
+ reader.skipType(tag & 7);
1130
+ }
1131
+ return message;
1132
+ },
1133
+ fromJSON(object) {
1134
+ return {
1135
+ key: isSet(object.key) ? globalThis.String(object.key) : '',
1136
+ value: isSet(object.value) ? globalThis.String(object.value) : '',
1137
+ };
1138
+ },
1139
+ toJSON(message) {
1140
+ const obj = {};
1141
+ if (message.key !== '') {
1142
+ obj.key = message.key;
1143
+ }
1144
+ if (message.value !== '') {
1145
+ obj.value = message.value;
1146
+ }
1147
+ return obj;
1148
+ },
1149
+ create(base) {
1150
+ return exports.LogEntry_AttributesEntry.fromPartial(base !== null && base !== void 0 ? base : {});
1151
+ },
1152
+ fromPartial(object) {
1153
+ var _a, _b;
1154
+ const message = createBaseLogEntry_AttributesEntry();
1155
+ message.key = (_a = object.key) !== null && _a !== void 0 ? _a : '';
1156
+ message.value = (_b = object.value) !== null && _b !== void 0 ? _b : '';
1157
+ return message;
1158
+ },
1159
+ };
1160
+ function createBaseLogDetails() {
1161
+ return { logs: [] };
1162
+ }
1163
+ exports.LogDetails = {
1164
+ encode(message, writer = _m0.Writer.create()) {
1165
+ for (const v of message.logs) {
1166
+ exports.LogEntry.encode(v, writer.uint32(10).fork()).ldelim();
1167
+ }
1168
+ return writer;
1169
+ },
1170
+ decode(input, length) {
1171
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
1172
+ let end = length === undefined ? reader.len : reader.pos + length;
1173
+ const message = createBaseLogDetails();
1174
+ while (reader.pos < end) {
1175
+ const tag = reader.uint32();
1176
+ switch (tag >>> 3) {
1177
+ case 1:
1178
+ if (tag !== 10) {
1179
+ break;
1180
+ }
1181
+ message.logs.push(exports.LogEntry.decode(reader, reader.uint32()));
1182
+ continue;
1183
+ }
1184
+ if ((tag & 7) === 4 || tag === 0) {
1185
+ break;
1186
+ }
1187
+ reader.skipType(tag & 7);
1188
+ }
1189
+ return message;
1190
+ },
1191
+ fromJSON(object) {
1192
+ return {
1193
+ logs: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.logs)
1194
+ ? object.logs.map((e) => exports.LogEntry.fromJSON(e))
1195
+ : [],
1196
+ };
1197
+ },
1198
+ toJSON(message) {
1199
+ var _a;
1200
+ const obj = {};
1201
+ if ((_a = message.logs) === null || _a === void 0 ? void 0 : _a.length) {
1202
+ obj.logs = message.logs.map((e) => exports.LogEntry.toJSON(e));
1203
+ }
1204
+ return obj;
1205
+ },
1206
+ create(base) {
1207
+ return exports.LogDetails.fromPartial(base !== null && base !== void 0 ? base : {});
1208
+ },
1209
+ fromPartial(object) {
1210
+ var _a;
1211
+ const message = createBaseLogDetails();
1212
+ message.logs = ((_a = object.logs) === null || _a === void 0 ? void 0 : _a.map((e) => exports.LogEntry.fromPartial(e))) || [];
1213
+ return message;
1214
+ },
1215
+ };
589
1216
  function createBaseOperationOutput() {
590
- return { error: undefined, output: undefined, port_outputs: [] };
1217
+ return {
1218
+ error: undefined,
1219
+ output: undefined,
1220
+ port_outputs: [],
1221
+ input_configuration: undefined,
1222
+ summary: undefined,
1223
+ status: undefined,
1224
+ state: undefined,
1225
+ log_details: undefined,
1226
+ };
591
1227
  }
592
1228
  exports.OperationOutput = {
593
1229
  encode(message, writer = _m0.Writer.create()) {
@@ -600,6 +1236,21 @@ exports.OperationOutput = {
600
1236
  for (const v of message.port_outputs) {
601
1237
  exports.PortOutput.encode(v, writer.uint32(26).fork()).ldelim();
602
1238
  }
1239
+ if (message.input_configuration !== undefined) {
1240
+ struct_pb_1.Struct.encode(struct_pb_1.Struct.wrap(message.input_configuration), writer.uint32(34).fork()).ldelim();
1241
+ }
1242
+ if (message.summary !== undefined) {
1243
+ writer.uint32(42).string(message.summary);
1244
+ }
1245
+ if (message.status !== undefined) {
1246
+ writer.uint32(48).int32(message.status);
1247
+ }
1248
+ if (message.state !== undefined) {
1249
+ struct_pb_1.Value.encode(struct_pb_1.Value.wrap(message.state), writer.uint32(58).fork()).ldelim();
1250
+ }
1251
+ if (message.log_details !== undefined) {
1252
+ exports.LogDetails.encode(message.log_details, writer.uint32(66).fork()).ldelim();
1253
+ }
603
1254
  return writer;
604
1255
  },
605
1256
  decode(input, length) {
@@ -627,6 +1278,36 @@ exports.OperationOutput = {
627
1278
  }
628
1279
  message.port_outputs.push(exports.PortOutput.decode(reader, reader.uint32()));
629
1280
  continue;
1281
+ case 4:
1282
+ if (tag !== 34) {
1283
+ break;
1284
+ }
1285
+ message.input_configuration = struct_pb_1.Struct.unwrap(struct_pb_1.Struct.decode(reader, reader.uint32()));
1286
+ continue;
1287
+ case 5:
1288
+ if (tag !== 42) {
1289
+ break;
1290
+ }
1291
+ message.summary = reader.string();
1292
+ continue;
1293
+ case 6:
1294
+ if (tag !== 48) {
1295
+ break;
1296
+ }
1297
+ message.status = reader.int32();
1298
+ continue;
1299
+ case 7:
1300
+ if (tag !== 58) {
1301
+ break;
1302
+ }
1303
+ message.state = struct_pb_1.Value.unwrap(struct_pb_1.Value.decode(reader, reader.uint32()));
1304
+ continue;
1305
+ case 8:
1306
+ if (tag !== 66) {
1307
+ break;
1308
+ }
1309
+ message.log_details = exports.LogDetails.decode(reader, reader.uint32());
1310
+ continue;
630
1311
  }
631
1312
  if ((tag & 7) === 4 || tag === 0) {
632
1313
  break;
@@ -644,6 +1325,19 @@ exports.OperationOutput = {
644
1325
  port_outputs: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.port_outputs)
645
1326
  ? object.port_outputs.map((e) => exports.PortOutput.fromJSON(e))
646
1327
  : [],
1328
+ input_configuration: isObject(object.input_configuration)
1329
+ ? object.input_configuration
1330
+ : undefined,
1331
+ summary: isSet(object.summary)
1332
+ ? globalThis.String(object.summary)
1333
+ : undefined,
1334
+ status: isSet(object.status)
1335
+ ? operationOutput_ExecutionStatusFromJSON(object.status)
1336
+ : undefined,
1337
+ state: isSet(object === null || object === void 0 ? void 0 : object.state) ? object.state : undefined,
1338
+ log_details: isSet(object.log_details)
1339
+ ? exports.LogDetails.fromJSON(object.log_details)
1340
+ : undefined,
647
1341
  };
648
1342
  },
649
1343
  toJSON(message) {
@@ -658,13 +1352,28 @@ exports.OperationOutput = {
658
1352
  if ((_a = message.port_outputs) === null || _a === void 0 ? void 0 : _a.length) {
659
1353
  obj.port_outputs = message.port_outputs.map((e) => exports.PortOutput.toJSON(e));
660
1354
  }
1355
+ if (message.input_configuration !== undefined) {
1356
+ obj.input_configuration = message.input_configuration;
1357
+ }
1358
+ if (message.summary !== undefined) {
1359
+ obj.summary = message.summary;
1360
+ }
1361
+ if (message.status !== undefined) {
1362
+ obj.status = operationOutput_ExecutionStatusToJSON(message.status);
1363
+ }
1364
+ if (message.state !== undefined) {
1365
+ obj.state = message.state;
1366
+ }
1367
+ if (message.log_details !== undefined) {
1368
+ obj.log_details = exports.LogDetails.toJSON(message.log_details);
1369
+ }
661
1370
  return obj;
662
1371
  },
663
1372
  create(base) {
664
1373
  return exports.OperationOutput.fromPartial(base !== null && base !== void 0 ? base : {});
665
1374
  },
666
1375
  fromPartial(object) {
667
- var _a;
1376
+ var _a, _b, _c, _d, _e;
668
1377
  const message = createBaseOperationOutput();
669
1378
  message.error =
670
1379
  object.error !== undefined && object.error !== null
@@ -676,9 +1385,250 @@ exports.OperationOutput = {
676
1385
  : undefined;
677
1386
  message.port_outputs =
678
1387
  ((_a = object.port_outputs) === null || _a === void 0 ? void 0 : _a.map((e) => exports.PortOutput.fromPartial(e))) || [];
1388
+ message.input_configuration = (_b = object.input_configuration) !== null && _b !== void 0 ? _b : undefined;
1389
+ message.summary = (_c = object.summary) !== null && _c !== void 0 ? _c : undefined;
1390
+ message.status = (_d = object.status) !== null && _d !== void 0 ? _d : undefined;
1391
+ message.state = (_e = object.state) !== null && _e !== void 0 ? _e : undefined;
1392
+ message.log_details =
1393
+ object.log_details !== undefined && object.log_details !== null
1394
+ ? exports.LogDetails.fromPartial(object.log_details)
1395
+ : undefined;
1396
+ return message;
1397
+ },
1398
+ };
1399
+ function createBaseExternalOperationScopes() {
1400
+ return { self: [], impersonation: [] };
1401
+ }
1402
+ exports.ExternalOperationScopes = {
1403
+ encode(message, writer = _m0.Writer.create()) {
1404
+ for (const v of message.self) {
1405
+ exports.ExternalScopeEntry.encode(v, writer.uint32(10).fork()).ldelim();
1406
+ }
1407
+ for (const v of message.impersonation) {
1408
+ exports.ExternalImpersonationScopeEntry.encode(v, writer.uint32(18).fork()).ldelim();
1409
+ }
1410
+ return writer;
1411
+ },
1412
+ decode(input, length) {
1413
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
1414
+ let end = length === undefined ? reader.len : reader.pos + length;
1415
+ const message = createBaseExternalOperationScopes();
1416
+ while (reader.pos < end) {
1417
+ const tag = reader.uint32();
1418
+ switch (tag >>> 3) {
1419
+ case 1:
1420
+ if (tag !== 10) {
1421
+ break;
1422
+ }
1423
+ message.self.push(exports.ExternalScopeEntry.decode(reader, reader.uint32()));
1424
+ continue;
1425
+ case 2:
1426
+ if (tag !== 18) {
1427
+ break;
1428
+ }
1429
+ message.impersonation.push(exports.ExternalImpersonationScopeEntry.decode(reader, reader.uint32()));
1430
+ continue;
1431
+ }
1432
+ if ((tag & 7) === 4 || tag === 0) {
1433
+ break;
1434
+ }
1435
+ reader.skipType(tag & 7);
1436
+ }
1437
+ return message;
1438
+ },
1439
+ fromJSON(object) {
1440
+ return {
1441
+ self: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.self)
1442
+ ? object.self.map((e) => exports.ExternalScopeEntry.fromJSON(e))
1443
+ : [],
1444
+ impersonation: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.impersonation)
1445
+ ? object.impersonation.map((e) => exports.ExternalImpersonationScopeEntry.fromJSON(e))
1446
+ : [],
1447
+ };
1448
+ },
1449
+ toJSON(message) {
1450
+ var _a, _b;
1451
+ const obj = {};
1452
+ if ((_a = message.self) === null || _a === void 0 ? void 0 : _a.length) {
1453
+ obj.self = message.self.map((e) => exports.ExternalScopeEntry.toJSON(e));
1454
+ }
1455
+ if ((_b = message.impersonation) === null || _b === void 0 ? void 0 : _b.length) {
1456
+ obj.impersonation = message.impersonation.map((e) => exports.ExternalImpersonationScopeEntry.toJSON(e));
1457
+ }
1458
+ return obj;
1459
+ },
1460
+ create(base) {
1461
+ return exports.ExternalOperationScopes.fromPartial(base !== null && base !== void 0 ? base : {});
1462
+ },
1463
+ fromPartial(object) {
1464
+ var _a, _b;
1465
+ const message = createBaseExternalOperationScopes();
1466
+ message.self =
1467
+ ((_a = object.self) === null || _a === void 0 ? void 0 : _a.map((e) => exports.ExternalScopeEntry.fromPartial(e))) || [];
1468
+ message.impersonation =
1469
+ ((_b = object.impersonation) === null || _b === void 0 ? void 0 : _b.map((e) => exports.ExternalImpersonationScopeEntry.fromPartial(e))) || [];
679
1470
  return message;
680
1471
  },
681
1472
  };
1473
+ function createBaseExternalScopeEntry() {
1474
+ return { scope: '', optional: undefined, reason: undefined };
1475
+ }
1476
+ exports.ExternalScopeEntry = {
1477
+ encode(message, writer = _m0.Writer.create()) {
1478
+ if (message.scope !== '') {
1479
+ writer.uint32(10).string(message.scope);
1480
+ }
1481
+ if (message.optional !== undefined) {
1482
+ writer.uint32(16).bool(message.optional);
1483
+ }
1484
+ if (message.reason !== undefined) {
1485
+ writer.uint32(26).string(message.reason);
1486
+ }
1487
+ return writer;
1488
+ },
1489
+ decode(input, length) {
1490
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
1491
+ let end = length === undefined ? reader.len : reader.pos + length;
1492
+ const message = createBaseExternalScopeEntry();
1493
+ while (reader.pos < end) {
1494
+ const tag = reader.uint32();
1495
+ switch (tag >>> 3) {
1496
+ case 1:
1497
+ if (tag !== 10) {
1498
+ break;
1499
+ }
1500
+ message.scope = reader.string();
1501
+ continue;
1502
+ case 2:
1503
+ if (tag !== 16) {
1504
+ break;
1505
+ }
1506
+ message.optional = reader.bool();
1507
+ continue;
1508
+ case 3:
1509
+ if (tag !== 26) {
1510
+ break;
1511
+ }
1512
+ message.reason = reader.string();
1513
+ continue;
1514
+ }
1515
+ if ((tag & 7) === 4 || tag === 0) {
1516
+ break;
1517
+ }
1518
+ reader.skipType(tag & 7);
1519
+ }
1520
+ return message;
1521
+ },
1522
+ fromJSON(object) {
1523
+ return {
1524
+ scope: isSet(object.scope) ? globalThis.String(object.scope) : '',
1525
+ optional: isSet(object.optional)
1526
+ ? globalThis.Boolean(object.optional)
1527
+ : undefined,
1528
+ reason: isSet(object.reason)
1529
+ ? globalThis.String(object.reason)
1530
+ : undefined,
1531
+ };
1532
+ },
1533
+ toJSON(message) {
1534
+ const obj = {};
1535
+ if (message.scope !== '') {
1536
+ obj.scope = message.scope;
1537
+ }
1538
+ if (message.optional !== undefined) {
1539
+ obj.optional = message.optional;
1540
+ }
1541
+ if (message.reason !== undefined) {
1542
+ obj.reason = message.reason;
1543
+ }
1544
+ return obj;
1545
+ },
1546
+ create(base) {
1547
+ return exports.ExternalScopeEntry.fromPartial(base !== null && base !== void 0 ? base : {});
1548
+ },
1549
+ fromPartial(object) {
1550
+ var _a, _b, _c;
1551
+ const message = createBaseExternalScopeEntry();
1552
+ message.scope = (_a = object.scope) !== null && _a !== void 0 ? _a : '';
1553
+ message.optional = (_b = object.optional) !== null && _b !== void 0 ? _b : undefined;
1554
+ message.reason = (_c = object.reason) !== null && _c !== void 0 ? _c : undefined;
1555
+ return message;
1556
+ },
1557
+ };
1558
+ function createBaseExternalImpersonationScopeEntry() {
1559
+ return { act_as: '', scopes: [] };
1560
+ }
1561
+ exports.ExternalImpersonationScopeEntry = {
1562
+ encode(message, writer = _m0.Writer.create()) {
1563
+ if (message.act_as !== '') {
1564
+ writer.uint32(10).string(message.act_as);
1565
+ }
1566
+ for (const v of message.scopes) {
1567
+ exports.ExternalScopeEntry.encode(v, writer.uint32(18).fork()).ldelim();
1568
+ }
1569
+ return writer;
1570
+ },
1571
+ decode(input, length) {
1572
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
1573
+ let end = length === undefined ? reader.len : reader.pos + length;
1574
+ const message = createBaseExternalImpersonationScopeEntry();
1575
+ while (reader.pos < end) {
1576
+ const tag = reader.uint32();
1577
+ switch (tag >>> 3) {
1578
+ case 1:
1579
+ if (tag !== 10) {
1580
+ break;
1581
+ }
1582
+ message.act_as = reader.string();
1583
+ continue;
1584
+ case 2:
1585
+ if (tag !== 18) {
1586
+ break;
1587
+ }
1588
+ message.scopes.push(exports.ExternalScopeEntry.decode(reader, reader.uint32()));
1589
+ continue;
1590
+ }
1591
+ if ((tag & 7) === 4 || tag === 0) {
1592
+ break;
1593
+ }
1594
+ reader.skipType(tag & 7);
1595
+ }
1596
+ return message;
1597
+ },
1598
+ fromJSON(object) {
1599
+ return {
1600
+ act_as: isSet(object.act_as) ? globalThis.String(object.act_as) : '',
1601
+ scopes: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.scopes)
1602
+ ? object.scopes.map((e) => exports.ExternalScopeEntry.fromJSON(e))
1603
+ : [],
1604
+ };
1605
+ },
1606
+ toJSON(message) {
1607
+ var _a;
1608
+ const obj = {};
1609
+ if (message.act_as !== '') {
1610
+ obj.act_as = message.act_as;
1611
+ }
1612
+ if ((_a = message.scopes) === null || _a === void 0 ? void 0 : _a.length) {
1613
+ obj.scopes = message.scopes.map((e) => exports.ExternalScopeEntry.toJSON(e));
1614
+ }
1615
+ return obj;
1616
+ },
1617
+ create(base) {
1618
+ return exports.ExternalImpersonationScopeEntry.fromPartial(base !== null && base !== void 0 ? base : {});
1619
+ },
1620
+ fromPartial(object) {
1621
+ var _a, _b;
1622
+ const message = createBaseExternalImpersonationScopeEntry();
1623
+ message.act_as = (_a = object.act_as) !== null && _a !== void 0 ? _a : '';
1624
+ message.scopes =
1625
+ ((_b = object.scopes) === null || _b === void 0 ? void 0 : _b.map((e) => exports.ExternalScopeEntry.fromPartial(e))) || [];
1626
+ return message;
1627
+ },
1628
+ };
1629
+ function isObject(value) {
1630
+ return typeof value === 'object' && value !== null;
1631
+ }
682
1632
  function isSet(value) {
683
1633
  return value !== null && value !== undefined;
684
1634
  }