@ottochain/sdk 1.5.0 → 1.7.0-beta.1

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 (92) hide show
  1. package/dist/cjs/apps/contracts/index.js +20 -19
  2. package/dist/cjs/apps/contracts/state-machines/index.js +845 -0
  3. package/dist/cjs/apps/corporate/index.js +20 -34
  4. package/dist/cjs/apps/corporate/state-machines/index.js +4445 -0
  5. package/dist/cjs/apps/governance/index.js +34 -44
  6. package/dist/cjs/apps/governance/state-machines/index.js +2938 -0
  7. package/dist/cjs/apps/identity/index.js +16 -11
  8. package/dist/{esm/apps/oracles/state-machines/oracle.json → cjs/apps/identity/state-machines/index.js} +385 -4
  9. package/dist/cjs/apps/index.js +15 -13
  10. package/dist/cjs/apps/markets/index.js +24 -14
  11. package/dist/cjs/apps/markets/state-machines/index.js +2302 -0
  12. package/dist/cjs/ottochain/index.js +4 -1
  13. package/dist/cjs/ottochain/normalize.js +17 -3
  14. package/dist/cjs/ottochain/types.js +12 -0
  15. package/dist/esm/apps/contracts/index.js +17 -15
  16. package/dist/esm/apps/contracts/state-machines/index.js +842 -0
  17. package/dist/esm/apps/corporate/index.js +15 -30
  18. package/dist/esm/apps/corporate/state-machines/index.js +4442 -0
  19. package/dist/esm/apps/governance/index.js +27 -39
  20. package/dist/esm/apps/governance/state-machines/index.js +2935 -0
  21. package/dist/esm/apps/identity/index.js +13 -7
  22. package/dist/{cjs/apps/oracles/state-machines/oracle.json → esm/apps/identity/state-machines/index.js} +382 -4
  23. package/dist/esm/apps/index.js +14 -12
  24. package/dist/esm/apps/markets/index.js +19 -10
  25. package/dist/esm/apps/markets/state-machines/index.js +2299 -0
  26. package/dist/esm/ottochain/index.js +2 -0
  27. package/dist/esm/ottochain/normalize.js +17 -3
  28. package/dist/esm/ottochain/types.js +11 -1
  29. package/dist/types/apps/contracts/index.d.ts +661 -9
  30. package/dist/types/apps/contracts/state-machines/index.d.ts +652 -0
  31. package/dist/types/apps/corporate/index.d.ts +4015 -7
  32. package/dist/types/apps/corporate/state-machines/index.d.ts +4006 -0
  33. package/dist/types/apps/governance/index.d.ts +2151 -12
  34. package/dist/types/apps/governance/state-machines/index.d.ts +2138 -0
  35. package/dist/types/apps/identity/index.d.ts +601 -4
  36. package/dist/types/apps/identity/state-machines/index.d.ts +596 -0
  37. package/dist/types/apps/index.d.ts +14 -12
  38. package/dist/types/apps/markets/index.d.ts +1690 -7
  39. package/dist/types/apps/markets/state-machines/index.d.ts +1680 -0
  40. package/dist/types/ottochain/index.d.ts +2 -1
  41. package/dist/types/ottochain/normalize.d.ts +14 -0
  42. package/dist/types/ottochain/types.d.ts +9 -0
  43. package/package.json +4 -3
  44. package/dist/cjs/apps/contracts/state-machines/contract.json +0 -352
  45. package/dist/cjs/apps/contracts/state-machines/escrow.json +0 -354
  46. package/dist/cjs/apps/corporate/state-machines/corporate-board.json +0 -1064
  47. package/dist/cjs/apps/corporate/state-machines/corporate-bylaws.json +0 -751
  48. package/dist/cjs/apps/corporate/state-machines/corporate-committee.json +0 -957
  49. package/dist/cjs/apps/corporate/state-machines/corporate-compliance.json +0 -1293
  50. package/dist/cjs/apps/corporate/state-machines/corporate-entity.json +0 -861
  51. package/dist/cjs/apps/corporate/state-machines/corporate-officers.json +0 -843
  52. package/dist/cjs/apps/corporate/state-machines/corporate-proxy.json +0 -783
  53. package/dist/cjs/apps/corporate/state-machines/corporate-resolution.json +0 -1174
  54. package/dist/cjs/apps/corporate/state-machines/corporate-securities.json +0 -1215
  55. package/dist/cjs/apps/corporate/state-machines/corporate-shareholders.json +0 -1298
  56. package/dist/cjs/apps/governance/state-machines/dao-multisig.json +0 -667
  57. package/dist/cjs/apps/governance/state-machines/dao-single.json +0 -230
  58. package/dist/cjs/apps/governance/state-machines/dao-threshold.json +0 -624
  59. package/dist/cjs/apps/governance/state-machines/dao-token.json +0 -638
  60. package/dist/cjs/apps/governance/state-machines/governance-constitution.json +0 -357
  61. package/dist/cjs/apps/governance/state-machines/governance-executive.json +0 -387
  62. package/dist/cjs/apps/governance/state-machines/governance-judiciary.json +0 -558
  63. package/dist/cjs/apps/governance/state-machines/governance-legislature.json +0 -662
  64. package/dist/cjs/apps/governance/state-machines/governance-simple.json +0 -625
  65. package/dist/cjs/apps/identity/state-machines/agent-identity.json +0 -270
  66. package/dist/cjs/apps/markets/state-machines/market-universal.json +0 -621
  67. package/dist/cjs/apps/oracles/index.js +0 -62
  68. package/dist/esm/apps/contracts/state-machines/contract.json +0 -352
  69. package/dist/esm/apps/contracts/state-machines/escrow.json +0 -354
  70. package/dist/esm/apps/corporate/state-machines/corporate-board.json +0 -1064
  71. package/dist/esm/apps/corporate/state-machines/corporate-bylaws.json +0 -751
  72. package/dist/esm/apps/corporate/state-machines/corporate-committee.json +0 -957
  73. package/dist/esm/apps/corporate/state-machines/corporate-compliance.json +0 -1293
  74. package/dist/esm/apps/corporate/state-machines/corporate-entity.json +0 -861
  75. package/dist/esm/apps/corporate/state-machines/corporate-officers.json +0 -843
  76. package/dist/esm/apps/corporate/state-machines/corporate-proxy.json +0 -783
  77. package/dist/esm/apps/corporate/state-machines/corporate-resolution.json +0 -1174
  78. package/dist/esm/apps/corporate/state-machines/corporate-securities.json +0 -1215
  79. package/dist/esm/apps/corporate/state-machines/corporate-shareholders.json +0 -1298
  80. package/dist/esm/apps/governance/state-machines/dao-multisig.json +0 -667
  81. package/dist/esm/apps/governance/state-machines/dao-single.json +0 -230
  82. package/dist/esm/apps/governance/state-machines/dao-threshold.json +0 -624
  83. package/dist/esm/apps/governance/state-machines/dao-token.json +0 -638
  84. package/dist/esm/apps/governance/state-machines/governance-constitution.json +0 -357
  85. package/dist/esm/apps/governance/state-machines/governance-executive.json +0 -387
  86. package/dist/esm/apps/governance/state-machines/governance-judiciary.json +0 -558
  87. package/dist/esm/apps/governance/state-machines/governance-legislature.json +0 -662
  88. package/dist/esm/apps/governance/state-machines/governance-simple.json +0 -625
  89. package/dist/esm/apps/identity/state-machines/agent-identity.json +0 -270
  90. package/dist/esm/apps/markets/state-machines/market-universal.json +0 -621
  91. package/dist/esm/apps/oracles/index.js +0 -42
  92. package/dist/types/apps/oracles/index.d.ts +0 -34
@@ -31,9 +31,606 @@ export declare const DEFAULT_REPUTATION_CONFIG: {
31
31
  readonly minReputation: 0;
32
32
  readonly challengeThreshold: 5;
33
33
  };
34
+ import { identityUniversalDef, identityAgentDef, identityOracleDef } from './state-machines/index.js';
35
+ export { identityUniversalDef, identityAgentDef, identityOracleDef };
36
+ /** All identity state machine definitions */
37
+ export declare const IDENTITY_DEFINITIONS: {
38
+ readonly universal: {
39
+ readonly metadata: {
40
+ readonly name: "IdentityUniversal";
41
+ readonly description: "Minimal identity state machine - extend for custom use cases";
42
+ readonly version: "1.0.0";
43
+ };
44
+ readonly states: {
45
+ readonly CREATED: {
46
+ readonly id: "CREATED";
47
+ readonly isFinal: false;
48
+ readonly metadata: null;
49
+ };
50
+ readonly ACTIVE: {
51
+ readonly id: "ACTIVE";
52
+ readonly isFinal: false;
53
+ readonly metadata: null;
54
+ };
55
+ readonly INACTIVE: {
56
+ readonly id: "INACTIVE";
57
+ readonly isFinal: true;
58
+ readonly metadata: null;
59
+ };
60
+ };
61
+ readonly initialState: "CREATED";
62
+ readonly transitions: readonly [{
63
+ readonly from: "CREATED";
64
+ readonly to: "ACTIVE";
65
+ readonly eventName: "activate";
66
+ readonly guard: {
67
+ readonly "==": readonly [1, 1];
68
+ };
69
+ readonly effect: {
70
+ readonly merge: readonly [{
71
+ readonly var: "state";
72
+ }, {
73
+ readonly status: "ACTIVE";
74
+ readonly activatedAt: {
75
+ readonly var: "$timestamp";
76
+ };
77
+ }];
78
+ };
79
+ readonly dependencies: readonly [];
80
+ }, {
81
+ readonly from: "ACTIVE";
82
+ readonly to: "ACTIVE";
83
+ readonly eventName: "update";
84
+ readonly guard: {
85
+ readonly "==": readonly [1, 1];
86
+ };
87
+ readonly effect: {
88
+ readonly merge: readonly [{
89
+ readonly var: "state";
90
+ }, {
91
+ readonly updatedAt: {
92
+ readonly var: "$timestamp";
93
+ };
94
+ readonly metadata: {
95
+ readonly var: "event.metadata";
96
+ };
97
+ }];
98
+ };
99
+ readonly dependencies: readonly [];
100
+ }, {
101
+ readonly from: "ACTIVE";
102
+ readonly to: "INACTIVE";
103
+ readonly eventName: "deactivate";
104
+ readonly guard: {
105
+ readonly "==": readonly [1, 1];
106
+ };
107
+ readonly effect: {
108
+ readonly merge: readonly [{
109
+ readonly var: "state";
110
+ }, {
111
+ readonly status: "INACTIVE";
112
+ readonly deactivatedAt: {
113
+ readonly var: "$timestamp";
114
+ };
115
+ }];
116
+ };
117
+ readonly dependencies: readonly [];
118
+ }];
119
+ };
120
+ readonly agent: {
121
+ readonly metadata: {
122
+ readonly name: "IdentityAgent";
123
+ readonly description: "Standard agent identity with reputation tracking, vouching, and lifecycle management";
124
+ readonly version: "1.0.0";
125
+ };
126
+ readonly states: {
127
+ readonly REGISTERED: {
128
+ readonly id: "REGISTERED";
129
+ readonly isFinal: false;
130
+ readonly metadata: null;
131
+ };
132
+ readonly ACTIVE: {
133
+ readonly id: "ACTIVE";
134
+ readonly isFinal: false;
135
+ readonly metadata: null;
136
+ };
137
+ readonly CHALLENGED: {
138
+ readonly id: "CHALLENGED";
139
+ readonly isFinal: false;
140
+ readonly metadata: null;
141
+ };
142
+ readonly SUSPENDED: {
143
+ readonly id: "SUSPENDED";
144
+ readonly isFinal: false;
145
+ readonly metadata: null;
146
+ };
147
+ readonly PROBATION: {
148
+ readonly id: "PROBATION";
149
+ readonly isFinal: false;
150
+ readonly metadata: null;
151
+ };
152
+ readonly WITHDRAWN: {
153
+ readonly id: "WITHDRAWN";
154
+ readonly isFinal: true;
155
+ readonly metadata: null;
156
+ };
157
+ };
158
+ readonly initialState: "REGISTERED";
159
+ readonly transitions: readonly [{
160
+ readonly from: "REGISTERED";
161
+ readonly to: "ACTIVE";
162
+ readonly eventName: "activate";
163
+ readonly guard: {
164
+ readonly "==": readonly [1, 1];
165
+ };
166
+ readonly effect: {
167
+ readonly merge: readonly [{
168
+ readonly var: "state";
169
+ }, {
170
+ readonly status: "ACTIVE";
171
+ readonly activatedAt: {
172
+ readonly var: "$timestamp";
173
+ };
174
+ }];
175
+ };
176
+ readonly dependencies: readonly [];
177
+ }, {
178
+ readonly from: "ACTIVE";
179
+ readonly to: "ACTIVE";
180
+ readonly eventName: "receive_vouch";
181
+ readonly guard: {
182
+ readonly "!!": readonly [{
183
+ readonly var: "event.from";
184
+ }];
185
+ };
186
+ readonly effect: {
187
+ readonly merge: readonly [{
188
+ readonly var: "state";
189
+ }, {
190
+ readonly reputation: {
191
+ readonly "+": readonly [{
192
+ readonly var: "state.reputation";
193
+ }, 2];
194
+ };
195
+ }];
196
+ };
197
+ readonly dependencies: readonly [];
198
+ }, {
199
+ readonly from: "ACTIVE";
200
+ readonly to: "ACTIVE";
201
+ readonly eventName: "receive_completion";
202
+ readonly guard: {
203
+ readonly "==": readonly [1, 1];
204
+ };
205
+ readonly effect: {
206
+ readonly merge: readonly [{
207
+ readonly var: "state";
208
+ }, {
209
+ readonly reputation: {
210
+ readonly "+": readonly [{
211
+ readonly var: "state.reputation";
212
+ }, 5];
213
+ };
214
+ }];
215
+ };
216
+ readonly dependencies: readonly [];
217
+ }, {
218
+ readonly from: "ACTIVE";
219
+ readonly to: "CHALLENGED";
220
+ readonly eventName: "challenge";
221
+ readonly guard: {
222
+ readonly "!!": readonly [{
223
+ readonly var: "event.challenger";
224
+ }];
225
+ };
226
+ readonly effect: {
227
+ readonly merge: readonly [{
228
+ readonly var: "state";
229
+ }, {
230
+ readonly status: "CHALLENGED";
231
+ readonly challengedBy: {
232
+ readonly var: "event.challenger";
233
+ };
234
+ }];
235
+ };
236
+ readonly dependencies: readonly [];
237
+ }, {
238
+ readonly from: "CHALLENGED";
239
+ readonly to: "ACTIVE";
240
+ readonly eventName: "dismiss_challenge";
241
+ readonly guard: {
242
+ readonly "==": readonly [1, 1];
243
+ };
244
+ readonly effect: {
245
+ readonly merge: readonly [{
246
+ readonly var: "state";
247
+ }, {
248
+ readonly status: "ACTIVE";
249
+ readonly challengedBy: null;
250
+ }];
251
+ };
252
+ readonly dependencies: readonly [];
253
+ }, {
254
+ readonly from: "CHALLENGED";
255
+ readonly to: "SUSPENDED";
256
+ readonly eventName: "uphold_challenge";
257
+ readonly guard: {
258
+ readonly "==": readonly [1, 1];
259
+ };
260
+ readonly effect: {
261
+ readonly merge: readonly [{
262
+ readonly var: "state";
263
+ }, {
264
+ readonly status: "SUSPENDED";
265
+ readonly suspendedAt: {
266
+ readonly var: "$timestamp";
267
+ };
268
+ }];
269
+ };
270
+ readonly dependencies: readonly [];
271
+ }, {
272
+ readonly from: "SUSPENDED";
273
+ readonly to: "PROBATION";
274
+ readonly eventName: "begin_probation";
275
+ readonly guard: {
276
+ readonly "==": readonly [1, 1];
277
+ };
278
+ readonly effect: {
279
+ readonly merge: readonly [{
280
+ readonly var: "state";
281
+ }, {
282
+ readonly status: "PROBATION";
283
+ readonly probationStartedAt: {
284
+ readonly var: "$timestamp";
285
+ };
286
+ }];
287
+ };
288
+ readonly dependencies: readonly [];
289
+ }, {
290
+ readonly from: "PROBATION";
291
+ readonly to: "ACTIVE";
292
+ readonly eventName: "complete_probation";
293
+ readonly guard: {
294
+ readonly "==": readonly [1, 1];
295
+ };
296
+ readonly effect: {
297
+ readonly merge: readonly [{
298
+ readonly var: "state";
299
+ }, {
300
+ readonly status: "ACTIVE";
301
+ readonly probationStartedAt: null;
302
+ }];
303
+ };
304
+ readonly dependencies: readonly [];
305
+ }, {
306
+ readonly from: "ACTIVE";
307
+ readonly to: "WITHDRAWN";
308
+ readonly eventName: "withdraw";
309
+ readonly guard: {
310
+ readonly "==": readonly [1, 1];
311
+ };
312
+ readonly effect: {
313
+ readonly merge: readonly [{
314
+ readonly var: "state";
315
+ }, {
316
+ readonly status: "WITHDRAWN";
317
+ }];
318
+ };
319
+ readonly dependencies: readonly [];
320
+ }];
321
+ };
322
+ readonly oracle: {
323
+ readonly metadata: {
324
+ readonly name: "IdentityOracle";
325
+ readonly description: "Oracle identity with staking, attestations, reputation, and slashing mechanics";
326
+ readonly version: "1.0.0";
327
+ };
328
+ readonly states: {
329
+ readonly UNREGISTERED: {
330
+ readonly id: "UNREGISTERED";
331
+ readonly isFinal: false;
332
+ readonly metadata: null;
333
+ };
334
+ readonly REGISTERED: {
335
+ readonly id: "REGISTERED";
336
+ readonly isFinal: false;
337
+ readonly metadata: null;
338
+ };
339
+ readonly ACTIVE: {
340
+ readonly id: "ACTIVE";
341
+ readonly isFinal: false;
342
+ readonly metadata: null;
343
+ };
344
+ readonly SLASHED: {
345
+ readonly id: "SLASHED";
346
+ readonly isFinal: false;
347
+ readonly metadata: null;
348
+ };
349
+ readonly WITHDRAWN: {
350
+ readonly id: "WITHDRAWN";
351
+ readonly isFinal: true;
352
+ readonly metadata: null;
353
+ };
354
+ };
355
+ readonly initialState: "UNREGISTERED";
356
+ readonly transitions: readonly [{
357
+ readonly from: "UNREGISTERED";
358
+ readonly to: "REGISTERED";
359
+ readonly eventName: "register";
360
+ readonly guard: {
361
+ readonly ">=": readonly [{
362
+ readonly var: "event.stake";
363
+ }, {
364
+ readonly var: "state.minStake";
365
+ }];
366
+ };
367
+ readonly effect: {
368
+ readonly merge: readonly [{
369
+ readonly var: "state";
370
+ }, {
371
+ readonly status: "REGISTERED";
372
+ readonly address: {
373
+ readonly var: "event.agent";
374
+ };
375
+ readonly stake: {
376
+ readonly var: "event.stake";
377
+ };
378
+ readonly registeredAt: {
379
+ readonly var: "$timestamp";
380
+ };
381
+ readonly reputation: {
382
+ readonly accuracy: 100;
383
+ readonly totalResolutions: 0;
384
+ readonly disputesWon: 0;
385
+ readonly disputesLost: 0;
386
+ };
387
+ readonly domains: {
388
+ readonly var: "event.domains";
389
+ };
390
+ readonly slashingHistory: readonly [];
391
+ }];
392
+ };
393
+ readonly dependencies: readonly [];
394
+ }, {
395
+ readonly from: "REGISTERED";
396
+ readonly to: "ACTIVE";
397
+ readonly eventName: "activate";
398
+ readonly guard: {
399
+ readonly or: readonly [{
400
+ readonly "===": readonly [{
401
+ readonly var: "event.agent";
402
+ }, {
403
+ readonly var: "state.address";
404
+ }];
405
+ }, {
406
+ readonly var: "event.adminOverride";
407
+ }];
408
+ };
409
+ readonly effect: {
410
+ readonly merge: readonly [{
411
+ readonly var: "state";
412
+ }, {
413
+ readonly status: "ACTIVE";
414
+ readonly activatedAt: {
415
+ readonly var: "$timestamp";
416
+ };
417
+ }];
418
+ };
419
+ readonly dependencies: readonly [];
420
+ }, {
421
+ readonly from: "ACTIVE";
422
+ readonly to: "ACTIVE";
423
+ readonly eventName: "add_stake";
424
+ readonly guard: {
425
+ readonly and: readonly [{
426
+ readonly "===": readonly [{
427
+ readonly var: "event.agent";
428
+ }, {
429
+ readonly var: "state.address";
430
+ }];
431
+ }, {
432
+ readonly ">": readonly [{
433
+ readonly var: "event.amount";
434
+ }, 0];
435
+ }];
436
+ };
437
+ readonly effect: {
438
+ readonly merge: readonly [{
439
+ readonly var: "state";
440
+ }, {
441
+ readonly stake: {
442
+ readonly "+": readonly [{
443
+ readonly var: "state.stake";
444
+ }, {
445
+ readonly var: "event.amount";
446
+ }];
447
+ };
448
+ readonly lastStakeAt: {
449
+ readonly var: "$timestamp";
450
+ };
451
+ }];
452
+ };
453
+ readonly dependencies: readonly [];
454
+ }, {
455
+ readonly from: "ACTIVE";
456
+ readonly to: "ACTIVE";
457
+ readonly eventName: "record_resolution";
458
+ readonly guard: {
459
+ readonly var: "event.marketId";
460
+ };
461
+ readonly effect: {
462
+ readonly merge: readonly [{
463
+ readonly var: "state";
464
+ }, {
465
+ readonly reputation: {
466
+ readonly merge: readonly [{
467
+ readonly var: "state.reputation";
468
+ }, {
469
+ readonly totalResolutions: {
470
+ readonly "+": readonly [{
471
+ readonly var: "state.reputation.totalResolutions";
472
+ }, 1];
473
+ };
474
+ readonly accuracy: {
475
+ readonly if: readonly [{
476
+ readonly var: "event.correct";
477
+ }, {
478
+ readonly var: "state.reputation.accuracy";
479
+ }, {
480
+ readonly "-": readonly [{
481
+ readonly var: "state.reputation.accuracy";
482
+ }, 5];
483
+ }];
484
+ };
485
+ }];
486
+ };
487
+ readonly lastResolutionAt: {
488
+ readonly var: "$timestamp";
489
+ };
490
+ }];
491
+ };
492
+ readonly dependencies: readonly [];
493
+ }, {
494
+ readonly from: "ACTIVE";
495
+ readonly to: "SLASHED";
496
+ readonly eventName: "slash";
497
+ readonly guard: {
498
+ readonly and: readonly [{
499
+ readonly var: "event.reason";
500
+ }, {
501
+ readonly ">": readonly [{
502
+ readonly var: "event.amount";
503
+ }, 0];
504
+ }, {
505
+ readonly "<=": readonly [{
506
+ readonly var: "event.amount";
507
+ }, {
508
+ readonly var: "state.stake";
509
+ }];
510
+ }];
511
+ };
512
+ readonly effect: {
513
+ readonly merge: readonly [{
514
+ readonly var: "state";
515
+ }, {
516
+ readonly status: "SLASHED";
517
+ readonly stake: {
518
+ readonly "-": readonly [{
519
+ readonly var: "state.stake";
520
+ }, {
521
+ readonly var: "event.amount";
522
+ }];
523
+ };
524
+ readonly slashingHistory: {
525
+ readonly cat: readonly [{
526
+ readonly var: "state.slashingHistory";
527
+ }, readonly [{
528
+ readonly reason: {
529
+ readonly var: "event.reason";
530
+ };
531
+ readonly amount: {
532
+ readonly var: "event.amount";
533
+ };
534
+ readonly marketId: {
535
+ readonly var: "event.marketId";
536
+ };
537
+ readonly slashedAt: {
538
+ readonly var: "$timestamp";
539
+ };
540
+ }]];
541
+ };
542
+ readonly slashedAt: {
543
+ readonly var: "$timestamp";
544
+ };
545
+ }];
546
+ };
547
+ readonly dependencies: readonly [];
548
+ }, {
549
+ readonly from: "SLASHED";
550
+ readonly to: "ACTIVE";
551
+ readonly eventName: "reactivate";
552
+ readonly guard: {
553
+ readonly and: readonly [{
554
+ readonly "===": readonly [{
555
+ readonly var: "event.agent";
556
+ }, {
557
+ readonly var: "state.address";
558
+ }];
559
+ }, {
560
+ readonly ">=": readonly [{
561
+ readonly var: "state.stake";
562
+ }, {
563
+ readonly var: "state.minStake";
564
+ }];
565
+ }];
566
+ };
567
+ readonly effect: {
568
+ readonly merge: readonly [{
569
+ readonly var: "state";
570
+ }, {
571
+ readonly status: "ACTIVE";
572
+ readonly reactivatedAt: {
573
+ readonly var: "$timestamp";
574
+ };
575
+ }];
576
+ };
577
+ readonly dependencies: readonly [];
578
+ }, {
579
+ readonly from: "ACTIVE";
580
+ readonly to: "WITHDRAWN";
581
+ readonly eventName: "withdraw";
582
+ readonly guard: {
583
+ readonly "===": readonly [{
584
+ readonly var: "event.agent";
585
+ }, {
586
+ readonly var: "state.address";
587
+ }];
588
+ };
589
+ readonly effect: {
590
+ readonly merge: readonly [{
591
+ readonly var: "state";
592
+ }, {
593
+ readonly status: "WITHDRAWN";
594
+ readonly withdrawnAt: {
595
+ readonly var: "$timestamp";
596
+ };
597
+ readonly finalStake: {
598
+ readonly var: "state.stake";
599
+ };
600
+ }];
601
+ };
602
+ readonly dependencies: readonly [];
603
+ }, {
604
+ readonly from: "SLASHED";
605
+ readonly to: "WITHDRAWN";
606
+ readonly eventName: "withdraw";
607
+ readonly guard: {
608
+ readonly "===": readonly [{
609
+ readonly var: "event.agent";
610
+ }, {
611
+ readonly var: "state.address";
612
+ }];
613
+ };
614
+ readonly effect: {
615
+ readonly merge: readonly [{
616
+ readonly var: "state";
617
+ }, {
618
+ readonly status: "WITHDRAWN";
619
+ readonly withdrawnAt: {
620
+ readonly var: "$timestamp";
621
+ };
622
+ readonly finalStake: {
623
+ readonly var: "state.stake";
624
+ };
625
+ }];
626
+ };
627
+ readonly dependencies: readonly [];
628
+ }];
629
+ };
630
+ };
631
+ export type IdentityType = keyof typeof IDENTITY_DEFINITIONS;
34
632
  /**
35
- * Get the agent identity state machine definition.
36
- *
37
- * @returns The state machine definition JSON for AgentIdentity
633
+ * Get an identity state machine definition by type.
634
+ * @param type - 'universal' | 'agent' | 'oracle' (default: 'agent')
38
635
  */
39
- export declare function getIdentityDefinition(): unknown;
636
+ export declare function getIdentityDefinition(type?: IdentityType): unknown;