@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
@@ -0,0 +1,4445 @@
1
+ "use strict";
2
+ /**
3
+ * Auto-generated from JSON state machine definitions.
4
+ * DO NOT EDIT - regenerate with: npm run prebuild
5
+ */
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.corpShareholdersDef = exports.corpSecuritiesDef = exports.corpEntityDef = exports.corpBoardDef = void 0;
8
+ exports.corpBoardDef = {
9
+ "$schema": "https://ottochain.dev/schemas/state-machine-v1.json",
10
+ "name": "CorpBoard",
11
+ "version": "1.0.0",
12
+ "category": "corporate-governance",
13
+ "description": "Board of directors state machine managing director seats, meetings, quorum, and formal board actions. Supports staggered boards with classified directors.",
14
+ "context": {
15
+ "boardId": {
16
+ "type": "string",
17
+ "description": "Unique identifier for this board instance"
18
+ },
19
+ "entityId": {
20
+ "type": "string",
21
+ "description": "Reference to parent corporate-entity"
22
+ },
23
+ "directors": {
24
+ "type": "array",
25
+ "items": {
26
+ "type": "object",
27
+ "properties": {
28
+ "directorId": {
29
+ "type": "string"
30
+ },
31
+ "name": {
32
+ "type": "string"
33
+ },
34
+ "email": {
35
+ "type": "string"
36
+ },
37
+ "termStart": {
38
+ "type": "string",
39
+ "format": "date"
40
+ },
41
+ "termEnd": {
42
+ "type": "string",
43
+ "format": "date"
44
+ },
45
+ "class": {
46
+ "type": "string",
47
+ "enum": [
48
+ "CLASS_I",
49
+ "CLASS_II",
50
+ "CLASS_III",
51
+ "UNCLASSIFIED"
52
+ ],
53
+ "description": "For staggered boards"
54
+ },
55
+ "status": {
56
+ "type": "string",
57
+ "enum": [
58
+ "ACTIVE",
59
+ "RESIGNED",
60
+ "REMOVED",
61
+ "TERM_EXPIRED"
62
+ ]
63
+ },
64
+ "isIndependent": {
65
+ "type": "boolean",
66
+ "description": "Independence under applicable rules"
67
+ },
68
+ "isChair": {
69
+ "type": "boolean",
70
+ "default": false
71
+ },
72
+ "isLeadIndependent": {
73
+ "type": "boolean",
74
+ "default": false
75
+ },
76
+ "committees": {
77
+ "type": "array",
78
+ "items": {
79
+ "type": "string"
80
+ },
81
+ "description": "Committee memberships by committee ID"
82
+ },
83
+ "electedBy": {
84
+ "type": "string",
85
+ "description": "Resolution reference for election"
86
+ },
87
+ "compensationAgreementRef": {
88
+ "type": "string",
89
+ "nullable": true
90
+ }
91
+ }
92
+ }
93
+ },
94
+ "seats": {
95
+ "type": "object",
96
+ "properties": {
97
+ "authorized": {
98
+ "type": "integer",
99
+ "description": "Number of board seats authorized by bylaws"
100
+ },
101
+ "filled": {
102
+ "type": "integer"
103
+ },
104
+ "vacant": {
105
+ "type": "integer"
106
+ }
107
+ }
108
+ },
109
+ "boardStructure": {
110
+ "type": "object",
111
+ "properties": {
112
+ "isClassified": {
113
+ "type": "boolean",
114
+ "description": "Whether board has staggered terms"
115
+ },
116
+ "termYears": {
117
+ "type": "integer",
118
+ "default": 1,
119
+ "description": "Director term length"
120
+ },
121
+ "classTerms": {
122
+ "type": "object",
123
+ "properties": {
124
+ "CLASS_I": {
125
+ "type": "integer"
126
+ },
127
+ "CLASS_II": {
128
+ "type": "integer"
129
+ },
130
+ "CLASS_III": {
131
+ "type": "integer"
132
+ }
133
+ }
134
+ }
135
+ }
136
+ },
137
+ "quorumRules": {
138
+ "type": "object",
139
+ "properties": {
140
+ "type": {
141
+ "type": "string",
142
+ "enum": [
143
+ "MAJORITY",
144
+ "SUPERMAJORITY",
145
+ "FIXED_NUMBER"
146
+ ],
147
+ "default": "MAJORITY"
148
+ },
149
+ "threshold": {
150
+ "type": "number",
151
+ "description": "Fraction for majority/super, or count for fixed"
152
+ },
153
+ "minimumRequired": {
154
+ "type": "integer",
155
+ "description": "Absolute minimum regardless of formula"
156
+ }
157
+ }
158
+ },
159
+ "votingRules": {
160
+ "type": "object",
161
+ "properties": {
162
+ "standardApproval": {
163
+ "type": "string",
164
+ "enum": [
165
+ "MAJORITY_PRESENT",
166
+ "MAJORITY_FULL_BOARD"
167
+ ],
168
+ "default": "MAJORITY_PRESENT"
169
+ },
170
+ "supermajorityMatters": {
171
+ "type": "array",
172
+ "items": {
173
+ "type": "string"
174
+ },
175
+ "description": "Action types requiring supermajority"
176
+ },
177
+ "supermajorityThreshold": {
178
+ "type": "number",
179
+ "default": 0.6667
180
+ }
181
+ }
182
+ },
183
+ "currentMeeting": {
184
+ "type": "object",
185
+ "nullable": true,
186
+ "properties": {
187
+ "meetingId": {
188
+ "type": "string"
189
+ },
190
+ "type": {
191
+ "type": "string",
192
+ "enum": [
193
+ "REGULAR",
194
+ "SPECIAL",
195
+ "ANNUAL",
196
+ "ORGANIZATIONAL"
197
+ ]
198
+ },
199
+ "scheduledDate": {
200
+ "type": "string",
201
+ "format": "date-time"
202
+ },
203
+ "location": {
204
+ "type": "string"
205
+ },
206
+ "isVirtual": {
207
+ "type": "boolean"
208
+ },
209
+ "calledBy": {
210
+ "type": "string"
211
+ },
212
+ "noticeDate": {
213
+ "type": "string",
214
+ "format": "date"
215
+ },
216
+ "agenda": {
217
+ "type": "array",
218
+ "items": {
219
+ "type": "string"
220
+ }
221
+ },
222
+ "attendees": {
223
+ "type": "array",
224
+ "items": {
225
+ "type": "object",
226
+ "properties": {
227
+ "directorId": {
228
+ "type": "string"
229
+ },
230
+ "present": {
231
+ "type": "boolean"
232
+ },
233
+ "arrivedAt": {
234
+ "type": "string",
235
+ "format": "date-time",
236
+ "nullable": true
237
+ },
238
+ "departedAt": {
239
+ "type": "string",
240
+ "format": "date-time",
241
+ "nullable": true
242
+ },
243
+ "viaProxy": {
244
+ "type": "boolean",
245
+ "default": false
246
+ }
247
+ }
248
+ }
249
+ },
250
+ "quorumPresent": {
251
+ "type": "boolean"
252
+ },
253
+ "quorumCount": {
254
+ "type": "integer"
255
+ },
256
+ "openedAt": {
257
+ "type": "string",
258
+ "format": "date-time",
259
+ "nullable": true
260
+ },
261
+ "closedAt": {
262
+ "type": "string",
263
+ "format": "date-time",
264
+ "nullable": true
265
+ },
266
+ "minutesRef": {
267
+ "type": "string",
268
+ "nullable": true
269
+ }
270
+ }
271
+ },
272
+ "meetingHistory": {
273
+ "type": "array",
274
+ "items": {
275
+ "type": "object",
276
+ "properties": {
277
+ "meetingId": {
278
+ "type": "string"
279
+ },
280
+ "type": {
281
+ "type": "string"
282
+ },
283
+ "date": {
284
+ "type": "string",
285
+ "format": "date"
286
+ },
287
+ "quorumAchieved": {
288
+ "type": "boolean"
289
+ },
290
+ "attendeeCount": {
291
+ "type": "integer"
292
+ },
293
+ "resolutionsPassed": {
294
+ "type": "array",
295
+ "items": {
296
+ "type": "string"
297
+ }
298
+ },
299
+ "minutesRef": {
300
+ "type": "string"
301
+ }
302
+ }
303
+ }
304
+ },
305
+ "createdAt": {
306
+ "type": "string",
307
+ "format": "date-time"
308
+ },
309
+ "updatedAt": {
310
+ "type": "string",
311
+ "format": "date-time"
312
+ }
313
+ },
314
+ "states": {
315
+ "ACTIVE": {
316
+ "description": "Board is constituted and able to conduct business. Default state between meetings.",
317
+ "metadata": null
318
+ },
319
+ "IN_MEETING": {
320
+ "description": "Board meeting is in session with quorum present. Can take formal actions.",
321
+ "metadata": null
322
+ },
323
+ "QUORUM_LOST": {
324
+ "description": "Meeting in progress but quorum lost due to departures. No further action until quorum restored or adjourned.",
325
+ "metadata": null
326
+ }
327
+ },
328
+ "initialState": "ACTIVE",
329
+ "transitions": {
330
+ "elect_director": {
331
+ "from": "ACTIVE",
332
+ "to": "ACTIVE",
333
+ "description": "Add a new director to the board (election typically done at shareholder meeting or by board to fill vacancy)",
334
+ "event": {
335
+ "name": "elect_director",
336
+ "payload": {
337
+ "directorId": {
338
+ "type": "string",
339
+ "required": true
340
+ },
341
+ "name": {
342
+ "type": "string",
343
+ "required": true
344
+ },
345
+ "email": {
346
+ "type": "string"
347
+ },
348
+ "termStart": {
349
+ "type": "string",
350
+ "format": "date",
351
+ "required": true
352
+ },
353
+ "termEnd": {
354
+ "type": "string",
355
+ "format": "date",
356
+ "required": true
357
+ },
358
+ "class": {
359
+ "type": "string",
360
+ "enum": [
361
+ "CLASS_I",
362
+ "CLASS_II",
363
+ "CLASS_III",
364
+ "UNCLASSIFIED"
365
+ ]
366
+ },
367
+ "isIndependent": {
368
+ "type": "boolean",
369
+ "required": true
370
+ },
371
+ "electionResolutionRef": {
372
+ "type": "string",
373
+ "required": true,
374
+ "description": "Shareholder or board resolution"
375
+ },
376
+ "isFillingVacancy": {
377
+ "type": "boolean",
378
+ "default": false
379
+ }
380
+ }
381
+ },
382
+ "guards": [
383
+ {
384
+ "name": "hasAvailableSeat",
385
+ "description": "Must have vacant seat or be filling expired term",
386
+ "expression": "context.seats.vacant > 0 || event.isFillingVacancy"
387
+ },
388
+ {
389
+ "name": "hasElectionResolution",
390
+ "description": "Must have valid election resolution (shareholder for annual, board for vacancy fill)",
391
+ "expression": "event.electionResolutionRef != null"
392
+ },
393
+ {
394
+ "name": "notAlreadyDirector",
395
+ "description": "Person not already serving on board",
396
+ "expression": "!context.directors.some(d => d.directorId === event.directorId && d.status === 'ACTIVE')"
397
+ }
398
+ ],
399
+ "effects": [
400
+ {
401
+ "type": "APPEND_ARRAY",
402
+ "path": "directors",
403
+ "value": {
404
+ "directorId": "{{ event.directorId }}",
405
+ "name": "{{ event.name }}",
406
+ "email": "{{ event.email }}",
407
+ "termStart": "{{ event.termStart }}",
408
+ "termEnd": "{{ event.termEnd }}",
409
+ "class": "{{ event.class }}",
410
+ "status": "ACTIVE",
411
+ "isIndependent": "{{ event.isIndependent }}",
412
+ "isChair": false,
413
+ "isLeadIndependent": false,
414
+ "committees": [],
415
+ "electedBy": "{{ event.electionResolutionRef }}"
416
+ }
417
+ },
418
+ {
419
+ "type": "INCREMENT",
420
+ "path": "seats.filled",
421
+ "amount": 1
422
+ },
423
+ {
424
+ "type": "DECREMENT",
425
+ "path": "seats.vacant",
426
+ "amount": 1
427
+ },
428
+ {
429
+ "type": "EMIT_EVENT",
430
+ "eventType": "DIRECTOR_ELECTED",
431
+ "payload": {
432
+ "boardId": "{{ context.boardId }}",
433
+ "directorId": "{{ event.directorId }}",
434
+ "name": "{{ event.name }}",
435
+ "termEnd": "{{ event.termEnd }}"
436
+ }
437
+ }
438
+ ]
439
+ },
440
+ "resign_director": {
441
+ "from": [
442
+ "ACTIVE",
443
+ "IN_MEETING"
444
+ ],
445
+ "to": "ACTIVE",
446
+ "description": "Director resigns from the board",
447
+ "event": {
448
+ "name": "resign_director",
449
+ "payload": {
450
+ "directorId": {
451
+ "type": "string",
452
+ "required": true
453
+ },
454
+ "effectiveDate": {
455
+ "type": "string",
456
+ "format": "date",
457
+ "required": true
458
+ },
459
+ "reason": {
460
+ "type": "string"
461
+ },
462
+ "resignationLetter": {
463
+ "type": "string",
464
+ "description": "Document reference"
465
+ }
466
+ }
467
+ },
468
+ "guards": [
469
+ {
470
+ "name": "isActiveDirector",
471
+ "expression": "context.directors.some(d => d.directorId === event.directorId && d.status === 'ACTIVE')"
472
+ }
473
+ ],
474
+ "effects": [
475
+ {
476
+ "type": "UPDATE_ARRAY_ITEM",
477
+ "path": "directors",
478
+ "matchKey": "directorId",
479
+ "matchValue": "{{ event.directorId }}",
480
+ "updates": {
481
+ "status": "RESIGNED",
482
+ "termEnd": "{{ event.effectiveDate }}"
483
+ }
484
+ },
485
+ {
486
+ "type": "DECREMENT",
487
+ "path": "seats.filled",
488
+ "amount": 1
489
+ },
490
+ {
491
+ "type": "INCREMENT",
492
+ "path": "seats.vacant",
493
+ "amount": 1
494
+ },
495
+ {
496
+ "type": "EMIT_EVENT",
497
+ "eventType": "DIRECTOR_RESIGNED",
498
+ "payload": {
499
+ "boardId": "{{ context.boardId }}",
500
+ "directorId": "{{ event.directorId }}",
501
+ "effectiveDate": "{{ event.effectiveDate }}"
502
+ }
503
+ }
504
+ ]
505
+ },
506
+ "remove_for_cause": {
507
+ "from": "ACTIVE",
508
+ "to": "ACTIVE",
509
+ "description": "Remove a director for cause (requires board or shareholder action depending on bylaws)",
510
+ "event": {
511
+ "name": "remove_for_cause",
512
+ "payload": {
513
+ "directorId": {
514
+ "type": "string",
515
+ "required": true
516
+ },
517
+ "cause": {
518
+ "type": "string",
519
+ "required": true
520
+ },
521
+ "removalResolutionRef": {
522
+ "type": "string",
523
+ "required": true
524
+ },
525
+ "effectiveDate": {
526
+ "type": "string",
527
+ "format": "date",
528
+ "required": true
529
+ }
530
+ }
531
+ },
532
+ "guards": [
533
+ {
534
+ "name": "isActiveDirector",
535
+ "expression": "context.directors.some(d => d.directorId === event.directorId && d.status === 'ACTIVE')"
536
+ },
537
+ {
538
+ "name": "hasRemovalResolution",
539
+ "crossMachine": {
540
+ "machine": "corporate-resolution",
541
+ "instanceRef": "{{ event.removalResolutionRef }}",
542
+ "requiredState": "EXECUTED"
543
+ }
544
+ }
545
+ ],
546
+ "effects": [
547
+ {
548
+ "type": "UPDATE_ARRAY_ITEM",
549
+ "path": "directors",
550
+ "matchKey": "directorId",
551
+ "matchValue": "{{ event.directorId }}",
552
+ "updates": {
553
+ "status": "REMOVED",
554
+ "termEnd": "{{ event.effectiveDate }}"
555
+ }
556
+ },
557
+ {
558
+ "type": "DECREMENT",
559
+ "path": "seats.filled",
560
+ "amount": 1
561
+ },
562
+ {
563
+ "type": "INCREMENT",
564
+ "path": "seats.vacant",
565
+ "amount": 1
566
+ },
567
+ {
568
+ "type": "EMIT_EVENT",
569
+ "eventType": "DIRECTOR_REMOVED",
570
+ "payload": {
571
+ "boardId": "{{ context.boardId }}",
572
+ "directorId": "{{ event.directorId }}",
573
+ "cause": "{{ event.cause }}"
574
+ }
575
+ }
576
+ ]
577
+ },
578
+ "designate_chair": {
579
+ "from": "ACTIVE",
580
+ "to": "ACTIVE",
581
+ "description": "Designate a director as board chair",
582
+ "event": {
583
+ "name": "designate_chair",
584
+ "payload": {
585
+ "directorId": {
586
+ "type": "string",
587
+ "required": true
588
+ },
589
+ "resolutionRef": {
590
+ "type": "string",
591
+ "required": true
592
+ }
593
+ }
594
+ },
595
+ "guards": [
596
+ {
597
+ "name": "isActiveDirector",
598
+ "expression": "context.directors.some(d => d.directorId === event.directorId && d.status === 'ACTIVE')"
599
+ }
600
+ ],
601
+ "effects": [
602
+ {
603
+ "type": "UPDATE_ARRAY_ALL",
604
+ "path": "directors",
605
+ "updates": {
606
+ "isChair": false
607
+ }
608
+ },
609
+ {
610
+ "type": "UPDATE_ARRAY_ITEM",
611
+ "path": "directors",
612
+ "matchKey": "directorId",
613
+ "matchValue": "{{ event.directorId }}",
614
+ "updates": {
615
+ "isChair": true
616
+ }
617
+ }
618
+ ]
619
+ },
620
+ "call_meeting": {
621
+ "from": "ACTIVE",
622
+ "to": "ACTIVE",
623
+ "description": "Schedule a board meeting (can be called by chair, CEO, or directors per bylaws)",
624
+ "event": {
625
+ "name": "call_meeting",
626
+ "payload": {
627
+ "meetingId": {
628
+ "type": "string",
629
+ "required": true
630
+ },
631
+ "type": {
632
+ "type": "string",
633
+ "enum": [
634
+ "REGULAR",
635
+ "SPECIAL",
636
+ "ANNUAL",
637
+ "ORGANIZATIONAL"
638
+ ],
639
+ "required": true
640
+ },
641
+ "scheduledDate": {
642
+ "type": "string",
643
+ "format": "date-time",
644
+ "required": true
645
+ },
646
+ "location": {
647
+ "type": "string"
648
+ },
649
+ "isVirtual": {
650
+ "type": "boolean",
651
+ "default": false
652
+ },
653
+ "calledBy": {
654
+ "type": "string",
655
+ "required": true,
656
+ "description": "Director ID or officer title"
657
+ },
658
+ "noticeDate": {
659
+ "type": "string",
660
+ "format": "date",
661
+ "required": true
662
+ },
663
+ "agenda": {
664
+ "type": "array",
665
+ "items": {
666
+ "type": "string"
667
+ }
668
+ },
669
+ "waiverOfNotice": {
670
+ "type": "boolean",
671
+ "default": false,
672
+ "description": "If all directors waive notice"
673
+ }
674
+ }
675
+ },
676
+ "guards": [
677
+ {
678
+ "name": "sufficientNotice",
679
+ "description": "Must provide notice per bylaws (typically 2-10 days for special, less for regular)",
680
+ "expression": "event.waiverOfNotice || (new Date(event.scheduledDate) - new Date(event.noticeDate)) >= 2 * 24 * 60 * 60 * 1000"
681
+ },
682
+ {
683
+ "name": "noConflictingMeeting",
684
+ "description": "No other meeting currently scheduled/in progress",
685
+ "expression": "context.currentMeeting == null || context.currentMeeting.closedAt != null"
686
+ }
687
+ ],
688
+ "effects": [
689
+ {
690
+ "type": "SET_CONTEXT",
691
+ "path": "currentMeeting",
692
+ "value": {
693
+ "meetingId": "{{ event.meetingId }}",
694
+ "type": "{{ event.type }}",
695
+ "scheduledDate": "{{ event.scheduledDate }}",
696
+ "location": "{{ event.location }}",
697
+ "isVirtual": "{{ event.isVirtual }}",
698
+ "calledBy": "{{ event.calledBy }}",
699
+ "noticeDate": "{{ event.noticeDate }}",
700
+ "agenda": "{{ event.agenda }}",
701
+ "attendees": [],
702
+ "quorumPresent": false,
703
+ "quorumCount": 0
704
+ }
705
+ },
706
+ {
707
+ "type": "EMIT_EVENT",
708
+ "eventType": "BOARD_MEETING_SCHEDULED",
709
+ "payload": {
710
+ "boardId": "{{ context.boardId }}",
711
+ "meetingId": "{{ event.meetingId }}",
712
+ "scheduledDate": "{{ event.scheduledDate }}"
713
+ }
714
+ }
715
+ ]
716
+ },
717
+ "record_attendance": {
718
+ "from": "ACTIVE",
719
+ "to": "ACTIVE",
720
+ "description": "Record a director's attendance before meeting opens",
721
+ "event": {
722
+ "name": "record_attendance",
723
+ "payload": {
724
+ "directorId": {
725
+ "type": "string",
726
+ "required": true
727
+ },
728
+ "present": {
729
+ "type": "boolean",
730
+ "required": true
731
+ },
732
+ "arrivedAt": {
733
+ "type": "string",
734
+ "format": "date-time"
735
+ }
736
+ }
737
+ },
738
+ "guards": [
739
+ {
740
+ "name": "hasPendingMeeting",
741
+ "expression": "context.currentMeeting != null && context.currentMeeting.openedAt == null"
742
+ },
743
+ {
744
+ "name": "isActiveDirector",
745
+ "expression": "context.directors.some(d => d.directorId === event.directorId && d.status === 'ACTIVE')"
746
+ }
747
+ ],
748
+ "effects": [
749
+ {
750
+ "type": "APPEND_ARRAY",
751
+ "path": "currentMeeting.attendees",
752
+ "value": {
753
+ "directorId": "{{ event.directorId }}",
754
+ "present": "{{ event.present }}",
755
+ "arrivedAt": "{{ event.arrivedAt }}",
756
+ "viaProxy": false
757
+ }
758
+ },
759
+ {
760
+ "type": "COMPUTE",
761
+ "path": "currentMeeting.quorumCount",
762
+ "expression": "context.currentMeeting.attendees.filter(a => a.present).length"
763
+ },
764
+ {
765
+ "type": "COMPUTE",
766
+ "path": "currentMeeting.quorumPresent",
767
+ "expression": "context.currentMeeting.attendees.filter(a => a.present).length >= Math.ceil(context.seats.filled * 0.5)"
768
+ }
769
+ ]
770
+ },
771
+ "open_meeting": {
772
+ "from": "ACTIVE",
773
+ "to": "IN_MEETING",
774
+ "description": "Officially open the board meeting once quorum is established",
775
+ "event": {
776
+ "name": "open_meeting",
777
+ "payload": {
778
+ "openedAt": {
779
+ "type": "string",
780
+ "format": "date-time",
781
+ "required": true
782
+ },
783
+ "chairPresiding": {
784
+ "type": "string",
785
+ "description": "Director ID presiding"
786
+ }
787
+ }
788
+ },
789
+ "guards": [
790
+ {
791
+ "name": "hasPendingMeeting",
792
+ "expression": "context.currentMeeting != null && context.currentMeeting.openedAt == null"
793
+ },
794
+ {
795
+ "name": "quorumPresent",
796
+ "description": "Cannot open meeting without quorum",
797
+ "expression": "context.currentMeeting.quorumPresent === true"
798
+ }
799
+ ],
800
+ "effects": [
801
+ {
802
+ "type": "SET_CONTEXT",
803
+ "path": "currentMeeting.openedAt",
804
+ "value": "{{ event.openedAt }}"
805
+ },
806
+ {
807
+ "type": "EMIT_EVENT",
808
+ "eventType": "BOARD_MEETING_OPENED",
809
+ "payload": {
810
+ "boardId": "{{ context.boardId }}",
811
+ "meetingId": "{{ context.currentMeeting.meetingId }}",
812
+ "quorumCount": "{{ context.currentMeeting.quorumCount }}"
813
+ }
814
+ }
815
+ ]
816
+ },
817
+ "director_departs": {
818
+ "from": "IN_MEETING",
819
+ "to": "IN_MEETING",
820
+ "description": "Record a director leaving the meeting (may affect quorum)",
821
+ "event": {
822
+ "name": "director_departs",
823
+ "payload": {
824
+ "directorId": {
825
+ "type": "string",
826
+ "required": true
827
+ },
828
+ "departedAt": {
829
+ "type": "string",
830
+ "format": "date-time",
831
+ "required": true
832
+ }
833
+ }
834
+ },
835
+ "effects": [
836
+ {
837
+ "type": "UPDATE_ARRAY_ITEM",
838
+ "path": "currentMeeting.attendees",
839
+ "matchKey": "directorId",
840
+ "matchValue": "{{ event.directorId }}",
841
+ "updates": {
842
+ "present": false,
843
+ "departedAt": "{{ event.departedAt }}"
844
+ }
845
+ },
846
+ {
847
+ "type": "COMPUTE",
848
+ "path": "currentMeeting.quorumCount",
849
+ "expression": "context.currentMeeting.attendees.filter(a => a.present).length"
850
+ },
851
+ {
852
+ "type": "COMPUTE",
853
+ "path": "currentMeeting.quorumPresent",
854
+ "expression": "context.currentMeeting.attendees.filter(a => a.present).length >= Math.ceil(context.seats.filled * 0.5)"
855
+ }
856
+ ]
857
+ },
858
+ "quorum_lost": {
859
+ "from": "IN_MEETING",
860
+ "to": "QUORUM_LOST",
861
+ "description": "Automatic transition when quorum is lost during meeting",
862
+ "event": {
863
+ "name": "quorum_lost",
864
+ "payload": {
865
+ "lostAt": {
866
+ "type": "string",
867
+ "format": "date-time",
868
+ "required": true
869
+ }
870
+ }
871
+ },
872
+ "guards": [
873
+ {
874
+ "name": "noLongerQuorate",
875
+ "expression": "context.currentMeeting.quorumPresent === false"
876
+ }
877
+ ],
878
+ "effects": [
879
+ {
880
+ "type": "EMIT_EVENT",
881
+ "eventType": "BOARD_QUORUM_LOST",
882
+ "payload": {
883
+ "boardId": "{{ context.boardId }}",
884
+ "meetingId": "{{ context.currentMeeting.meetingId }}",
885
+ "remainingDirectors": "{{ context.currentMeeting.quorumCount }}"
886
+ }
887
+ }
888
+ ]
889
+ },
890
+ "quorum_restored": {
891
+ "from": "QUORUM_LOST",
892
+ "to": "IN_MEETING",
893
+ "description": "Quorum restored after additional director(s) join",
894
+ "event": {
895
+ "name": "quorum_restored",
896
+ "payload": {
897
+ "restoredAt": {
898
+ "type": "string",
899
+ "format": "date-time",
900
+ "required": true
901
+ },
902
+ "directorId": {
903
+ "type": "string",
904
+ "required": true,
905
+ "description": "Joining director"
906
+ }
907
+ }
908
+ },
909
+ "guards": [
910
+ {
911
+ "name": "nowQuorate",
912
+ "expression": "context.currentMeeting.quorumPresent === true"
913
+ }
914
+ ],
915
+ "effects": [
916
+ {
917
+ "type": "EMIT_EVENT",
918
+ "eventType": "BOARD_QUORUM_RESTORED",
919
+ "payload": {
920
+ "boardId": "{{ context.boardId }}",
921
+ "meetingId": "{{ context.currentMeeting.meetingId }}"
922
+ }
923
+ }
924
+ ]
925
+ },
926
+ "adjourn": {
927
+ "from": [
928
+ "IN_MEETING",
929
+ "QUORUM_LOST"
930
+ ],
931
+ "to": "ACTIVE",
932
+ "description": "Adjourn the board meeting",
933
+ "event": {
934
+ "name": "adjourn",
935
+ "payload": {
936
+ "closedAt": {
937
+ "type": "string",
938
+ "format": "date-time",
939
+ "required": true
940
+ },
941
+ "minutesRef": {
942
+ "type": "string",
943
+ "description": "Reference to meeting minutes document"
944
+ },
945
+ "resolutionsPassed": {
946
+ "type": "array",
947
+ "items": {
948
+ "type": "string"
949
+ }
950
+ },
951
+ "adjournedTo": {
952
+ "type": "string",
953
+ "format": "date-time",
954
+ "nullable": true,
955
+ "description": "If adjourning to later date"
956
+ }
957
+ }
958
+ },
959
+ "effects": [
960
+ {
961
+ "type": "SET_CONTEXT",
962
+ "path": "currentMeeting.closedAt",
963
+ "value": "{{ event.closedAt }}"
964
+ },
965
+ {
966
+ "type": "SET_CONTEXT",
967
+ "path": "currentMeeting.minutesRef",
968
+ "value": "{{ event.minutesRef }}"
969
+ },
970
+ {
971
+ "type": "APPEND_ARRAY",
972
+ "path": "meetingHistory",
973
+ "value": {
974
+ "meetingId": "{{ context.currentMeeting.meetingId }}",
975
+ "type": "{{ context.currentMeeting.type }}",
976
+ "date": "{{ context.currentMeeting.scheduledDate }}",
977
+ "quorumAchieved": "{{ context.currentMeeting.quorumPresent }}",
978
+ "attendeeCount": "{{ context.currentMeeting.attendees.filter(a => a.present).length }}",
979
+ "resolutionsPassed": "{{ event.resolutionsPassed }}",
980
+ "minutesRef": "{{ event.minutesRef }}"
981
+ }
982
+ },
983
+ {
984
+ "type": "SET_CONTEXT",
985
+ "path": "currentMeeting",
986
+ "value": null
987
+ },
988
+ {
989
+ "type": "EMIT_EVENT",
990
+ "eventType": "BOARD_MEETING_ADJOURNED",
991
+ "payload": {
992
+ "boardId": "{{ context.boardId }}",
993
+ "meetingId": "{{ context.currentMeeting.meetingId }}",
994
+ "resolutionsPassed": "{{ event.resolutionsPassed }}"
995
+ }
996
+ }
997
+ ]
998
+ },
999
+ "update_seats": {
1000
+ "from": "ACTIVE",
1001
+ "to": "ACTIVE",
1002
+ "description": "Change the number of authorized board seats (requires bylaw amendment)",
1003
+ "event": {
1004
+ "name": "update_seats",
1005
+ "payload": {
1006
+ "newAuthorizedSeats": {
1007
+ "type": "integer",
1008
+ "required": true
1009
+ },
1010
+ "bylawAmendmentRef": {
1011
+ "type": "string",
1012
+ "required": true
1013
+ }
1014
+ }
1015
+ },
1016
+ "guards": [
1017
+ {
1018
+ "name": "seatsNotLessThanFilled",
1019
+ "description": "Cannot reduce below current filled seats",
1020
+ "expression": "event.newAuthorizedSeats >= context.seats.filled"
1021
+ }
1022
+ ],
1023
+ "effects": [
1024
+ {
1025
+ "type": "SET_CONTEXT",
1026
+ "path": "seats.authorized",
1027
+ "value": "{{ event.newAuthorizedSeats }}"
1028
+ },
1029
+ {
1030
+ "type": "COMPUTE",
1031
+ "path": "seats.vacant",
1032
+ "expression": "event.newAuthorizedSeats - context.seats.filled"
1033
+ }
1034
+ ]
1035
+ }
1036
+ },
1037
+ "crossMachineRefs": {
1038
+ "entity": {
1039
+ "machine": "corporate-entity",
1040
+ "description": "Parent corporate entity",
1041
+ "foreignKey": "entityId"
1042
+ },
1043
+ "resolutions": {
1044
+ "machine": "corporate-resolution",
1045
+ "description": "Board resolutions",
1046
+ "foreignKey": "boardId"
1047
+ },
1048
+ "committees": {
1049
+ "machine": "corporate-committee",
1050
+ "description": "Board committees",
1051
+ "foreignKey": "boardId"
1052
+ },
1053
+ "officers": {
1054
+ "machine": "corporate-officers",
1055
+ "description": "Officers appointed by board",
1056
+ "foreignKey": "entityId"
1057
+ }
1058
+ },
1059
+ "metadata": {
1060
+ "author": "OttoChain",
1061
+ "license": "MIT",
1062
+ "tags": [
1063
+ "corporate",
1064
+ "governance",
1065
+ "board",
1066
+ "directors",
1067
+ "meetings"
1068
+ ],
1069
+ "documentation": "https://ottochain.dev/docs/corporate/board"
1070
+ }
1071
+ };
1072
+ exports.corpEntityDef = {
1073
+ "$schema": "https://ottochain.dev/schemas/state-machine-v1.json",
1074
+ "name": "CorpEntity",
1075
+ "version": "1.0.0",
1076
+ "category": "corporate-governance",
1077
+ "description": "Master corporate record tracking the lifecycle of a business entity from incorporation through dissolution. Manages legal identity, share structure, and corporate status.",
1078
+ "context": {
1079
+ "entityId": {
1080
+ "type": "string",
1081
+ "description": "Unique identifier for this corporate entity"
1082
+ },
1083
+ "legalName": {
1084
+ "type": "string",
1085
+ "description": "Full legal name of the corporation"
1086
+ },
1087
+ "tradeName": {
1088
+ "type": "string",
1089
+ "nullable": true,
1090
+ "description": "DBA or trade name if different"
1091
+ },
1092
+ "entityType": {
1093
+ "type": "string",
1094
+ "enum": [
1095
+ "C_CORP",
1096
+ "S_CORP",
1097
+ "B_CORP",
1098
+ "LLC",
1099
+ "LP",
1100
+ "LLP"
1101
+ ],
1102
+ "description": "Legal entity type"
1103
+ },
1104
+ "jurisdiction": {
1105
+ "type": "object",
1106
+ "properties": {
1107
+ "state": {
1108
+ "type": "string",
1109
+ "description": "State of incorporation (e.g., DE, NV, WY)"
1110
+ },
1111
+ "country": {
1112
+ "type": "string",
1113
+ "default": "USA"
1114
+ },
1115
+ "foreignQualifications": {
1116
+ "type": "array",
1117
+ "items": {
1118
+ "type": "string"
1119
+ },
1120
+ "description": "States where foreign qualified to do business"
1121
+ }
1122
+ }
1123
+ },
1124
+ "formationDate": {
1125
+ "type": "string",
1126
+ "format": "date",
1127
+ "description": "Date of incorporation"
1128
+ },
1129
+ "fiscalYearEnd": {
1130
+ "type": "string",
1131
+ "description": "Fiscal year end (MM-DD format)"
1132
+ },
1133
+ "registeredAgent": {
1134
+ "type": "object",
1135
+ "properties": {
1136
+ "name": {
1137
+ "type": "string"
1138
+ },
1139
+ "address": {
1140
+ "type": "object"
1141
+ },
1142
+ "phone": {
1143
+ "type": "string"
1144
+ },
1145
+ "email": {
1146
+ "type": "string"
1147
+ },
1148
+ "effectiveDate": {
1149
+ "type": "string",
1150
+ "format": "date"
1151
+ }
1152
+ }
1153
+ },
1154
+ "principalOffice": {
1155
+ "type": "object",
1156
+ "properties": {
1157
+ "street": {
1158
+ "type": "string"
1159
+ },
1160
+ "city": {
1161
+ "type": "string"
1162
+ },
1163
+ "state": {
1164
+ "type": "string"
1165
+ },
1166
+ "zip": {
1167
+ "type": "string"
1168
+ },
1169
+ "country": {
1170
+ "type": "string",
1171
+ "default": "USA"
1172
+ }
1173
+ }
1174
+ },
1175
+ "shareStructure": {
1176
+ "type": "object",
1177
+ "properties": {
1178
+ "classes": {
1179
+ "type": "array",
1180
+ "items": {
1181
+ "type": "object",
1182
+ "properties": {
1183
+ "className": {
1184
+ "type": "string",
1185
+ "description": "e.g., Common, Series A Preferred"
1186
+ },
1187
+ "classId": {
1188
+ "type": "string"
1189
+ },
1190
+ "authorized": {
1191
+ "type": "integer",
1192
+ "description": "Total shares authorized"
1193
+ },
1194
+ "issued": {
1195
+ "type": "integer",
1196
+ "description": "Shares currently issued"
1197
+ },
1198
+ "outstanding": {
1199
+ "type": "integer",
1200
+ "description": "Issued minus treasury"
1201
+ },
1202
+ "treasury": {
1203
+ "type": "integer",
1204
+ "description": "Shares held by company"
1205
+ },
1206
+ "parValue": {
1207
+ "type": "number",
1208
+ "description": "Par value per share"
1209
+ },
1210
+ "votingRights": {
1211
+ "type": "boolean",
1212
+ "description": "Whether class has voting rights"
1213
+ },
1214
+ "votesPerShare": {
1215
+ "type": "number",
1216
+ "default": 1
1217
+ },
1218
+ "liquidationPreference": {
1219
+ "type": "number",
1220
+ "nullable": true,
1221
+ "description": "Liquidation preference multiple"
1222
+ },
1223
+ "dividendRate": {
1224
+ "type": "number",
1225
+ "nullable": true,
1226
+ "description": "Annual dividend rate %"
1227
+ },
1228
+ "convertible": {
1229
+ "type": "boolean",
1230
+ "default": false
1231
+ },
1232
+ "conversionRatio": {
1233
+ "type": "number",
1234
+ "nullable": true
1235
+ },
1236
+ "antidilution": {
1237
+ "type": "string",
1238
+ "enum": [
1239
+ "NONE",
1240
+ "BROAD_BASED",
1241
+ "NARROW_BASED",
1242
+ "FULL_RATCHET"
1243
+ ],
1244
+ "nullable": true
1245
+ }
1246
+ }
1247
+ }
1248
+ },
1249
+ "totalAuthorized": {
1250
+ "type": "integer",
1251
+ "description": "Sum of all authorized shares"
1252
+ },
1253
+ "totalIssued": {
1254
+ "type": "integer"
1255
+ },
1256
+ "totalOutstanding": {
1257
+ "type": "integer"
1258
+ }
1259
+ }
1260
+ },
1261
+ "incorporators": {
1262
+ "type": "array",
1263
+ "items": {
1264
+ "type": "object",
1265
+ "properties": {
1266
+ "name": {
1267
+ "type": "string"
1268
+ },
1269
+ "address": {
1270
+ "type": "object"
1271
+ },
1272
+ "signatureDate": {
1273
+ "type": "string",
1274
+ "format": "date"
1275
+ }
1276
+ }
1277
+ }
1278
+ },
1279
+ "ein": {
1280
+ "type": "string",
1281
+ "nullable": true,
1282
+ "description": "Federal EIN"
1283
+ },
1284
+ "stateIds": {
1285
+ "type": "object",
1286
+ "additionalProperties": {
1287
+ "type": "string"
1288
+ },
1289
+ "description": "State-specific entity IDs keyed by state code"
1290
+ },
1291
+ "suspensionReason": {
1292
+ "type": "string",
1293
+ "nullable": true
1294
+ },
1295
+ "suspensionDate": {
1296
+ "type": "string",
1297
+ "format": "date",
1298
+ "nullable": true
1299
+ },
1300
+ "dissolutionDate": {
1301
+ "type": "string",
1302
+ "format": "date",
1303
+ "nullable": true
1304
+ },
1305
+ "dissolutionReason": {
1306
+ "type": "string",
1307
+ "nullable": true
1308
+ },
1309
+ "charterAmendments": {
1310
+ "type": "array",
1311
+ "items": {
1312
+ "type": "object",
1313
+ "properties": {
1314
+ "amendmentId": {
1315
+ "type": "string"
1316
+ },
1317
+ "description": {
1318
+ "type": "string"
1319
+ },
1320
+ "effectiveDate": {
1321
+ "type": "string",
1322
+ "format": "date"
1323
+ },
1324
+ "resolutionRef": {
1325
+ "type": "string",
1326
+ "description": "Reference to approving resolution"
1327
+ },
1328
+ "filedDate": {
1329
+ "type": "string",
1330
+ "format": "date"
1331
+ }
1332
+ }
1333
+ }
1334
+ },
1335
+ "createdAt": {
1336
+ "type": "string",
1337
+ "format": "date-time"
1338
+ },
1339
+ "updatedAt": {
1340
+ "type": "string",
1341
+ "format": "date-time"
1342
+ }
1343
+ },
1344
+ "states": {
1345
+ "INCORPORATING": {
1346
+ "description": "Initial state during formation process. Articles filed but not yet approved by state.",
1347
+ "metadata": null
1348
+ },
1349
+ "ACTIVE": {
1350
+ "description": "Corporation is in good standing and authorized to conduct business.",
1351
+ "metadata": null
1352
+ },
1353
+ "SUSPENDED": {
1354
+ "description": "Corporate powers suspended due to compliance failure (tax, filings, etc). Can be reinstated.",
1355
+ "metadata": null
1356
+ },
1357
+ "DISSOLVED": {
1358
+ "description": "Corporation has been legally dissolved. Terminal state.",
1359
+ "metadata": null,
1360
+ "terminal": true
1361
+ }
1362
+ },
1363
+ "initialState": "INCORPORATING",
1364
+ "transitions": {
1365
+ "incorporate": {
1366
+ "from": "INCORPORATING",
1367
+ "to": "ACTIVE",
1368
+ "description": "State approves articles of incorporation, corporation comes into existence",
1369
+ "event": {
1370
+ "name": "incorporate",
1371
+ "payload": {
1372
+ "approvalDate": {
1373
+ "type": "string",
1374
+ "format": "date",
1375
+ "required": true
1376
+ },
1377
+ "stateFileNumber": {
1378
+ "type": "string",
1379
+ "required": true
1380
+ },
1381
+ "certificateOfIncorporation": {
1382
+ "type": "string",
1383
+ "description": "Document reference"
1384
+ }
1385
+ }
1386
+ },
1387
+ "guards": [
1388
+ {
1389
+ "name": "hasRequiredFormationDocs",
1390
+ "description": "Articles of incorporation filed, incorporators signed, registered agent designated",
1391
+ "expression": "context.legalName != null && context.jurisdiction.state != null && context.registeredAgent != null && context.incorporators.length > 0"
1392
+ },
1393
+ {
1394
+ "name": "hasAuthorizedShares",
1395
+ "description": "At least one share class authorized",
1396
+ "expression": "context.shareStructure.classes.length > 0 && context.shareStructure.totalAuthorized > 0"
1397
+ }
1398
+ ],
1399
+ "effects": [
1400
+ {
1401
+ "type": "SET_CONTEXT",
1402
+ "path": "formationDate",
1403
+ "value": "{{ event.approvalDate }}"
1404
+ },
1405
+ {
1406
+ "type": "SET_CONTEXT",
1407
+ "path": "stateIds.{{ context.jurisdiction.state }}",
1408
+ "value": "{{ event.stateFileNumber }}"
1409
+ },
1410
+ {
1411
+ "type": "SET_CONTEXT",
1412
+ "path": "updatedAt",
1413
+ "value": "{{ now() }}"
1414
+ },
1415
+ {
1416
+ "type": "EMIT_EVENT",
1417
+ "eventType": "CORPORATION_FORMED",
1418
+ "payload": {
1419
+ "entityId": "{{ context.entityId }}",
1420
+ "legalName": "{{ context.legalName }}",
1421
+ "jurisdiction": "{{ context.jurisdiction.state }}",
1422
+ "formationDate": "{{ event.approvalDate }}"
1423
+ }
1424
+ }
1425
+ ]
1426
+ },
1427
+ "amend_charter": {
1428
+ "from": "ACTIVE",
1429
+ "to": "ACTIVE",
1430
+ "description": "Amend the certificate/articles of incorporation (requires shareholder approval for most amendments)",
1431
+ "event": {
1432
+ "name": "amend_charter",
1433
+ "payload": {
1434
+ "amendmentId": {
1435
+ "type": "string",
1436
+ "required": true
1437
+ },
1438
+ "description": {
1439
+ "type": "string",
1440
+ "required": true
1441
+ },
1442
+ "amendmentType": {
1443
+ "type": "string",
1444
+ "enum": [
1445
+ "NAME_CHANGE",
1446
+ "SHARE_AUTHORIZATION",
1447
+ "PURPOSE_CHANGE",
1448
+ "OTHER"
1449
+ ],
1450
+ "required": true
1451
+ },
1452
+ "resolutionRef": {
1453
+ "type": "string",
1454
+ "required": true,
1455
+ "description": "Reference to board/shareholder resolution"
1456
+ },
1457
+ "effectiveDate": {
1458
+ "type": "string",
1459
+ "format": "date",
1460
+ "required": true
1461
+ },
1462
+ "filedDate": {
1463
+ "type": "string",
1464
+ "format": "date",
1465
+ "required": true
1466
+ },
1467
+ "newShareAuthorization": {
1468
+ "type": "object",
1469
+ "nullable": true,
1470
+ "description": "If increasing/changing authorized shares"
1471
+ },
1472
+ "newLegalName": {
1473
+ "type": "string",
1474
+ "nullable": true
1475
+ }
1476
+ }
1477
+ },
1478
+ "guards": [
1479
+ {
1480
+ "name": "hasApprovedResolution",
1481
+ "description": "Charter amendment must be backed by an executed resolution",
1482
+ "expression": "event.resolutionRef != null",
1483
+ "crossMachine": {
1484
+ "machine": "corporate-resolution",
1485
+ "instanceRef": "{{ event.resolutionRef }}",
1486
+ "requiredState": "EXECUTED"
1487
+ }
1488
+ }
1489
+ ],
1490
+ "effects": [
1491
+ {
1492
+ "type": "APPEND_ARRAY",
1493
+ "path": "charterAmendments",
1494
+ "value": {
1495
+ "amendmentId": "{{ event.amendmentId }}",
1496
+ "description": "{{ event.description }}",
1497
+ "effectiveDate": "{{ event.effectiveDate }}",
1498
+ "resolutionRef": "{{ event.resolutionRef }}",
1499
+ "filedDate": "{{ event.filedDate }}"
1500
+ }
1501
+ },
1502
+ {
1503
+ "type": "CONDITIONAL",
1504
+ "condition": "event.newLegalName != null",
1505
+ "then": {
1506
+ "type": "SET_CONTEXT",
1507
+ "path": "legalName",
1508
+ "value": "{{ event.newLegalName }}"
1509
+ }
1510
+ },
1511
+ {
1512
+ "type": "SET_CONTEXT",
1513
+ "path": "updatedAt",
1514
+ "value": "{{ now() }}"
1515
+ },
1516
+ {
1517
+ "type": "EMIT_EVENT",
1518
+ "eventType": "CHARTER_AMENDED",
1519
+ "payload": {
1520
+ "entityId": "{{ context.entityId }}",
1521
+ "amendmentId": "{{ event.amendmentId }}",
1522
+ "amendmentType": "{{ event.amendmentType }}"
1523
+ }
1524
+ }
1525
+ ]
1526
+ },
1527
+ "update_share_class": {
1528
+ "from": "ACTIVE",
1529
+ "to": "ACTIVE",
1530
+ "description": "Update authorized shares for an existing class or add new class (requires charter amendment)",
1531
+ "event": {
1532
+ "name": "update_share_class",
1533
+ "payload": {
1534
+ "classId": {
1535
+ "type": "string",
1536
+ "required": true
1537
+ },
1538
+ "className": {
1539
+ "type": "string",
1540
+ "required": true
1541
+ },
1542
+ "authorized": {
1543
+ "type": "integer",
1544
+ "required": true
1545
+ },
1546
+ "parValue": {
1547
+ "type": "number",
1548
+ "required": true
1549
+ },
1550
+ "votingRights": {
1551
+ "type": "boolean",
1552
+ "required": true
1553
+ },
1554
+ "votesPerShare": {
1555
+ "type": "number",
1556
+ "default": 1
1557
+ },
1558
+ "liquidationPreference": {
1559
+ "type": "number",
1560
+ "nullable": true
1561
+ },
1562
+ "dividendRate": {
1563
+ "type": "number",
1564
+ "nullable": true
1565
+ },
1566
+ "convertible": {
1567
+ "type": "boolean",
1568
+ "default": false
1569
+ },
1570
+ "charterAmendmentRef": {
1571
+ "type": "string",
1572
+ "required": true
1573
+ }
1574
+ }
1575
+ },
1576
+ "guards": [
1577
+ {
1578
+ "name": "charterAmended",
1579
+ "description": "Share class changes require charter amendment to be filed",
1580
+ "expression": "context.charterAmendments.some(a => a.amendmentId === event.charterAmendmentRef)"
1581
+ }
1582
+ ],
1583
+ "effects": [
1584
+ {
1585
+ "type": "UPSERT_ARRAY",
1586
+ "path": "shareStructure.classes",
1587
+ "matchKey": "classId",
1588
+ "matchValue": "{{ event.classId }}",
1589
+ "value": {
1590
+ "classId": "{{ event.classId }}",
1591
+ "className": "{{ event.className }}",
1592
+ "authorized": "{{ event.authorized }}",
1593
+ "issued": 0,
1594
+ "outstanding": 0,
1595
+ "treasury": 0,
1596
+ "parValue": "{{ event.parValue }}",
1597
+ "votingRights": "{{ event.votingRights }}",
1598
+ "votesPerShare": "{{ event.votesPerShare }}",
1599
+ "liquidationPreference": "{{ event.liquidationPreference }}",
1600
+ "dividendRate": "{{ event.dividendRate }}",
1601
+ "convertible": "{{ event.convertible }}"
1602
+ }
1603
+ },
1604
+ {
1605
+ "type": "COMPUTE",
1606
+ "path": "shareStructure.totalAuthorized",
1607
+ "expression": "context.shareStructure.classes.reduce((sum, c) => sum + c.authorized, 0)"
1608
+ }
1609
+ ]
1610
+ },
1611
+ "update_registered_agent": {
1612
+ "from": "ACTIVE",
1613
+ "to": "ACTIVE",
1614
+ "description": "Change the registered agent on file with the state",
1615
+ "event": {
1616
+ "name": "update_registered_agent",
1617
+ "payload": {
1618
+ "name": {
1619
+ "type": "string",
1620
+ "required": true
1621
+ },
1622
+ "address": {
1623
+ "type": "object",
1624
+ "required": true
1625
+ },
1626
+ "phone": {
1627
+ "type": "string"
1628
+ },
1629
+ "email": {
1630
+ "type": "string"
1631
+ },
1632
+ "effectiveDate": {
1633
+ "type": "string",
1634
+ "format": "date",
1635
+ "required": true
1636
+ },
1637
+ "filingConfirmation": {
1638
+ "type": "string",
1639
+ "description": "State filing confirmation number"
1640
+ }
1641
+ }
1642
+ },
1643
+ "effects": [
1644
+ {
1645
+ "type": "SET_CONTEXT",
1646
+ "path": "registeredAgent",
1647
+ "value": {
1648
+ "name": "{{ event.name }}",
1649
+ "address": "{{ event.address }}",
1650
+ "phone": "{{ event.phone }}",
1651
+ "email": "{{ event.email }}",
1652
+ "effectiveDate": "{{ event.effectiveDate }}"
1653
+ }
1654
+ },
1655
+ {
1656
+ "type": "EMIT_EVENT",
1657
+ "eventType": "REGISTERED_AGENT_CHANGED",
1658
+ "payload": {
1659
+ "entityId": "{{ context.entityId }}",
1660
+ "newAgent": "{{ event.name }}",
1661
+ "effectiveDate": "{{ event.effectiveDate }}"
1662
+ }
1663
+ }
1664
+ ]
1665
+ },
1666
+ "suspend": {
1667
+ "from": "ACTIVE",
1668
+ "to": "SUSPENDED",
1669
+ "description": "State suspends corporate powers (typically for tax/filing noncompliance)",
1670
+ "event": {
1671
+ "name": "suspend",
1672
+ "payload": {
1673
+ "reason": {
1674
+ "type": "string",
1675
+ "enum": [
1676
+ "FRANCHISE_TAX_DELINQUENT",
1677
+ "ANNUAL_REPORT_MISSING",
1678
+ "REGISTERED_AGENT_LAPSE",
1679
+ "ADMINISTRATIVE",
1680
+ "OTHER"
1681
+ ],
1682
+ "required": true
1683
+ },
1684
+ "suspensionDate": {
1685
+ "type": "string",
1686
+ "format": "date",
1687
+ "required": true
1688
+ },
1689
+ "stateNotice": {
1690
+ "type": "string",
1691
+ "description": "Reference to state notice"
1692
+ },
1693
+ "cureDeadline": {
1694
+ "type": "string",
1695
+ "format": "date",
1696
+ "nullable": true
1697
+ }
1698
+ }
1699
+ },
1700
+ "effects": [
1701
+ {
1702
+ "type": "SET_CONTEXT",
1703
+ "path": "suspensionReason",
1704
+ "value": "{{ event.reason }}"
1705
+ },
1706
+ {
1707
+ "type": "SET_CONTEXT",
1708
+ "path": "suspensionDate",
1709
+ "value": "{{ event.suspensionDate }}"
1710
+ },
1711
+ {
1712
+ "type": "EMIT_EVENT",
1713
+ "eventType": "CORPORATION_SUSPENDED",
1714
+ "payload": {
1715
+ "entityId": "{{ context.entityId }}",
1716
+ "reason": "{{ event.reason }}",
1717
+ "cureDeadline": "{{ event.cureDeadline }}"
1718
+ }
1719
+ }
1720
+ ]
1721
+ },
1722
+ "reinstate": {
1723
+ "from": "SUSPENDED",
1724
+ "to": "ACTIVE",
1725
+ "description": "Cure deficiencies and reinstate corporate powers",
1726
+ "event": {
1727
+ "name": "reinstate",
1728
+ "payload": {
1729
+ "reinstatementDate": {
1730
+ "type": "string",
1731
+ "format": "date",
1732
+ "required": true
1733
+ },
1734
+ "curativeActions": {
1735
+ "type": "array",
1736
+ "items": {
1737
+ "type": "string"
1738
+ },
1739
+ "description": "List of actions taken to cure",
1740
+ "required": true
1741
+ },
1742
+ "stateConfirmation": {
1743
+ "type": "string",
1744
+ "required": true
1745
+ },
1746
+ "penaltiesPaid": {
1747
+ "type": "number",
1748
+ "nullable": true
1749
+ }
1750
+ }
1751
+ },
1752
+ "effects": [
1753
+ {
1754
+ "type": "SET_CONTEXT",
1755
+ "path": "suspensionReason",
1756
+ "value": null
1757
+ },
1758
+ {
1759
+ "type": "SET_CONTEXT",
1760
+ "path": "suspensionDate",
1761
+ "value": null
1762
+ },
1763
+ {
1764
+ "type": "EMIT_EVENT",
1765
+ "eventType": "CORPORATION_REINSTATED",
1766
+ "payload": {
1767
+ "entityId": "{{ context.entityId }}",
1768
+ "reinstatementDate": "{{ event.reinstatementDate }}"
1769
+ }
1770
+ }
1771
+ ]
1772
+ },
1773
+ "dissolve_voluntary": {
1774
+ "from": "ACTIVE",
1775
+ "to": "DISSOLVED",
1776
+ "description": "Voluntary dissolution approved by board and shareholders",
1777
+ "event": {
1778
+ "name": "dissolve_voluntary",
1779
+ "payload": {
1780
+ "dissolutionDate": {
1781
+ "type": "string",
1782
+ "format": "date",
1783
+ "required": true
1784
+ },
1785
+ "boardResolutionRef": {
1786
+ "type": "string",
1787
+ "required": true
1788
+ },
1789
+ "shareholderResolutionRef": {
1790
+ "type": "string",
1791
+ "required": true
1792
+ },
1793
+ "windingUpPlan": {
1794
+ "type": "string",
1795
+ "description": "Reference to winding up plan"
1796
+ },
1797
+ "certificateOfDissolution": {
1798
+ "type": "string"
1799
+ }
1800
+ }
1801
+ },
1802
+ "guards": [
1803
+ {
1804
+ "name": "boardApproved",
1805
+ "description": "Board must approve dissolution",
1806
+ "crossMachine": {
1807
+ "machine": "corporate-resolution",
1808
+ "instanceRef": "{{ event.boardResolutionRef }}",
1809
+ "requiredState": "EXECUTED"
1810
+ }
1811
+ },
1812
+ {
1813
+ "name": "shareholdersApproved",
1814
+ "description": "Shareholders must approve dissolution (typically majority or supermajority)",
1815
+ "crossMachine": {
1816
+ "machine": "corporate-resolution",
1817
+ "instanceRef": "{{ event.shareholderResolutionRef }}",
1818
+ "requiredState": "EXECUTED"
1819
+ }
1820
+ }
1821
+ ],
1822
+ "effects": [
1823
+ {
1824
+ "type": "SET_CONTEXT",
1825
+ "path": "dissolutionDate",
1826
+ "value": "{{ event.dissolutionDate }}"
1827
+ },
1828
+ {
1829
+ "type": "SET_CONTEXT",
1830
+ "path": "dissolutionReason",
1831
+ "value": "VOLUNTARY"
1832
+ },
1833
+ {
1834
+ "type": "EMIT_EVENT",
1835
+ "eventType": "CORPORATION_DISSOLVED",
1836
+ "payload": {
1837
+ "entityId": "{{ context.entityId }}",
1838
+ "dissolutionType": "VOLUNTARY",
1839
+ "dissolutionDate": "{{ event.dissolutionDate }}"
1840
+ }
1841
+ }
1842
+ ]
1843
+ },
1844
+ "dissolve_administrative": {
1845
+ "from": "SUSPENDED",
1846
+ "to": "DISSOLVED",
1847
+ "description": "Administrative dissolution by state after prolonged suspension",
1848
+ "event": {
1849
+ "name": "dissolve_administrative",
1850
+ "payload": {
1851
+ "dissolutionDate": {
1852
+ "type": "string",
1853
+ "format": "date",
1854
+ "required": true
1855
+ },
1856
+ "stateOrder": {
1857
+ "type": "string",
1858
+ "required": true
1859
+ },
1860
+ "reason": {
1861
+ "type": "string",
1862
+ "required": true
1863
+ }
1864
+ }
1865
+ },
1866
+ "effects": [
1867
+ {
1868
+ "type": "SET_CONTEXT",
1869
+ "path": "dissolutionDate",
1870
+ "value": "{{ event.dissolutionDate }}"
1871
+ },
1872
+ {
1873
+ "type": "SET_CONTEXT",
1874
+ "path": "dissolutionReason",
1875
+ "value": "ADMINISTRATIVE: {{ event.reason }}"
1876
+ },
1877
+ {
1878
+ "type": "EMIT_EVENT",
1879
+ "eventType": "CORPORATION_DISSOLVED",
1880
+ "payload": {
1881
+ "entityId": "{{ context.entityId }}",
1882
+ "dissolutionType": "ADMINISTRATIVE",
1883
+ "dissolutionDate": "{{ event.dissolutionDate }}"
1884
+ }
1885
+ }
1886
+ ]
1887
+ }
1888
+ },
1889
+ "crossMachineRefs": {
1890
+ "board": {
1891
+ "machine": "corporate-board",
1892
+ "description": "Board of directors for this entity",
1893
+ "foreignKey": "entityId"
1894
+ },
1895
+ "officers": {
1896
+ "machine": "corporate-officers",
1897
+ "description": "Executive officers for this entity",
1898
+ "foreignKey": "entityId"
1899
+ },
1900
+ "bylaws": {
1901
+ "machine": "corporate-bylaws",
1902
+ "description": "Governing bylaws for this entity",
1903
+ "foreignKey": "entityId"
1904
+ },
1905
+ "shareholders": {
1906
+ "machine": "corporate-shareholders",
1907
+ "description": "Shareholder meeting instances",
1908
+ "foreignKey": "entityId"
1909
+ },
1910
+ "securities": {
1911
+ "machine": "corporate-securities",
1912
+ "description": "Stock issuance records",
1913
+ "foreignKey": "entityId"
1914
+ },
1915
+ "compliance": {
1916
+ "machine": "corporate-compliance",
1917
+ "description": "Regulatory compliance tracking",
1918
+ "foreignKey": "entityId"
1919
+ }
1920
+ },
1921
+ "metadata": {
1922
+ "author": "OttoChain",
1923
+ "license": "MIT",
1924
+ "tags": [
1925
+ "corporate",
1926
+ "governance",
1927
+ "entity",
1928
+ "formation"
1929
+ ],
1930
+ "documentation": "https://ottochain.dev/docs/corporate/entity"
1931
+ }
1932
+ };
1933
+ exports.corpSecuritiesDef = {
1934
+ "$schema": "https://ottochain.dev/schemas/state-machine-v1.json",
1935
+ "name": "CorpSecurities",
1936
+ "version": "1.0.0",
1937
+ "category": "corporate-governance",
1938
+ "description": "Securities state machine tracking the lifecycle of equity from authorization through issuance, transfer, and retirement. Manages stock certificates, book entry positions, and restricted securities.",
1939
+ "context": {
1940
+ "securityId": {
1941
+ "type": "string",
1942
+ "description": "Unique identifier for this security lot/certificate"
1943
+ },
1944
+ "entityId": {
1945
+ "type": "string",
1946
+ "description": "Reference to parent corporate-entity"
1947
+ },
1948
+ "shareClass": {
1949
+ "type": "string",
1950
+ "description": "Share class ID from corporate-entity"
1951
+ },
1952
+ "shareClassName": {
1953
+ "type": "string",
1954
+ "description": "Human-readable class name"
1955
+ },
1956
+ "certificateNumber": {
1957
+ "type": "string",
1958
+ "nullable": true,
1959
+ "description": "For certificated shares"
1960
+ },
1961
+ "cusip": {
1962
+ "type": "string",
1963
+ "nullable": true,
1964
+ "description": "CUSIP number if assigned"
1965
+ },
1966
+ "shareCount": {
1967
+ "type": "integer",
1968
+ "description": "Number of shares in this lot"
1969
+ },
1970
+ "parValue": {
1971
+ "type": "number",
1972
+ "description": "Par value per share"
1973
+ },
1974
+ "issuancePrice": {
1975
+ "type": "number",
1976
+ "nullable": true,
1977
+ "description": "Price per share at issuance"
1978
+ },
1979
+ "issuanceDate": {
1980
+ "type": "string",
1981
+ "format": "date",
1982
+ "nullable": true
1983
+ },
1984
+ "form": {
1985
+ "type": "string",
1986
+ "enum": [
1987
+ "CERTIFICATED",
1988
+ "BOOK_ENTRY",
1989
+ "DRS"
1990
+ ],
1991
+ "description": "Physical certificate, book entry, or Direct Registration System"
1992
+ },
1993
+ "holder": {
1994
+ "type": "object",
1995
+ "nullable": true,
1996
+ "properties": {
1997
+ "holderId": {
1998
+ "type": "string"
1999
+ },
2000
+ "holderType": {
2001
+ "type": "string",
2002
+ "enum": [
2003
+ "INDIVIDUAL",
2004
+ "ENTITY",
2005
+ "TRUST",
2006
+ "TREASURY"
2007
+ ]
2008
+ },
2009
+ "name": {
2010
+ "type": "string"
2011
+ },
2012
+ "taxId": {
2013
+ "type": "string",
2014
+ "nullable": true
2015
+ },
2016
+ "address": {
2017
+ "type": "object",
2018
+ "nullable": true
2019
+ },
2020
+ "acquisitionDate": {
2021
+ "type": "string",
2022
+ "format": "date"
2023
+ },
2024
+ "acquisitionMethod": {
2025
+ "type": "string",
2026
+ "enum": [
2027
+ "ORIGINAL_ISSUANCE",
2028
+ "PURCHASE",
2029
+ "GIFT",
2030
+ "INHERITANCE",
2031
+ "STOCK_SPLIT",
2032
+ "CONVERSION",
2033
+ "EXERCISE"
2034
+ ]
2035
+ },
2036
+ "costBasis": {
2037
+ "type": "number",
2038
+ "nullable": true
2039
+ }
2040
+ }
2041
+ },
2042
+ "restrictions": {
2043
+ "type": "object",
2044
+ "properties": {
2045
+ "isRestricted": {
2046
+ "type": "boolean",
2047
+ "default": false
2048
+ },
2049
+ "restrictionType": {
2050
+ "type": "array",
2051
+ "items": {
2052
+ "type": "string",
2053
+ "enum": [
2054
+ "RULE_144",
2055
+ "SECTION_4(a)(2)",
2056
+ "REG_D",
2057
+ "REG_S",
2058
+ "LOCK_UP",
2059
+ "VESTING",
2060
+ "RIGHT_OF_FIRST_REFUSAL"
2061
+ ]
2062
+ }
2063
+ },
2064
+ "restrictionEndDate": {
2065
+ "type": "string",
2066
+ "format": "date",
2067
+ "nullable": true
2068
+ },
2069
+ "legends": {
2070
+ "type": "array",
2071
+ "items": {
2072
+ "type": "string"
2073
+ },
2074
+ "description": "Legend text on certificates"
2075
+ },
2076
+ "vestingSchedule": {
2077
+ "type": "object",
2078
+ "nullable": true,
2079
+ "properties": {
2080
+ "vestingStartDate": {
2081
+ "type": "string",
2082
+ "format": "date"
2083
+ },
2084
+ "totalShares": {
2085
+ "type": "integer"
2086
+ },
2087
+ "vestedShares": {
2088
+ "type": "integer"
2089
+ },
2090
+ "vestingScheduleRef": {
2091
+ "type": "string"
2092
+ }
2093
+ }
2094
+ },
2095
+ "lockUpExpiration": {
2096
+ "type": "string",
2097
+ "format": "date",
2098
+ "nullable": true
2099
+ },
2100
+ "rofr": {
2101
+ "type": "object",
2102
+ "nullable": true,
2103
+ "description": "Right of First Refusal",
2104
+ "properties": {
2105
+ "holderIds": {
2106
+ "type": "array",
2107
+ "items": {
2108
+ "type": "string"
2109
+ }
2110
+ },
2111
+ "noticePeriodDays": {
2112
+ "type": "integer"
2113
+ }
2114
+ }
2115
+ }
2116
+ }
2117
+ },
2118
+ "authorization": {
2119
+ "type": "object",
2120
+ "nullable": true,
2121
+ "description": "For shares in AUTHORIZED state",
2122
+ "properties": {
2123
+ "authorizedDate": {
2124
+ "type": "string",
2125
+ "format": "date"
2126
+ },
2127
+ "charterProvision": {
2128
+ "type": "string"
2129
+ },
2130
+ "authorizedShares": {
2131
+ "type": "integer"
2132
+ }
2133
+ }
2134
+ },
2135
+ "issuanceDetails": {
2136
+ "type": "object",
2137
+ "nullable": true,
2138
+ "properties": {
2139
+ "boardResolutionRef": {
2140
+ "type": "string"
2141
+ },
2142
+ "issuanceAgreementRef": {
2143
+ "type": "string"
2144
+ },
2145
+ "consideration": {
2146
+ "type": "object",
2147
+ "properties": {
2148
+ "type": {
2149
+ "type": "string",
2150
+ "enum": [
2151
+ "CASH",
2152
+ "PROPERTY",
2153
+ "SERVICES",
2154
+ "DEBT_CONVERSION",
2155
+ "STOCK_CONVERSION"
2156
+ ]
2157
+ },
2158
+ "value": {
2159
+ "type": "number"
2160
+ },
2161
+ "description": {
2162
+ "type": "string"
2163
+ }
2164
+ }
2165
+ },
2166
+ "exemptionUsed": {
2167
+ "type": "string",
2168
+ "nullable": true
2169
+ },
2170
+ "accreditedInvestor": {
2171
+ "type": "boolean",
2172
+ "nullable": true
2173
+ }
2174
+ }
2175
+ },
2176
+ "transferHistory": {
2177
+ "type": "array",
2178
+ "items": {
2179
+ "type": "object",
2180
+ "properties": {
2181
+ "transferId": {
2182
+ "type": "string"
2183
+ },
2184
+ "transferDate": {
2185
+ "type": "string",
2186
+ "format": "date"
2187
+ },
2188
+ "fromHolderId": {
2189
+ "type": "string"
2190
+ },
2191
+ "toHolderId": {
2192
+ "type": "string"
2193
+ },
2194
+ "shares": {
2195
+ "type": "integer"
2196
+ },
2197
+ "transferType": {
2198
+ "type": "string",
2199
+ "enum": [
2200
+ "SALE",
2201
+ "GIFT",
2202
+ "INHERITANCE",
2203
+ "INTERNAL"
2204
+ ]
2205
+ },
2206
+ "pricePerShare": {
2207
+ "type": "number",
2208
+ "nullable": true
2209
+ },
2210
+ "transferAgentConfirmation": {
2211
+ "type": "string",
2212
+ "nullable": true
2213
+ }
2214
+ }
2215
+ }
2216
+ },
2217
+ "corporateActions": {
2218
+ "type": "array",
2219
+ "description": "Stock splits, dividends, etc. affecting this lot",
2220
+ "items": {
2221
+ "type": "object",
2222
+ "properties": {
2223
+ "actionId": {
2224
+ "type": "string"
2225
+ },
2226
+ "actionType": {
2227
+ "type": "string",
2228
+ "enum": [
2229
+ "STOCK_SPLIT",
2230
+ "REVERSE_SPLIT",
2231
+ "STOCK_DIVIDEND",
2232
+ "CONVERSION",
2233
+ "RECLASSIFICATION"
2234
+ ]
2235
+ },
2236
+ "actionDate": {
2237
+ "type": "string",
2238
+ "format": "date"
2239
+ },
2240
+ "ratio": {
2241
+ "type": "string",
2242
+ "nullable": true,
2243
+ "description": "e.g., 2:1 for split"
2244
+ },
2245
+ "sharesBeforeAction": {
2246
+ "type": "integer"
2247
+ },
2248
+ "sharesAfterAction": {
2249
+ "type": "integer"
2250
+ },
2251
+ "resolutionRef": {
2252
+ "type": "string"
2253
+ }
2254
+ }
2255
+ }
2256
+ },
2257
+ "retirementDetails": {
2258
+ "type": "object",
2259
+ "nullable": true,
2260
+ "properties": {
2261
+ "retiredDate": {
2262
+ "type": "string",
2263
+ "format": "date"
2264
+ },
2265
+ "retirementMethod": {
2266
+ "type": "string",
2267
+ "enum": [
2268
+ "REPURCHASE",
2269
+ "REDEMPTION",
2270
+ "CANCELLATION",
2271
+ "CONVERSION"
2272
+ ]
2273
+ },
2274
+ "repurchasePrice": {
2275
+ "type": "number",
2276
+ "nullable": true
2277
+ },
2278
+ "boardResolutionRef": {
2279
+ "type": "string"
2280
+ }
2281
+ }
2282
+ },
2283
+ "createdAt": {
2284
+ "type": "string",
2285
+ "format": "date-time"
2286
+ },
2287
+ "updatedAt": {
2288
+ "type": "string",
2289
+ "format": "date-time"
2290
+ }
2291
+ },
2292
+ "states": {
2293
+ "AUTHORIZED": {
2294
+ "description": "Shares authorized by charter but not yet issued",
2295
+ "metadata": null
2296
+ },
2297
+ "ISSUED": {
2298
+ "description": "Shares issued and held by a shareholder",
2299
+ "metadata": null
2300
+ },
2301
+ "TREASURY": {
2302
+ "description": "Shares repurchased and held by the company",
2303
+ "metadata": null
2304
+ },
2305
+ "TRANSFERRED": {
2306
+ "description": "Transitional state during transfer between holders",
2307
+ "metadata": null
2308
+ },
2309
+ "RETIRED": {
2310
+ "description": "Shares cancelled and returned to authorized but unissued",
2311
+ "metadata": null,
2312
+ "terminal": true
2313
+ }
2314
+ },
2315
+ "initialState": "AUTHORIZED",
2316
+ "transitions": {
2317
+ "authorize_shares": {
2318
+ "from": null,
2319
+ "to": "AUTHORIZED",
2320
+ "description": "Record shares as authorized per charter/amendment",
2321
+ "event": {
2322
+ "name": "authorize_shares",
2323
+ "payload": {
2324
+ "securityId": {
2325
+ "type": "string",
2326
+ "required": true
2327
+ },
2328
+ "entityId": {
2329
+ "type": "string",
2330
+ "required": true
2331
+ },
2332
+ "shareClass": {
2333
+ "type": "string",
2334
+ "required": true
2335
+ },
2336
+ "shareClassName": {
2337
+ "type": "string",
2338
+ "required": true
2339
+ },
2340
+ "shareCount": {
2341
+ "type": "integer",
2342
+ "required": true
2343
+ },
2344
+ "parValue": {
2345
+ "type": "number",
2346
+ "required": true
2347
+ },
2348
+ "authorizedDate": {
2349
+ "type": "string",
2350
+ "format": "date",
2351
+ "required": true
2352
+ },
2353
+ "charterProvision": {
2354
+ "type": "string"
2355
+ }
2356
+ }
2357
+ },
2358
+ "effects": [
2359
+ {
2360
+ "type": "SET_CONTEXT",
2361
+ "path": "securityId",
2362
+ "value": "{{ event.securityId }}"
2363
+ },
2364
+ {
2365
+ "type": "SET_CONTEXT",
2366
+ "path": "entityId",
2367
+ "value": "{{ event.entityId }}"
2368
+ },
2369
+ {
2370
+ "type": "SET_CONTEXT",
2371
+ "path": "shareClass",
2372
+ "value": "{{ event.shareClass }}"
2373
+ },
2374
+ {
2375
+ "type": "SET_CONTEXT",
2376
+ "path": "shareClassName",
2377
+ "value": "{{ event.shareClassName }}"
2378
+ },
2379
+ {
2380
+ "type": "SET_CONTEXT",
2381
+ "path": "shareCount",
2382
+ "value": "{{ event.shareCount }}"
2383
+ },
2384
+ {
2385
+ "type": "SET_CONTEXT",
2386
+ "path": "parValue",
2387
+ "value": "{{ event.parValue }}"
2388
+ },
2389
+ {
2390
+ "type": "SET_CONTEXT",
2391
+ "path": "authorization",
2392
+ "value": {
2393
+ "authorizedDate": "{{ event.authorizedDate }}",
2394
+ "charterProvision": "{{ event.charterProvision }}",
2395
+ "authorizedShares": "{{ event.shareCount }}"
2396
+ }
2397
+ },
2398
+ {
2399
+ "type": "SET_CONTEXT",
2400
+ "path": "transferHistory",
2401
+ "value": []
2402
+ },
2403
+ {
2404
+ "type": "SET_CONTEXT",
2405
+ "path": "corporateActions",
2406
+ "value": []
2407
+ }
2408
+ ]
2409
+ },
2410
+ "issue_shares": {
2411
+ "from": "AUTHORIZED",
2412
+ "to": "ISSUED",
2413
+ "description": "Issue shares to a holder",
2414
+ "event": {
2415
+ "name": "issue_shares",
2416
+ "payload": {
2417
+ "holderId": {
2418
+ "type": "string",
2419
+ "required": true
2420
+ },
2421
+ "holderType": {
2422
+ "type": "string",
2423
+ "required": true
2424
+ },
2425
+ "holderName": {
2426
+ "type": "string",
2427
+ "required": true
2428
+ },
2429
+ "address": {
2430
+ "type": "object"
2431
+ },
2432
+ "issuanceDate": {
2433
+ "type": "string",
2434
+ "format": "date",
2435
+ "required": true
2436
+ },
2437
+ "issuancePrice": {
2438
+ "type": "number"
2439
+ },
2440
+ "form": {
2441
+ "type": "string",
2442
+ "enum": [
2443
+ "CERTIFICATED",
2444
+ "BOOK_ENTRY",
2445
+ "DRS"
2446
+ ],
2447
+ "required": true
2448
+ },
2449
+ "certificateNumber": {
2450
+ "type": "string"
2451
+ },
2452
+ "boardResolutionRef": {
2453
+ "type": "string",
2454
+ "required": true
2455
+ },
2456
+ "consideration": {
2457
+ "type": "object",
2458
+ "required": true
2459
+ },
2460
+ "isRestricted": {
2461
+ "type": "boolean",
2462
+ "default": false
2463
+ },
2464
+ "restrictionType": {
2465
+ "type": "array"
2466
+ },
2467
+ "legends": {
2468
+ "type": "array"
2469
+ },
2470
+ "exemptionUsed": {
2471
+ "type": "string"
2472
+ },
2473
+ "accreditedInvestor": {
2474
+ "type": "boolean"
2475
+ }
2476
+ }
2477
+ },
2478
+ "guards": [
2479
+ {
2480
+ "name": "hasIssuanceResolution",
2481
+ "description": "Board must have approved stock issuance",
2482
+ "crossMachine": {
2483
+ "machine": "corporate-resolution",
2484
+ "instanceRef": "{{ event.boardResolutionRef }}",
2485
+ "requiredState": "EXECUTED"
2486
+ }
2487
+ },
2488
+ {
2489
+ "name": "entityIsActive",
2490
+ "description": "Cannot issue stock if corporation is suspended or dissolved",
2491
+ "crossMachine": {
2492
+ "machine": "corporate-entity",
2493
+ "instanceRef": "{{ context.entityId }}",
2494
+ "requiredState": "ACTIVE"
2495
+ }
2496
+ }
2497
+ ],
2498
+ "effects": [
2499
+ {
2500
+ "type": "SET_CONTEXT",
2501
+ "path": "form",
2502
+ "value": "{{ event.form }}"
2503
+ },
2504
+ {
2505
+ "type": "SET_CONTEXT",
2506
+ "path": "certificateNumber",
2507
+ "value": "{{ event.certificateNumber }}"
2508
+ },
2509
+ {
2510
+ "type": "SET_CONTEXT",
2511
+ "path": "issuanceDate",
2512
+ "value": "{{ event.issuanceDate }}"
2513
+ },
2514
+ {
2515
+ "type": "SET_CONTEXT",
2516
+ "path": "issuancePrice",
2517
+ "value": "{{ event.issuancePrice }}"
2518
+ },
2519
+ {
2520
+ "type": "SET_CONTEXT",
2521
+ "path": "holder",
2522
+ "value": {
2523
+ "holderId": "{{ event.holderId }}",
2524
+ "holderType": "{{ event.holderType }}",
2525
+ "name": "{{ event.holderName }}",
2526
+ "address": "{{ event.address }}",
2527
+ "acquisitionDate": "{{ event.issuanceDate }}",
2528
+ "acquisitionMethod": "ORIGINAL_ISSUANCE",
2529
+ "costBasis": "{{ event.issuancePrice * context.shareCount }}"
2530
+ }
2531
+ },
2532
+ {
2533
+ "type": "SET_CONTEXT",
2534
+ "path": "restrictions",
2535
+ "value": {
2536
+ "isRestricted": "{{ event.isRestricted }}",
2537
+ "restrictionType": "{{ event.restrictionType }}",
2538
+ "legends": "{{ event.legends }}"
2539
+ }
2540
+ },
2541
+ {
2542
+ "type": "SET_CONTEXT",
2543
+ "path": "issuanceDetails",
2544
+ "value": {
2545
+ "boardResolutionRef": "{{ event.boardResolutionRef }}",
2546
+ "consideration": "{{ event.consideration }}",
2547
+ "exemptionUsed": "{{ event.exemptionUsed }}",
2548
+ "accreditedInvestor": "{{ event.accreditedInvestor }}"
2549
+ }
2550
+ },
2551
+ {
2552
+ "type": "EMIT_EVENT",
2553
+ "eventType": "SHARES_ISSUED",
2554
+ "payload": {
2555
+ "securityId": "{{ context.securityId }}",
2556
+ "entityId": "{{ context.entityId }}",
2557
+ "shareClass": "{{ context.shareClassName }}",
2558
+ "shares": "{{ context.shareCount }}",
2559
+ "holderId": "{{ event.holderId }}",
2560
+ "holderName": "{{ event.holderName }}"
2561
+ }
2562
+ }
2563
+ ]
2564
+ },
2565
+ "initiate_transfer": {
2566
+ "from": "ISSUED",
2567
+ "to": "TRANSFERRED",
2568
+ "description": "Begin transfer of shares to new holder",
2569
+ "event": {
2570
+ "name": "initiate_transfer",
2571
+ "payload": {
2572
+ "transferId": {
2573
+ "type": "string",
2574
+ "required": true
2575
+ },
2576
+ "toHolderId": {
2577
+ "type": "string",
2578
+ "required": true
2579
+ },
2580
+ "toHolderName": {
2581
+ "type": "string",
2582
+ "required": true
2583
+ },
2584
+ "toHolderType": {
2585
+ "type": "string",
2586
+ "required": true
2587
+ },
2588
+ "toAddress": {
2589
+ "type": "object"
2590
+ },
2591
+ "transferType": {
2592
+ "type": "string",
2593
+ "required": true
2594
+ },
2595
+ "pricePerShare": {
2596
+ "type": "number"
2597
+ },
2598
+ "transferDate": {
2599
+ "type": "string",
2600
+ "format": "date",
2601
+ "required": true
2602
+ }
2603
+ }
2604
+ },
2605
+ "guards": [
2606
+ {
2607
+ "name": "restrictionsCleared",
2608
+ "description": "Must clear any transfer restrictions",
2609
+ "expression": "!context.restrictions.isRestricted || context.restrictions.restrictionEndDate == null || new Date() >= new Date(context.restrictions.restrictionEndDate)"
2610
+ },
2611
+ {
2612
+ "name": "rofrSatisfied",
2613
+ "description": "Right of first refusal must be waived or expired",
2614
+ "expression": "context.restrictions.rofr == null"
2615
+ }
2616
+ ],
2617
+ "effects": [
2618
+ {
2619
+ "type": "APPEND_ARRAY",
2620
+ "path": "transferHistory",
2621
+ "value": {
2622
+ "transferId": "{{ event.transferId }}",
2623
+ "transferDate": "{{ event.transferDate }}",
2624
+ "fromHolderId": "{{ context.holder.holderId }}",
2625
+ "toHolderId": "{{ event.toHolderId }}",
2626
+ "shares": "{{ context.shareCount }}",
2627
+ "transferType": "{{ event.transferType }}",
2628
+ "pricePerShare": "{{ event.pricePerShare }}"
2629
+ }
2630
+ },
2631
+ {
2632
+ "type": "EMIT_EVENT",
2633
+ "eventType": "TRANSFER_INITIATED",
2634
+ "payload": {
2635
+ "securityId": "{{ context.securityId }}",
2636
+ "transferId": "{{ event.transferId }}",
2637
+ "fromHolderId": "{{ context.holder.holderId }}",
2638
+ "toHolderId": "{{ event.toHolderId }}"
2639
+ }
2640
+ }
2641
+ ]
2642
+ },
2643
+ "complete_transfer": {
2644
+ "from": "TRANSFERRED",
2645
+ "to": "ISSUED",
2646
+ "description": "Complete the transfer, update holder",
2647
+ "event": {
2648
+ "name": "complete_transfer",
2649
+ "payload": {
2650
+ "transferAgentConfirmation": {
2651
+ "type": "string"
2652
+ },
2653
+ "newCertificateNumber": {
2654
+ "type": "string"
2655
+ },
2656
+ "toHolderId": {
2657
+ "type": "string",
2658
+ "required": true
2659
+ },
2660
+ "toHolderName": {
2661
+ "type": "string",
2662
+ "required": true
2663
+ },
2664
+ "toHolderType": {
2665
+ "type": "string",
2666
+ "required": true
2667
+ },
2668
+ "toAddress": {
2669
+ "type": "object"
2670
+ },
2671
+ "completedDate": {
2672
+ "type": "string",
2673
+ "format": "date",
2674
+ "required": true
2675
+ },
2676
+ "costBasis": {
2677
+ "type": "number"
2678
+ }
2679
+ }
2680
+ },
2681
+ "effects": [
2682
+ {
2683
+ "type": "SET_CONTEXT",
2684
+ "path": "holder",
2685
+ "value": {
2686
+ "holderId": "{{ event.toHolderId }}",
2687
+ "holderType": "{{ event.toHolderType }}",
2688
+ "name": "{{ event.toHolderName }}",
2689
+ "address": "{{ event.toAddress }}",
2690
+ "acquisitionDate": "{{ event.completedDate }}",
2691
+ "acquisitionMethod": "PURCHASE",
2692
+ "costBasis": "{{ event.costBasis }}"
2693
+ }
2694
+ },
2695
+ {
2696
+ "type": "CONDITIONAL",
2697
+ "condition": "event.newCertificateNumber != null",
2698
+ "then": {
2699
+ "type": "SET_CONTEXT",
2700
+ "path": "certificateNumber",
2701
+ "value": "{{ event.newCertificateNumber }}"
2702
+ }
2703
+ },
2704
+ {
2705
+ "type": "UPDATE_ARRAY_ITEM",
2706
+ "path": "transferHistory",
2707
+ "matchKey": "toHolderId",
2708
+ "matchValue": "{{ event.toHolderId }}",
2709
+ "updates": {
2710
+ "transferAgentConfirmation": "{{ event.transferAgentConfirmation }}"
2711
+ }
2712
+ },
2713
+ {
2714
+ "type": "EMIT_EVENT",
2715
+ "eventType": "TRANSFER_COMPLETED",
2716
+ "payload": {
2717
+ "securityId": "{{ context.securityId }}",
2718
+ "newHolderId": "{{ event.toHolderId }}"
2719
+ }
2720
+ }
2721
+ ]
2722
+ },
2723
+ "repurchase": {
2724
+ "from": "ISSUED",
2725
+ "to": "TREASURY",
2726
+ "description": "Company repurchases shares from holder",
2727
+ "event": {
2728
+ "name": "repurchase",
2729
+ "payload": {
2730
+ "repurchaseDate": {
2731
+ "type": "string",
2732
+ "format": "date",
2733
+ "required": true
2734
+ },
2735
+ "pricePerShare": {
2736
+ "type": "number",
2737
+ "required": true
2738
+ },
2739
+ "boardResolutionRef": {
2740
+ "type": "string",
2741
+ "required": true
2742
+ },
2743
+ "repurchaseAgreementRef": {
2744
+ "type": "string"
2745
+ }
2746
+ }
2747
+ },
2748
+ "guards": [
2749
+ {
2750
+ "name": "hasRepurchaseResolution",
2751
+ "crossMachine": {
2752
+ "machine": "corporate-resolution",
2753
+ "instanceRef": "{{ event.boardResolutionRef }}",
2754
+ "requiredState": "EXECUTED"
2755
+ }
2756
+ }
2757
+ ],
2758
+ "effects": [
2759
+ {
2760
+ "type": "APPEND_ARRAY",
2761
+ "path": "transferHistory",
2762
+ "value": {
2763
+ "transferId": "REPURCHASE-{{ event.repurchaseDate }}",
2764
+ "transferDate": "{{ event.repurchaseDate }}",
2765
+ "fromHolderId": "{{ context.holder.holderId }}",
2766
+ "toHolderId": "TREASURY",
2767
+ "shares": "{{ context.shareCount }}",
2768
+ "transferType": "INTERNAL",
2769
+ "pricePerShare": "{{ event.pricePerShare }}"
2770
+ }
2771
+ },
2772
+ {
2773
+ "type": "SET_CONTEXT",
2774
+ "path": "holder",
2775
+ "value": {
2776
+ "holderId": "TREASURY",
2777
+ "holderType": "TREASURY",
2778
+ "name": "Treasury Stock",
2779
+ "acquisitionDate": "{{ event.repurchaseDate }}",
2780
+ "acquisitionMethod": "PURCHASE",
2781
+ "costBasis": "{{ event.pricePerShare * context.shareCount }}"
2782
+ }
2783
+ },
2784
+ {
2785
+ "type": "EMIT_EVENT",
2786
+ "eventType": "SHARES_REPURCHASED",
2787
+ "payload": {
2788
+ "securityId": "{{ context.securityId }}",
2789
+ "shares": "{{ context.shareCount }}",
2790
+ "pricePerShare": "{{ event.pricePerShare }}"
2791
+ }
2792
+ }
2793
+ ]
2794
+ },
2795
+ "reissue_from_treasury": {
2796
+ "from": "TREASURY",
2797
+ "to": "ISSUED",
2798
+ "description": "Reissue treasury shares to a new holder",
2799
+ "event": {
2800
+ "name": "reissue_from_treasury",
2801
+ "payload": {
2802
+ "holderId": {
2803
+ "type": "string",
2804
+ "required": true
2805
+ },
2806
+ "holderName": {
2807
+ "type": "string",
2808
+ "required": true
2809
+ },
2810
+ "holderType": {
2811
+ "type": "string",
2812
+ "required": true
2813
+ },
2814
+ "address": {
2815
+ "type": "object"
2816
+ },
2817
+ "reissueDate": {
2818
+ "type": "string",
2819
+ "format": "date",
2820
+ "required": true
2821
+ },
2822
+ "issuancePrice": {
2823
+ "type": "number"
2824
+ },
2825
+ "boardResolutionRef": {
2826
+ "type": "string",
2827
+ "required": true
2828
+ }
2829
+ }
2830
+ },
2831
+ "guards": [
2832
+ {
2833
+ "name": "hasReissueResolution",
2834
+ "crossMachine": {
2835
+ "machine": "corporate-resolution",
2836
+ "instanceRef": "{{ event.boardResolutionRef }}",
2837
+ "requiredState": "EXECUTED"
2838
+ }
2839
+ }
2840
+ ],
2841
+ "effects": [
2842
+ {
2843
+ "type": "SET_CONTEXT",
2844
+ "path": "holder",
2845
+ "value": {
2846
+ "holderId": "{{ event.holderId }}",
2847
+ "holderType": "{{ event.holderType }}",
2848
+ "name": "{{ event.holderName }}",
2849
+ "address": "{{ event.address }}",
2850
+ "acquisitionDate": "{{ event.reissueDate }}",
2851
+ "acquisitionMethod": "PURCHASE",
2852
+ "costBasis": "{{ event.issuancePrice * context.shareCount }}"
2853
+ }
2854
+ },
2855
+ {
2856
+ "type": "EMIT_EVENT",
2857
+ "eventType": "TREASURY_SHARES_REISSUED",
2858
+ "payload": {
2859
+ "securityId": "{{ context.securityId }}",
2860
+ "holderId": "{{ event.holderId }}"
2861
+ }
2862
+ }
2863
+ ]
2864
+ },
2865
+ "retire": {
2866
+ "from": [
2867
+ "ISSUED",
2868
+ "TREASURY"
2869
+ ],
2870
+ "to": "RETIRED",
2871
+ "description": "Retire shares (cancel them)",
2872
+ "event": {
2873
+ "name": "retire",
2874
+ "payload": {
2875
+ "retiredDate": {
2876
+ "type": "string",
2877
+ "format": "date",
2878
+ "required": true
2879
+ },
2880
+ "retirementMethod": {
2881
+ "type": "string",
2882
+ "required": true
2883
+ },
2884
+ "boardResolutionRef": {
2885
+ "type": "string",
2886
+ "required": true
2887
+ },
2888
+ "repurchasePrice": {
2889
+ "type": "number"
2890
+ }
2891
+ }
2892
+ },
2893
+ "guards": [
2894
+ {
2895
+ "name": "hasRetirementResolution",
2896
+ "crossMachine": {
2897
+ "machine": "corporate-resolution",
2898
+ "instanceRef": "{{ event.boardResolutionRef }}",
2899
+ "requiredState": "EXECUTED"
2900
+ }
2901
+ }
2902
+ ],
2903
+ "effects": [
2904
+ {
2905
+ "type": "SET_CONTEXT",
2906
+ "path": "retirementDetails",
2907
+ "value": {
2908
+ "retiredDate": "{{ event.retiredDate }}",
2909
+ "retirementMethod": "{{ event.retirementMethod }}",
2910
+ "repurchasePrice": "{{ event.repurchasePrice }}",
2911
+ "boardResolutionRef": "{{ event.boardResolutionRef }}"
2912
+ }
2913
+ },
2914
+ {
2915
+ "type": "SET_CONTEXT",
2916
+ "path": "holder",
2917
+ "value": null
2918
+ },
2919
+ {
2920
+ "type": "EMIT_EVENT",
2921
+ "eventType": "SHARES_RETIRED",
2922
+ "payload": {
2923
+ "securityId": "{{ context.securityId }}",
2924
+ "shareClass": "{{ context.shareClassName }}",
2925
+ "shares": "{{ context.shareCount }}"
2926
+ }
2927
+ }
2928
+ ]
2929
+ },
2930
+ "stock_split": {
2931
+ "from": "ISSUED",
2932
+ "to": "ISSUED",
2933
+ "description": "Apply stock split to this lot",
2934
+ "event": {
2935
+ "name": "stock_split",
2936
+ "payload": {
2937
+ "actionId": {
2938
+ "type": "string",
2939
+ "required": true
2940
+ },
2941
+ "splitRatio": {
2942
+ "type": "string",
2943
+ "required": true,
2944
+ "description": "e.g., '2:1' for 2-for-1 split"
2945
+ },
2946
+ "effectiveDate": {
2947
+ "type": "string",
2948
+ "format": "date",
2949
+ "required": true
2950
+ },
2951
+ "resolutionRef": {
2952
+ "type": "string",
2953
+ "required": true
2954
+ },
2955
+ "newShareCount": {
2956
+ "type": "integer",
2957
+ "required": true
2958
+ }
2959
+ }
2960
+ },
2961
+ "effects": [
2962
+ {
2963
+ "type": "APPEND_ARRAY",
2964
+ "path": "corporateActions",
2965
+ "value": {
2966
+ "actionId": "{{ event.actionId }}",
2967
+ "actionType": "STOCK_SPLIT",
2968
+ "actionDate": "{{ event.effectiveDate }}",
2969
+ "ratio": "{{ event.splitRatio }}",
2970
+ "sharesBeforeAction": "{{ context.shareCount }}",
2971
+ "sharesAfterAction": "{{ event.newShareCount }}",
2972
+ "resolutionRef": "{{ event.resolutionRef }}"
2973
+ }
2974
+ },
2975
+ {
2976
+ "type": "SET_CONTEXT",
2977
+ "path": "shareCount",
2978
+ "value": "{{ event.newShareCount }}"
2979
+ },
2980
+ {
2981
+ "type": "EMIT_EVENT",
2982
+ "eventType": "STOCK_SPLIT_APPLIED",
2983
+ "payload": {
2984
+ "securityId": "{{ context.securityId }}",
2985
+ "ratio": "{{ event.splitRatio }}",
2986
+ "newShareCount": "{{ event.newShareCount }}"
2987
+ }
2988
+ }
2989
+ ]
2990
+ },
2991
+ "declare_dividend": {
2992
+ "from": "ISSUED",
2993
+ "to": "ISSUED",
2994
+ "description": "Record dividend declaration affecting this lot (for stock dividends)",
2995
+ "event": {
2996
+ "name": "declare_dividend",
2997
+ "payload": {
2998
+ "actionId": {
2999
+ "type": "string",
3000
+ "required": true
3001
+ },
3002
+ "dividendType": {
3003
+ "type": "string",
3004
+ "enum": [
3005
+ "CASH",
3006
+ "STOCK"
3007
+ ],
3008
+ "required": true
3009
+ },
3010
+ "recordDate": {
3011
+ "type": "string",
3012
+ "format": "date",
3013
+ "required": true
3014
+ },
3015
+ "paymentDate": {
3016
+ "type": "string",
3017
+ "format": "date",
3018
+ "required": true
3019
+ },
3020
+ "cashAmount": {
3021
+ "type": "number"
3022
+ },
3023
+ "stockShares": {
3024
+ "type": "integer"
3025
+ },
3026
+ "resolutionRef": {
3027
+ "type": "string",
3028
+ "required": true
3029
+ }
3030
+ }
3031
+ },
3032
+ "guards": [
3033
+ {
3034
+ "name": "hasDividendResolution",
3035
+ "crossMachine": {
3036
+ "machine": "corporate-resolution",
3037
+ "instanceRef": "{{ event.resolutionRef }}",
3038
+ "requiredState": "EXECUTED"
3039
+ }
3040
+ }
3041
+ ],
3042
+ "effects": [
3043
+ {
3044
+ "type": "CONDITIONAL",
3045
+ "condition": "event.dividendType === 'STOCK'",
3046
+ "then": {
3047
+ "type": "APPEND_ARRAY",
3048
+ "path": "corporateActions",
3049
+ "value": {
3050
+ "actionId": "{{ event.actionId }}",
3051
+ "actionType": "STOCK_DIVIDEND",
3052
+ "actionDate": "{{ event.paymentDate }}",
3053
+ "sharesBeforeAction": "{{ context.shareCount }}",
3054
+ "sharesAfterAction": "{{ context.shareCount + event.stockShares }}",
3055
+ "resolutionRef": "{{ event.resolutionRef }}"
3056
+ }
3057
+ }
3058
+ },
3059
+ {
3060
+ "type": "CONDITIONAL",
3061
+ "condition": "event.dividendType === 'STOCK'",
3062
+ "then": {
3063
+ "type": "INCREMENT",
3064
+ "path": "shareCount",
3065
+ "amount": "{{ event.stockShares }}"
3066
+ }
3067
+ }
3068
+ ]
3069
+ },
3070
+ "remove_restriction": {
3071
+ "from": "ISSUED",
3072
+ "to": "ISSUED",
3073
+ "description": "Remove or update restrictions on the shares",
3074
+ "event": {
3075
+ "name": "remove_restriction",
3076
+ "payload": {
3077
+ "restrictionType": {
3078
+ "type": "string",
3079
+ "required": true
3080
+ },
3081
+ "removedDate": {
3082
+ "type": "string",
3083
+ "format": "date",
3084
+ "required": true
3085
+ },
3086
+ "reason": {
3087
+ "type": "string"
3088
+ },
3089
+ "legalOpinionRef": {
3090
+ "type": "string"
3091
+ }
3092
+ }
3093
+ },
3094
+ "effects": [
3095
+ {
3096
+ "type": "UPDATE_ARRAY",
3097
+ "path": "restrictions.restrictionType",
3098
+ "operation": "REMOVE",
3099
+ "value": "{{ event.restrictionType }}"
3100
+ },
3101
+ {
3102
+ "type": "COMPUTE",
3103
+ "path": "restrictions.isRestricted",
3104
+ "expression": "context.restrictions.restrictionType.length > 0"
3105
+ },
3106
+ {
3107
+ "type": "EMIT_EVENT",
3108
+ "eventType": "RESTRICTION_REMOVED",
3109
+ "payload": {
3110
+ "securityId": "{{ context.securityId }}",
3111
+ "restrictionType": "{{ event.restrictionType }}"
3112
+ }
3113
+ }
3114
+ ]
3115
+ }
3116
+ },
3117
+ "crossMachineRefs": {
3118
+ "entity": {
3119
+ "machine": "corporate-entity",
3120
+ "description": "Parent corporate entity with share class definitions",
3121
+ "foreignKey": "entityId"
3122
+ },
3123
+ "resolutions": {
3124
+ "machine": "corporate-resolution",
3125
+ "description": "Board resolutions authorizing securities actions",
3126
+ "foreignKey": "entityId"
3127
+ },
3128
+ "shareholders": {
3129
+ "machine": "corporate-shareholders",
3130
+ "description": "Shareholder meetings for determining voting rights",
3131
+ "foreignKey": "entityId"
3132
+ }
3133
+ },
3134
+ "metadata": {
3135
+ "author": "OttoChain",
3136
+ "license": "MIT",
3137
+ "tags": [
3138
+ "corporate",
3139
+ "governance",
3140
+ "securities",
3141
+ "stock",
3142
+ "equity",
3143
+ "certificates"
3144
+ ],
3145
+ "documentation": "https://ottochain.dev/docs/corporate/securities"
3146
+ }
3147
+ };
3148
+ exports.corpShareholdersDef = {
3149
+ "$schema": "https://ottochain.dev/schemas/state-machine-v1.json",
3150
+ "name": "CorpShareholders",
3151
+ "version": "1.0.0",
3152
+ "category": "corporate-governance",
3153
+ "description": "Shareholder meeting state machine managing annual/special meetings, record dates, proxy periods, voting, and certification of results. Supports multiple share classes and cumulative voting.",
3154
+ "context": {
3155
+ "meetingId": {
3156
+ "type": "string",
3157
+ "description": "Unique identifier for this shareholder meeting"
3158
+ },
3159
+ "entityId": {
3160
+ "type": "string",
3161
+ "description": "Reference to parent corporate-entity"
3162
+ },
3163
+ "meetingType": {
3164
+ "type": "string",
3165
+ "enum": [
3166
+ "ANNUAL",
3167
+ "SPECIAL"
3168
+ ],
3169
+ "description": "Annual meetings are required; special meetings called for specific purposes"
3170
+ },
3171
+ "fiscalYear": {
3172
+ "type": "integer",
3173
+ "description": "Fiscal year for annual meetings"
3174
+ },
3175
+ "scheduledDate": {
3176
+ "type": "string",
3177
+ "format": "date-time"
3178
+ },
3179
+ "location": {
3180
+ "type": "object",
3181
+ "properties": {
3182
+ "physical": {
3183
+ "type": "string",
3184
+ "nullable": true
3185
+ },
3186
+ "virtualUrl": {
3187
+ "type": "string",
3188
+ "nullable": true
3189
+ },
3190
+ "isHybrid": {
3191
+ "type": "boolean",
3192
+ "default": false
3193
+ }
3194
+ }
3195
+ },
3196
+ "calledBy": {
3197
+ "type": "object",
3198
+ "properties": {
3199
+ "type": {
3200
+ "type": "string",
3201
+ "enum": [
3202
+ "BOARD",
3203
+ "SHAREHOLDERS",
3204
+ "COURT"
3205
+ ]
3206
+ },
3207
+ "resolutionRef": {
3208
+ "type": "string",
3209
+ "nullable": true
3210
+ },
3211
+ "shareholderPetitionRef": {
3212
+ "type": "string",
3213
+ "nullable": true
3214
+ },
3215
+ "courtOrderRef": {
3216
+ "type": "string",
3217
+ "nullable": true
3218
+ }
3219
+ }
3220
+ },
3221
+ "noticeInfo": {
3222
+ "type": "object",
3223
+ "properties": {
3224
+ "noticeSentDate": {
3225
+ "type": "string",
3226
+ "format": "date"
3227
+ },
3228
+ "noticeMethod": {
3229
+ "type": "string",
3230
+ "enum": [
3231
+ "MAIL",
3232
+ "EMAIL",
3233
+ "ELECTRONIC_ACCESS"
3234
+ ]
3235
+ },
3236
+ "minimumNoticeDays": {
3237
+ "type": "integer",
3238
+ "default": 10
3239
+ },
3240
+ "maximumNoticeDays": {
3241
+ "type": "integer",
3242
+ "default": 60
3243
+ }
3244
+ }
3245
+ },
3246
+ "recordDate": {
3247
+ "type": "object",
3248
+ "nullable": true,
3249
+ "properties": {
3250
+ "date": {
3251
+ "type": "string",
3252
+ "format": "date"
3253
+ },
3254
+ "setByBoardOn": {
3255
+ "type": "string",
3256
+ "format": "date"
3257
+ },
3258
+ "resolutionRef": {
3259
+ "type": "string"
3260
+ }
3261
+ }
3262
+ },
3263
+ "eligibleVoters": {
3264
+ "type": "array",
3265
+ "description": "Shareholders as of record date with their share counts",
3266
+ "items": {
3267
+ "type": "object",
3268
+ "properties": {
3269
+ "shareholderId": {
3270
+ "type": "string"
3271
+ },
3272
+ "name": {
3273
+ "type": "string"
3274
+ },
3275
+ "shareholdings": {
3276
+ "type": "array",
3277
+ "items": {
3278
+ "type": "object",
3279
+ "properties": {
3280
+ "shareClass": {
3281
+ "type": "string"
3282
+ },
3283
+ "shares": {
3284
+ "type": "integer"
3285
+ },
3286
+ "votes": {
3287
+ "type": "integer",
3288
+ "description": "Votes this holding represents"
3289
+ }
3290
+ }
3291
+ }
3292
+ },
3293
+ "totalVotes": {
3294
+ "type": "integer"
3295
+ },
3296
+ "proxyGrantedTo": {
3297
+ "type": "string",
3298
+ "nullable": true,
3299
+ "description": "Proxy holder ID if proxied"
3300
+ },
3301
+ "hasVoted": {
3302
+ "type": "boolean",
3303
+ "default": false
3304
+ }
3305
+ }
3306
+ }
3307
+ },
3308
+ "quorumRequirements": {
3309
+ "type": "object",
3310
+ "properties": {
3311
+ "type": {
3312
+ "type": "string",
3313
+ "enum": [
3314
+ "SHARES_REPRESENTED",
3315
+ "SHARES_OUTSTANDING"
3316
+ ]
3317
+ },
3318
+ "threshold": {
3319
+ "type": "number",
3320
+ "default": 0.5,
3321
+ "description": "Fraction required for quorum"
3322
+ },
3323
+ "sharesRequired": {
3324
+ "type": "integer"
3325
+ },
3326
+ "sharesRepresented": {
3327
+ "type": "integer",
3328
+ "default": 0
3329
+ },
3330
+ "quorumMet": {
3331
+ "type": "boolean",
3332
+ "default": false
3333
+ }
3334
+ }
3335
+ },
3336
+ "agenda": {
3337
+ "type": "array",
3338
+ "items": {
3339
+ "type": "object",
3340
+ "properties": {
3341
+ "itemId": {
3342
+ "type": "string"
3343
+ },
3344
+ "itemNumber": {
3345
+ "type": "integer"
3346
+ },
3347
+ "title": {
3348
+ "type": "string"
3349
+ },
3350
+ "description": {
3351
+ "type": "string"
3352
+ },
3353
+ "type": {
3354
+ "type": "string",
3355
+ "enum": [
3356
+ "DIRECTOR_ELECTION",
3357
+ "AUDITOR_RATIFICATION",
3358
+ "SAY_ON_PAY",
3359
+ "CHARTER_AMENDMENT",
3360
+ "MERGER",
3361
+ "STOCK_PLAN",
3362
+ "SHAREHOLDER_PROPOSAL",
3363
+ "OTHER"
3364
+ ]
3365
+ },
3366
+ "voteRequired": {
3367
+ "type": "string",
3368
+ "enum": [
3369
+ "PLURALITY",
3370
+ "MAJORITY_CAST",
3371
+ "MAJORITY_OUTSTANDING",
3372
+ "SUPERMAJORITY",
3373
+ "UNANIMOUS"
3374
+ ],
3375
+ "description": "Vote threshold for approval"
3376
+ },
3377
+ "supermajorityThreshold": {
3378
+ "type": "number",
3379
+ "nullable": true
3380
+ },
3381
+ "eligibleClasses": {
3382
+ "type": "array",
3383
+ "items": {
3384
+ "type": "string"
3385
+ },
3386
+ "description": "Share classes that can vote on this item"
3387
+ },
3388
+ "allowCumulativeVoting": {
3389
+ "type": "boolean",
3390
+ "default": false,
3391
+ "description": "For director elections"
3392
+ },
3393
+ "status": {
3394
+ "type": "string",
3395
+ "enum": [
3396
+ "PENDING",
3397
+ "VOTING",
3398
+ "CLOSED",
3399
+ "APPROVED",
3400
+ "REJECTED"
3401
+ ]
3402
+ }
3403
+ }
3404
+ }
3405
+ },
3406
+ "proxyPeriod": {
3407
+ "type": "object",
3408
+ "nullable": true,
3409
+ "properties": {
3410
+ "startDate": {
3411
+ "type": "string",
3412
+ "format": "date"
3413
+ },
3414
+ "endDate": {
3415
+ "type": "string",
3416
+ "format": "date-time",
3417
+ "description": "Usually meeting start time"
3418
+ },
3419
+ "proxyMaterials": {
3420
+ "type": "object",
3421
+ "properties": {
3422
+ "proxyStatementRef": {
3423
+ "type": "string"
3424
+ },
3425
+ "formOfProxyRef": {
3426
+ "type": "string"
3427
+ },
3428
+ "annualReportRef": {
3429
+ "type": "string",
3430
+ "nullable": true
3431
+ }
3432
+ }
3433
+ }
3434
+ }
3435
+ },
3436
+ "votes": {
3437
+ "type": "array",
3438
+ "items": {
3439
+ "type": "object",
3440
+ "properties": {
3441
+ "voteId": {
3442
+ "type": "string"
3443
+ },
3444
+ "agendaItemId": {
3445
+ "type": "string"
3446
+ },
3447
+ "voterId": {
3448
+ "type": "string",
3449
+ "description": "Shareholder or proxy holder ID"
3450
+ },
3451
+ "shareholderId": {
3452
+ "type": "string",
3453
+ "description": "Beneficial owner"
3454
+ },
3455
+ "shareClass": {
3456
+ "type": "string"
3457
+ },
3458
+ "votesFor": {
3459
+ "type": "integer",
3460
+ "default": 0
3461
+ },
3462
+ "votesAgainst": {
3463
+ "type": "integer",
3464
+ "default": 0
3465
+ },
3466
+ "votesAbstain": {
3467
+ "type": "integer",
3468
+ "default": 0
3469
+ },
3470
+ "votesWithhold": {
3471
+ "type": "integer",
3472
+ "default": 0,
3473
+ "description": "For director elections"
3474
+ },
3475
+ "cumulativeVoteAllocation": {
3476
+ "type": "object",
3477
+ "additionalProperties": {
3478
+ "type": "integer"
3479
+ },
3480
+ "nullable": true,
3481
+ "description": "For cumulative voting: candidate ID -> votes allocated"
3482
+ },
3483
+ "viaProxy": {
3484
+ "type": "boolean",
3485
+ "default": false
3486
+ },
3487
+ "timestamp": {
3488
+ "type": "string",
3489
+ "format": "date-time"
3490
+ }
3491
+ }
3492
+ }
3493
+ },
3494
+ "voteTallies": {
3495
+ "type": "array",
3496
+ "items": {
3497
+ "type": "object",
3498
+ "properties": {
3499
+ "agendaItemId": {
3500
+ "type": "string"
3501
+ },
3502
+ "forVotes": {
3503
+ "type": "integer",
3504
+ "default": 0
3505
+ },
3506
+ "againstVotes": {
3507
+ "type": "integer",
3508
+ "default": 0
3509
+ },
3510
+ "abstainVotes": {
3511
+ "type": "integer",
3512
+ "default": 0
3513
+ },
3514
+ "withholdVotes": {
3515
+ "type": "integer",
3516
+ "default": 0
3517
+ },
3518
+ "brokerNonVotes": {
3519
+ "type": "integer",
3520
+ "default": 0
3521
+ },
3522
+ "candidateVotes": {
3523
+ "type": "object",
3524
+ "additionalProperties": {
3525
+ "type": "integer"
3526
+ },
3527
+ "nullable": true,
3528
+ "description": "For director elections: candidate ID -> total votes"
3529
+ },
3530
+ "result": {
3531
+ "type": "string",
3532
+ "enum": [
3533
+ "APPROVED",
3534
+ "REJECTED",
3535
+ "PENDING"
3536
+ ]
3537
+ },
3538
+ "certified": {
3539
+ "type": "boolean",
3540
+ "default": false
3541
+ }
3542
+ }
3543
+ }
3544
+ },
3545
+ "inspectorOfElections": {
3546
+ "type": "object",
3547
+ "nullable": true,
3548
+ "properties": {
3549
+ "name": {
3550
+ "type": "string"
3551
+ },
3552
+ "company": {
3553
+ "type": "string",
3554
+ "nullable": true
3555
+ },
3556
+ "appointedBy": {
3557
+ "type": "string"
3558
+ },
3559
+ "appointmentDate": {
3560
+ "type": "string",
3561
+ "format": "date"
3562
+ }
3563
+ }
3564
+ },
3565
+ "sessionInfo": {
3566
+ "type": "object",
3567
+ "nullable": true,
3568
+ "properties": {
3569
+ "openedAt": {
3570
+ "type": "string",
3571
+ "format": "date-time"
3572
+ },
3573
+ "chairPerson": {
3574
+ "type": "string"
3575
+ },
3576
+ "secretaryPresent": {
3577
+ "type": "string"
3578
+ },
3579
+ "pollsOpenedAt": {
3580
+ "type": "string",
3581
+ "format": "date-time",
3582
+ "nullable": true
3583
+ },
3584
+ "pollsClosedAt": {
3585
+ "type": "string",
3586
+ "format": "date-time",
3587
+ "nullable": true
3588
+ },
3589
+ "adjournedAt": {
3590
+ "type": "string",
3591
+ "format": "date-time",
3592
+ "nullable": true
3593
+ },
3594
+ "minutesRef": {
3595
+ "type": "string",
3596
+ "nullable": true
3597
+ }
3598
+ }
3599
+ },
3600
+ "certification": {
3601
+ "type": "object",
3602
+ "nullable": true,
3603
+ "properties": {
3604
+ "certifiedAt": {
3605
+ "type": "string",
3606
+ "format": "date-time"
3607
+ },
3608
+ "certifiedBy": {
3609
+ "type": "string"
3610
+ },
3611
+ "certificateRef": {
3612
+ "type": "string"
3613
+ }
3614
+ }
3615
+ },
3616
+ "createdAt": {
3617
+ "type": "string",
3618
+ "format": "date-time"
3619
+ },
3620
+ "updatedAt": {
3621
+ "type": "string",
3622
+ "format": "date-time"
3623
+ }
3624
+ },
3625
+ "states": {
3626
+ "SCHEDULED": {
3627
+ "description": "Meeting has been scheduled but record date not yet set",
3628
+ "metadata": null
3629
+ },
3630
+ "RECORD_DATE_SET": {
3631
+ "description": "Record date established; eligible shareholders determined",
3632
+ "metadata": null
3633
+ },
3634
+ "PROXY_PERIOD": {
3635
+ "description": "Proxy materials distributed; shareholders may submit proxies",
3636
+ "metadata": null
3637
+ },
3638
+ "IN_SESSION": {
3639
+ "description": "Meeting is convened and in progress",
3640
+ "metadata": null
3641
+ },
3642
+ "VOTING": {
3643
+ "description": "Polls are open for voting on agenda items",
3644
+ "metadata": null
3645
+ },
3646
+ "CLOSED": {
3647
+ "description": "Meeting concluded; results certified",
3648
+ "metadata": null,
3649
+ "terminal": true
3650
+ }
3651
+ },
3652
+ "initialState": "SCHEDULED",
3653
+ "transitions": {
3654
+ "schedule_annual": {
3655
+ "from": null,
3656
+ "to": "SCHEDULED",
3657
+ "description": "Schedule an annual shareholder meeting",
3658
+ "event": {
3659
+ "name": "schedule_annual",
3660
+ "payload": {
3661
+ "meetingId": {
3662
+ "type": "string",
3663
+ "required": true
3664
+ },
3665
+ "entityId": {
3666
+ "type": "string",
3667
+ "required": true
3668
+ },
3669
+ "fiscalYear": {
3670
+ "type": "integer",
3671
+ "required": true
3672
+ },
3673
+ "scheduledDate": {
3674
+ "type": "string",
3675
+ "format": "date-time",
3676
+ "required": true
3677
+ },
3678
+ "location": {
3679
+ "type": "object"
3680
+ },
3681
+ "boardResolutionRef": {
3682
+ "type": "string",
3683
+ "required": true
3684
+ }
3685
+ }
3686
+ },
3687
+ "guards": [
3688
+ {
3689
+ "name": "boardApproved",
3690
+ "crossMachine": {
3691
+ "machine": "corporate-resolution",
3692
+ "instanceRef": "{{ event.boardResolutionRef }}",
3693
+ "requiredState": "EXECUTED"
3694
+ }
3695
+ }
3696
+ ],
3697
+ "effects": [
3698
+ {
3699
+ "type": "SET_CONTEXT",
3700
+ "path": "meetingId",
3701
+ "value": "{{ event.meetingId }}"
3702
+ },
3703
+ {
3704
+ "type": "SET_CONTEXT",
3705
+ "path": "entityId",
3706
+ "value": "{{ event.entityId }}"
3707
+ },
3708
+ {
3709
+ "type": "SET_CONTEXT",
3710
+ "path": "meetingType",
3711
+ "value": "ANNUAL"
3712
+ },
3713
+ {
3714
+ "type": "SET_CONTEXT",
3715
+ "path": "fiscalYear",
3716
+ "value": "{{ event.fiscalYear }}"
3717
+ },
3718
+ {
3719
+ "type": "SET_CONTEXT",
3720
+ "path": "scheduledDate",
3721
+ "value": "{{ event.scheduledDate }}"
3722
+ },
3723
+ {
3724
+ "type": "SET_CONTEXT",
3725
+ "path": "location",
3726
+ "value": "{{ event.location }}"
3727
+ },
3728
+ {
3729
+ "type": "SET_CONTEXT",
3730
+ "path": "calledBy",
3731
+ "value": {
3732
+ "type": "BOARD",
3733
+ "resolutionRef": "{{ event.boardResolutionRef }}"
3734
+ }
3735
+ },
3736
+ {
3737
+ "type": "EMIT_EVENT",
3738
+ "eventType": "SHAREHOLDER_MEETING_SCHEDULED",
3739
+ "payload": {
3740
+ "meetingId": "{{ event.meetingId }}",
3741
+ "type": "ANNUAL",
3742
+ "scheduledDate": "{{ event.scheduledDate }}"
3743
+ }
3744
+ }
3745
+ ]
3746
+ },
3747
+ "schedule_special": {
3748
+ "from": null,
3749
+ "to": "SCHEDULED",
3750
+ "description": "Schedule a special shareholder meeting",
3751
+ "event": {
3752
+ "name": "schedule_special",
3753
+ "payload": {
3754
+ "meetingId": {
3755
+ "type": "string",
3756
+ "required": true
3757
+ },
3758
+ "entityId": {
3759
+ "type": "string",
3760
+ "required": true
3761
+ },
3762
+ "scheduledDate": {
3763
+ "type": "string",
3764
+ "format": "date-time",
3765
+ "required": true
3766
+ },
3767
+ "location": {
3768
+ "type": "object"
3769
+ },
3770
+ "purpose": {
3771
+ "type": "string",
3772
+ "required": true,
3773
+ "description": "Specific purpose for special meeting"
3774
+ },
3775
+ "calledByType": {
3776
+ "type": "string",
3777
+ "enum": [
3778
+ "BOARD",
3779
+ "SHAREHOLDERS",
3780
+ "COURT"
3781
+ ],
3782
+ "required": true
3783
+ },
3784
+ "resolutionRef": {
3785
+ "type": "string"
3786
+ },
3787
+ "petitionRef": {
3788
+ "type": "string"
3789
+ }
3790
+ }
3791
+ },
3792
+ "effects": [
3793
+ {
3794
+ "type": "SET_CONTEXT",
3795
+ "path": "meetingId",
3796
+ "value": "{{ event.meetingId }}"
3797
+ },
3798
+ {
3799
+ "type": "SET_CONTEXT",
3800
+ "path": "entityId",
3801
+ "value": "{{ event.entityId }}"
3802
+ },
3803
+ {
3804
+ "type": "SET_CONTEXT",
3805
+ "path": "meetingType",
3806
+ "value": "SPECIAL"
3807
+ },
3808
+ {
3809
+ "type": "SET_CONTEXT",
3810
+ "path": "scheduledDate",
3811
+ "value": "{{ event.scheduledDate }}"
3812
+ },
3813
+ {
3814
+ "type": "SET_CONTEXT",
3815
+ "path": "calledBy.type",
3816
+ "value": "{{ event.calledByType }}"
3817
+ },
3818
+ {
3819
+ "type": "EMIT_EVENT",
3820
+ "eventType": "SPECIAL_MEETING_SCHEDULED",
3821
+ "payload": {
3822
+ "meetingId": "{{ event.meetingId }}",
3823
+ "purpose": "{{ event.purpose }}"
3824
+ }
3825
+ }
3826
+ ]
3827
+ },
3828
+ "set_record_date": {
3829
+ "from": "SCHEDULED",
3830
+ "to": "RECORD_DATE_SET",
3831
+ "description": "Board sets the record date for determining eligible shareholders",
3832
+ "event": {
3833
+ "name": "set_record_date",
3834
+ "payload": {
3835
+ "recordDate": {
3836
+ "type": "string",
3837
+ "format": "date",
3838
+ "required": true
3839
+ },
3840
+ "resolutionRef": {
3841
+ "type": "string",
3842
+ "required": true
3843
+ }
3844
+ }
3845
+ },
3846
+ "guards": [
3847
+ {
3848
+ "name": "validRecordDateTiming",
3849
+ "description": "Record date must be 10-60 days before meeting (per most state laws)",
3850
+ "expression": "true"
3851
+ }
3852
+ ],
3853
+ "effects": [
3854
+ {
3855
+ "type": "SET_CONTEXT",
3856
+ "path": "recordDate",
3857
+ "value": {
3858
+ "date": "{{ event.recordDate }}",
3859
+ "setByBoardOn": "{{ today() }}",
3860
+ "resolutionRef": "{{ event.resolutionRef }}"
3861
+ }
3862
+ },
3863
+ {
3864
+ "type": "EMIT_EVENT",
3865
+ "eventType": "RECORD_DATE_SET",
3866
+ "payload": {
3867
+ "meetingId": "{{ context.meetingId }}",
3868
+ "recordDate": "{{ event.recordDate }}"
3869
+ }
3870
+ }
3871
+ ]
3872
+ },
3873
+ "register_eligible_shareholders": {
3874
+ "from": "RECORD_DATE_SET",
3875
+ "to": "RECORD_DATE_SET",
3876
+ "description": "Register shareholders of record as of record date",
3877
+ "event": {
3878
+ "name": "register_eligible_shareholders",
3879
+ "payload": {
3880
+ "shareholders": {
3881
+ "type": "array",
3882
+ "required": true,
3883
+ "items": {
3884
+ "type": "object",
3885
+ "properties": {
3886
+ "shareholderId": {
3887
+ "type": "string"
3888
+ },
3889
+ "name": {
3890
+ "type": "string"
3891
+ },
3892
+ "shareholdings": {
3893
+ "type": "array"
3894
+ }
3895
+ }
3896
+ }
3897
+ },
3898
+ "totalSharesOutstanding": {
3899
+ "type": "integer",
3900
+ "required": true
3901
+ }
3902
+ }
3903
+ },
3904
+ "effects": [
3905
+ {
3906
+ "type": "SET_CONTEXT",
3907
+ "path": "eligibleVoters",
3908
+ "value": "{{ event.shareholders }}"
3909
+ },
3910
+ {
3911
+ "type": "SET_CONTEXT",
3912
+ "path": "quorumRequirements.sharesRequired",
3913
+ "value": "{{ Math.ceil(event.totalSharesOutstanding * 0.5) }}"
3914
+ }
3915
+ ]
3916
+ },
3917
+ "open_proxy_period": {
3918
+ "from": "RECORD_DATE_SET",
3919
+ "to": "PROXY_PERIOD",
3920
+ "description": "Distribute proxy materials and open proxy solicitation period",
3921
+ "event": {
3922
+ "name": "open_proxy_period",
3923
+ "payload": {
3924
+ "startDate": {
3925
+ "type": "string",
3926
+ "format": "date",
3927
+ "required": true
3928
+ },
3929
+ "proxyStatementRef": {
3930
+ "type": "string",
3931
+ "required": true
3932
+ },
3933
+ "formOfProxyRef": {
3934
+ "type": "string",
3935
+ "required": true
3936
+ },
3937
+ "annualReportRef": {
3938
+ "type": "string"
3939
+ },
3940
+ "agenda": {
3941
+ "type": "array",
3942
+ "required": true
3943
+ }
3944
+ }
3945
+ },
3946
+ "effects": [
3947
+ {
3948
+ "type": "SET_CONTEXT",
3949
+ "path": "proxyPeriod",
3950
+ "value": {
3951
+ "startDate": "{{ event.startDate }}",
3952
+ "endDate": "{{ context.scheduledDate }}",
3953
+ "proxyMaterials": {
3954
+ "proxyStatementRef": "{{ event.proxyStatementRef }}",
3955
+ "formOfProxyRef": "{{ event.formOfProxyRef }}",
3956
+ "annualReportRef": "{{ event.annualReportRef }}"
3957
+ }
3958
+ }
3959
+ },
3960
+ {
3961
+ "type": "SET_CONTEXT",
3962
+ "path": "agenda",
3963
+ "value": "{{ event.agenda }}"
3964
+ },
3965
+ {
3966
+ "type": "SET_CONTEXT",
3967
+ "path": "noticeInfo.noticeSentDate",
3968
+ "value": "{{ event.startDate }}"
3969
+ },
3970
+ {
3971
+ "type": "EMIT_EVENT",
3972
+ "eventType": "PROXY_PERIOD_OPENED",
3973
+ "payload": {
3974
+ "meetingId": "{{ context.meetingId }}",
3975
+ "proxyStatementRef": "{{ event.proxyStatementRef }}"
3976
+ }
3977
+ }
3978
+ ]
3979
+ },
3980
+ "add_agenda_item": {
3981
+ "from": [
3982
+ "SCHEDULED",
3983
+ "RECORD_DATE_SET",
3984
+ "PROXY_PERIOD"
3985
+ ],
3986
+ "to": null,
3987
+ "description": "Add an item to the meeting agenda (e.g., shareholder proposal)",
3988
+ "event": {
3989
+ "name": "add_agenda_item",
3990
+ "payload": {
3991
+ "itemId": {
3992
+ "type": "string",
3993
+ "required": true
3994
+ },
3995
+ "title": {
3996
+ "type": "string",
3997
+ "required": true
3998
+ },
3999
+ "description": {
4000
+ "type": "string"
4001
+ },
4002
+ "type": {
4003
+ "type": "string",
4004
+ "required": true
4005
+ },
4006
+ "voteRequired": {
4007
+ "type": "string",
4008
+ "required": true
4009
+ },
4010
+ "eligibleClasses": {
4011
+ "type": "array",
4012
+ "items": {
4013
+ "type": "string"
4014
+ }
4015
+ },
4016
+ "allowCumulativeVoting": {
4017
+ "type": "boolean",
4018
+ "default": false
4019
+ }
4020
+ }
4021
+ },
4022
+ "effects": [
4023
+ {
4024
+ "type": "APPEND_ARRAY",
4025
+ "path": "agenda",
4026
+ "value": {
4027
+ "itemId": "{{ event.itemId }}",
4028
+ "itemNumber": "{{ context.agenda.length + 1 }}",
4029
+ "title": "{{ event.title }}",
4030
+ "description": "{{ event.description }}",
4031
+ "type": "{{ event.type }}",
4032
+ "voteRequired": "{{ event.voteRequired }}",
4033
+ "eligibleClasses": "{{ event.eligibleClasses }}",
4034
+ "allowCumulativeVoting": "{{ event.allowCumulativeVoting }}",
4035
+ "status": "PENDING"
4036
+ }
4037
+ }
4038
+ ]
4039
+ },
4040
+ "open_meeting": {
4041
+ "from": "PROXY_PERIOD",
4042
+ "to": "IN_SESSION",
4043
+ "description": "Convene the shareholder meeting",
4044
+ "event": {
4045
+ "name": "open_meeting",
4046
+ "payload": {
4047
+ "openedAt": {
4048
+ "type": "string",
4049
+ "format": "date-time",
4050
+ "required": true
4051
+ },
4052
+ "chairPerson": {
4053
+ "type": "string",
4054
+ "required": true
4055
+ },
4056
+ "secretaryPresent": {
4057
+ "type": "string",
4058
+ "required": true
4059
+ },
4060
+ "inspectorOfElections": {
4061
+ "type": "object"
4062
+ },
4063
+ "initialQuorumCount": {
4064
+ "type": "integer",
4065
+ "required": true
4066
+ }
4067
+ }
4068
+ },
4069
+ "guards": [
4070
+ {
4071
+ "name": "quorumPresentOrRepresented",
4072
+ "description": "Must have quorum to proceed",
4073
+ "expression": "event.initialQuorumCount >= context.quorumRequirements.sharesRequired"
4074
+ }
4075
+ ],
4076
+ "effects": [
4077
+ {
4078
+ "type": "SET_CONTEXT",
4079
+ "path": "sessionInfo",
4080
+ "value": {
4081
+ "openedAt": "{{ event.openedAt }}",
4082
+ "chairPerson": "{{ event.chairPerson }}",
4083
+ "secretaryPresent": "{{ event.secretaryPresent }}"
4084
+ }
4085
+ },
4086
+ {
4087
+ "type": "SET_CONTEXT",
4088
+ "path": "inspectorOfElections",
4089
+ "value": "{{ event.inspectorOfElections }}"
4090
+ },
4091
+ {
4092
+ "type": "SET_CONTEXT",
4093
+ "path": "quorumRequirements.sharesRepresented",
4094
+ "value": "{{ event.initialQuorumCount }}"
4095
+ },
4096
+ {
4097
+ "type": "SET_CONTEXT",
4098
+ "path": "quorumRequirements.quorumMet",
4099
+ "value": true
4100
+ },
4101
+ {
4102
+ "type": "EMIT_EVENT",
4103
+ "eventType": "SHAREHOLDER_MEETING_OPENED",
4104
+ "payload": {
4105
+ "meetingId": "{{ context.meetingId }}",
4106
+ "sharesRepresented": "{{ event.initialQuorumCount }}"
4107
+ }
4108
+ }
4109
+ ]
4110
+ },
4111
+ "open_polls": {
4112
+ "from": "IN_SESSION",
4113
+ "to": "VOTING",
4114
+ "description": "Open polls for voting on agenda items",
4115
+ "event": {
4116
+ "name": "open_polls",
4117
+ "payload": {
4118
+ "pollsOpenedAt": {
4119
+ "type": "string",
4120
+ "format": "date-time",
4121
+ "required": true
4122
+ }
4123
+ }
4124
+ },
4125
+ "effects": [
4126
+ {
4127
+ "type": "SET_CONTEXT",
4128
+ "path": "sessionInfo.pollsOpenedAt",
4129
+ "value": "{{ event.pollsOpenedAt }}"
4130
+ },
4131
+ {
4132
+ "type": "UPDATE_ARRAY_ALL",
4133
+ "path": "agenda",
4134
+ "updates": {
4135
+ "status": "VOTING"
4136
+ }
4137
+ }
4138
+ ]
4139
+ },
4140
+ "cast_vote": {
4141
+ "from": "VOTING",
4142
+ "to": "VOTING",
4143
+ "description": "Record a vote from a shareholder or proxy holder",
4144
+ "event": {
4145
+ "name": "cast_vote",
4146
+ "payload": {
4147
+ "voteId": {
4148
+ "type": "string",
4149
+ "required": true
4150
+ },
4151
+ "agendaItemId": {
4152
+ "type": "string",
4153
+ "required": true
4154
+ },
4155
+ "voterId": {
4156
+ "type": "string",
4157
+ "required": true
4158
+ },
4159
+ "shareholderId": {
4160
+ "type": "string",
4161
+ "required": true
4162
+ },
4163
+ "shareClass": {
4164
+ "type": "string",
4165
+ "required": true
4166
+ },
4167
+ "votesFor": {
4168
+ "type": "integer",
4169
+ "default": 0
4170
+ },
4171
+ "votesAgainst": {
4172
+ "type": "integer",
4173
+ "default": 0
4174
+ },
4175
+ "votesAbstain": {
4176
+ "type": "integer",
4177
+ "default": 0
4178
+ },
4179
+ "votesWithhold": {
4180
+ "type": "integer",
4181
+ "default": 0
4182
+ },
4183
+ "cumulativeVoteAllocation": {
4184
+ "type": "object",
4185
+ "nullable": true
4186
+ },
4187
+ "viaProxy": {
4188
+ "type": "boolean",
4189
+ "default": false
4190
+ }
4191
+ }
4192
+ },
4193
+ "guards": [
4194
+ {
4195
+ "name": "isEligibleVoter",
4196
+ "expression": "context.eligibleVoters.some(v => v.shareholderId === event.shareholderId)"
4197
+ },
4198
+ {
4199
+ "name": "hasNotAlreadyVoted",
4200
+ "description": "Shareholder cannot vote twice on same item",
4201
+ "expression": "!context.votes.some(v => v.shareholderId === event.shareholderId && v.agendaItemId === event.agendaItemId)"
4202
+ },
4203
+ {
4204
+ "name": "validProxyIfApplicable",
4205
+ "description": "If voting via proxy, proxy must be valid",
4206
+ "expression": "!event.viaProxy || true",
4207
+ "crossMachine": {
4208
+ "machine": "corporate-proxy",
4209
+ "condition": "event.viaProxy",
4210
+ "query": "findByGrantor(event.shareholderId)",
4211
+ "requiredState": "ACTIVE"
4212
+ }
4213
+ }
4214
+ ],
4215
+ "effects": [
4216
+ {
4217
+ "type": "APPEND_ARRAY",
4218
+ "path": "votes",
4219
+ "value": {
4220
+ "voteId": "{{ event.voteId }}",
4221
+ "agendaItemId": "{{ event.agendaItemId }}",
4222
+ "voterId": "{{ event.voterId }}",
4223
+ "shareholderId": "{{ event.shareholderId }}",
4224
+ "shareClass": "{{ event.shareClass }}",
4225
+ "votesFor": "{{ event.votesFor }}",
4226
+ "votesAgainst": "{{ event.votesAgainst }}",
4227
+ "votesAbstain": "{{ event.votesAbstain }}",
4228
+ "votesWithhold": "{{ event.votesWithhold }}",
4229
+ "cumulativeVoteAllocation": "{{ event.cumulativeVoteAllocation }}",
4230
+ "viaProxy": "{{ event.viaProxy }}",
4231
+ "timestamp": "{{ now() }}"
4232
+ }
4233
+ },
4234
+ {
4235
+ "type": "UPDATE_ARRAY_ITEM",
4236
+ "path": "eligibleVoters",
4237
+ "matchKey": "shareholderId",
4238
+ "matchValue": "{{ event.shareholderId }}",
4239
+ "updates": {
4240
+ "hasVoted": true
4241
+ }
4242
+ }
4243
+ ]
4244
+ },
4245
+ "close_polls": {
4246
+ "from": "VOTING",
4247
+ "to": "IN_SESSION",
4248
+ "description": "Close polls and begin vote tabulation",
4249
+ "event": {
4250
+ "name": "close_polls",
4251
+ "payload": {
4252
+ "pollsClosedAt": {
4253
+ "type": "string",
4254
+ "format": "date-time",
4255
+ "required": true
4256
+ }
4257
+ }
4258
+ },
4259
+ "effects": [
4260
+ {
4261
+ "type": "SET_CONTEXT",
4262
+ "path": "sessionInfo.pollsClosedAt",
4263
+ "value": "{{ event.pollsClosedAt }}"
4264
+ },
4265
+ {
4266
+ "type": "UPDATE_ARRAY_ALL",
4267
+ "path": "agenda",
4268
+ "updates": {
4269
+ "status": "CLOSED"
4270
+ }
4271
+ },
4272
+ {
4273
+ "type": "COMPUTE_TALLIES",
4274
+ "description": "Aggregate votes by agenda item",
4275
+ "targetPath": "voteTallies"
4276
+ }
4277
+ ]
4278
+ },
4279
+ "certify_results": {
4280
+ "from": "IN_SESSION",
4281
+ "to": "CLOSED",
4282
+ "description": "Inspector of elections certifies vote results",
4283
+ "event": {
4284
+ "name": "certify_results",
4285
+ "payload": {
4286
+ "certifiedAt": {
4287
+ "type": "string",
4288
+ "format": "date-time",
4289
+ "required": true
4290
+ },
4291
+ "certifiedBy": {
4292
+ "type": "string",
4293
+ "required": true
4294
+ },
4295
+ "certificateRef": {
4296
+ "type": "string",
4297
+ "required": true
4298
+ },
4299
+ "results": {
4300
+ "type": "array",
4301
+ "items": {
4302
+ "type": "object",
4303
+ "properties": {
4304
+ "agendaItemId": {
4305
+ "type": "string"
4306
+ },
4307
+ "result": {
4308
+ "type": "string",
4309
+ "enum": [
4310
+ "APPROVED",
4311
+ "REJECTED"
4312
+ ]
4313
+ }
4314
+ }
4315
+ }
4316
+ },
4317
+ "minutesRef": {
4318
+ "type": "string"
4319
+ }
4320
+ }
4321
+ },
4322
+ "effects": [
4323
+ {
4324
+ "type": "SET_CONTEXT",
4325
+ "path": "certification",
4326
+ "value": {
4327
+ "certifiedAt": "{{ event.certifiedAt }}",
4328
+ "certifiedBy": "{{ event.certifiedBy }}",
4329
+ "certificateRef": "{{ event.certificateRef }}"
4330
+ }
4331
+ },
4332
+ {
4333
+ "type": "SET_CONTEXT",
4334
+ "path": "sessionInfo.adjournedAt",
4335
+ "value": "{{ event.certifiedAt }}"
4336
+ },
4337
+ {
4338
+ "type": "SET_CONTEXT",
4339
+ "path": "sessionInfo.minutesRef",
4340
+ "value": "{{ event.minutesRef }}"
4341
+ },
4342
+ {
4343
+ "type": "FOR_EACH",
4344
+ "array": "{{ event.results }}",
4345
+ "do": {
4346
+ "type": "UPDATE_ARRAY_ITEM",
4347
+ "path": "voteTallies",
4348
+ "matchKey": "agendaItemId",
4349
+ "matchValue": "{{ item.agendaItemId }}",
4350
+ "updates": {
4351
+ "result": "{{ item.result }}",
4352
+ "certified": true
4353
+ }
4354
+ }
4355
+ },
4356
+ {
4357
+ "type": "EMIT_EVENT",
4358
+ "eventType": "MEETING_RESULTS_CERTIFIED",
4359
+ "payload": {
4360
+ "meetingId": "{{ context.meetingId }}",
4361
+ "results": "{{ event.results }}"
4362
+ }
4363
+ }
4364
+ ]
4365
+ },
4366
+ "adjourn_without_action": {
4367
+ "from": [
4368
+ "IN_SESSION",
4369
+ "VOTING"
4370
+ ],
4371
+ "to": "CLOSED",
4372
+ "description": "Adjourn meeting without completing agenda (e.g., quorum lost)",
4373
+ "event": {
4374
+ "name": "adjourn_without_action",
4375
+ "payload": {
4376
+ "adjournedAt": {
4377
+ "type": "string",
4378
+ "format": "date-time",
4379
+ "required": true
4380
+ },
4381
+ "reason": {
4382
+ "type": "string",
4383
+ "required": true
4384
+ },
4385
+ "adjournedTo": {
4386
+ "type": "string",
4387
+ "format": "date-time",
4388
+ "nullable": true
4389
+ }
4390
+ }
4391
+ },
4392
+ "effects": [
4393
+ {
4394
+ "type": "SET_CONTEXT",
4395
+ "path": "sessionInfo.adjournedAt",
4396
+ "value": "{{ event.adjournedAt }}"
4397
+ },
4398
+ {
4399
+ "type": "EMIT_EVENT",
4400
+ "eventType": "MEETING_ADJOURNED",
4401
+ "payload": {
4402
+ "meetingId": "{{ context.meetingId }}",
4403
+ "reason": "{{ event.reason }}",
4404
+ "adjournedTo": "{{ event.adjournedTo }}"
4405
+ }
4406
+ }
4407
+ ]
4408
+ }
4409
+ },
4410
+ "crossMachineRefs": {
4411
+ "entity": {
4412
+ "machine": "corporate-entity",
4413
+ "description": "Parent corporate entity",
4414
+ "foreignKey": "entityId"
4415
+ },
4416
+ "proxies": {
4417
+ "machine": "corporate-proxy",
4418
+ "description": "Proxy grants for this meeting",
4419
+ "foreignKey": "meetingId"
4420
+ },
4421
+ "resolutions": {
4422
+ "machine": "corporate-resolution",
4423
+ "description": "Resolutions resulting from meeting votes",
4424
+ "foreignKey": "meetingId"
4425
+ },
4426
+ "securities": {
4427
+ "machine": "corporate-securities",
4428
+ "description": "Share records for determining voting rights",
4429
+ "foreignKey": "entityId"
4430
+ }
4431
+ },
4432
+ "metadata": {
4433
+ "author": "OttoChain",
4434
+ "license": "MIT",
4435
+ "tags": [
4436
+ "corporate",
4437
+ "governance",
4438
+ "shareholders",
4439
+ "voting",
4440
+ "meetings",
4441
+ "proxy"
4442
+ ],
4443
+ "documentation": "https://ottochain.dev/docs/corporate/shareholders"
4444
+ }
4445
+ };