@robosystems/client 2.29.0 → 2.31.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2585,7 +2585,7 @@ export type ConsolidationProposal = {
2585
2585
  *
2586
2586
  * What the entry adjusts.
2587
2587
  */
2588
- adjustment_kind: 'elimination_investment' | 'elimination_intercompany' | 'elimination_unrealized_profit' | 'nci_allocation' | 'nci_distribution' | 'equity_method_pickup' | 'equity_method_distribution' | 'acquisition' | 'deconsolidation' | 'translation' | 'manual';
2588
+ adjustment_kind: 'elimination_investment' | 'elimination_intercompany' | 'elimination_unrealized_profit' | 'nci_allocation' | 'nci_distribution' | 'equity_method_pickup' | 'equity_method_distribution' | 'acquisition' | 'ownership_change' | 'deconsolidation' | 'translation' | 'manual';
2589
2589
  /**
2590
2590
  * Adjusts Entity Id
2591
2591
  *
@@ -3941,9 +3941,9 @@ export type CreateScheduleRequest = {
3941
3941
  /**
3942
3942
  * Monthly Amount
3943
3943
  *
3944
- * Monthly amount in cents
3944
+ * Monthly amount in cents. Required for a straight-line schedule; a custom or loan schedule takes its amounts from its curve.
3945
3945
  */
3946
- monthly_amount: number;
3946
+ monthly_amount?: number;
3947
3947
  entry_template: EntryTemplateRequest;
3948
3948
  schedule_metadata?: ScheduleMetadataRequest | null;
3949
3949
  /**
@@ -6023,7 +6023,7 @@ export type EntryTemplateRequest = {
6023
6023
  /**
6024
6024
  * Credit Element Id
6025
6025
  *
6026
- * CoA element id to credit (e.g. Accumulated Depreciation). A chart-of-accounts element id (see get-unmapped-elements), not a taxonomy qname. One template = one debit/credit pair; model a multi-account entry as several schedules.
6026
+ * CoA element id to credit (e.g. Accumulated Depreciation). A chart-of-accounts element id (see get-unmapped-elements), not a taxonomy qname. A straight-line or custom schedule posts this one debit/credit pair; a loan schedule posts its `legs`.
6027
6027
  */
6028
6028
  credit_element_id: string;
6029
6029
  /**
@@ -6050,6 +6050,12 @@ export type EntryTemplateRequest = {
6050
6050
  * The management dimension members (department, class, location, project) every entry the schedule drafts carries on both lines, one per axis: a department's depreciation lands in that department.
6051
6051
  */
6052
6052
  dimension_ids?: Array<string>;
6053
+ /**
6054
+ * Legs
6055
+ *
6056
+ * The lines of a loan schedule's entry (`method='effective_interest'` only), each taking one column of the amortization table; each period's lines must balance. Accrue interest and pay through the bank: debit Interest Expense and credit Accrued Interest, both `interest`. The schedule settles the payment itself: debit the note `principal`, debit Interest Expense `interest`, credit cash or a due-to `payment`. `debit_element_id` names the interest debit leg and `credit_element_id` one credit leg. Empty for every other method, which posts the debit/credit pair.
6057
+ */
6058
+ legs?: Array<ScheduleLegRequest>;
6053
6059
  };
6054
6060
  /**
6055
6061
  * ErrorResponse
@@ -10444,6 +10450,85 @@ export type LiveStatementFactRow = {
10444
10450
  */
10445
10451
  sources?: Array<Array<StatementRowSource>> | null;
10446
10452
  };
10453
+ /**
10454
+ * LoanTermsRequest
10455
+ *
10456
+ * The terms a loan schedule's amortization table is computed from.
10457
+ */
10458
+ export type LoanTermsRequest = {
10459
+ /**
10460
+ * Principal
10461
+ *
10462
+ * Principal drawn, in cents.
10463
+ */
10464
+ principal: number;
10465
+ /**
10466
+ * Annual Rate
10467
+ *
10468
+ * Annual interest rate as a fraction: 0.099 for 9.9%.
10469
+ */
10470
+ annual_rate: number;
10471
+ /**
10472
+ * Start Date
10473
+ *
10474
+ * The day the principal was drawn; interest accrues from it. Falls in the schedule's first month.
10475
+ */
10476
+ start_date: string;
10477
+ /**
10478
+ * Day Count
10479
+ *
10480
+ * How a period's interest counts days: `30/360` (every whole month is 30 days), `actual/365` or `actual/360` (the days elapsed, over a 365- or 360-day year; actual/360 is the usual bank line of credit).
10481
+ */
10482
+ day_count?: '30/360' | 'actual/365' | 'actual/360';
10483
+ /**
10484
+ * Payment Frequency
10485
+ *
10486
+ * How often a payment falls due. A payment is applied at the end of the month it falls in.
10487
+ */
10488
+ payment_frequency?: 'monthly' | 'quarterly' | 'annual' | 'at_maturity';
10489
+ /**
10490
+ * First Payment Date
10491
+ *
10492
+ * The first payment's date. Omit for one frequency after the schedule's first month.
10493
+ */
10494
+ first_payment_date?: string | null;
10495
+ /**
10496
+ * Payment Amount
10497
+ *
10498
+ * Each scheduled payment in cents, interest included. Omit for the level payment that retires the principal by `maturity_date`, or for the accrued interest when `interest_only`.
10499
+ */
10500
+ payment_amount?: number | null;
10501
+ /**
10502
+ * Interest Only
10503
+ *
10504
+ * Payments settle interest only; the principal is due at maturity.
10505
+ */
10506
+ interest_only?: boolean;
10507
+ /**
10508
+ * Maturity Date
10509
+ *
10510
+ * When the remaining principal is due: it is repaid in that month, which is the schedule's last. Omit for a line of credit with no maturity, whose balance carries past the schedule.
10511
+ */
10512
+ maturity_date?: string | null;
10513
+ /**
10514
+ * Capitalize Interest
10515
+ *
10516
+ * Interest is added to the note rather than accrued apart (a PIK note): the balance grows by each period's interest, and payments reduce it whole.
10517
+ */
10518
+ capitalize_interest?: boolean;
10519
+ /**
10520
+ * Note Element Id
10521
+ *
10522
+ * The liability account the principal is carried in. The schedule states its balance each period, which the schedule reconciliation compares with the ledger.
10523
+ */
10524
+ note_element_id: string;
10525
+ /**
10526
+ * Current Portion Element Id
10527
+ *
10528
+ * A current-liability account for the principal due within twelve months. When set, each period's entry also reclasses between it and `note_element_id` so it holds the next twelve months' principal.
10529
+ */
10530
+ current_portion_element_id?: string | null;
10531
+ };
10447
10532
  /**
10448
10533
  * LoginRequest
10449
10534
  *
@@ -13052,6 +13137,51 @@ export type OperationEnvelopeLiveFinancialStatementResponse = {
13052
13137
  */
13053
13138
  idempotentReplay?: boolean;
13054
13139
  };
13140
+ /**
13141
+ * OperationEnvelope[OwnershipChangeResponse]
13142
+ */
13143
+ export type OperationEnvelopeOwnershipChangeResponse = {
13144
+ /**
13145
+ * Operation
13146
+ *
13147
+ * Kebab-case operation name
13148
+ */
13149
+ operation: string;
13150
+ /**
13151
+ * Operationid
13152
+ *
13153
+ * op_-prefixed ULID for audit and SSE correlation
13154
+ */
13155
+ operationId: string;
13156
+ /**
13157
+ * Status
13158
+ *
13159
+ * Operation lifecycle state
13160
+ */
13161
+ status: 'completed' | 'pending' | 'failed';
13162
+ /**
13163
+ * Command-specific result payload
13164
+ */
13165
+ result?: OwnershipChangeResponse | null;
13166
+ /**
13167
+ * At
13168
+ *
13169
+ * ISO-8601 UTC timestamp
13170
+ */
13171
+ at: string;
13172
+ /**
13173
+ * Createdby
13174
+ *
13175
+ * User ID that initiated the operation
13176
+ */
13177
+ createdBy?: string | null;
13178
+ /**
13179
+ * Idempotentreplay
13180
+ *
13181
+ * True when this envelope came from the idempotency cache — the underlying command did not execute again. False on fresh executions.
13182
+ */
13183
+ idempotentReplay?: boolean;
13184
+ };
13055
13185
  /**
13056
13186
  * OperationEnvelope[PortfolioBlockEnvelope]
13057
13187
  */
@@ -13187,6 +13317,51 @@ export type OperationEnvelopePreviewEventBlockResponse = {
13187
13317
  */
13188
13318
  idempotentReplay?: boolean;
13189
13319
  };
13320
+ /**
13321
+ * OperationEnvelope[PreviewScheduleResponse]
13322
+ */
13323
+ export type OperationEnvelopePreviewScheduleResponse = {
13324
+ /**
13325
+ * Operation
13326
+ *
13327
+ * Kebab-case operation name
13328
+ */
13329
+ operation: string;
13330
+ /**
13331
+ * Operationid
13332
+ *
13333
+ * op_-prefixed ULID for audit and SSE correlation
13334
+ */
13335
+ operationId: string;
13336
+ /**
13337
+ * Status
13338
+ *
13339
+ * Operation lifecycle state
13340
+ */
13341
+ status: 'completed' | 'pending' | 'failed';
13342
+ /**
13343
+ * Command-specific result payload
13344
+ */
13345
+ result?: PreviewScheduleResponse | null;
13346
+ /**
13347
+ * At
13348
+ *
13349
+ * ISO-8601 UTC timestamp
13350
+ */
13351
+ at: string;
13352
+ /**
13353
+ * Createdby
13354
+ *
13355
+ * User ID that initiated the operation
13356
+ */
13357
+ createdBy?: string | null;
13358
+ /**
13359
+ * Idempotentreplay
13360
+ *
13361
+ * True when this envelope came from the idempotency cache — the underlying command did not execute again. False on fresh executions.
13362
+ */
13363
+ idempotentReplay?: boolean;
13364
+ };
13190
13365
  /**
13191
13366
  * OperationEnvelope[PromoteObligationsResponse]
13192
13367
  */
@@ -14670,6 +14845,78 @@ export type OrgUsageSummary = {
14670
14845
  */
14671
14846
  storage_limit_gb: number | null;
14672
14847
  };
14848
+ /**
14849
+ * OwnershipChangeResponse
14850
+ *
14851
+ * A change in the parent's share of a member as recorded: the draft in
14852
+ * the consolidation entity its close posts.
14853
+ */
14854
+ export type OwnershipChangeResponse = {
14855
+ /**
14856
+ * Entity Id
14857
+ *
14858
+ * The member.
14859
+ */
14860
+ entity_id: string;
14861
+ /**
14862
+ * Entity Name
14863
+ *
14864
+ * The member's name.
14865
+ */
14866
+ entity_name: string;
14867
+ /**
14868
+ * Period
14869
+ *
14870
+ * The first month the new share holds.
14871
+ */
14872
+ period: string;
14873
+ /**
14874
+ * From Pct
14875
+ *
14876
+ * The parent's share the month before.
14877
+ */
14878
+ from_pct: number;
14879
+ /**
14880
+ * To Pct
14881
+ *
14882
+ * The parent's share from `period`.
14883
+ */
14884
+ to_pct: number;
14885
+ /**
14886
+ * Consideration
14887
+ *
14888
+ * Cents paid to the outside owners.
14889
+ */
14890
+ consideration: number;
14891
+ /**
14892
+ * Book Value
14893
+ *
14894
+ * Cents: the share bought of the member's capital, which the investment elimination moves from the outside owners to the parent.
14895
+ */
14896
+ book_value: number;
14897
+ /**
14898
+ * Earnings Transferred
14899
+ *
14900
+ * Cents: the share bought of the member's results since it joined, moved from the outside owners' interest to the parent.
14901
+ */
14902
+ earnings_transferred: number;
14903
+ /**
14904
+ * Equity Adjustment
14905
+ *
14906
+ * Cents taken from the parent's equity: the price above the carrying amount of what was bought (negative when it paid less).
14907
+ */
14908
+ equity_adjustment: number;
14909
+ /**
14910
+ * The ownership change entry, a draft the close posts.
14911
+ */
14912
+ entry: JournalEntryResponse;
14913
+ /**
14914
+ * Replaced
14915
+ *
14916
+ * True when it replaced an earlier draft for the month.
14917
+ */
14918
+ replaced?: boolean;
14919
+ };
14673
14920
  /**
14674
14921
  * PasskeyDeleteRequest
14675
14922
  *
@@ -15714,6 +15961,101 @@ export type PreviewReconcilingItemRequest = {
15714
15961
  */
15715
15962
  event_id: string;
15716
15963
  };
15964
+ /**
15965
+ * PreviewScheduleRequest
15966
+ *
15967
+ * A schedule's definition, generated without being kept.
15968
+ */
15969
+ export type PreviewScheduleRequest = {
15970
+ /**
15971
+ * Name
15972
+ *
15973
+ * Schedule name
15974
+ */
15975
+ name: string;
15976
+ /**
15977
+ * Entity Id
15978
+ *
15979
+ * The entity whose books the schedule belongs to, by id. Omit for the group parent. Its facts, obligations and closing entries land in that entity's books, against that entity's own accounts.
15980
+ */
15981
+ entity_id?: string | null;
15982
+ /**
15983
+ * Taxonomy Id
15984
+ *
15985
+ * Taxonomy ID (auto-creates if omitted)
15986
+ */
15987
+ taxonomy_id?: string | null;
15988
+ /**
15989
+ * Element Ids
15990
+ *
15991
+ * CoA element ids the schedule touches (the `id` from get-unmapped-elements, not taxonomy qnames) — typically the same debit + credit ids used in entry_template.
15992
+ */
15993
+ element_ids: Array<string>;
15994
+ /**
15995
+ * Period Start
15996
+ *
15997
+ * First period start
15998
+ */
15999
+ period_start: string;
16000
+ /**
16001
+ * Period End
16002
+ *
16003
+ * Last period end
16004
+ */
16005
+ period_end: string;
16006
+ /**
16007
+ * Monthly Amount
16008
+ *
16009
+ * Monthly amount in cents. Required for a straight-line schedule; a custom or loan schedule takes its amounts from its curve.
16010
+ */
16011
+ monthly_amount?: number;
16012
+ entry_template: EntryTemplateRequest;
16013
+ schedule_metadata?: ScheduleMetadataRequest | null;
16014
+ /**
16015
+ * Closed Through
16016
+ *
16017
+ * Watermark for onboarding. Facts with period_end ≤ this date are flagged 'historical' and their schedule_entry_due obligations are emitted 'voided', so the close workflow starts drafting at the first open period. Defaults to the calendar's history end: the last day of its closed_through month (calendar '2026-05' → '2026-05-31'), or the day before its first month when nothing has closed yet. An earlier date is raised to it, since an obligation there could never post; set a later one only to treat more months as already booked.
16018
+ */
16019
+ closed_through?: string | null;
16020
+ /**
16021
+ * Source Transaction Id
16022
+ *
16023
+ * Free-form reference to the originating GL transaction (e.g. an import ID, ledger entry ID, or external system key). Stored in artifact_mechanics for audit; no FK constraint.
16024
+ */
16025
+ source_transaction_id?: string | null;
16026
+ /**
16027
+ * Replaces Structure Id
16028
+ *
16029
+ * The schedule this definition would replace, when editing or recreating one: the preview then says what its posted entries mean for the change.
16030
+ */
16031
+ replaces_structure_id?: string | null;
16032
+ };
16033
+ /**
16034
+ * PreviewScheduleResponse
16035
+ *
16036
+ * A generated schedule nobody kept: its envelope as create would leave
16037
+ * it, period by period.
16038
+ */
16039
+ export type PreviewScheduleResponse = {
16040
+ /**
16041
+ * The schedule's Information Block envelope as create would leave it. Its ids are provisional: nothing was written.
16042
+ */
16043
+ envelope: InformationBlockEnvelope;
16044
+ /**
16045
+ * Roll Forward
16046
+ */
16047
+ roll_forward?: Array<ScheduleRollForwardRow>;
16048
+ /**
16049
+ * Warnings
16050
+ *
16051
+ * Things create would go ahead with that deserve a look: an active schedule already posting to the same accounts over the same months.
16052
+ */
16053
+ warnings?: Array<string>;
16054
+ /**
16055
+ * With `replaces_structure_id`: the schedule being replaced.
16056
+ */
16057
+ replaces?: ScheduleReplacementSummary | null;
16058
+ };
15717
16059
  /**
15718
16060
  * PromoteObligationsRequest
15719
16061
  *
@@ -16138,14 +16480,45 @@ export type ReadTextResponse = {
16138
16480
  * month, are history), so a rebuild re-scopes the schedule to today's
16139
16481
  * close state. Use this to pick up a fixed generator (e.g. the
16140
16482
  * roll-forward direction fix) without orphaning obligations.
16483
+ *
16484
+ * It is also how an edit is saved while nothing has posted: the fields below
16485
+ * replace the stored definition before it regenerates, as the schedule's
16486
+ * envelope reads them back (`artifact.mechanics`). Omitted fields keep their
16487
+ * stored values, inside `schedule_metadata` too.
16141
16488
  */
16142
16489
  export type RebuildScheduleRequest = {
16143
16490
  /**
16144
- * Structure Id
16491
+ * Structure Id
16492
+ *
16493
+ * The schedule structure to regenerate in place.
16494
+ */
16495
+ structure_id: string;
16496
+ /**
16497
+ * Period Start
16498
+ *
16499
+ * A new first period start.
16500
+ */
16501
+ period_start?: string | null;
16502
+ /**
16503
+ * Period End
16504
+ *
16505
+ * A new last period end.
16506
+ */
16507
+ period_end?: string | null;
16508
+ /**
16509
+ * Monthly Amount
16145
16510
  *
16146
- * The schedule structure to regenerate in place.
16511
+ * A new straight-line monthly amount, in cents.
16147
16512
  */
16148
- structure_id: string;
16513
+ monthly_amount?: number | null;
16514
+ /**
16515
+ * A new entry template, replacing the stored one whole.
16516
+ */
16517
+ entry_template?: EntryTemplateRequest | null;
16518
+ /**
16519
+ * The schedule_metadata fields to change.
16520
+ */
16521
+ schedule_metadata?: ScheduleMetadataRequest | null;
16149
16522
  };
16150
16523
  /**
16151
16524
  * ReconciliationComponent
@@ -17043,6 +17416,45 @@ export type RecordOpeningBalanceRequest = {
17043
17416
  */
17044
17417
  memo?: string | null;
17045
17418
  };
17419
+ /**
17420
+ * RecordOwnershipChangeRequest
17421
+ *
17422
+ * The parent buys more of a member from its outside owners, staying on the
17423
+ * same consolidation method: the share it holds from a month, and what it
17424
+ * paid. ASC 810 makes it an equity transaction, never a gain or loss.
17425
+ */
17426
+ export type RecordOwnershipChangeRequest = {
17427
+ /**
17428
+ * Entity Id
17429
+ *
17430
+ * The member, consolidated in full.
17431
+ */
17432
+ entity_id: string;
17433
+ /**
17434
+ * Period
17435
+ *
17436
+ * The month, as YYYY-MM.
17437
+ */
17438
+ period: string;
17439
+ /**
17440
+ * Ownership Pct
17441
+ *
17442
+ * The parent's share from `period`, as a percentage: above its share the month before, and 50 or more, so the member stays consolidated in full.
17443
+ */
17444
+ ownership_pct: number;
17445
+ /**
17446
+ * Consideration
17447
+ *
17448
+ * Cents the parent paid the outside owners for the shares. Its line names them, not the member, which is why it is given here.
17449
+ */
17450
+ consideration: number;
17451
+ /**
17452
+ * Basis
17453
+ *
17454
+ * The purchase agreement, or what sets the price.
17455
+ */
17456
+ basis: string;
17457
+ };
17046
17458
  /**
17047
17459
  * RecordStatementBalanceRequest
17048
17460
  *
@@ -18118,6 +18530,37 @@ export type ScheduleCreatedResponse = {
18118
18530
  * Pending Event Count
18119
18531
  */
18120
18532
  pending_event_count?: number;
18533
+ /**
18534
+ * Warnings
18535
+ *
18536
+ * What the write went ahead with that deserves a look: another active schedule posting to the same accounts over the same months.
18537
+ */
18538
+ warnings?: Array<string>;
18539
+ };
18540
+ /**
18541
+ * ScheduleLegRequest
18542
+ *
18543
+ * One line of the entry a loan schedule drafts each period.
18544
+ */
18545
+ export type ScheduleLegRequest = {
18546
+ /**
18547
+ * Element Id
18548
+ *
18549
+ * CoA element id the line posts to.
18550
+ */
18551
+ element_id: string;
18552
+ /**
18553
+ * Side
18554
+ *
18555
+ * The line's side.
18556
+ */
18557
+ side: 'debit' | 'credit';
18558
+ /**
18559
+ * Amount Source
18560
+ *
18561
+ * The amortization-table column the line takes each period: `interest` (accrued in the period), `interest_paid` (accrued interest settled by the period's payment), `principal` (principal repaid), `payment` (interest_paid + principal).
18562
+ */
18563
+ amount_source: 'interest' | 'interest_paid' | 'principal' | 'payment';
18121
18564
  };
18122
18565
  /**
18123
18566
  * ScheduleMechanics
@@ -18148,6 +18591,42 @@ export type ScheduleMechanics = {
18148
18591
  * Number of in-scope periods that have at least one closing entry posted. Runtime state derived at envelope-build time from the Entry table.
18149
18592
  */
18150
18593
  periods_with_entries?: number;
18594
+ /**
18595
+ * Period Start
18596
+ *
18597
+ * The schedule's first period start, as defined.
18598
+ */
18599
+ period_start?: string | null;
18600
+ /**
18601
+ * Period End
18602
+ *
18603
+ * The schedule's last period end, as defined. An early end is `end_date`; rebuild-schedule regenerates to this and ends at it again.
18604
+ */
18605
+ period_end?: string | null;
18606
+ /**
18607
+ * Monthly Amount
18608
+ *
18609
+ * The straight-line monthly amount in cents. With `period_start`, `period_end`, `entry_template` and `schedule_metadata` this is the whole definition: rebuild-schedule takes the same fields back.
18610
+ */
18611
+ monthly_amount?: number | null;
18612
+ /**
18613
+ * End Date
18614
+ *
18615
+ * Where terminate-schedule ended it, when it did.
18616
+ */
18617
+ end_date?: string | null;
18618
+ /**
18619
+ * Posted Periods
18620
+ *
18621
+ * The months (YYYY-MM) holding a posted or shadowed closing entry of the schedule, which no edit may rewrite.
18622
+ */
18623
+ posted_periods?: Array<string>;
18624
+ /**
18625
+ * Edit Warning
18626
+ *
18627
+ * Set once an entry has posted: what deleting, rebuilding or recreating the schedule would do to that history, and the path an edit takes instead.
18628
+ */
18629
+ edit_warning?: string | null;
18151
18630
  };
18152
18631
  /**
18153
18632
  * ScheduleMetadataRequest
@@ -18156,9 +18635,13 @@ export type ScheduleMetadataRequest = {
18156
18635
  /**
18157
18636
  * Method
18158
18637
  *
18159
- * Calculation method. 'straight_line' (default) distributes `monthly_amount` evenly across periods with the final period absorbing rounding. 'custom' requires `periodic_amounts` — the generator uses those values verbatim instead of computing. Other strings are labels only; fact values still come from `monthly_amount` or `periodic_amounts`.
18638
+ * Calculation method. 'straight_line' (default) distributes `monthly_amount` evenly across periods with the final period absorbing rounding. 'custom' requires `periodic_amounts` — the generator uses those values verbatim instead of computing. 'effective_interest' requires `loan_terms` and the template's `legs`: the generator computes the amortization table (opening balance, interest, payment, principal, closing balance) and drafts the legs from it. Other strings are labels only; fact values still come from `monthly_amount` or `periodic_amounts`.
18160
18639
  */
18161
18640
  method?: string;
18641
+ /**
18642
+ * The loan's terms, for `method='effective_interest'`.
18643
+ */
18644
+ loan_terms?: LoanTermsRequest | null;
18162
18645
  /**
18163
18646
  * Original Amount
18164
18647
  *
@@ -18196,6 +18679,107 @@ export type ScheduleMetadataRequest = {
18196
18679
  */
18197
18680
  periodic_amounts?: Array<number> | null;
18198
18681
  };
18682
+ /**
18683
+ * ScheduleReplacementSummary
18684
+ *
18685
+ * What an existing schedule's entries mean for replacing it.
18686
+ */
18687
+ export type ScheduleReplacementSummary = {
18688
+ /**
18689
+ * Structure Id
18690
+ */
18691
+ structure_id: string;
18692
+ /**
18693
+ * Name
18694
+ */
18695
+ name: string;
18696
+ /**
18697
+ * Posted Entry Count
18698
+ *
18699
+ * Its posted or shadowed closing entries.
18700
+ */
18701
+ posted_entry_count: number;
18702
+ /**
18703
+ * Posted Periods
18704
+ *
18705
+ * The months those entries are in (YYYY-MM).
18706
+ */
18707
+ posted_periods?: Array<string>;
18708
+ /**
18709
+ * Draft Entry Count
18710
+ */
18711
+ draft_entry_count?: number;
18712
+ /**
18713
+ * Path
18714
+ *
18715
+ * `rebuild` when nothing has posted: rebuild-schedule with the new definition replaces it in place. `terminate_and_succeed` once an entry has: terminate it after its last posted month and create the successor from the month after.
18716
+ */
18717
+ path: 'rebuild' | 'terminate_and_succeed';
18718
+ };
18719
+ /**
18720
+ * ScheduleRollForwardRow
18721
+ *
18722
+ * One period of a previewed schedule: the balance it carries, and what
18723
+ * moves it.
18724
+ */
18725
+ export type ScheduleRollForwardRow = {
18726
+ /**
18727
+ * Period Start
18728
+ */
18729
+ period_start: string;
18730
+ /**
18731
+ * Period End
18732
+ */
18733
+ period_end: string;
18734
+ /**
18735
+ * Opening
18736
+ *
18737
+ * The carried balance at the period's start.
18738
+ */
18739
+ opening: number;
18740
+ /**
18741
+ * Amount
18742
+ *
18743
+ * What the period recognizes: the entry's debit amount.
18744
+ */
18745
+ amount: number;
18746
+ /**
18747
+ * Closing
18748
+ *
18749
+ * The carried balance at the period's end.
18750
+ */
18751
+ closing: number;
18752
+ /**
18753
+ * Scope
18754
+ *
18755
+ * `historical` for a month already in the books' history, which the schedule records but never drafts; `in_scope` for one a close drafts.
18756
+ */
18757
+ scope: 'historical' | 'in_scope';
18758
+ /**
18759
+ * Interest
18760
+ *
18761
+ * Loan schedules: interest accrued.
18762
+ */
18763
+ interest?: number | null;
18764
+ /**
18765
+ * Payment
18766
+ *
18767
+ * Loan schedules: the payment.
18768
+ */
18769
+ payment?: number | null;
18770
+ /**
18771
+ * Principal
18772
+ *
18773
+ * Loan schedules: principal repaid.
18774
+ */
18775
+ principal?: number | null;
18776
+ /**
18777
+ * Current Portion
18778
+ *
18779
+ * Loan schedules with a current-portion account: the principal due in the next twelve months.
18780
+ */
18781
+ current_portion?: number | null;
18782
+ };
18199
18783
  /**
18200
18784
  * SchemaExportResponse
18201
18785
  *
@@ -32111,6 +32695,65 @@ export type RecordAcquisitionResponses = {
32111
32695
  200: OperationEnvelopeAcquisitionResponse;
32112
32696
  };
32113
32697
  export type RecordAcquisitionResponse = RecordAcquisitionResponses[keyof RecordAcquisitionResponses];
32698
+ export type RecordOwnershipChangeData = {
32699
+ body: RecordOwnershipChangeRequest;
32700
+ headers?: {
32701
+ /**
32702
+ * Idempotency-Key
32703
+ */
32704
+ 'Idempotency-Key'?: string | null;
32705
+ };
32706
+ path: {
32707
+ /**
32708
+ * Graph Id
32709
+ */
32710
+ graph_id: string;
32711
+ };
32712
+ query?: never;
32713
+ url: '/extensions/roboledger/{graph_id}/operations/record-ownership-change';
32714
+ };
32715
+ export type RecordOwnershipChangeErrors = {
32716
+ /**
32717
+ * Invalid request
32718
+ */
32719
+ 400: ErrorResponse;
32720
+ /**
32721
+ * Authentication required
32722
+ */
32723
+ 401: ErrorResponse;
32724
+ /**
32725
+ * Access denied
32726
+ */
32727
+ 403: ErrorResponse;
32728
+ /**
32729
+ * Resource not found
32730
+ */
32731
+ 404: ErrorResponse;
32732
+ /**
32733
+ * Idempotency-Key conflict — key reused with different body
32734
+ */
32735
+ 409: ErrorResponse;
32736
+ /**
32737
+ * Validation error
32738
+ */
32739
+ 422: ErrorResponse;
32740
+ /**
32741
+ * Rate limit exceeded
32742
+ */
32743
+ 429: ErrorResponse;
32744
+ /**
32745
+ * Internal server error
32746
+ */
32747
+ 500: ErrorResponse;
32748
+ };
32749
+ export type RecordOwnershipChangeError = RecordOwnershipChangeErrors[keyof RecordOwnershipChangeErrors];
32750
+ export type RecordOwnershipChangeResponses = {
32751
+ /**
32752
+ * Successful Response
32753
+ */
32754
+ 200: OperationEnvelopeOwnershipChangeResponse;
32755
+ };
32756
+ export type RecordOwnershipChangeResponse = RecordOwnershipChangeResponses[keyof RecordOwnershipChangeResponses];
32114
32757
  export type UpdateJournalEntryData = {
32115
32758
  body: UpdateJournalEntryRequest;
32116
32759
  headers?: {
@@ -32524,6 +33167,65 @@ export type PromoteObligationsResponses = {
32524
33167
  200: OperationEnvelopePromoteObligationsResponse;
32525
33168
  };
32526
33169
  export type PromoteObligationsResponse2 = PromoteObligationsResponses[keyof PromoteObligationsResponses];
33170
+ export type PreviewScheduleData = {
33171
+ body: PreviewScheduleRequest;
33172
+ headers?: {
33173
+ /**
33174
+ * Idempotency-Key
33175
+ */
33176
+ 'Idempotency-Key'?: string | null;
33177
+ };
33178
+ path: {
33179
+ /**
33180
+ * Graph Id
33181
+ */
33182
+ graph_id: string;
33183
+ };
33184
+ query?: never;
33185
+ url: '/extensions/roboledger/{graph_id}/operations/preview-schedule';
33186
+ };
33187
+ export type PreviewScheduleErrors = {
33188
+ /**
33189
+ * Invalid request
33190
+ */
33191
+ 400: ErrorResponse;
33192
+ /**
33193
+ * Authentication required
33194
+ */
33195
+ 401: ErrorResponse;
33196
+ /**
33197
+ * Access denied
33198
+ */
33199
+ 403: ErrorResponse;
33200
+ /**
33201
+ * Resource not found
33202
+ */
33203
+ 404: ErrorResponse;
33204
+ /**
33205
+ * Idempotency-Key conflict — key reused with different body
33206
+ */
33207
+ 409: ErrorResponse;
33208
+ /**
33209
+ * Validation error
33210
+ */
33211
+ 422: ErrorResponse;
33212
+ /**
33213
+ * Rate limit exceeded
33214
+ */
33215
+ 429: ErrorResponse;
33216
+ /**
33217
+ * Internal server error
33218
+ */
33219
+ 500: ErrorResponse;
33220
+ };
33221
+ export type PreviewScheduleError = PreviewScheduleErrors[keyof PreviewScheduleErrors];
33222
+ export type PreviewScheduleResponses = {
33223
+ /**
33224
+ * Successful Response
33225
+ */
33226
+ 200: OperationEnvelopePreviewScheduleResponse;
33227
+ };
33228
+ export type PreviewScheduleResponse2 = PreviewScheduleResponses[keyof PreviewScheduleResponses];
32527
33229
  export type RebuildScheduleData = {
32528
33230
  body: RebuildScheduleRequest;
32529
33231
  headers?: {