weave-typescript 0.11.12 → 0.11.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/dist/weaveapi/project/v1/project.pb.d.ts +40 -0
  2. package/dist/weaveapi/project/v1/project.pb.js +263 -0
  3. package/dist/weaveapi/project/v1/service.pb.d.ts +181 -0
  4. package/dist/weaveapi/project/v1/service.pb.js +1066 -0
  5. package/dist/weaveapi/workflow/v1/service.pb.d.ts +235 -0
  6. package/dist/weaveapi/workflow/v1/service.pb.js +1834 -0
  7. package/dist/weaveapi/workflow/v1/workflow.pb.d.ts +76 -0
  8. package/dist/weaveapi/workflow/v1/workflow.pb.js +539 -0
  9. package/dist/weavesql/llmxdb/capabilities_sql.d.ts +7 -7
  10. package/dist/weavesql/llmxdb/capabilities_sql.js +7 -7
  11. package/dist/weavesql/llmxdb/changes_sql.d.ts +5 -5
  12. package/dist/weavesql/llmxdb/changes_sql.js +6 -6
  13. package/dist/weavesql/llmxdb/models_sql.d.ts +6 -6
  14. package/dist/weavesql/llmxdb/models_sql.js +6 -6
  15. package/dist/weavesql/llmxdb/providers_sql.d.ts +5 -5
  16. package/dist/weavesql/llmxdb/providers_sql.js +5 -5
  17. package/dist/weavesql/llmxdb/scraper_runs_sql.d.ts +5 -5
  18. package/dist/weavesql/llmxdb/scraper_runs_sql.js +5 -5
  19. package/dist/weavesql/llmxdb/search_sql.d.ts +7 -7
  20. package/dist/weavesql/llmxdb/search_sql.js +7 -7
  21. package/dist/weavesql/weavedb/llm_provider_credentials_sql.d.ts +1 -1
  22. package/dist/weavesql/weavedb/llm_provider_credentials_sql.js +1 -1
  23. package/dist/weavesql/weavedb/project_sql.d.ts +95 -0
  24. package/dist/weavesql/weavedb/project_sql.js +166 -0
  25. package/dist/weavesql/weavedb/storage_sql.d.ts +2 -2
  26. package/dist/weavesql/weavedb/storage_sql.js +2 -2
  27. package/dist/weavesql/weavedb/workflow_sql.d.ts +142 -0
  28. package/dist/weavesql/weavedb/workflow_sql.js +260 -0
  29. package/package.json +1 -1
@@ -0,0 +1,1834 @@
1
+ "use strict";
2
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
+ // versions:
4
+ // protoc-gen-ts_proto v2.11.2
5
+ // protoc unknown
6
+ // source: weaveapi/workflow/v1/service.proto
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.WorkflowServiceDefinition = exports.WorkflowServiceClientImpl = exports.WorkflowServiceServiceName = exports.ListWorkflowStageStatesResponse = exports.ListWorkflowStageStatesRequest = exports.UpsertWorkflowStageStateResponse = exports.UpsertWorkflowStageStateRequest = exports.DeleteWorkflowResponse = exports.DeleteWorkflowRequest = exports.ArchiveWorkflowResponse = exports.ArchiveWorkflowRequest = exports.UpdateWorkflowResponse = exports.UpdateWorkflowRequest = exports.ListWorkflowsResponse = exports.ListWorkflowsRequest = exports.GetWorkflowResponse = exports.GetWorkflowRequest = exports.CreateWorkflowResponse = exports.CreateWorkflowRequest = exports.protobufPackage = void 0;
9
+ /* eslint-disable */
10
+ const wire_1 = require("@bufbuild/protobuf/wire");
11
+ const workflow_pb_1 = require("./workflow.pb");
12
+ exports.protobufPackage = "weaveapi.workflow.v1";
13
+ function createBaseCreateWorkflowRequest() {
14
+ return { projectId: "", name: "", description: "" };
15
+ }
16
+ exports.CreateWorkflowRequest = {
17
+ encode(message, writer = new wire_1.BinaryWriter()) {
18
+ if (message.projectId !== "") {
19
+ writer.uint32(10).string(message.projectId);
20
+ }
21
+ if (message.name !== "") {
22
+ writer.uint32(18).string(message.name);
23
+ }
24
+ if (message.description !== "") {
25
+ writer.uint32(26).string(message.description);
26
+ }
27
+ return writer;
28
+ },
29
+ decode(input, length) {
30
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
31
+ const end = length === undefined ? reader.len : reader.pos + length;
32
+ const message = createBaseCreateWorkflowRequest();
33
+ while (reader.pos < end) {
34
+ const tag = reader.uint32();
35
+ switch (tag >>> 3) {
36
+ case 1: {
37
+ if (tag !== 10) {
38
+ break;
39
+ }
40
+ message.projectId = reader.string();
41
+ continue;
42
+ }
43
+ case 2: {
44
+ if (tag !== 18) {
45
+ break;
46
+ }
47
+ message.name = reader.string();
48
+ continue;
49
+ }
50
+ case 3: {
51
+ if (tag !== 26) {
52
+ break;
53
+ }
54
+ message.description = reader.string();
55
+ continue;
56
+ }
57
+ }
58
+ if ((tag & 7) === 4 || tag === 0) {
59
+ break;
60
+ }
61
+ reader.skip(tag & 7);
62
+ }
63
+ return message;
64
+ },
65
+ fromJSON(object) {
66
+ return {
67
+ projectId: isSet(object.projectId)
68
+ ? globalThis.String(object.projectId)
69
+ : isSet(object.project_id)
70
+ ? globalThis.String(object.project_id)
71
+ : "",
72
+ name: isSet(object.name) ? globalThis.String(object.name) : "",
73
+ description: isSet(object.description) ? globalThis.String(object.description) : "",
74
+ };
75
+ },
76
+ toJSON(message) {
77
+ const obj = {};
78
+ if (message.projectId !== "") {
79
+ obj.projectId = message.projectId;
80
+ }
81
+ if (message.name !== "") {
82
+ obj.name = message.name;
83
+ }
84
+ if (message.description !== "") {
85
+ obj.description = message.description;
86
+ }
87
+ return obj;
88
+ },
89
+ create(base) {
90
+ return exports.CreateWorkflowRequest.fromPartial(base !== null && base !== void 0 ? base : {});
91
+ },
92
+ fromPartial(object) {
93
+ var _a, _b, _c;
94
+ const message = createBaseCreateWorkflowRequest();
95
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
96
+ message.name = (_b = object.name) !== null && _b !== void 0 ? _b : "";
97
+ message.description = (_c = object.description) !== null && _c !== void 0 ? _c : "";
98
+ return message;
99
+ },
100
+ };
101
+ function createBaseCreateWorkflowResponse() {
102
+ return { workflow: undefined };
103
+ }
104
+ exports.CreateWorkflowResponse = {
105
+ encode(message, writer = new wire_1.BinaryWriter()) {
106
+ if (message.workflow !== undefined) {
107
+ workflow_pb_1.Workflow.encode(message.workflow, writer.uint32(10).fork()).join();
108
+ }
109
+ return writer;
110
+ },
111
+ decode(input, length) {
112
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
113
+ const end = length === undefined ? reader.len : reader.pos + length;
114
+ const message = createBaseCreateWorkflowResponse();
115
+ while (reader.pos < end) {
116
+ const tag = reader.uint32();
117
+ switch (tag >>> 3) {
118
+ case 1: {
119
+ if (tag !== 10) {
120
+ break;
121
+ }
122
+ message.workflow = workflow_pb_1.Workflow.decode(reader, reader.uint32());
123
+ continue;
124
+ }
125
+ }
126
+ if ((tag & 7) === 4 || tag === 0) {
127
+ break;
128
+ }
129
+ reader.skip(tag & 7);
130
+ }
131
+ return message;
132
+ },
133
+ fromJSON(object) {
134
+ return { workflow: isSet(object.workflow) ? workflow_pb_1.Workflow.fromJSON(object.workflow) : undefined };
135
+ },
136
+ toJSON(message) {
137
+ const obj = {};
138
+ if (message.workflow !== undefined) {
139
+ obj.workflow = workflow_pb_1.Workflow.toJSON(message.workflow);
140
+ }
141
+ return obj;
142
+ },
143
+ create(base) {
144
+ return exports.CreateWorkflowResponse.fromPartial(base !== null && base !== void 0 ? base : {});
145
+ },
146
+ fromPartial(object) {
147
+ const message = createBaseCreateWorkflowResponse();
148
+ message.workflow = (object.workflow !== undefined && object.workflow !== null)
149
+ ? workflow_pb_1.Workflow.fromPartial(object.workflow)
150
+ : undefined;
151
+ return message;
152
+ },
153
+ };
154
+ function createBaseGetWorkflowRequest() {
155
+ return { projectId: "", workflowId: "" };
156
+ }
157
+ exports.GetWorkflowRequest = {
158
+ encode(message, writer = new wire_1.BinaryWriter()) {
159
+ if (message.projectId !== "") {
160
+ writer.uint32(10).string(message.projectId);
161
+ }
162
+ if (message.workflowId !== "") {
163
+ writer.uint32(18).string(message.workflowId);
164
+ }
165
+ return writer;
166
+ },
167
+ decode(input, length) {
168
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
169
+ const end = length === undefined ? reader.len : reader.pos + length;
170
+ const message = createBaseGetWorkflowRequest();
171
+ while (reader.pos < end) {
172
+ const tag = reader.uint32();
173
+ switch (tag >>> 3) {
174
+ case 1: {
175
+ if (tag !== 10) {
176
+ break;
177
+ }
178
+ message.projectId = reader.string();
179
+ continue;
180
+ }
181
+ case 2: {
182
+ if (tag !== 18) {
183
+ break;
184
+ }
185
+ message.workflowId = reader.string();
186
+ continue;
187
+ }
188
+ }
189
+ if ((tag & 7) === 4 || tag === 0) {
190
+ break;
191
+ }
192
+ reader.skip(tag & 7);
193
+ }
194
+ return message;
195
+ },
196
+ fromJSON(object) {
197
+ return {
198
+ projectId: isSet(object.projectId)
199
+ ? globalThis.String(object.projectId)
200
+ : isSet(object.project_id)
201
+ ? globalThis.String(object.project_id)
202
+ : "",
203
+ workflowId: isSet(object.workflowId)
204
+ ? globalThis.String(object.workflowId)
205
+ : isSet(object.workflow_id)
206
+ ? globalThis.String(object.workflow_id)
207
+ : "",
208
+ };
209
+ },
210
+ toJSON(message) {
211
+ const obj = {};
212
+ if (message.projectId !== "") {
213
+ obj.projectId = message.projectId;
214
+ }
215
+ if (message.workflowId !== "") {
216
+ obj.workflowId = message.workflowId;
217
+ }
218
+ return obj;
219
+ },
220
+ create(base) {
221
+ return exports.GetWorkflowRequest.fromPartial(base !== null && base !== void 0 ? base : {});
222
+ },
223
+ fromPartial(object) {
224
+ var _a, _b;
225
+ const message = createBaseGetWorkflowRequest();
226
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
227
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
228
+ return message;
229
+ },
230
+ };
231
+ function createBaseGetWorkflowResponse() {
232
+ return { workflow: undefined };
233
+ }
234
+ exports.GetWorkflowResponse = {
235
+ encode(message, writer = new wire_1.BinaryWriter()) {
236
+ if (message.workflow !== undefined) {
237
+ workflow_pb_1.Workflow.encode(message.workflow, writer.uint32(10).fork()).join();
238
+ }
239
+ return writer;
240
+ },
241
+ decode(input, length) {
242
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
243
+ const end = length === undefined ? reader.len : reader.pos + length;
244
+ const message = createBaseGetWorkflowResponse();
245
+ while (reader.pos < end) {
246
+ const tag = reader.uint32();
247
+ switch (tag >>> 3) {
248
+ case 1: {
249
+ if (tag !== 10) {
250
+ break;
251
+ }
252
+ message.workflow = workflow_pb_1.Workflow.decode(reader, reader.uint32());
253
+ continue;
254
+ }
255
+ }
256
+ if ((tag & 7) === 4 || tag === 0) {
257
+ break;
258
+ }
259
+ reader.skip(tag & 7);
260
+ }
261
+ return message;
262
+ },
263
+ fromJSON(object) {
264
+ return { workflow: isSet(object.workflow) ? workflow_pb_1.Workflow.fromJSON(object.workflow) : undefined };
265
+ },
266
+ toJSON(message) {
267
+ const obj = {};
268
+ if (message.workflow !== undefined) {
269
+ obj.workflow = workflow_pb_1.Workflow.toJSON(message.workflow);
270
+ }
271
+ return obj;
272
+ },
273
+ create(base) {
274
+ return exports.GetWorkflowResponse.fromPartial(base !== null && base !== void 0 ? base : {});
275
+ },
276
+ fromPartial(object) {
277
+ const message = createBaseGetWorkflowResponse();
278
+ message.workflow = (object.workflow !== undefined && object.workflow !== null)
279
+ ? workflow_pb_1.Workflow.fromPartial(object.workflow)
280
+ : undefined;
281
+ return message;
282
+ },
283
+ };
284
+ function createBaseListWorkflowsRequest() {
285
+ return { projectId: "", pageSize: 0, pageToken: "", includeArchived: false };
286
+ }
287
+ exports.ListWorkflowsRequest = {
288
+ encode(message, writer = new wire_1.BinaryWriter()) {
289
+ if (message.projectId !== "") {
290
+ writer.uint32(10).string(message.projectId);
291
+ }
292
+ if (message.pageSize !== 0) {
293
+ writer.uint32(16).int32(message.pageSize);
294
+ }
295
+ if (message.pageToken !== "") {
296
+ writer.uint32(26).string(message.pageToken);
297
+ }
298
+ if (message.includeArchived !== false) {
299
+ writer.uint32(32).bool(message.includeArchived);
300
+ }
301
+ return writer;
302
+ },
303
+ decode(input, length) {
304
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
305
+ const end = length === undefined ? reader.len : reader.pos + length;
306
+ const message = createBaseListWorkflowsRequest();
307
+ while (reader.pos < end) {
308
+ const tag = reader.uint32();
309
+ switch (tag >>> 3) {
310
+ case 1: {
311
+ if (tag !== 10) {
312
+ break;
313
+ }
314
+ message.projectId = reader.string();
315
+ continue;
316
+ }
317
+ case 2: {
318
+ if (tag !== 16) {
319
+ break;
320
+ }
321
+ message.pageSize = reader.int32();
322
+ continue;
323
+ }
324
+ case 3: {
325
+ if (tag !== 26) {
326
+ break;
327
+ }
328
+ message.pageToken = reader.string();
329
+ continue;
330
+ }
331
+ case 4: {
332
+ if (tag !== 32) {
333
+ break;
334
+ }
335
+ message.includeArchived = reader.bool();
336
+ continue;
337
+ }
338
+ }
339
+ if ((tag & 7) === 4 || tag === 0) {
340
+ break;
341
+ }
342
+ reader.skip(tag & 7);
343
+ }
344
+ return message;
345
+ },
346
+ fromJSON(object) {
347
+ return {
348
+ projectId: isSet(object.projectId)
349
+ ? globalThis.String(object.projectId)
350
+ : isSet(object.project_id)
351
+ ? globalThis.String(object.project_id)
352
+ : "",
353
+ pageSize: isSet(object.pageSize)
354
+ ? globalThis.Number(object.pageSize)
355
+ : isSet(object.page_size)
356
+ ? globalThis.Number(object.page_size)
357
+ : 0,
358
+ pageToken: isSet(object.pageToken)
359
+ ? globalThis.String(object.pageToken)
360
+ : isSet(object.page_token)
361
+ ? globalThis.String(object.page_token)
362
+ : "",
363
+ includeArchived: isSet(object.includeArchived)
364
+ ? globalThis.Boolean(object.includeArchived)
365
+ : isSet(object.include_archived)
366
+ ? globalThis.Boolean(object.include_archived)
367
+ : false,
368
+ };
369
+ },
370
+ toJSON(message) {
371
+ const obj = {};
372
+ if (message.projectId !== "") {
373
+ obj.projectId = message.projectId;
374
+ }
375
+ if (message.pageSize !== 0) {
376
+ obj.pageSize = Math.round(message.pageSize);
377
+ }
378
+ if (message.pageToken !== "") {
379
+ obj.pageToken = message.pageToken;
380
+ }
381
+ if (message.includeArchived !== false) {
382
+ obj.includeArchived = message.includeArchived;
383
+ }
384
+ return obj;
385
+ },
386
+ create(base) {
387
+ return exports.ListWorkflowsRequest.fromPartial(base !== null && base !== void 0 ? base : {});
388
+ },
389
+ fromPartial(object) {
390
+ var _a, _b, _c, _d;
391
+ const message = createBaseListWorkflowsRequest();
392
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
393
+ message.pageSize = (_b = object.pageSize) !== null && _b !== void 0 ? _b : 0;
394
+ message.pageToken = (_c = object.pageToken) !== null && _c !== void 0 ? _c : "";
395
+ message.includeArchived = (_d = object.includeArchived) !== null && _d !== void 0 ? _d : false;
396
+ return message;
397
+ },
398
+ };
399
+ function createBaseListWorkflowsResponse() {
400
+ return { workflows: [], nextPageToken: "" };
401
+ }
402
+ exports.ListWorkflowsResponse = {
403
+ encode(message, writer = new wire_1.BinaryWriter()) {
404
+ for (const v of message.workflows) {
405
+ workflow_pb_1.Workflow.encode(v, writer.uint32(10).fork()).join();
406
+ }
407
+ if (message.nextPageToken !== "") {
408
+ writer.uint32(18).string(message.nextPageToken);
409
+ }
410
+ return writer;
411
+ },
412
+ decode(input, length) {
413
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
414
+ const end = length === undefined ? reader.len : reader.pos + length;
415
+ const message = createBaseListWorkflowsResponse();
416
+ while (reader.pos < end) {
417
+ const tag = reader.uint32();
418
+ switch (tag >>> 3) {
419
+ case 1: {
420
+ if (tag !== 10) {
421
+ break;
422
+ }
423
+ message.workflows.push(workflow_pb_1.Workflow.decode(reader, reader.uint32()));
424
+ continue;
425
+ }
426
+ case 2: {
427
+ if (tag !== 18) {
428
+ break;
429
+ }
430
+ message.nextPageToken = reader.string();
431
+ continue;
432
+ }
433
+ }
434
+ if ((tag & 7) === 4 || tag === 0) {
435
+ break;
436
+ }
437
+ reader.skip(tag & 7);
438
+ }
439
+ return message;
440
+ },
441
+ fromJSON(object) {
442
+ return {
443
+ workflows: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.workflows)
444
+ ? object.workflows.map((e) => workflow_pb_1.Workflow.fromJSON(e))
445
+ : [],
446
+ nextPageToken: isSet(object.nextPageToken)
447
+ ? globalThis.String(object.nextPageToken)
448
+ : isSet(object.next_page_token)
449
+ ? globalThis.String(object.next_page_token)
450
+ : "",
451
+ };
452
+ },
453
+ toJSON(message) {
454
+ var _a;
455
+ const obj = {};
456
+ if ((_a = message.workflows) === null || _a === void 0 ? void 0 : _a.length) {
457
+ obj.workflows = message.workflows.map((e) => workflow_pb_1.Workflow.toJSON(e));
458
+ }
459
+ if (message.nextPageToken !== "") {
460
+ obj.nextPageToken = message.nextPageToken;
461
+ }
462
+ return obj;
463
+ },
464
+ create(base) {
465
+ return exports.ListWorkflowsResponse.fromPartial(base !== null && base !== void 0 ? base : {});
466
+ },
467
+ fromPartial(object) {
468
+ var _a;
469
+ var _b;
470
+ const message = createBaseListWorkflowsResponse();
471
+ message.workflows = ((_a = object.workflows) === null || _a === void 0 ? void 0 : _a.map((e) => workflow_pb_1.Workflow.fromPartial(e))) || [];
472
+ message.nextPageToken = (_b = object.nextPageToken) !== null && _b !== void 0 ? _b : "";
473
+ return message;
474
+ },
475
+ };
476
+ function createBaseUpdateWorkflowRequest() {
477
+ return { projectId: "", workflowId: "", name: "", description: "", status: 0 };
478
+ }
479
+ exports.UpdateWorkflowRequest = {
480
+ encode(message, writer = new wire_1.BinaryWriter()) {
481
+ if (message.projectId !== "") {
482
+ writer.uint32(10).string(message.projectId);
483
+ }
484
+ if (message.workflowId !== "") {
485
+ writer.uint32(18).string(message.workflowId);
486
+ }
487
+ if (message.name !== "") {
488
+ writer.uint32(26).string(message.name);
489
+ }
490
+ if (message.description !== "") {
491
+ writer.uint32(34).string(message.description);
492
+ }
493
+ if (message.status !== 0) {
494
+ writer.uint32(40).int32(message.status);
495
+ }
496
+ return writer;
497
+ },
498
+ decode(input, length) {
499
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
500
+ const end = length === undefined ? reader.len : reader.pos + length;
501
+ const message = createBaseUpdateWorkflowRequest();
502
+ while (reader.pos < end) {
503
+ const tag = reader.uint32();
504
+ switch (tag >>> 3) {
505
+ case 1: {
506
+ if (tag !== 10) {
507
+ break;
508
+ }
509
+ message.projectId = reader.string();
510
+ continue;
511
+ }
512
+ case 2: {
513
+ if (tag !== 18) {
514
+ break;
515
+ }
516
+ message.workflowId = reader.string();
517
+ continue;
518
+ }
519
+ case 3: {
520
+ if (tag !== 26) {
521
+ break;
522
+ }
523
+ message.name = reader.string();
524
+ continue;
525
+ }
526
+ case 4: {
527
+ if (tag !== 34) {
528
+ break;
529
+ }
530
+ message.description = reader.string();
531
+ continue;
532
+ }
533
+ case 5: {
534
+ if (tag !== 40) {
535
+ break;
536
+ }
537
+ message.status = reader.int32();
538
+ continue;
539
+ }
540
+ }
541
+ if ((tag & 7) === 4 || tag === 0) {
542
+ break;
543
+ }
544
+ reader.skip(tag & 7);
545
+ }
546
+ return message;
547
+ },
548
+ fromJSON(object) {
549
+ return {
550
+ projectId: isSet(object.projectId)
551
+ ? globalThis.String(object.projectId)
552
+ : isSet(object.project_id)
553
+ ? globalThis.String(object.project_id)
554
+ : "",
555
+ workflowId: isSet(object.workflowId)
556
+ ? globalThis.String(object.workflowId)
557
+ : isSet(object.workflow_id)
558
+ ? globalThis.String(object.workflow_id)
559
+ : "",
560
+ name: isSet(object.name) ? globalThis.String(object.name) : "",
561
+ description: isSet(object.description) ? globalThis.String(object.description) : "",
562
+ status: isSet(object.status) ? (0, workflow_pb_1.workflowStatusFromJSON)(object.status) : 0,
563
+ };
564
+ },
565
+ toJSON(message) {
566
+ const obj = {};
567
+ if (message.projectId !== "") {
568
+ obj.projectId = message.projectId;
569
+ }
570
+ if (message.workflowId !== "") {
571
+ obj.workflowId = message.workflowId;
572
+ }
573
+ if (message.name !== "") {
574
+ obj.name = message.name;
575
+ }
576
+ if (message.description !== "") {
577
+ obj.description = message.description;
578
+ }
579
+ if (message.status !== 0) {
580
+ obj.status = (0, workflow_pb_1.workflowStatusToJSON)(message.status);
581
+ }
582
+ return obj;
583
+ },
584
+ create(base) {
585
+ return exports.UpdateWorkflowRequest.fromPartial(base !== null && base !== void 0 ? base : {});
586
+ },
587
+ fromPartial(object) {
588
+ var _a, _b, _c, _d, _e;
589
+ const message = createBaseUpdateWorkflowRequest();
590
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
591
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
592
+ message.name = (_c = object.name) !== null && _c !== void 0 ? _c : "";
593
+ message.description = (_d = object.description) !== null && _d !== void 0 ? _d : "";
594
+ message.status = (_e = object.status) !== null && _e !== void 0 ? _e : 0;
595
+ return message;
596
+ },
597
+ };
598
+ function createBaseUpdateWorkflowResponse() {
599
+ return { workflow: undefined };
600
+ }
601
+ exports.UpdateWorkflowResponse = {
602
+ encode(message, writer = new wire_1.BinaryWriter()) {
603
+ if (message.workflow !== undefined) {
604
+ workflow_pb_1.Workflow.encode(message.workflow, writer.uint32(10).fork()).join();
605
+ }
606
+ return writer;
607
+ },
608
+ decode(input, length) {
609
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
610
+ const end = length === undefined ? reader.len : reader.pos + length;
611
+ const message = createBaseUpdateWorkflowResponse();
612
+ while (reader.pos < end) {
613
+ const tag = reader.uint32();
614
+ switch (tag >>> 3) {
615
+ case 1: {
616
+ if (tag !== 10) {
617
+ break;
618
+ }
619
+ message.workflow = workflow_pb_1.Workflow.decode(reader, reader.uint32());
620
+ continue;
621
+ }
622
+ }
623
+ if ((tag & 7) === 4 || tag === 0) {
624
+ break;
625
+ }
626
+ reader.skip(tag & 7);
627
+ }
628
+ return message;
629
+ },
630
+ fromJSON(object) {
631
+ return { workflow: isSet(object.workflow) ? workflow_pb_1.Workflow.fromJSON(object.workflow) : undefined };
632
+ },
633
+ toJSON(message) {
634
+ const obj = {};
635
+ if (message.workflow !== undefined) {
636
+ obj.workflow = workflow_pb_1.Workflow.toJSON(message.workflow);
637
+ }
638
+ return obj;
639
+ },
640
+ create(base) {
641
+ return exports.UpdateWorkflowResponse.fromPartial(base !== null && base !== void 0 ? base : {});
642
+ },
643
+ fromPartial(object) {
644
+ const message = createBaseUpdateWorkflowResponse();
645
+ message.workflow = (object.workflow !== undefined && object.workflow !== null)
646
+ ? workflow_pb_1.Workflow.fromPartial(object.workflow)
647
+ : undefined;
648
+ return message;
649
+ },
650
+ };
651
+ function createBaseArchiveWorkflowRequest() {
652
+ return { projectId: "", workflowId: "" };
653
+ }
654
+ exports.ArchiveWorkflowRequest = {
655
+ encode(message, writer = new wire_1.BinaryWriter()) {
656
+ if (message.projectId !== "") {
657
+ writer.uint32(10).string(message.projectId);
658
+ }
659
+ if (message.workflowId !== "") {
660
+ writer.uint32(18).string(message.workflowId);
661
+ }
662
+ return writer;
663
+ },
664
+ decode(input, length) {
665
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
666
+ const end = length === undefined ? reader.len : reader.pos + length;
667
+ const message = createBaseArchiveWorkflowRequest();
668
+ while (reader.pos < end) {
669
+ const tag = reader.uint32();
670
+ switch (tag >>> 3) {
671
+ case 1: {
672
+ if (tag !== 10) {
673
+ break;
674
+ }
675
+ message.projectId = reader.string();
676
+ continue;
677
+ }
678
+ case 2: {
679
+ if (tag !== 18) {
680
+ break;
681
+ }
682
+ message.workflowId = reader.string();
683
+ continue;
684
+ }
685
+ }
686
+ if ((tag & 7) === 4 || tag === 0) {
687
+ break;
688
+ }
689
+ reader.skip(tag & 7);
690
+ }
691
+ return message;
692
+ },
693
+ fromJSON(object) {
694
+ return {
695
+ projectId: isSet(object.projectId)
696
+ ? globalThis.String(object.projectId)
697
+ : isSet(object.project_id)
698
+ ? globalThis.String(object.project_id)
699
+ : "",
700
+ workflowId: isSet(object.workflowId)
701
+ ? globalThis.String(object.workflowId)
702
+ : isSet(object.workflow_id)
703
+ ? globalThis.String(object.workflow_id)
704
+ : "",
705
+ };
706
+ },
707
+ toJSON(message) {
708
+ const obj = {};
709
+ if (message.projectId !== "") {
710
+ obj.projectId = message.projectId;
711
+ }
712
+ if (message.workflowId !== "") {
713
+ obj.workflowId = message.workflowId;
714
+ }
715
+ return obj;
716
+ },
717
+ create(base) {
718
+ return exports.ArchiveWorkflowRequest.fromPartial(base !== null && base !== void 0 ? base : {});
719
+ },
720
+ fromPartial(object) {
721
+ var _a, _b;
722
+ const message = createBaseArchiveWorkflowRequest();
723
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
724
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
725
+ return message;
726
+ },
727
+ };
728
+ function createBaseArchiveWorkflowResponse() {
729
+ return { workflow: undefined };
730
+ }
731
+ exports.ArchiveWorkflowResponse = {
732
+ encode(message, writer = new wire_1.BinaryWriter()) {
733
+ if (message.workflow !== undefined) {
734
+ workflow_pb_1.Workflow.encode(message.workflow, writer.uint32(10).fork()).join();
735
+ }
736
+ return writer;
737
+ },
738
+ decode(input, length) {
739
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
740
+ const end = length === undefined ? reader.len : reader.pos + length;
741
+ const message = createBaseArchiveWorkflowResponse();
742
+ while (reader.pos < end) {
743
+ const tag = reader.uint32();
744
+ switch (tag >>> 3) {
745
+ case 1: {
746
+ if (tag !== 10) {
747
+ break;
748
+ }
749
+ message.workflow = workflow_pb_1.Workflow.decode(reader, reader.uint32());
750
+ continue;
751
+ }
752
+ }
753
+ if ((tag & 7) === 4 || tag === 0) {
754
+ break;
755
+ }
756
+ reader.skip(tag & 7);
757
+ }
758
+ return message;
759
+ },
760
+ fromJSON(object) {
761
+ return { workflow: isSet(object.workflow) ? workflow_pb_1.Workflow.fromJSON(object.workflow) : undefined };
762
+ },
763
+ toJSON(message) {
764
+ const obj = {};
765
+ if (message.workflow !== undefined) {
766
+ obj.workflow = workflow_pb_1.Workflow.toJSON(message.workflow);
767
+ }
768
+ return obj;
769
+ },
770
+ create(base) {
771
+ return exports.ArchiveWorkflowResponse.fromPartial(base !== null && base !== void 0 ? base : {});
772
+ },
773
+ fromPartial(object) {
774
+ const message = createBaseArchiveWorkflowResponse();
775
+ message.workflow = (object.workflow !== undefined && object.workflow !== null)
776
+ ? workflow_pb_1.Workflow.fromPartial(object.workflow)
777
+ : undefined;
778
+ return message;
779
+ },
780
+ };
781
+ function createBaseDeleteWorkflowRequest() {
782
+ return { projectId: "", workflowId: "" };
783
+ }
784
+ exports.DeleteWorkflowRequest = {
785
+ encode(message, writer = new wire_1.BinaryWriter()) {
786
+ if (message.projectId !== "") {
787
+ writer.uint32(10).string(message.projectId);
788
+ }
789
+ if (message.workflowId !== "") {
790
+ writer.uint32(18).string(message.workflowId);
791
+ }
792
+ return writer;
793
+ },
794
+ decode(input, length) {
795
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
796
+ const end = length === undefined ? reader.len : reader.pos + length;
797
+ const message = createBaseDeleteWorkflowRequest();
798
+ while (reader.pos < end) {
799
+ const tag = reader.uint32();
800
+ switch (tag >>> 3) {
801
+ case 1: {
802
+ if (tag !== 10) {
803
+ break;
804
+ }
805
+ message.projectId = reader.string();
806
+ continue;
807
+ }
808
+ case 2: {
809
+ if (tag !== 18) {
810
+ break;
811
+ }
812
+ message.workflowId = reader.string();
813
+ continue;
814
+ }
815
+ }
816
+ if ((tag & 7) === 4 || tag === 0) {
817
+ break;
818
+ }
819
+ reader.skip(tag & 7);
820
+ }
821
+ return message;
822
+ },
823
+ fromJSON(object) {
824
+ return {
825
+ projectId: isSet(object.projectId)
826
+ ? globalThis.String(object.projectId)
827
+ : isSet(object.project_id)
828
+ ? globalThis.String(object.project_id)
829
+ : "",
830
+ workflowId: isSet(object.workflowId)
831
+ ? globalThis.String(object.workflowId)
832
+ : isSet(object.workflow_id)
833
+ ? globalThis.String(object.workflow_id)
834
+ : "",
835
+ };
836
+ },
837
+ toJSON(message) {
838
+ const obj = {};
839
+ if (message.projectId !== "") {
840
+ obj.projectId = message.projectId;
841
+ }
842
+ if (message.workflowId !== "") {
843
+ obj.workflowId = message.workflowId;
844
+ }
845
+ return obj;
846
+ },
847
+ create(base) {
848
+ return exports.DeleteWorkflowRequest.fromPartial(base !== null && base !== void 0 ? base : {});
849
+ },
850
+ fromPartial(object) {
851
+ var _a, _b;
852
+ const message = createBaseDeleteWorkflowRequest();
853
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
854
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
855
+ return message;
856
+ },
857
+ };
858
+ function createBaseDeleteWorkflowResponse() {
859
+ return {};
860
+ }
861
+ exports.DeleteWorkflowResponse = {
862
+ encode(_, writer = new wire_1.BinaryWriter()) {
863
+ return writer;
864
+ },
865
+ decode(input, length) {
866
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
867
+ const end = length === undefined ? reader.len : reader.pos + length;
868
+ const message = createBaseDeleteWorkflowResponse();
869
+ while (reader.pos < end) {
870
+ const tag = reader.uint32();
871
+ switch (tag >>> 3) {
872
+ }
873
+ if ((tag & 7) === 4 || tag === 0) {
874
+ break;
875
+ }
876
+ reader.skip(tag & 7);
877
+ }
878
+ return message;
879
+ },
880
+ fromJSON(_) {
881
+ return {};
882
+ },
883
+ toJSON(_) {
884
+ const obj = {};
885
+ return obj;
886
+ },
887
+ create(base) {
888
+ return exports.DeleteWorkflowResponse.fromPartial(base !== null && base !== void 0 ? base : {});
889
+ },
890
+ fromPartial(_) {
891
+ const message = createBaseDeleteWorkflowResponse();
892
+ return message;
893
+ },
894
+ };
895
+ function createBaseUpsertWorkflowStageStateRequest() {
896
+ return { projectId: "", workflowId: "", stage: 0, status: 0, blockedReason: "" };
897
+ }
898
+ exports.UpsertWorkflowStageStateRequest = {
899
+ encode(message, writer = new wire_1.BinaryWriter()) {
900
+ if (message.projectId !== "") {
901
+ writer.uint32(10).string(message.projectId);
902
+ }
903
+ if (message.workflowId !== "") {
904
+ writer.uint32(18).string(message.workflowId);
905
+ }
906
+ if (message.stage !== 0) {
907
+ writer.uint32(24).int32(message.stage);
908
+ }
909
+ if (message.status !== 0) {
910
+ writer.uint32(32).int32(message.status);
911
+ }
912
+ if (message.blockedReason !== "") {
913
+ writer.uint32(42).string(message.blockedReason);
914
+ }
915
+ return writer;
916
+ },
917
+ decode(input, length) {
918
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
919
+ const end = length === undefined ? reader.len : reader.pos + length;
920
+ const message = createBaseUpsertWorkflowStageStateRequest();
921
+ while (reader.pos < end) {
922
+ const tag = reader.uint32();
923
+ switch (tag >>> 3) {
924
+ case 1: {
925
+ if (tag !== 10) {
926
+ break;
927
+ }
928
+ message.projectId = reader.string();
929
+ continue;
930
+ }
931
+ case 2: {
932
+ if (tag !== 18) {
933
+ break;
934
+ }
935
+ message.workflowId = reader.string();
936
+ continue;
937
+ }
938
+ case 3: {
939
+ if (tag !== 24) {
940
+ break;
941
+ }
942
+ message.stage = reader.int32();
943
+ continue;
944
+ }
945
+ case 4: {
946
+ if (tag !== 32) {
947
+ break;
948
+ }
949
+ message.status = reader.int32();
950
+ continue;
951
+ }
952
+ case 5: {
953
+ if (tag !== 42) {
954
+ break;
955
+ }
956
+ message.blockedReason = reader.string();
957
+ continue;
958
+ }
959
+ }
960
+ if ((tag & 7) === 4 || tag === 0) {
961
+ break;
962
+ }
963
+ reader.skip(tag & 7);
964
+ }
965
+ return message;
966
+ },
967
+ fromJSON(object) {
968
+ return {
969
+ projectId: isSet(object.projectId)
970
+ ? globalThis.String(object.projectId)
971
+ : isSet(object.project_id)
972
+ ? globalThis.String(object.project_id)
973
+ : "",
974
+ workflowId: isSet(object.workflowId)
975
+ ? globalThis.String(object.workflowId)
976
+ : isSet(object.workflow_id)
977
+ ? globalThis.String(object.workflow_id)
978
+ : "",
979
+ stage: isSet(object.stage) ? (0, workflow_pb_1.workflowStageFromJSON)(object.stage) : 0,
980
+ status: isSet(object.status) ? (0, workflow_pb_1.stageStatusFromJSON)(object.status) : 0,
981
+ blockedReason: isSet(object.blockedReason)
982
+ ? globalThis.String(object.blockedReason)
983
+ : isSet(object.blocked_reason)
984
+ ? globalThis.String(object.blocked_reason)
985
+ : "",
986
+ };
987
+ },
988
+ toJSON(message) {
989
+ const obj = {};
990
+ if (message.projectId !== "") {
991
+ obj.projectId = message.projectId;
992
+ }
993
+ if (message.workflowId !== "") {
994
+ obj.workflowId = message.workflowId;
995
+ }
996
+ if (message.stage !== 0) {
997
+ obj.stage = (0, workflow_pb_1.workflowStageToJSON)(message.stage);
998
+ }
999
+ if (message.status !== 0) {
1000
+ obj.status = (0, workflow_pb_1.stageStatusToJSON)(message.status);
1001
+ }
1002
+ if (message.blockedReason !== "") {
1003
+ obj.blockedReason = message.blockedReason;
1004
+ }
1005
+ return obj;
1006
+ },
1007
+ create(base) {
1008
+ return exports.UpsertWorkflowStageStateRequest.fromPartial(base !== null && base !== void 0 ? base : {});
1009
+ },
1010
+ fromPartial(object) {
1011
+ var _a, _b, _c, _d, _e;
1012
+ const message = createBaseUpsertWorkflowStageStateRequest();
1013
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
1014
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
1015
+ message.stage = (_c = object.stage) !== null && _c !== void 0 ? _c : 0;
1016
+ message.status = (_d = object.status) !== null && _d !== void 0 ? _d : 0;
1017
+ message.blockedReason = (_e = object.blockedReason) !== null && _e !== void 0 ? _e : "";
1018
+ return message;
1019
+ },
1020
+ };
1021
+ function createBaseUpsertWorkflowStageStateResponse() {
1022
+ return { stageState: undefined };
1023
+ }
1024
+ exports.UpsertWorkflowStageStateResponse = {
1025
+ encode(message, writer = new wire_1.BinaryWriter()) {
1026
+ if (message.stageState !== undefined) {
1027
+ workflow_pb_1.WorkflowStageState.encode(message.stageState, writer.uint32(10).fork()).join();
1028
+ }
1029
+ return writer;
1030
+ },
1031
+ decode(input, length) {
1032
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
1033
+ const end = length === undefined ? reader.len : reader.pos + length;
1034
+ const message = createBaseUpsertWorkflowStageStateResponse();
1035
+ while (reader.pos < end) {
1036
+ const tag = reader.uint32();
1037
+ switch (tag >>> 3) {
1038
+ case 1: {
1039
+ if (tag !== 10) {
1040
+ break;
1041
+ }
1042
+ message.stageState = workflow_pb_1.WorkflowStageState.decode(reader, reader.uint32());
1043
+ continue;
1044
+ }
1045
+ }
1046
+ if ((tag & 7) === 4 || tag === 0) {
1047
+ break;
1048
+ }
1049
+ reader.skip(tag & 7);
1050
+ }
1051
+ return message;
1052
+ },
1053
+ fromJSON(object) {
1054
+ return {
1055
+ stageState: isSet(object.stageState)
1056
+ ? workflow_pb_1.WorkflowStageState.fromJSON(object.stageState)
1057
+ : isSet(object.stage_state)
1058
+ ? workflow_pb_1.WorkflowStageState.fromJSON(object.stage_state)
1059
+ : undefined,
1060
+ };
1061
+ },
1062
+ toJSON(message) {
1063
+ const obj = {};
1064
+ if (message.stageState !== undefined) {
1065
+ obj.stageState = workflow_pb_1.WorkflowStageState.toJSON(message.stageState);
1066
+ }
1067
+ return obj;
1068
+ },
1069
+ create(base) {
1070
+ return exports.UpsertWorkflowStageStateResponse.fromPartial(base !== null && base !== void 0 ? base : {});
1071
+ },
1072
+ fromPartial(object) {
1073
+ const message = createBaseUpsertWorkflowStageStateResponse();
1074
+ message.stageState = (object.stageState !== undefined && object.stageState !== null)
1075
+ ? workflow_pb_1.WorkflowStageState.fromPartial(object.stageState)
1076
+ : undefined;
1077
+ return message;
1078
+ },
1079
+ };
1080
+ function createBaseListWorkflowStageStatesRequest() {
1081
+ return { projectId: "", workflowId: "" };
1082
+ }
1083
+ exports.ListWorkflowStageStatesRequest = {
1084
+ encode(message, writer = new wire_1.BinaryWriter()) {
1085
+ if (message.projectId !== "") {
1086
+ writer.uint32(10).string(message.projectId);
1087
+ }
1088
+ if (message.workflowId !== "") {
1089
+ writer.uint32(18).string(message.workflowId);
1090
+ }
1091
+ return writer;
1092
+ },
1093
+ decode(input, length) {
1094
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
1095
+ const end = length === undefined ? reader.len : reader.pos + length;
1096
+ const message = createBaseListWorkflowStageStatesRequest();
1097
+ while (reader.pos < end) {
1098
+ const tag = reader.uint32();
1099
+ switch (tag >>> 3) {
1100
+ case 1: {
1101
+ if (tag !== 10) {
1102
+ break;
1103
+ }
1104
+ message.projectId = reader.string();
1105
+ continue;
1106
+ }
1107
+ case 2: {
1108
+ if (tag !== 18) {
1109
+ break;
1110
+ }
1111
+ message.workflowId = reader.string();
1112
+ continue;
1113
+ }
1114
+ }
1115
+ if ((tag & 7) === 4 || tag === 0) {
1116
+ break;
1117
+ }
1118
+ reader.skip(tag & 7);
1119
+ }
1120
+ return message;
1121
+ },
1122
+ fromJSON(object) {
1123
+ return {
1124
+ projectId: isSet(object.projectId)
1125
+ ? globalThis.String(object.projectId)
1126
+ : isSet(object.project_id)
1127
+ ? globalThis.String(object.project_id)
1128
+ : "",
1129
+ workflowId: isSet(object.workflowId)
1130
+ ? globalThis.String(object.workflowId)
1131
+ : isSet(object.workflow_id)
1132
+ ? globalThis.String(object.workflow_id)
1133
+ : "",
1134
+ };
1135
+ },
1136
+ toJSON(message) {
1137
+ const obj = {};
1138
+ if (message.projectId !== "") {
1139
+ obj.projectId = message.projectId;
1140
+ }
1141
+ if (message.workflowId !== "") {
1142
+ obj.workflowId = message.workflowId;
1143
+ }
1144
+ return obj;
1145
+ },
1146
+ create(base) {
1147
+ return exports.ListWorkflowStageStatesRequest.fromPartial(base !== null && base !== void 0 ? base : {});
1148
+ },
1149
+ fromPartial(object) {
1150
+ var _a, _b;
1151
+ const message = createBaseListWorkflowStageStatesRequest();
1152
+ message.projectId = (_a = object.projectId) !== null && _a !== void 0 ? _a : "";
1153
+ message.workflowId = (_b = object.workflowId) !== null && _b !== void 0 ? _b : "";
1154
+ return message;
1155
+ },
1156
+ };
1157
+ function createBaseListWorkflowStageStatesResponse() {
1158
+ return { stageStates: [] };
1159
+ }
1160
+ exports.ListWorkflowStageStatesResponse = {
1161
+ encode(message, writer = new wire_1.BinaryWriter()) {
1162
+ for (const v of message.stageStates) {
1163
+ workflow_pb_1.WorkflowStageState.encode(v, writer.uint32(10).fork()).join();
1164
+ }
1165
+ return writer;
1166
+ },
1167
+ decode(input, length) {
1168
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
1169
+ const end = length === undefined ? reader.len : reader.pos + length;
1170
+ const message = createBaseListWorkflowStageStatesResponse();
1171
+ while (reader.pos < end) {
1172
+ const tag = reader.uint32();
1173
+ switch (tag >>> 3) {
1174
+ case 1: {
1175
+ if (tag !== 10) {
1176
+ break;
1177
+ }
1178
+ message.stageStates.push(workflow_pb_1.WorkflowStageState.decode(reader, reader.uint32()));
1179
+ continue;
1180
+ }
1181
+ }
1182
+ if ((tag & 7) === 4 || tag === 0) {
1183
+ break;
1184
+ }
1185
+ reader.skip(tag & 7);
1186
+ }
1187
+ return message;
1188
+ },
1189
+ fromJSON(object) {
1190
+ return {
1191
+ stageStates: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.stageStates)
1192
+ ? object.stageStates.map((e) => workflow_pb_1.WorkflowStageState.fromJSON(e))
1193
+ : globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.stage_states)
1194
+ ? object.stage_states.map((e) => workflow_pb_1.WorkflowStageState.fromJSON(e))
1195
+ : [],
1196
+ };
1197
+ },
1198
+ toJSON(message) {
1199
+ var _a;
1200
+ const obj = {};
1201
+ if ((_a = message.stageStates) === null || _a === void 0 ? void 0 : _a.length) {
1202
+ obj.stageStates = message.stageStates.map((e) => workflow_pb_1.WorkflowStageState.toJSON(e));
1203
+ }
1204
+ return obj;
1205
+ },
1206
+ create(base) {
1207
+ return exports.ListWorkflowStageStatesResponse.fromPartial(base !== null && base !== void 0 ? base : {});
1208
+ },
1209
+ fromPartial(object) {
1210
+ var _a;
1211
+ const message = createBaseListWorkflowStageStatesResponse();
1212
+ message.stageStates = ((_a = object.stageStates) === null || _a === void 0 ? void 0 : _a.map((e) => workflow_pb_1.WorkflowStageState.fromPartial(e))) || [];
1213
+ return message;
1214
+ },
1215
+ };
1216
+ exports.WorkflowServiceServiceName = "weaveapi.workflow.v1.WorkflowService";
1217
+ class WorkflowServiceClientImpl {
1218
+ rpc;
1219
+ service;
1220
+ constructor(rpc, opts) {
1221
+ this.service = (opts === null || opts === void 0 ? void 0 : opts.service) || exports.WorkflowServiceServiceName;
1222
+ this.rpc = rpc;
1223
+ this.CreateWorkflow = this.CreateWorkflow.bind(this);
1224
+ this.GetWorkflow = this.GetWorkflow.bind(this);
1225
+ this.ListWorkflows = this.ListWorkflows.bind(this);
1226
+ this.UpdateWorkflow = this.UpdateWorkflow.bind(this);
1227
+ this.ArchiveWorkflow = this.ArchiveWorkflow.bind(this);
1228
+ this.DeleteWorkflow = this.DeleteWorkflow.bind(this);
1229
+ this.UpsertWorkflowStageState = this.UpsertWorkflowStageState.bind(this);
1230
+ this.ListWorkflowStageStates = this.ListWorkflowStageStates.bind(this);
1231
+ }
1232
+ CreateWorkflow(request) {
1233
+ const data = exports.CreateWorkflowRequest.encode(request).finish();
1234
+ const promise = this.rpc.request(this.service, "CreateWorkflow", data);
1235
+ return promise.then((data) => exports.CreateWorkflowResponse.decode(new wire_1.BinaryReader(data)));
1236
+ }
1237
+ GetWorkflow(request) {
1238
+ const data = exports.GetWorkflowRequest.encode(request).finish();
1239
+ const promise = this.rpc.request(this.service, "GetWorkflow", data);
1240
+ return promise.then((data) => exports.GetWorkflowResponse.decode(new wire_1.BinaryReader(data)));
1241
+ }
1242
+ ListWorkflows(request) {
1243
+ const data = exports.ListWorkflowsRequest.encode(request).finish();
1244
+ const promise = this.rpc.request(this.service, "ListWorkflows", data);
1245
+ return promise.then((data) => exports.ListWorkflowsResponse.decode(new wire_1.BinaryReader(data)));
1246
+ }
1247
+ UpdateWorkflow(request) {
1248
+ const data = exports.UpdateWorkflowRequest.encode(request).finish();
1249
+ const promise = this.rpc.request(this.service, "UpdateWorkflow", data);
1250
+ return promise.then((data) => exports.UpdateWorkflowResponse.decode(new wire_1.BinaryReader(data)));
1251
+ }
1252
+ ArchiveWorkflow(request) {
1253
+ const data = exports.ArchiveWorkflowRequest.encode(request).finish();
1254
+ const promise = this.rpc.request(this.service, "ArchiveWorkflow", data);
1255
+ return promise.then((data) => exports.ArchiveWorkflowResponse.decode(new wire_1.BinaryReader(data)));
1256
+ }
1257
+ DeleteWorkflow(request) {
1258
+ const data = exports.DeleteWorkflowRequest.encode(request).finish();
1259
+ const promise = this.rpc.request(this.service, "DeleteWorkflow", data);
1260
+ return promise.then((data) => exports.DeleteWorkflowResponse.decode(new wire_1.BinaryReader(data)));
1261
+ }
1262
+ UpsertWorkflowStageState(request) {
1263
+ const data = exports.UpsertWorkflowStageStateRequest.encode(request).finish();
1264
+ const promise = this.rpc.request(this.service, "UpsertWorkflowStageState", data);
1265
+ return promise.then((data) => exports.UpsertWorkflowStageStateResponse.decode(new wire_1.BinaryReader(data)));
1266
+ }
1267
+ ListWorkflowStageStates(request) {
1268
+ const data = exports.ListWorkflowStageStatesRequest.encode(request).finish();
1269
+ const promise = this.rpc.request(this.service, "ListWorkflowStageStates", data);
1270
+ return promise.then((data) => exports.ListWorkflowStageStatesResponse.decode(new wire_1.BinaryReader(data)));
1271
+ }
1272
+ }
1273
+ exports.WorkflowServiceClientImpl = WorkflowServiceClientImpl;
1274
+ exports.WorkflowServiceDefinition = {
1275
+ name: "WorkflowService",
1276
+ fullName: "weaveapi.workflow.v1.WorkflowService",
1277
+ methods: {
1278
+ createWorkflow: {
1279
+ name: "CreateWorkflow",
1280
+ requestType: exports.CreateWorkflowRequest,
1281
+ requestStream: false,
1282
+ responseType: exports.CreateWorkflowResponse,
1283
+ responseStream: false,
1284
+ options: {
1285
+ _unknownFields: {
1286
+ 578365826: [
1287
+ new Uint8Array([
1288
+ 40,
1289
+ 58,
1290
+ 1,
1291
+ 42,
1292
+ 34,
1293
+ 35,
1294
+ 47,
1295
+ 118,
1296
+ 49,
1297
+ 47,
1298
+ 112,
1299
+ 114,
1300
+ 111,
1301
+ 106,
1302
+ 101,
1303
+ 99,
1304
+ 116,
1305
+ 115,
1306
+ 47,
1307
+ 123,
1308
+ 112,
1309
+ 114,
1310
+ 111,
1311
+ 106,
1312
+ 101,
1313
+ 99,
1314
+ 116,
1315
+ 95,
1316
+ 105,
1317
+ 100,
1318
+ 125,
1319
+ 47,
1320
+ 119,
1321
+ 111,
1322
+ 114,
1323
+ 107,
1324
+ 102,
1325
+ 108,
1326
+ 111,
1327
+ 119,
1328
+ 115,
1329
+ ]),
1330
+ ],
1331
+ },
1332
+ },
1333
+ },
1334
+ getWorkflow: {
1335
+ name: "GetWorkflow",
1336
+ requestType: exports.GetWorkflowRequest,
1337
+ requestStream: false,
1338
+ responseType: exports.GetWorkflowResponse,
1339
+ responseStream: false,
1340
+ options: {
1341
+ _unknownFields: {
1342
+ 578365826: [
1343
+ new Uint8Array([
1344
+ 51,
1345
+ 18,
1346
+ 49,
1347
+ 47,
1348
+ 118,
1349
+ 49,
1350
+ 47,
1351
+ 112,
1352
+ 114,
1353
+ 111,
1354
+ 106,
1355
+ 101,
1356
+ 99,
1357
+ 116,
1358
+ 115,
1359
+ 47,
1360
+ 123,
1361
+ 112,
1362
+ 114,
1363
+ 111,
1364
+ 106,
1365
+ 101,
1366
+ 99,
1367
+ 116,
1368
+ 95,
1369
+ 105,
1370
+ 100,
1371
+ 125,
1372
+ 47,
1373
+ 119,
1374
+ 111,
1375
+ 114,
1376
+ 107,
1377
+ 102,
1378
+ 108,
1379
+ 111,
1380
+ 119,
1381
+ 115,
1382
+ 47,
1383
+ 123,
1384
+ 119,
1385
+ 111,
1386
+ 114,
1387
+ 107,
1388
+ 102,
1389
+ 108,
1390
+ 111,
1391
+ 119,
1392
+ 95,
1393
+ 105,
1394
+ 100,
1395
+ 125,
1396
+ ]),
1397
+ ],
1398
+ },
1399
+ },
1400
+ },
1401
+ listWorkflows: {
1402
+ name: "ListWorkflows",
1403
+ requestType: exports.ListWorkflowsRequest,
1404
+ requestStream: false,
1405
+ responseType: exports.ListWorkflowsResponse,
1406
+ responseStream: false,
1407
+ options: {
1408
+ _unknownFields: {
1409
+ 578365826: [
1410
+ new Uint8Array([
1411
+ 37,
1412
+ 18,
1413
+ 35,
1414
+ 47,
1415
+ 118,
1416
+ 49,
1417
+ 47,
1418
+ 112,
1419
+ 114,
1420
+ 111,
1421
+ 106,
1422
+ 101,
1423
+ 99,
1424
+ 116,
1425
+ 115,
1426
+ 47,
1427
+ 123,
1428
+ 112,
1429
+ 114,
1430
+ 111,
1431
+ 106,
1432
+ 101,
1433
+ 99,
1434
+ 116,
1435
+ 95,
1436
+ 105,
1437
+ 100,
1438
+ 125,
1439
+ 47,
1440
+ 119,
1441
+ 111,
1442
+ 114,
1443
+ 107,
1444
+ 102,
1445
+ 108,
1446
+ 111,
1447
+ 119,
1448
+ 115,
1449
+ ]),
1450
+ ],
1451
+ },
1452
+ },
1453
+ },
1454
+ updateWorkflow: {
1455
+ name: "UpdateWorkflow",
1456
+ requestType: exports.UpdateWorkflowRequest,
1457
+ requestStream: false,
1458
+ responseType: exports.UpdateWorkflowResponse,
1459
+ responseStream: false,
1460
+ options: {
1461
+ _unknownFields: {
1462
+ 578365826: [
1463
+ new Uint8Array([
1464
+ 54,
1465
+ 58,
1466
+ 1,
1467
+ 42,
1468
+ 50,
1469
+ 49,
1470
+ 47,
1471
+ 118,
1472
+ 49,
1473
+ 47,
1474
+ 112,
1475
+ 114,
1476
+ 111,
1477
+ 106,
1478
+ 101,
1479
+ 99,
1480
+ 116,
1481
+ 115,
1482
+ 47,
1483
+ 123,
1484
+ 112,
1485
+ 114,
1486
+ 111,
1487
+ 106,
1488
+ 101,
1489
+ 99,
1490
+ 116,
1491
+ 95,
1492
+ 105,
1493
+ 100,
1494
+ 125,
1495
+ 47,
1496
+ 119,
1497
+ 111,
1498
+ 114,
1499
+ 107,
1500
+ 102,
1501
+ 108,
1502
+ 111,
1503
+ 119,
1504
+ 115,
1505
+ 47,
1506
+ 123,
1507
+ 119,
1508
+ 111,
1509
+ 114,
1510
+ 107,
1511
+ 102,
1512
+ 108,
1513
+ 111,
1514
+ 119,
1515
+ 95,
1516
+ 105,
1517
+ 100,
1518
+ 125,
1519
+ ]),
1520
+ ],
1521
+ },
1522
+ },
1523
+ },
1524
+ archiveWorkflow: {
1525
+ name: "ArchiveWorkflow",
1526
+ requestType: exports.ArchiveWorkflowRequest,
1527
+ requestStream: false,
1528
+ responseType: exports.ArchiveWorkflowResponse,
1529
+ responseStream: false,
1530
+ options: {
1531
+ _unknownFields: {
1532
+ 578365826: [
1533
+ new Uint8Array([
1534
+ 62,
1535
+ 58,
1536
+ 1,
1537
+ 42,
1538
+ 34,
1539
+ 57,
1540
+ 47,
1541
+ 118,
1542
+ 49,
1543
+ 47,
1544
+ 112,
1545
+ 114,
1546
+ 111,
1547
+ 106,
1548
+ 101,
1549
+ 99,
1550
+ 116,
1551
+ 115,
1552
+ 47,
1553
+ 123,
1554
+ 112,
1555
+ 114,
1556
+ 111,
1557
+ 106,
1558
+ 101,
1559
+ 99,
1560
+ 116,
1561
+ 95,
1562
+ 105,
1563
+ 100,
1564
+ 125,
1565
+ 47,
1566
+ 119,
1567
+ 111,
1568
+ 114,
1569
+ 107,
1570
+ 102,
1571
+ 108,
1572
+ 111,
1573
+ 119,
1574
+ 115,
1575
+ 47,
1576
+ 123,
1577
+ 119,
1578
+ 111,
1579
+ 114,
1580
+ 107,
1581
+ 102,
1582
+ 108,
1583
+ 111,
1584
+ 119,
1585
+ 95,
1586
+ 105,
1587
+ 100,
1588
+ 125,
1589
+ 58,
1590
+ 97,
1591
+ 114,
1592
+ 99,
1593
+ 104,
1594
+ 105,
1595
+ 118,
1596
+ 101,
1597
+ ]),
1598
+ ],
1599
+ },
1600
+ },
1601
+ },
1602
+ deleteWorkflow: {
1603
+ name: "DeleteWorkflow",
1604
+ requestType: exports.DeleteWorkflowRequest,
1605
+ requestStream: false,
1606
+ responseType: exports.DeleteWorkflowResponse,
1607
+ responseStream: false,
1608
+ options: {
1609
+ _unknownFields: {
1610
+ 578365826: [
1611
+ new Uint8Array([
1612
+ 51,
1613
+ 42,
1614
+ 49,
1615
+ 47,
1616
+ 118,
1617
+ 49,
1618
+ 47,
1619
+ 112,
1620
+ 114,
1621
+ 111,
1622
+ 106,
1623
+ 101,
1624
+ 99,
1625
+ 116,
1626
+ 115,
1627
+ 47,
1628
+ 123,
1629
+ 112,
1630
+ 114,
1631
+ 111,
1632
+ 106,
1633
+ 101,
1634
+ 99,
1635
+ 116,
1636
+ 95,
1637
+ 105,
1638
+ 100,
1639
+ 125,
1640
+ 47,
1641
+ 119,
1642
+ 111,
1643
+ 114,
1644
+ 107,
1645
+ 102,
1646
+ 108,
1647
+ 111,
1648
+ 119,
1649
+ 115,
1650
+ 47,
1651
+ 123,
1652
+ 119,
1653
+ 111,
1654
+ 114,
1655
+ 107,
1656
+ 102,
1657
+ 108,
1658
+ 111,
1659
+ 119,
1660
+ 95,
1661
+ 105,
1662
+ 100,
1663
+ 125,
1664
+ ]),
1665
+ ],
1666
+ },
1667
+ },
1668
+ },
1669
+ upsertWorkflowStageState: {
1670
+ name: "UpsertWorkflowStageState",
1671
+ requestType: exports.UpsertWorkflowStageStateRequest,
1672
+ requestStream: false,
1673
+ responseType: exports.UpsertWorkflowStageStateResponse,
1674
+ responseStream: false,
1675
+ options: {
1676
+ _unknownFields: {
1677
+ 578365826: [
1678
+ new Uint8Array([
1679
+ 66,
1680
+ 58,
1681
+ 1,
1682
+ 42,
1683
+ 34,
1684
+ 61,
1685
+ 47,
1686
+ 118,
1687
+ 49,
1688
+ 47,
1689
+ 112,
1690
+ 114,
1691
+ 111,
1692
+ 106,
1693
+ 101,
1694
+ 99,
1695
+ 116,
1696
+ 115,
1697
+ 47,
1698
+ 123,
1699
+ 112,
1700
+ 114,
1701
+ 111,
1702
+ 106,
1703
+ 101,
1704
+ 99,
1705
+ 116,
1706
+ 95,
1707
+ 105,
1708
+ 100,
1709
+ 125,
1710
+ 47,
1711
+ 119,
1712
+ 111,
1713
+ 114,
1714
+ 107,
1715
+ 102,
1716
+ 108,
1717
+ 111,
1718
+ 119,
1719
+ 115,
1720
+ 47,
1721
+ 123,
1722
+ 119,
1723
+ 111,
1724
+ 114,
1725
+ 107,
1726
+ 102,
1727
+ 108,
1728
+ 111,
1729
+ 119,
1730
+ 95,
1731
+ 105,
1732
+ 100,
1733
+ 125,
1734
+ 47,
1735
+ 115,
1736
+ 116,
1737
+ 97,
1738
+ 103,
1739
+ 101,
1740
+ 45,
1741
+ 115,
1742
+ 116,
1743
+ 97,
1744
+ 116,
1745
+ 101,
1746
+ ]),
1747
+ ],
1748
+ },
1749
+ },
1750
+ },
1751
+ listWorkflowStageStates: {
1752
+ name: "ListWorkflowStageStates",
1753
+ requestType: exports.ListWorkflowStageStatesRequest,
1754
+ requestStream: false,
1755
+ responseType: exports.ListWorkflowStageStatesResponse,
1756
+ responseStream: false,
1757
+ options: {
1758
+ _unknownFields: {
1759
+ 578365826: [
1760
+ new Uint8Array([
1761
+ 63,
1762
+ 18,
1763
+ 61,
1764
+ 47,
1765
+ 118,
1766
+ 49,
1767
+ 47,
1768
+ 112,
1769
+ 114,
1770
+ 111,
1771
+ 106,
1772
+ 101,
1773
+ 99,
1774
+ 116,
1775
+ 115,
1776
+ 47,
1777
+ 123,
1778
+ 112,
1779
+ 114,
1780
+ 111,
1781
+ 106,
1782
+ 101,
1783
+ 99,
1784
+ 116,
1785
+ 95,
1786
+ 105,
1787
+ 100,
1788
+ 125,
1789
+ 47,
1790
+ 119,
1791
+ 111,
1792
+ 114,
1793
+ 107,
1794
+ 102,
1795
+ 108,
1796
+ 111,
1797
+ 119,
1798
+ 115,
1799
+ 47,
1800
+ 123,
1801
+ 119,
1802
+ 111,
1803
+ 114,
1804
+ 107,
1805
+ 102,
1806
+ 108,
1807
+ 111,
1808
+ 119,
1809
+ 95,
1810
+ 105,
1811
+ 100,
1812
+ 125,
1813
+ 47,
1814
+ 115,
1815
+ 116,
1816
+ 97,
1817
+ 103,
1818
+ 101,
1819
+ 45,
1820
+ 115,
1821
+ 116,
1822
+ 97,
1823
+ 116,
1824
+ 101,
1825
+ ]),
1826
+ ],
1827
+ },
1828
+ },
1829
+ },
1830
+ },
1831
+ };
1832
+ function isSet(value) {
1833
+ return value !== null && value !== undefined;
1834
+ }