@cratis/chronicle.contracts 19.67.0 → 19.69.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/dist/cjs/generated/descriptorSet.js +1 -1
  2. package/dist/cjs/generated/descriptorSet.js.map +1 -1
  3. package/dist/cjs/generated/index.d.ts +2 -0
  4. package/dist/cjs/generated/index.d.ts.map +1 -1
  5. package/dist/cjs/generated/occurrences.d.ts +490 -0
  6. package/dist/cjs/generated/occurrences.d.ts.map +1 -0
  7. package/dist/cjs/generated/occurrences.js +5166 -0
  8. package/dist/cjs/generated/occurrences.js.map +1 -0
  9. package/dist/cjs/generated/sequences.d.ts +39 -0
  10. package/dist/cjs/generated/sequences.d.ts.map +1 -1
  11. package/dist/cjs/generated/sequences.js +580 -1
  12. package/dist/cjs/generated/sequences.js.map +1 -1
  13. package/dist/cjs/index.js +70 -0
  14. package/dist/cjs/index.js.map +1 -1
  15. package/dist/esm/generated/descriptorSet.js +1 -1
  16. package/dist/esm/generated/descriptorSet.js.map +1 -1
  17. package/dist/esm/generated/index.d.ts +2 -0
  18. package/dist/esm/generated/index.d.ts.map +1 -1
  19. package/dist/esm/generated/occurrences.d.ts +490 -0
  20. package/dist/esm/generated/occurrences.d.ts.map +1 -0
  21. package/dist/esm/generated/occurrences.js +5116 -0
  22. package/dist/esm/generated/occurrences.js.map +1 -0
  23. package/dist/esm/generated/sequences.d.ts +39 -0
  24. package/dist/esm/generated/sequences.d.ts.map +1 -1
  25. package/dist/esm/generated/sequences.js +577 -2
  26. package/dist/esm/generated/sequences.js.map +1 -1
  27. package/dist/esm/index.js +1 -0
  28. package/dist/esm/index.js.map +1 -1
  29. package/dist/generated/descriptorSet.js +1 -1
  30. package/dist/generated/descriptorSet.js.map +1 -1
  31. package/dist/generated/index.d.ts +2 -0
  32. package/dist/generated/index.d.ts.map +1 -1
  33. package/dist/generated/index.js +1 -0
  34. package/dist/generated/index.js.map +1 -1
  35. package/dist/generated/occurrences.d.ts +490 -0
  36. package/dist/generated/occurrences.d.ts.map +1 -0
  37. package/dist/generated/occurrences.js +5114 -0
  38. package/dist/generated/occurrences.js.map +1 -0
  39. package/dist/generated/sequences.d.ts +39 -0
  40. package/dist/generated/sequences.d.ts.map +1 -1
  41. package/dist/generated/sequences.js +576 -1
  42. package/dist/generated/sequences.js.map +1 -1
  43. package/dist/tsconfig.tsbuildinfo +1 -1
  44. package/generated/descriptorSet.ts +1 -1
  45. package/generated/index.ts +3 -0
  46. package/generated/occurrences.ts +5917 -0
  47. package/generated/sequences.ts +644 -1
  48. package/package.json +1 -1
@@ -191,6 +191,45 @@ export function contentVerificationResultToJSON(object: ContentVerificationResul
191
191
  }
192
192
  }
193
193
 
194
+ export enum EffectOutcome {
195
+ Appended = 0,
196
+ NoEvents = 1,
197
+ Refused = 2,
198
+ UNRECOGNIZED = -1,
199
+ }
200
+
201
+ export function effectOutcomeFromJSON(object: any): EffectOutcome {
202
+ switch (object) {
203
+ case 0:
204
+ case "Appended":
205
+ return EffectOutcome.Appended;
206
+ case 1:
207
+ case "NoEvents":
208
+ return EffectOutcome.NoEvents;
209
+ case 2:
210
+ case "Refused":
211
+ return EffectOutcome.Refused;
212
+ case -1:
213
+ case "UNRECOGNIZED":
214
+ default:
215
+ return EffectOutcome.UNRECOGNIZED;
216
+ }
217
+ }
218
+
219
+ export function effectOutcomeToJSON(object: EffectOutcome): string {
220
+ switch (object) {
221
+ case EffectOutcome.Appended:
222
+ return "Appended";
223
+ case EffectOutcome.NoEvents:
224
+ return "NoEvents";
225
+ case EffectOutcome.Refused:
226
+ return "Refused";
227
+ case EffectOutcome.UNRECOGNIZED:
228
+ default:
229
+ return "UNRECOGNIZED";
230
+ }
231
+ }
232
+
194
233
  export enum EventObservationState {
195
234
  EVENT_OBSERVATION_STATE_None = 0,
196
235
  Initial = 1,
@@ -476,6 +515,7 @@ export interface AppendManyForEventSourcesRequest {
476
515
  Causation: Causation[];
477
516
  CausedBy: Identity | undefined;
478
517
  ConcurrencyScopes: EventSourceConcurrencyScope[];
518
+ EffectReceipt: EffectReceipt | undefined;
479
519
  }
480
520
 
481
521
  export interface AppendManyForEventSourcesWithNamedTagsRequest {
@@ -488,6 +528,7 @@ export interface AppendManyForEventSourcesWithNamedTagsRequest {
488
528
  Causation: Causation[];
489
529
  CausedBy: Identity | undefined;
490
530
  ConcurrencyScopes: EventSourceConcurrencyScope[];
531
+ EffectReceipt: EffectReceipt | undefined;
491
532
  }
492
533
 
493
534
  export interface AppendManyRequest {
@@ -502,6 +543,7 @@ export interface AppendManyRequest {
502
543
  CausedBy: Identity | undefined;
503
544
  ConcurrencyScope: ConcurrencyScope | undefined;
504
545
  Occurred: SerializableDateTimeOffset | undefined;
546
+ EffectReceipt: EffectReceipt | undefined;
505
547
  }
506
548
 
507
549
  export interface AppendManyResponse {
@@ -516,6 +558,8 @@ export interface AppendManyResponse {
516
558
  ConstraintViolations: ConstraintViolation[];
517
559
  Errors: string[];
518
560
  ConcurrencyViolations: ConcurrencyViolation[];
561
+ EffectReceipt: EffectReceiptDetails | undefined;
562
+ EffectAlreadyRecorded: boolean;
519
563
  }
520
564
 
521
565
  export interface AppendManyWithNamedTagsRequest {
@@ -530,6 +574,7 @@ export interface AppendManyWithNamedTagsRequest {
530
574
  Causation: Causation[];
531
575
  CausedBy: Identity | undefined;
532
576
  ConcurrencyScope: ConcurrencyScope | undefined;
577
+ EffectReceipt: EffectReceipt | undefined;
533
578
  }
534
579
 
535
580
  export interface AppendRequest {
@@ -550,6 +595,7 @@ export interface AppendRequest {
550
595
  CausedBy: Identity | undefined;
551
596
  ConcurrencyScope: ConcurrencyScope | undefined;
552
597
  EventSource: string;
598
+ EffectReceipt: EffectReceipt | undefined;
553
599
  }
554
600
 
555
601
  export interface AppendResponse {
@@ -564,6 +610,8 @@ export interface AppendResponse {
564
610
  ConstraintViolations: ConstraintViolation[];
565
611
  Errors: string[];
566
612
  ConcurrencyViolation: ConcurrencyViolation | undefined;
613
+ EffectReceipt: EffectReceiptDetails | undefined;
614
+ EffectAlreadyRecorded: boolean;
567
615
  }
568
616
 
569
617
  export interface AppendWithNamedTagsRequest {
@@ -585,6 +633,7 @@ export interface AppendWithNamedTagsRequest {
585
633
  CausedBy: Identity | undefined;
586
634
  ConcurrencyScope: ConcurrencyScope | undefined;
587
635
  EventSource: string;
636
+ EffectReceipt: EffectReceipt | undefined;
588
637
  }
589
638
 
590
639
  export interface AppendedEventResponse {
@@ -594,6 +643,7 @@ export interface AppendedEventResponse {
594
643
  OriginalContent: string;
595
644
  Revisions: EventRevision[];
596
645
  GenerationalContent: KeyValuePairInt32String[];
646
+ RevisedGeneration: number;
597
647
  }
598
648
 
599
649
  export interface AppendedEventsRequest {
@@ -755,6 +805,26 @@ export interface ConstraintViolation_DetailsEntry {
755
805
  value: string;
756
806
  }
757
807
 
808
+ export interface EffectReceipt {
809
+ OccurrenceId: string;
810
+ EffectKey: string;
811
+ Epoch: bigint;
812
+ Response: string;
813
+ }
814
+
815
+ export interface EffectReceiptDetails {
816
+ Id: string;
817
+ OccurrenceId: string;
818
+ Epoch: bigint;
819
+ Outcome: EffectOutcome;
820
+ EventSequenceId: string;
821
+ FirstSequenceNumber: bigint;
822
+ LastSequenceNumber: bigint;
823
+ Reasons: string[];
824
+ Response: string;
825
+ RecordedAt: SerializableDateTimeOffset | undefined;
826
+ }
827
+
758
828
  export interface EndOfRequest {
759
829
  Start: SerializableDateTimeOffset | undefined;
760
830
  Resolution: HistogramResolution;
@@ -1345,6 +1415,7 @@ function createBaseAppendManyForEventSourcesRequest(): AppendManyForEventSources
1345
1415
  Causation: [],
1346
1416
  CausedBy: undefined,
1347
1417
  ConcurrencyScopes: [],
1418
+ EffectReceipt: undefined,
1348
1419
  };
1349
1420
  }
1350
1421
 
@@ -1377,6 +1448,9 @@ export const AppendManyForEventSourcesRequest: MessageFns<AppendManyForEventSour
1377
1448
  for (const v of message.ConcurrencyScopes) {
1378
1449
  EventSourceConcurrencyScope.encode(v!, writer.uint32(74).fork()).join();
1379
1450
  }
1451
+ if (message.EffectReceipt !== undefined) {
1452
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(82).fork()).join();
1453
+ }
1380
1454
  return writer;
1381
1455
  },
1382
1456
 
@@ -1465,6 +1539,14 @@ export const AppendManyForEventSourcesRequest: MessageFns<AppendManyForEventSour
1465
1539
  message.ConcurrencyScopes.push(EventSourceConcurrencyScope.decode(reader, reader.uint32()));
1466
1540
  continue;
1467
1541
  }
1542
+ case 10: {
1543
+ if (tag !== 82) {
1544
+ break;
1545
+ }
1546
+
1547
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
1548
+ continue;
1549
+ }
1468
1550
  }
1469
1551
  if ((tag & 7) === 4 || tag === 0) {
1470
1552
  break;
@@ -1494,6 +1576,7 @@ export const AppendManyForEventSourcesRequest: MessageFns<AppendManyForEventSour
1494
1576
  ConcurrencyScopes: globalThis.Array.isArray(object?.ConcurrencyScopes)
1495
1577
  ? object.ConcurrencyScopes.map((e: any) => EventSourceConcurrencyScope.fromJSON(e))
1496
1578
  : [],
1579
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
1497
1580
  };
1498
1581
  },
1499
1582
 
@@ -1526,6 +1609,9 @@ export const AppendManyForEventSourcesRequest: MessageFns<AppendManyForEventSour
1526
1609
  if (message.ConcurrencyScopes?.length) {
1527
1610
  obj.ConcurrencyScopes = message.ConcurrencyScopes.map((e) => EventSourceConcurrencyScope.toJSON(e));
1528
1611
  }
1612
+ if (message.EffectReceipt !== undefined) {
1613
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
1614
+ }
1529
1615
  return obj;
1530
1616
  },
1531
1617
 
@@ -1547,6 +1633,9 @@ export const AppendManyForEventSourcesRequest: MessageFns<AppendManyForEventSour
1547
1633
  ? Identity.fromPartial(object.CausedBy)
1548
1634
  : undefined;
1549
1635
  message.ConcurrencyScopes = object.ConcurrencyScopes?.map((e) => EventSourceConcurrencyScope.fromPartial(e)) || [];
1636
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
1637
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
1638
+ : undefined;
1550
1639
  return message;
1551
1640
  },
1552
1641
  };
@@ -1562,6 +1651,7 @@ function createBaseAppendManyForEventSourcesWithNamedTagsRequest(): AppendManyFo
1562
1651
  Causation: [],
1563
1652
  CausedBy: undefined,
1564
1653
  ConcurrencyScopes: [],
1654
+ EffectReceipt: undefined,
1565
1655
  };
1566
1656
  }
1567
1657
 
@@ -1598,6 +1688,9 @@ export const AppendManyForEventSourcesWithNamedTagsRequest: MessageFns<AppendMan
1598
1688
  for (const v of message.ConcurrencyScopes) {
1599
1689
  EventSourceConcurrencyScope.encode(v!, writer.uint32(74).fork()).join();
1600
1690
  }
1691
+ if (message.EffectReceipt !== undefined) {
1692
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(82).fork()).join();
1693
+ }
1601
1694
  return writer;
1602
1695
  },
1603
1696
 
@@ -1686,6 +1779,14 @@ export const AppendManyForEventSourcesWithNamedTagsRequest: MessageFns<AppendMan
1686
1779
  message.ConcurrencyScopes.push(EventSourceConcurrencyScope.decode(reader, reader.uint32()));
1687
1780
  continue;
1688
1781
  }
1782
+ case 10: {
1783
+ if (tag !== 82) {
1784
+ break;
1785
+ }
1786
+
1787
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
1788
+ continue;
1789
+ }
1689
1790
  }
1690
1791
  if ((tag & 7) === 4 || tag === 0) {
1691
1792
  break;
@@ -1715,6 +1816,7 @@ export const AppendManyForEventSourcesWithNamedTagsRequest: MessageFns<AppendMan
1715
1816
  ConcurrencyScopes: globalThis.Array.isArray(object?.ConcurrencyScopes)
1716
1817
  ? object.ConcurrencyScopes.map((e: any) => EventSourceConcurrencyScope.fromJSON(e))
1717
1818
  : [],
1819
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
1718
1820
  };
1719
1821
  },
1720
1822
 
@@ -1747,6 +1849,9 @@ export const AppendManyForEventSourcesWithNamedTagsRequest: MessageFns<AppendMan
1747
1849
  if (message.ConcurrencyScopes?.length) {
1748
1850
  obj.ConcurrencyScopes = message.ConcurrencyScopes.map((e) => EventSourceConcurrencyScope.toJSON(e));
1749
1851
  }
1852
+ if (message.EffectReceipt !== undefined) {
1853
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
1854
+ }
1750
1855
  return obj;
1751
1856
  },
1752
1857
 
@@ -1773,6 +1878,9 @@ export const AppendManyForEventSourcesWithNamedTagsRequest: MessageFns<AppendMan
1773
1878
  : undefined;
1774
1879
  message.ConcurrencyScopes = object.ConcurrencyScopes?.map((e) => EventSourceConcurrencyScope.fromPartial(e)) ||
1775
1880
  [];
1881
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
1882
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
1883
+ : undefined;
1776
1884
  return message;
1777
1885
  },
1778
1886
  };
@@ -1790,6 +1898,7 @@ function createBaseAppendManyRequest(): AppendManyRequest {
1790
1898
  CausedBy: undefined,
1791
1899
  ConcurrencyScope: undefined,
1792
1900
  Occurred: undefined,
1901
+ EffectReceipt: undefined,
1793
1902
  };
1794
1903
  }
1795
1904
 
@@ -1828,6 +1937,9 @@ export const AppendManyRequest: MessageFns<AppendManyRequest> = {
1828
1937
  if (message.Occurred !== undefined) {
1829
1938
  SerializableDateTimeOffset.encode(message.Occurred, writer.uint32(90).fork()).join();
1830
1939
  }
1940
+ if (message.EffectReceipt !== undefined) {
1941
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(98).fork()).join();
1942
+ }
1831
1943
  return writer;
1832
1944
  },
1833
1945
 
@@ -1932,6 +2044,14 @@ export const AppendManyRequest: MessageFns<AppendManyRequest> = {
1932
2044
  message.Occurred = SerializableDateTimeOffset.decode(reader, reader.uint32());
1933
2045
  continue;
1934
2046
  }
2047
+ case 12: {
2048
+ if (tag !== 98) {
2049
+ break;
2050
+ }
2051
+
2052
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
2053
+ continue;
2054
+ }
1935
2055
  }
1936
2056
  if ((tag & 7) === 4 || tag === 0) {
1937
2057
  break;
@@ -1959,6 +2079,7 @@ export const AppendManyRequest: MessageFns<AppendManyRequest> = {
1959
2079
  CausedBy: isSet(object.CausedBy) ? Identity.fromJSON(object.CausedBy) : undefined,
1960
2080
  ConcurrencyScope: isSet(object.ConcurrencyScope) ? ConcurrencyScope.fromJSON(object.ConcurrencyScope) : undefined,
1961
2081
  Occurred: isSet(object.Occurred) ? SerializableDateTimeOffset.fromJSON(object.Occurred) : undefined,
2082
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
1962
2083
  };
1963
2084
  },
1964
2085
 
@@ -1997,6 +2118,9 @@ export const AppendManyRequest: MessageFns<AppendManyRequest> = {
1997
2118
  if (message.Occurred !== undefined) {
1998
2119
  obj.Occurred = SerializableDateTimeOffset.toJSON(message.Occurred);
1999
2120
  }
2121
+ if (message.EffectReceipt !== undefined) {
2122
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
2123
+ }
2000
2124
  return obj;
2001
2125
  },
2002
2126
 
@@ -2024,6 +2148,9 @@ export const AppendManyRequest: MessageFns<AppendManyRequest> = {
2024
2148
  message.Occurred = (object.Occurred !== undefined && object.Occurred !== null)
2025
2149
  ? SerializableDateTimeOffset.fromPartial(object.Occurred)
2026
2150
  : undefined;
2151
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
2152
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
2153
+ : undefined;
2027
2154
  return message;
2028
2155
  },
2029
2156
  };
@@ -2040,6 +2167,8 @@ function createBaseAppendManyResponse(): AppendManyResponse {
2040
2167
  ConstraintViolations: [],
2041
2168
  Errors: [],
2042
2169
  ConcurrencyViolations: [],
2170
+ EffectReceipt: undefined,
2171
+ EffectAlreadyRecorded: false,
2043
2172
  };
2044
2173
  }
2045
2174
 
@@ -2078,6 +2207,12 @@ export const AppendManyResponse: MessageFns<AppendManyResponse> = {
2078
2207
  for (const v of message.ConcurrencyViolations) {
2079
2208
  ConcurrencyViolation.encode(v!, writer.uint32(82).fork()).join();
2080
2209
  }
2210
+ if (message.EffectReceipt !== undefined) {
2211
+ EffectReceiptDetails.encode(message.EffectReceipt, writer.uint32(90).fork()).join();
2212
+ }
2213
+ if (message.EffectAlreadyRecorded !== false) {
2214
+ writer.uint32(96).bool(message.EffectAlreadyRecorded);
2215
+ }
2081
2216
  return writer;
2082
2217
  },
2083
2218
 
@@ -2184,6 +2319,22 @@ export const AppendManyResponse: MessageFns<AppendManyResponse> = {
2184
2319
  message.ConcurrencyViolations.push(ConcurrencyViolation.decode(reader, reader.uint32()));
2185
2320
  continue;
2186
2321
  }
2322
+ case 11: {
2323
+ if (tag !== 90) {
2324
+ break;
2325
+ }
2326
+
2327
+ message.EffectReceipt = EffectReceiptDetails.decode(reader, reader.uint32());
2328
+ continue;
2329
+ }
2330
+ case 12: {
2331
+ if (tag !== 96) {
2332
+ break;
2333
+ }
2334
+
2335
+ message.EffectAlreadyRecorded = reader.bool();
2336
+ continue;
2337
+ }
2187
2338
  }
2188
2339
  if ((tag & 7) === 4 || tag === 0) {
2189
2340
  break;
@@ -2220,6 +2371,10 @@ export const AppendManyResponse: MessageFns<AppendManyResponse> = {
2220
2371
  ConcurrencyViolations: globalThis.Array.isArray(object?.ConcurrencyViolations)
2221
2372
  ? object.ConcurrencyViolations.map((e: any) => ConcurrencyViolation.fromJSON(e))
2222
2373
  : [],
2374
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceiptDetails.fromJSON(object.EffectReceipt) : undefined,
2375
+ EffectAlreadyRecorded: isSet(object.EffectAlreadyRecorded)
2376
+ ? globalThis.Boolean(object.EffectAlreadyRecorded)
2377
+ : false,
2223
2378
  };
2224
2379
  },
2225
2380
 
@@ -2255,6 +2410,12 @@ export const AppendManyResponse: MessageFns<AppendManyResponse> = {
2255
2410
  if (message.ConcurrencyViolations?.length) {
2256
2411
  obj.ConcurrencyViolations = message.ConcurrencyViolations.map((e) => ConcurrencyViolation.toJSON(e));
2257
2412
  }
2413
+ if (message.EffectReceipt !== undefined) {
2414
+ obj.EffectReceipt = EffectReceiptDetails.toJSON(message.EffectReceipt);
2415
+ }
2416
+ if (message.EffectAlreadyRecorded !== false) {
2417
+ obj.EffectAlreadyRecorded = message.EffectAlreadyRecorded;
2418
+ }
2258
2419
  return obj;
2259
2420
  },
2260
2421
 
@@ -2275,6 +2436,10 @@ export const AppendManyResponse: MessageFns<AppendManyResponse> = {
2275
2436
  message.ConstraintViolations = object.ConstraintViolations?.map((e) => ConstraintViolation.fromPartial(e)) || [];
2276
2437
  message.Errors = object.Errors?.map((e) => e) || [];
2277
2438
  message.ConcurrencyViolations = object.ConcurrencyViolations?.map((e) => ConcurrencyViolation.fromPartial(e)) || [];
2439
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
2440
+ ? EffectReceiptDetails.fromPartial(object.EffectReceipt)
2441
+ : undefined;
2442
+ message.EffectAlreadyRecorded = object.EffectAlreadyRecorded ?? false;
2278
2443
  return message;
2279
2444
  },
2280
2445
  };
@@ -2292,6 +2457,7 @@ function createBaseAppendManyWithNamedTagsRequest(): AppendManyWithNamedTagsRequ
2292
2457
  Causation: [],
2293
2458
  CausedBy: undefined,
2294
2459
  ConcurrencyScope: undefined,
2460
+ EffectReceipt: undefined,
2295
2461
  };
2296
2462
  }
2297
2463
 
@@ -2330,6 +2496,9 @@ export const AppendManyWithNamedTagsRequest: MessageFns<AppendManyWithNamedTagsR
2330
2496
  if (message.ConcurrencyScope !== undefined) {
2331
2497
  ConcurrencyScope.encode(message.ConcurrencyScope, writer.uint32(90).fork()).join();
2332
2498
  }
2499
+ if (message.EffectReceipt !== undefined) {
2500
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(98).fork()).join();
2501
+ }
2333
2502
  return writer;
2334
2503
  },
2335
2504
 
@@ -2434,6 +2603,14 @@ export const AppendManyWithNamedTagsRequest: MessageFns<AppendManyWithNamedTagsR
2434
2603
  message.ConcurrencyScope = ConcurrencyScope.decode(reader, reader.uint32());
2435
2604
  continue;
2436
2605
  }
2606
+ case 12: {
2607
+ if (tag !== 98) {
2608
+ break;
2609
+ }
2610
+
2611
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
2612
+ continue;
2613
+ }
2437
2614
  }
2438
2615
  if ((tag & 7) === 4 || tag === 0) {
2439
2616
  break;
@@ -2463,6 +2640,7 @@ export const AppendManyWithNamedTagsRequest: MessageFns<AppendManyWithNamedTagsR
2463
2640
  : [],
2464
2641
  CausedBy: isSet(object.CausedBy) ? Identity.fromJSON(object.CausedBy) : undefined,
2465
2642
  ConcurrencyScope: isSet(object.ConcurrencyScope) ? ConcurrencyScope.fromJSON(object.ConcurrencyScope) : undefined,
2643
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
2466
2644
  };
2467
2645
  },
2468
2646
 
@@ -2501,6 +2679,9 @@ export const AppendManyWithNamedTagsRequest: MessageFns<AppendManyWithNamedTagsR
2501
2679
  if (message.ConcurrencyScope !== undefined) {
2502
2680
  obj.ConcurrencyScope = ConcurrencyScope.toJSON(message.ConcurrencyScope);
2503
2681
  }
2682
+ if (message.EffectReceipt !== undefined) {
2683
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
2684
+ }
2504
2685
  return obj;
2505
2686
  },
2506
2687
 
@@ -2528,6 +2709,9 @@ export const AppendManyWithNamedTagsRequest: MessageFns<AppendManyWithNamedTagsR
2528
2709
  message.ConcurrencyScope = (object.ConcurrencyScope !== undefined && object.ConcurrencyScope !== null)
2529
2710
  ? ConcurrencyScope.fromPartial(object.ConcurrencyScope)
2530
2711
  : undefined;
2712
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
2713
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
2714
+ : undefined;
2531
2715
  return message;
2532
2716
  },
2533
2717
  };
@@ -2551,6 +2735,7 @@ function createBaseAppendRequest(): AppendRequest {
2551
2735
  CausedBy: undefined,
2552
2736
  ConcurrencyScope: undefined,
2553
2737
  EventSource: "",
2738
+ EffectReceipt: undefined,
2554
2739
  };
2555
2740
  }
2556
2741
 
@@ -2607,6 +2792,9 @@ export const AppendRequest: MessageFns<AppendRequest> = {
2607
2792
  if (message.EventSource !== "") {
2608
2793
  writer.uint32(138).string(message.EventSource);
2609
2794
  }
2795
+ if (message.EffectReceipt !== undefined) {
2796
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(146).fork()).join();
2797
+ }
2610
2798
  return writer;
2611
2799
  },
2612
2800
 
@@ -2759,6 +2947,14 @@ export const AppendRequest: MessageFns<AppendRequest> = {
2759
2947
  message.EventSource = reader.string();
2760
2948
  continue;
2761
2949
  }
2950
+ case 18: {
2951
+ if (tag !== 146) {
2952
+ break;
2953
+ }
2954
+
2955
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
2956
+ continue;
2957
+ }
2762
2958
  }
2763
2959
  if ((tag & 7) === 4 || tag === 0) {
2764
2960
  break;
@@ -2792,6 +2988,7 @@ export const AppendRequest: MessageFns<AppendRequest> = {
2792
2988
  CausedBy: isSet(object.CausedBy) ? Identity.fromJSON(object.CausedBy) : undefined,
2793
2989
  ConcurrencyScope: isSet(object.ConcurrencyScope) ? ConcurrencyScope.fromJSON(object.ConcurrencyScope) : undefined,
2794
2990
  EventSource: isSet(object.EventSource) ? globalThis.String(object.EventSource) : "",
2991
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
2795
2992
  };
2796
2993
  },
2797
2994
 
@@ -2848,6 +3045,9 @@ export const AppendRequest: MessageFns<AppendRequest> = {
2848
3045
  if (message.EventSource !== "") {
2849
3046
  obj.EventSource = message.EventSource;
2850
3047
  }
3048
+ if (message.EffectReceipt !== undefined) {
3049
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
3050
+ }
2851
3051
  return obj;
2852
3052
  },
2853
3053
 
@@ -2883,6 +3083,9 @@ export const AppendRequest: MessageFns<AppendRequest> = {
2883
3083
  ? ConcurrencyScope.fromPartial(object.ConcurrencyScope)
2884
3084
  : undefined;
2885
3085
  message.EventSource = object.EventSource ?? "";
3086
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
3087
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
3088
+ : undefined;
2886
3089
  return message;
2887
3090
  },
2888
3091
  };
@@ -2899,6 +3102,8 @@ function createBaseAppendResponse(): AppendResponse {
2899
3102
  ConstraintViolations: [],
2900
3103
  Errors: [],
2901
3104
  ConcurrencyViolation: undefined,
3105
+ EffectReceipt: undefined,
3106
+ EffectAlreadyRecorded: false,
2902
3107
  };
2903
3108
  }
2904
3109
 
@@ -2937,6 +3142,12 @@ export const AppendResponse: MessageFns<AppendResponse> = {
2937
3142
  if (message.ConcurrencyViolation !== undefined) {
2938
3143
  ConcurrencyViolation.encode(message.ConcurrencyViolation, writer.uint32(82).fork()).join();
2939
3144
  }
3145
+ if (message.EffectReceipt !== undefined) {
3146
+ EffectReceiptDetails.encode(message.EffectReceipt, writer.uint32(90).fork()).join();
3147
+ }
3148
+ if (message.EffectAlreadyRecorded !== false) {
3149
+ writer.uint32(96).bool(message.EffectAlreadyRecorded);
3150
+ }
2940
3151
  return writer;
2941
3152
  },
2942
3153
 
@@ -3033,6 +3244,22 @@ export const AppendResponse: MessageFns<AppendResponse> = {
3033
3244
  message.ConcurrencyViolation = ConcurrencyViolation.decode(reader, reader.uint32());
3034
3245
  continue;
3035
3246
  }
3247
+ case 11: {
3248
+ if (tag !== 90) {
3249
+ break;
3250
+ }
3251
+
3252
+ message.EffectReceipt = EffectReceiptDetails.decode(reader, reader.uint32());
3253
+ continue;
3254
+ }
3255
+ case 12: {
3256
+ if (tag !== 96) {
3257
+ break;
3258
+ }
3259
+
3260
+ message.EffectAlreadyRecorded = reader.bool();
3261
+ continue;
3262
+ }
3036
3263
  }
3037
3264
  if ((tag & 7) === 4 || tag === 0) {
3038
3265
  break;
@@ -3069,6 +3296,10 @@ export const AppendResponse: MessageFns<AppendResponse> = {
3069
3296
  ConcurrencyViolation: isSet(object.ConcurrencyViolation)
3070
3297
  ? ConcurrencyViolation.fromJSON(object.ConcurrencyViolation)
3071
3298
  : undefined,
3299
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceiptDetails.fromJSON(object.EffectReceipt) : undefined,
3300
+ EffectAlreadyRecorded: isSet(object.EffectAlreadyRecorded)
3301
+ ? globalThis.Boolean(object.EffectAlreadyRecorded)
3302
+ : false,
3072
3303
  };
3073
3304
  },
3074
3305
 
@@ -3104,6 +3335,12 @@ export const AppendResponse: MessageFns<AppendResponse> = {
3104
3335
  if (message.ConcurrencyViolation !== undefined) {
3105
3336
  obj.ConcurrencyViolation = ConcurrencyViolation.toJSON(message.ConcurrencyViolation);
3106
3337
  }
3338
+ if (message.EffectReceipt !== undefined) {
3339
+ obj.EffectReceipt = EffectReceiptDetails.toJSON(message.EffectReceipt);
3340
+ }
3341
+ if (message.EffectAlreadyRecorded !== false) {
3342
+ obj.EffectAlreadyRecorded = message.EffectAlreadyRecorded;
3343
+ }
3107
3344
  return obj;
3108
3345
  },
3109
3346
 
@@ -3128,6 +3365,10 @@ export const AppendResponse: MessageFns<AppendResponse> = {
3128
3365
  message.ConcurrencyViolation = (object.ConcurrencyViolation !== undefined && object.ConcurrencyViolation !== null)
3129
3366
  ? ConcurrencyViolation.fromPartial(object.ConcurrencyViolation)
3130
3367
  : undefined;
3368
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
3369
+ ? EffectReceiptDetails.fromPartial(object.EffectReceipt)
3370
+ : undefined;
3371
+ message.EffectAlreadyRecorded = object.EffectAlreadyRecorded ?? false;
3131
3372
  return message;
3132
3373
  },
3133
3374
  };
@@ -3152,6 +3393,7 @@ function createBaseAppendWithNamedTagsRequest(): AppendWithNamedTagsRequest {
3152
3393
  CausedBy: undefined,
3153
3394
  ConcurrencyScope: undefined,
3154
3395
  EventSource: "",
3396
+ EffectReceipt: undefined,
3155
3397
  };
3156
3398
  }
3157
3399
 
@@ -3211,6 +3453,9 @@ export const AppendWithNamedTagsRequest: MessageFns<AppendWithNamedTagsRequest>
3211
3453
  if (message.EventSource !== "") {
3212
3454
  writer.uint32(146).string(message.EventSource);
3213
3455
  }
3456
+ if (message.EffectReceipt !== undefined) {
3457
+ EffectReceipt.encode(message.EffectReceipt, writer.uint32(154).fork()).join();
3458
+ }
3214
3459
  return writer;
3215
3460
  },
3216
3461
 
@@ -3371,6 +3616,14 @@ export const AppendWithNamedTagsRequest: MessageFns<AppendWithNamedTagsRequest>
3371
3616
  message.EventSource = reader.string();
3372
3617
  continue;
3373
3618
  }
3619
+ case 19: {
3620
+ if (tag !== 154) {
3621
+ break;
3622
+ }
3623
+
3624
+ message.EffectReceipt = EffectReceipt.decode(reader, reader.uint32());
3625
+ continue;
3626
+ }
3374
3627
  }
3375
3628
  if ((tag & 7) === 4 || tag === 0) {
3376
3629
  break;
@@ -3407,6 +3660,7 @@ export const AppendWithNamedTagsRequest: MessageFns<AppendWithNamedTagsRequest>
3407
3660
  CausedBy: isSet(object.CausedBy) ? Identity.fromJSON(object.CausedBy) : undefined,
3408
3661
  ConcurrencyScope: isSet(object.ConcurrencyScope) ? ConcurrencyScope.fromJSON(object.ConcurrencyScope) : undefined,
3409
3662
  EventSource: isSet(object.EventSource) ? globalThis.String(object.EventSource) : "",
3663
+ EffectReceipt: isSet(object.EffectReceipt) ? EffectReceipt.fromJSON(object.EffectReceipt) : undefined,
3410
3664
  };
3411
3665
  },
3412
3666
 
@@ -3466,6 +3720,9 @@ export const AppendWithNamedTagsRequest: MessageFns<AppendWithNamedTagsRequest>
3466
3720
  if (message.EventSource !== "") {
3467
3721
  obj.EventSource = message.EventSource;
3468
3722
  }
3723
+ if (message.EffectReceipt !== undefined) {
3724
+ obj.EffectReceipt = EffectReceipt.toJSON(message.EffectReceipt);
3725
+ }
3469
3726
  return obj;
3470
3727
  },
3471
3728
 
@@ -3502,12 +3759,23 @@ export const AppendWithNamedTagsRequest: MessageFns<AppendWithNamedTagsRequest>
3502
3759
  ? ConcurrencyScope.fromPartial(object.ConcurrencyScope)
3503
3760
  : undefined;
3504
3761
  message.EventSource = object.EventSource ?? "";
3762
+ message.EffectReceipt = (object.EffectReceipt !== undefined && object.EffectReceipt !== null)
3763
+ ? EffectReceipt.fromPartial(object.EffectReceipt)
3764
+ : undefined;
3505
3765
  return message;
3506
3766
  },
3507
3767
  };
3508
3768
 
3509
3769
  function createBaseAppendedEventResponse(): AppendedEventResponse {
3510
- return { Id: "", Context: undefined, Content: "", OriginalContent: "", Revisions: [], GenerationalContent: [] };
3770
+ return {
3771
+ Id: "",
3772
+ Context: undefined,
3773
+ Content: "",
3774
+ OriginalContent: "",
3775
+ Revisions: [],
3776
+ GenerationalContent: [],
3777
+ RevisedGeneration: 0,
3778
+ };
3511
3779
  }
3512
3780
 
3513
3781
  export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
@@ -3530,6 +3798,9 @@ export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
3530
3798
  for (const v of message.GenerationalContent) {
3531
3799
  KeyValuePairInt32String.encode(v!, writer.uint32(50).fork()).join();
3532
3800
  }
3801
+ if (message.RevisedGeneration !== 0) {
3802
+ writer.uint32(56).uint32(message.RevisedGeneration);
3803
+ }
3533
3804
  return writer;
3534
3805
  },
3535
3806
 
@@ -3594,6 +3865,14 @@ export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
3594
3865
  message.GenerationalContent.push(KeyValuePairInt32String.decode(reader, reader.uint32()));
3595
3866
  continue;
3596
3867
  }
3868
+ case 7: {
3869
+ if (tag !== 56) {
3870
+ break;
3871
+ }
3872
+
3873
+ message.RevisedGeneration = reader.uint32();
3874
+ continue;
3875
+ }
3597
3876
  }
3598
3877
  if ((tag & 7) === 4 || tag === 0) {
3599
3878
  break;
@@ -3618,6 +3897,7 @@ export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
3618
3897
  GenerationalContent: globalThis.Array.isArray(object?.GenerationalContent)
3619
3898
  ? object.GenerationalContent.map((e: any) => KeyValuePairInt32String.fromJSON(e))
3620
3899
  : [],
3900
+ RevisedGeneration: isSet(object.RevisedGeneration) ? globalThis.Number(object.RevisedGeneration) : 0,
3621
3901
  };
3622
3902
  },
3623
3903
 
@@ -3641,6 +3921,9 @@ export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
3641
3921
  if (message.GenerationalContent?.length) {
3642
3922
  obj.GenerationalContent = message.GenerationalContent.map((e) => KeyValuePairInt32String.toJSON(e));
3643
3923
  }
3924
+ if (message.RevisedGeneration !== 0) {
3925
+ obj.RevisedGeneration = Math.round(message.RevisedGeneration);
3926
+ }
3644
3927
  return obj;
3645
3928
  },
3646
3929
 
@@ -3657,6 +3940,7 @@ export const AppendedEventResponse: MessageFns<AppendedEventResponse> = {
3657
3940
  message.OriginalContent = object.OriginalContent ?? "";
3658
3941
  message.Revisions = object.Revisions?.map((e) => EventRevision.fromPartial(e)) || [];
3659
3942
  message.GenerationalContent = object.GenerationalContent?.map((e) => KeyValuePairInt32String.fromPartial(e)) || [];
3943
+ message.RevisedGeneration = object.RevisedGeneration ?? 0;
3660
3944
  return message;
3661
3945
  },
3662
3946
  };
@@ -6447,6 +6731,365 @@ export const ConstraintViolation_DetailsEntry: MessageFns<ConstraintViolation_De
6447
6731
  },
6448
6732
  };
6449
6733
 
6734
+ function createBaseEffectReceipt(): EffectReceipt {
6735
+ return { OccurrenceId: "", EffectKey: "", Epoch: 0n, Response: "" };
6736
+ }
6737
+
6738
+ export const EffectReceipt: MessageFns<EffectReceipt> = {
6739
+ encode(message: EffectReceipt, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
6740
+ if (message.OccurrenceId !== "") {
6741
+ writer.uint32(10).string(message.OccurrenceId);
6742
+ }
6743
+ if (message.EffectKey !== "") {
6744
+ writer.uint32(18).string(message.EffectKey);
6745
+ }
6746
+ if (message.Epoch !== 0n) {
6747
+ if (BigInt.asIntN(64, message.Epoch) !== message.Epoch) {
6748
+ throw new globalThis.Error("value provided for field message.Epoch of type int64 too large");
6749
+ }
6750
+ writer.uint32(24).int64(message.Epoch);
6751
+ }
6752
+ if (message.Response !== "") {
6753
+ writer.uint32(34).string(message.Response);
6754
+ }
6755
+ return writer;
6756
+ },
6757
+
6758
+ decode(input: BinaryReader | Uint8Array, length?: number): EffectReceipt {
6759
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
6760
+ const previousRecursionDepth = (reader as any).__tsProtoDecodeDepth ?? 0;
6761
+ if (previousRecursionDepth >= 100) {
6762
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
6763
+ }
6764
+ (reader as any).__tsProtoDecodeDepth = previousRecursionDepth + 1;
6765
+ try {
6766
+ const end = length === undefined ? reader.len : reader.pos + length;
6767
+ const message = createBaseEffectReceipt();
6768
+ while (reader.pos < end) {
6769
+ const tag = reader.uint32();
6770
+ switch (tag >>> 3) {
6771
+ case 1: {
6772
+ if (tag !== 10) {
6773
+ break;
6774
+ }
6775
+
6776
+ message.OccurrenceId = reader.string();
6777
+ continue;
6778
+ }
6779
+ case 2: {
6780
+ if (tag !== 18) {
6781
+ break;
6782
+ }
6783
+
6784
+ message.EffectKey = reader.string();
6785
+ continue;
6786
+ }
6787
+ case 3: {
6788
+ if (tag !== 24) {
6789
+ break;
6790
+ }
6791
+
6792
+ message.Epoch = reader.int64() as bigint;
6793
+ continue;
6794
+ }
6795
+ case 4: {
6796
+ if (tag !== 34) {
6797
+ break;
6798
+ }
6799
+
6800
+ message.Response = reader.string();
6801
+ continue;
6802
+ }
6803
+ }
6804
+ if ((tag & 7) === 4 || tag === 0) {
6805
+ break;
6806
+ }
6807
+ reader.skip(tag & 7);
6808
+ }
6809
+ return message;
6810
+ } finally {
6811
+ (reader as any).__tsProtoDecodeDepth = previousRecursionDepth;
6812
+ }
6813
+ },
6814
+
6815
+ fromJSON(object: any): EffectReceipt {
6816
+ return {
6817
+ OccurrenceId: isSet(object.OccurrenceId) ? globalThis.String(object.OccurrenceId) : "",
6818
+ EffectKey: isSet(object.EffectKey) ? globalThis.String(object.EffectKey) : "",
6819
+ Epoch: isSet(object.Epoch) ? BigInt(object.Epoch) : 0n,
6820
+ Response: isSet(object.Response) ? globalThis.String(object.Response) : "",
6821
+ };
6822
+ },
6823
+
6824
+ toJSON(message: EffectReceipt): unknown {
6825
+ const obj: any = {};
6826
+ if (message.OccurrenceId !== "") {
6827
+ obj.OccurrenceId = message.OccurrenceId;
6828
+ }
6829
+ if (message.EffectKey !== "") {
6830
+ obj.EffectKey = message.EffectKey;
6831
+ }
6832
+ if (message.Epoch !== 0n) {
6833
+ obj.Epoch = message.Epoch.toString();
6834
+ }
6835
+ if (message.Response !== "") {
6836
+ obj.Response = message.Response;
6837
+ }
6838
+ return obj;
6839
+ },
6840
+
6841
+ create(base?: DeepPartial<EffectReceipt>): EffectReceipt {
6842
+ return EffectReceipt.fromPartial(base ?? {});
6843
+ },
6844
+ fromPartial(object: DeepPartial<EffectReceipt>): EffectReceipt {
6845
+ const message = createBaseEffectReceipt();
6846
+ message.OccurrenceId = object.OccurrenceId ?? "";
6847
+ message.EffectKey = object.EffectKey ?? "";
6848
+ message.Epoch = (object.Epoch !== undefined && object.Epoch !== null) ? BigInt(object.Epoch) : 0n;
6849
+ message.Response = object.Response ?? "";
6850
+ return message;
6851
+ },
6852
+ };
6853
+
6854
+ function createBaseEffectReceiptDetails(): EffectReceiptDetails {
6855
+ return {
6856
+ Id: "",
6857
+ OccurrenceId: "",
6858
+ Epoch: 0n,
6859
+ Outcome: 0,
6860
+ EventSequenceId: "",
6861
+ FirstSequenceNumber: 0n,
6862
+ LastSequenceNumber: 0n,
6863
+ Reasons: [],
6864
+ Response: "",
6865
+ RecordedAt: undefined,
6866
+ };
6867
+ }
6868
+
6869
+ export const EffectReceiptDetails: MessageFns<EffectReceiptDetails> = {
6870
+ encode(message: EffectReceiptDetails, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
6871
+ if (message.Id !== "") {
6872
+ writer.uint32(10).string(message.Id);
6873
+ }
6874
+ if (message.OccurrenceId !== "") {
6875
+ writer.uint32(18).string(message.OccurrenceId);
6876
+ }
6877
+ if (message.Epoch !== 0n) {
6878
+ if (BigInt.asIntN(64, message.Epoch) !== message.Epoch) {
6879
+ throw new globalThis.Error("value provided for field message.Epoch of type int64 too large");
6880
+ }
6881
+ writer.uint32(24).int64(message.Epoch);
6882
+ }
6883
+ if (message.Outcome !== 0) {
6884
+ writer.uint32(32).int32(message.Outcome);
6885
+ }
6886
+ if (message.EventSequenceId !== "") {
6887
+ writer.uint32(42).string(message.EventSequenceId);
6888
+ }
6889
+ if (message.FirstSequenceNumber !== 0n) {
6890
+ if (BigInt.asUintN(64, message.FirstSequenceNumber) !== message.FirstSequenceNumber) {
6891
+ throw new globalThis.Error("value provided for field message.FirstSequenceNumber of type uint64 too large");
6892
+ }
6893
+ writer.uint32(48).uint64(message.FirstSequenceNumber);
6894
+ }
6895
+ if (message.LastSequenceNumber !== 0n) {
6896
+ if (BigInt.asUintN(64, message.LastSequenceNumber) !== message.LastSequenceNumber) {
6897
+ throw new globalThis.Error("value provided for field message.LastSequenceNumber of type uint64 too large");
6898
+ }
6899
+ writer.uint32(56).uint64(message.LastSequenceNumber);
6900
+ }
6901
+ for (const v of message.Reasons) {
6902
+ writer.uint32(66).string(v!);
6903
+ }
6904
+ if (message.Response !== "") {
6905
+ writer.uint32(74).string(message.Response);
6906
+ }
6907
+ if (message.RecordedAt !== undefined) {
6908
+ SerializableDateTimeOffset.encode(message.RecordedAt, writer.uint32(82).fork()).join();
6909
+ }
6910
+ return writer;
6911
+ },
6912
+
6913
+ decode(input: BinaryReader | Uint8Array, length?: number): EffectReceiptDetails {
6914
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
6915
+ const previousRecursionDepth = (reader as any).__tsProtoDecodeDepth ?? 0;
6916
+ if (previousRecursionDepth >= 100) {
6917
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
6918
+ }
6919
+ (reader as any).__tsProtoDecodeDepth = previousRecursionDepth + 1;
6920
+ try {
6921
+ const end = length === undefined ? reader.len : reader.pos + length;
6922
+ const message = createBaseEffectReceiptDetails();
6923
+ while (reader.pos < end) {
6924
+ const tag = reader.uint32();
6925
+ switch (tag >>> 3) {
6926
+ case 1: {
6927
+ if (tag !== 10) {
6928
+ break;
6929
+ }
6930
+
6931
+ message.Id = reader.string();
6932
+ continue;
6933
+ }
6934
+ case 2: {
6935
+ if (tag !== 18) {
6936
+ break;
6937
+ }
6938
+
6939
+ message.OccurrenceId = reader.string();
6940
+ continue;
6941
+ }
6942
+ case 3: {
6943
+ if (tag !== 24) {
6944
+ break;
6945
+ }
6946
+
6947
+ message.Epoch = reader.int64() as bigint;
6948
+ continue;
6949
+ }
6950
+ case 4: {
6951
+ if (tag !== 32) {
6952
+ break;
6953
+ }
6954
+
6955
+ message.Outcome = reader.int32() as any;
6956
+ continue;
6957
+ }
6958
+ case 5: {
6959
+ if (tag !== 42) {
6960
+ break;
6961
+ }
6962
+
6963
+ message.EventSequenceId = reader.string();
6964
+ continue;
6965
+ }
6966
+ case 6: {
6967
+ if (tag !== 48) {
6968
+ break;
6969
+ }
6970
+
6971
+ message.FirstSequenceNumber = reader.uint64() as bigint;
6972
+ continue;
6973
+ }
6974
+ case 7: {
6975
+ if (tag !== 56) {
6976
+ break;
6977
+ }
6978
+
6979
+ message.LastSequenceNumber = reader.uint64() as bigint;
6980
+ continue;
6981
+ }
6982
+ case 8: {
6983
+ if (tag !== 66) {
6984
+ break;
6985
+ }
6986
+
6987
+ message.Reasons.push(reader.string());
6988
+ continue;
6989
+ }
6990
+ case 9: {
6991
+ if (tag !== 74) {
6992
+ break;
6993
+ }
6994
+
6995
+ message.Response = reader.string();
6996
+ continue;
6997
+ }
6998
+ case 10: {
6999
+ if (tag !== 82) {
7000
+ break;
7001
+ }
7002
+
7003
+ message.RecordedAt = SerializableDateTimeOffset.decode(reader, reader.uint32());
7004
+ continue;
7005
+ }
7006
+ }
7007
+ if ((tag & 7) === 4 || tag === 0) {
7008
+ break;
7009
+ }
7010
+ reader.skip(tag & 7);
7011
+ }
7012
+ return message;
7013
+ } finally {
7014
+ (reader as any).__tsProtoDecodeDepth = previousRecursionDepth;
7015
+ }
7016
+ },
7017
+
7018
+ fromJSON(object: any): EffectReceiptDetails {
7019
+ return {
7020
+ Id: isSet(object.Id) ? globalThis.String(object.Id) : "",
7021
+ OccurrenceId: isSet(object.OccurrenceId) ? globalThis.String(object.OccurrenceId) : "",
7022
+ Epoch: isSet(object.Epoch) ? BigInt(object.Epoch) : 0n,
7023
+ Outcome: isSet(object.Outcome) ? effectOutcomeFromJSON(object.Outcome) : 0,
7024
+ EventSequenceId: isSet(object.EventSequenceId) ? globalThis.String(object.EventSequenceId) : "",
7025
+ FirstSequenceNumber: isSet(object.FirstSequenceNumber) ? BigInt(object.FirstSequenceNumber) : 0n,
7026
+ LastSequenceNumber: isSet(object.LastSequenceNumber) ? BigInt(object.LastSequenceNumber) : 0n,
7027
+ Reasons: globalThis.Array.isArray(object?.Reasons) ? object.Reasons.map((e: any) => globalThis.String(e)) : [],
7028
+ Response: isSet(object.Response) ? globalThis.String(object.Response) : "",
7029
+ RecordedAt: isSet(object.RecordedAt) ? SerializableDateTimeOffset.fromJSON(object.RecordedAt) : undefined,
7030
+ };
7031
+ },
7032
+
7033
+ toJSON(message: EffectReceiptDetails): unknown {
7034
+ const obj: any = {};
7035
+ if (message.Id !== "") {
7036
+ obj.Id = message.Id;
7037
+ }
7038
+ if (message.OccurrenceId !== "") {
7039
+ obj.OccurrenceId = message.OccurrenceId;
7040
+ }
7041
+ if (message.Epoch !== 0n) {
7042
+ obj.Epoch = message.Epoch.toString();
7043
+ }
7044
+ if (message.Outcome !== 0) {
7045
+ obj.Outcome = effectOutcomeToJSON(message.Outcome);
7046
+ }
7047
+ if (message.EventSequenceId !== "") {
7048
+ obj.EventSequenceId = message.EventSequenceId;
7049
+ }
7050
+ if (message.FirstSequenceNumber !== 0n) {
7051
+ obj.FirstSequenceNumber = message.FirstSequenceNumber.toString();
7052
+ }
7053
+ if (message.LastSequenceNumber !== 0n) {
7054
+ obj.LastSequenceNumber = message.LastSequenceNumber.toString();
7055
+ }
7056
+ if (message.Reasons?.length) {
7057
+ obj.Reasons = message.Reasons;
7058
+ }
7059
+ if (message.Response !== "") {
7060
+ obj.Response = message.Response;
7061
+ }
7062
+ if (message.RecordedAt !== undefined) {
7063
+ obj.RecordedAt = SerializableDateTimeOffset.toJSON(message.RecordedAt);
7064
+ }
7065
+ return obj;
7066
+ },
7067
+
7068
+ create(base?: DeepPartial<EffectReceiptDetails>): EffectReceiptDetails {
7069
+ return EffectReceiptDetails.fromPartial(base ?? {});
7070
+ },
7071
+ fromPartial(object: DeepPartial<EffectReceiptDetails>): EffectReceiptDetails {
7072
+ const message = createBaseEffectReceiptDetails();
7073
+ message.Id = object.Id ?? "";
7074
+ message.OccurrenceId = object.OccurrenceId ?? "";
7075
+ message.Epoch = (object.Epoch !== undefined && object.Epoch !== null) ? BigInt(object.Epoch) : 0n;
7076
+ message.Outcome = object.Outcome ?? 0;
7077
+ message.EventSequenceId = object.EventSequenceId ?? "";
7078
+ message.FirstSequenceNumber = (object.FirstSequenceNumber !== undefined && object.FirstSequenceNumber !== null)
7079
+ ? BigInt(object.FirstSequenceNumber)
7080
+ : 0n;
7081
+ message.LastSequenceNumber = (object.LastSequenceNumber !== undefined && object.LastSequenceNumber !== null)
7082
+ ? BigInt(object.LastSequenceNumber)
7083
+ : 0n;
7084
+ message.Reasons = object.Reasons?.map((e) => e) || [];
7085
+ message.Response = object.Response ?? "";
7086
+ message.RecordedAt = (object.RecordedAt !== undefined && object.RecordedAt !== null)
7087
+ ? SerializableDateTimeOffset.fromPartial(object.RecordedAt)
7088
+ : undefined;
7089
+ return message;
7090
+ },
7091
+ };
7092
+
6450
7093
  function createBaseEndOfRequest(): EndOfRequest {
6451
7094
  return { Start: undefined, Resolution: 0 };
6452
7095
  }