@robosystems/client 2.26.0 → 2.26.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.
package/sdk/types.gen.ts CHANGED
@@ -729,13 +729,13 @@ export type AssociationResponse = {
729
729
  /**
730
730
  * Replaced Association Id
731
731
  *
732
- * The arc this write removed in the same transaction, when the call named one in `replaces_association_id`.
732
+ * The arc this one replaced, when the write named one in `replaces_association_id`. On a read, set for an arc whose move reached a closed month.
733
733
  */
734
734
  replaced_association_id?: string | null;
735
735
  /**
736
736
  * Reclassified Periods
737
737
  *
738
- * Closed months whose live statements now read through this arc while their stamped sets keep the answer as closed. Empty unless the write replaced an arc on an account with landed history in a closed month.
738
+ * Closed months whose live statements read through this arc while their stamped sets keep the answer as closed. Empty unless the arc replaced one on an account with landed history in a closed month.
739
739
  */
740
740
  reclassified_periods?: Array<string>;
741
741
  };
@@ -935,52 +935,6 @@ export type AvailableGraphTiersResponse = {
935
935
  tiers: Array<GraphTierInfo>;
936
936
  };
937
937
 
938
- /**
939
- * BackfillPeriodOutcome
940
- *
941
- * Per-month result of a plan-history backfill pass.
942
- */
943
- export type BackfillPeriodOutcome = {
944
- /**
945
- * Period
946
- *
947
- * The month, in YYYY-MM
948
- */
949
- period: string;
950
- /**
951
- * Status
952
- *
953
- * stamped: reopen → reclose completed. skipped_drafts: the month holds draft entries the backfill refuses to post — review via list-period-drafts, then close-period or re-run. failed: the reclose raised; processing halted (see detail).
954
- */
955
- status: string;
956
- /**
957
- * Statements Stamped
958
- *
959
- * Whether the reclose stamped canonical statement FactSets. False with a statement_stamp_note soft-skip when reporting isn't set up.
960
- */
961
- statements_stamped?: boolean;
962
- /**
963
- * Statement Stamp Note
964
- *
965
- * Soft-skip reason when statements_stamped is false
966
- */
967
- statement_stamp_note?: string | null;
968
- /**
969
- * Statement Rule Summary
970
- *
971
- * Statement-rule verification tally for the month's stamped sets (pass/fail/error/skipped); None when no rules ran.
972
- */
973
- statement_rule_summary?: {
974
- [key: string]: number;
975
- } | null;
976
- /**
977
- * Detail
978
- *
979
- * Human-readable detail for skipped/failed months
980
- */
981
- detail?: string | null;
982
- };
983
-
984
938
  /**
985
939
  * BackfillPlanHistoryOperation
986
940
  *
@@ -1055,51 +1009,6 @@ export type BackfillPlanHistoryOperation = {
1055
1009
  note?: string | null;
1056
1010
  };
1057
1011
 
1058
- /**
1059
- * BackfillPlanHistoryResponse
1060
- *
1061
- * Response from one chunked plan-history backfill call.
1062
- */
1063
- export type BackfillPlanHistoryResponse = {
1064
- fiscal_calendar: FiscalCalendarResponse;
1065
- /**
1066
- * Earliest Available Period
1067
- *
1068
- * First month with ledger data — the hard floor for backfill
1069
- */
1070
- earliest_available_period: string;
1071
- /**
1072
- * Effective Start Period
1073
- *
1074
- * The start actually used after clamping to earliest_available_period
1075
- */
1076
- effective_start_period: string;
1077
- /**
1078
- * Closed Through
1079
- *
1080
- * The close boundary the backfill runs up to (inclusive)
1081
- */
1082
- closed_through: string;
1083
- /**
1084
- * Period Rows Created
1085
- *
1086
- * FiscalPeriod rows seeded (baseline-closed) for months the calendar didn't cover yet
1087
- */
1088
- period_rows_created?: number;
1089
- /**
1090
- * Processed
1091
- *
1092
- * Months this call attempted, oldest first
1093
- */
1094
- processed?: Array<BackfillPeriodOutcome>;
1095
- /**
1096
- * Remaining Periods
1097
- *
1098
- * Months still lacking canonical statement sets that this call did not attempt (beyond max_periods, or after a failure halt). Loop until empty.
1099
- */
1100
- remaining_periods?: Array<string>;
1101
- };
1102
-
1103
1012
  /**
1104
1013
  * BackupCreateRequest
1105
1014
  *
@@ -2067,6 +1976,12 @@ export type ClosePeriodOperation = {
2067
1976
  * Override the reconciliation gate — close even though a reconciliation the close waits on is not reconciled for the period, or was never compared for it. The books are then closed without that check. Prefer refresh-reconciliations and clearing what it reports first. The override is recorded in the close audit note.
2068
1977
  */
2069
1978
  allow_unreconciled_accounts?: boolean;
1979
+ /**
1980
+ * Allow Held Bank Lines
1981
+ *
1982
+ * Override the held-bank-line gate — close even though bank lines a sync held out of an earlier, closed month (dated there, arriving after it closed) are still undecided. Each is recorded as decided by this close and stops blocking; none posts. Prefer reopening the month they are dated in, which gives them back to classify and commit. The override is recorded in the close audit note.
1983
+ */
1984
+ allow_held_bank_lines?: boolean;
2070
1985
  /**
2071
1986
  * Allow Unexplained Residuals
2072
1987
  *
@@ -2151,7 +2066,7 @@ export type ClosePeriodResponse = {
2151
2066
  /**
2152
2067
  * Gate Findings
2153
2068
  *
2154
- * Blocker codes a shadow close recorded instead of enforcing: sync_stale, pending_obligations, stranded_obligations, reconciling_items, unposted_source_events, unreconciled_accounts. Empty outside shadow.
2069
+ * Blocker codes a shadow close recorded instead of enforcing: sync_stale, pending_obligations, stranded_obligations, reconciling_items, unposted_source_events, unreconciled_accounts, held_bank_lines. Empty outside shadow.
2155
2070
  */
2156
2071
  gate_findings?: Array<string>;
2157
2072
  /**
@@ -3087,7 +3002,7 @@ export type CreateAgentRequest = {
3087
3002
  /**
3088
3003
  * Tax Id
3089
3004
  *
3090
- * Tax ID (EIN / SSN / VAT). Used for 1099 / withholding reporting.
3005
+ * Tax ID (EIN / SSN / VAT), kept for 1099 and withholding reporting; no report reads it yet.
3091
3006
  */
3092
3007
  tax_id?: string | null;
3093
3008
  /**
@@ -3145,7 +3060,7 @@ export type CreateAgentRequest = {
3145
3060
  /**
3146
3061
  * Is 1099 Recipient
3147
3062
  *
3148
- * Marks a vendor as 1099-eligible. Drives year-end 1099 reporting.
3063
+ * Marks a vendor as 1099-eligible: a flag a year-end 1099 summary will read. No report reads it yet.
3149
3064
  */
3150
3065
  is_1099_recipient?: boolean;
3151
3066
  /**
@@ -3648,7 +3563,7 @@ export type CreateEventHandlerRequest = {
3648
3563
  /**
3649
3564
  * Origin
3650
3565
  *
3651
- * Provenance of the handler. `tenant` = author by graph owner; `hub` = platform-shipped template (immutable for tenants).
3566
+ * Provenance of the handler. `tenant` = authored on this graph, the only value a caller may set; `hub` = platform-shipped template.
3652
3567
  */
3653
3568
  origin?: 'hub' | 'tenant';
3654
3569
  /**
@@ -4271,6 +4186,12 @@ export type CreateTaxonomyBlockRequest = {
4271
4186
  * Required when `taxonomy_type == 'reporting_extension'` — the id of the library `reporting_standard` being extended.
4272
4187
  */
4273
4188
  parent_taxonomy_id?: string | null;
4189
+ /**
4190
+ * Entity Id
4191
+ *
4192
+ * For a `chart_of_accounts`: the entity whose books it keeps, default the group parent. It becomes that entity's primary chart only if the entity has none; otherwise it is linked beside the primary, which stays. Not read by other types.
4193
+ */
4194
+ entity_id?: string | null;
4274
4195
  /**
4275
4196
  * Version
4276
4197
  */
@@ -6360,6 +6281,12 @@ export type EvaluateRulesRequest = {
6360
6281
  * Upper bound on the fact period window (inclusive).
6361
6282
  */
6362
6283
  period_end?: string | null;
6284
+ /**
6285
+ * Entity Id
6286
+ *
6287
+ * The entity whose facts bind, when no `fact_set_id` pins them; default the group parent. On a group, each entity's statements share the structure.
6288
+ */
6289
+ entity_id?: string | null;
6363
6290
  };
6364
6291
 
6365
6292
  /**
@@ -6908,6 +6835,18 @@ export type FactRecord = {
6908
6835
  * Entity name; present only when an entity filter was applied
6909
6836
  */
6910
6837
  entity_name?: string | null;
6838
+ /**
6839
+ * Presentation
6840
+ *
6841
+ * 'as_closed' when the value is the one the period's close stamped, kept as the month closed; null otherwise. A live read of the books (live-financial-statement) can differ from it once a mapping is reclassified after the close.
6842
+ */
6843
+ presentation?: string | null;
6844
+ /**
6845
+ * Stamped At
6846
+ *
6847
+ * When the close stamped the value (ISO 8601); set with 'as_closed'.
6848
+ */
6849
+ stamped_at?: string | null;
6911
6850
  };
6912
6851
 
6913
6852
  /**
@@ -7297,7 +7236,7 @@ export type FiscalCalendarResponse = {
7297
7236
  /**
7298
7237
  * Blockers
7299
7238
  *
7300
- * Structured blocker codes when closeable_now is False: 'sequence_violation', 'period_incomplete', 'sync_stale', 'calendar_not_initialized', 'period_already_closed', 'pending_obligations', 'stranded_obligations', 'reconciling_items', 'unposted_source_events', 'unreconciled_accounts'; on the consolidation entity, whose close is the group's, also 'entity_open', 'adjustments_unposted', 'residual_unexplained', 'consolidated_does_not_foot'
7239
+ * Structured blocker codes when closeable_now is False: 'sequence_violation', 'period_incomplete', 'sync_stale', 'calendar_not_initialized', 'period_already_closed', 'pending_obligations', 'stranded_obligations', 'reconciling_items', 'unposted_source_events', 'unreconciled_accounts', 'held_bank_lines'; on the consolidation entity, whose close is the group's, also 'entity_open', 'adjustments_unposted', 'residual_unexplained', 'consolidated_does_not_foot'
7301
7240
  */
7302
7241
  blockers?: Array<string>;
7303
7242
  /**
@@ -7360,6 +7299,18 @@ export type FiscalCalendarResponse = {
7360
7299
  * Source identifiers (or event ids) of up to 5 unposted source events, so the blocker names what is holding the close.
7361
7300
  */
7362
7301
  unposted_source_event_sample?: Array<string>;
7302
+ /**
7303
+ * Held Bank Line Count
7304
+ *
7305
+ * Bank lines a sync held out of an earlier, closed month — dated there, arriving after it closed — that no close has decided on. They block the next close: reopen the month they are dated in, which gives them back to post, or close over them knowingly with allow_held_bank_lines. Listed by list-event-blocks with status='voided' and void_reason 'feed_in_closed_month'.
7306
+ */
7307
+ held_bank_line_count?: number;
7308
+ /**
7309
+ * Held Bank Line Sample
7310
+ *
7311
+ * Up to 5 held lines, oldest first, as 'date: description amount [event id]', so the blocker names what is holding the close.
7312
+ */
7313
+ held_bank_line_sample?: Array<string>;
7363
7314
  /**
7364
7315
  * Unreconciled Account Count
7365
7316
  *
@@ -10628,6 +10579,12 @@ export type LiveFinancialStatementResponse = {
10628
10579
  * The entities summed, parent first; on `consolidated` the consolidation entity comes last.
10629
10580
  */
10630
10581
  combined_entity_ids?: Array<string>;
10582
+ /**
10583
+ * Presentation
10584
+ *
10585
+ * Always 'live': the books as they stand, through the current mapping. A closed month's figures as its close stamped them (`as_closed` on build-fact-grid and on statement columns) can differ once a mapping was reclassified after the close.
10586
+ */
10587
+ presentation?: string;
10631
10588
  /**
10632
10589
  * Statement Type
10633
10590
  */
@@ -11781,52 +11738,6 @@ export type OperationEnvelopeAssociationResponse = {
11781
11738
  idempotentReplay?: boolean;
11782
11739
  };
11783
11740
 
11784
- /**
11785
- * OperationEnvelope[BackfillPlanHistoryResponse]
11786
- */
11787
- export type OperationEnvelopeBackfillPlanHistoryResponse = {
11788
- /**
11789
- * Operation
11790
- *
11791
- * Kebab-case operation name
11792
- */
11793
- operation: string;
11794
- /**
11795
- * Operationid
11796
- *
11797
- * op_-prefixed ULID for audit and SSE correlation
11798
- */
11799
- operationId: string;
11800
- /**
11801
- * Status
11802
- *
11803
- * Operation lifecycle state
11804
- */
11805
- status: 'completed' | 'pending' | 'failed';
11806
- /**
11807
- * Command-specific result payload
11808
- */
11809
- result?: BackfillPlanHistoryResponse | null;
11810
- /**
11811
- * At
11812
- *
11813
- * ISO-8601 UTC timestamp
11814
- */
11815
- at: string;
11816
- /**
11817
- * Createdby
11818
- *
11819
- * User ID that initiated the operation
11820
- */
11821
- createdBy?: string | null;
11822
- /**
11823
- * Idempotentreplay
11824
- *
11825
- * True when this envelope came from the idempotency cache — the underlying command did not execute again. False on fresh executions.
11826
- */
11827
- idempotentReplay?: boolean;
11828
- };
11829
-
11830
11741
  /**
11831
11742
  * OperationEnvelope[BindTextBlockResponse]
11832
11743
  */
@@ -16592,7 +16503,7 @@ export type ReconciliationComponent = {
16592
16503
  /**
16593
16504
  * Kind
16594
16505
  *
16595
- * `schedule`, `statement`, or `outstanding`: a ledger line on a bank-fed account that did not come from the feed, dated on or before the statement, so the bank had not cleared it.
16506
+ * `schedule`, `statement`, `outstanding`: a ledger line on a bank-fed account that did not come from the feed, dated on or before the statement, so the bank had not cleared it; or `stale_outstanding`: such a line dated before the statement's cycle, which the bank should have cleared by now. A stale line is listed but not counted toward the balance, so the difference it would explain stays unexplained until it clears, is voided or is re-dated.
16596
16507
  */
16597
16508
  kind?: string | null;
16598
16509
  /**
@@ -17466,7 +17377,7 @@ export type RecordStatementBalanceRequest = {
17466
17377
  /**
17467
17378
  * Document Id
17468
17379
  *
17469
- * The statement itself, as a document already added with create-document. Kept on the record as evidence.
17380
+ * The statement itself, as a document already added with create-document. Kept on the record as evidence. Recording the same account and date again keeps the earlier record's document when this is omitted; an empty string drops it.
17470
17381
  */
17471
17382
  document_id?: string | null;
17472
17383
  /**
@@ -17722,6 +17633,18 @@ export type RenderingPeriodLite = {
17722
17633
  * True when this column comes from a forecast scenario's FactSet — the machine-readable seam marker (labels also carry a '(forecast)' suffix, but consumers should key styling off this flag, not label parsing). None/absent = an actuals column.
17723
17634
  */
17724
17635
  forecast?: boolean | null;
17636
+ /**
17637
+ * Presentation
17638
+ *
17639
+ * 'as_closed' when the column's figures are the ones its month's close stamped, kept as the month closed; a live read of the books (live-financial-statement) can differ from them once a mapping is reclassified after the close. None for a report's own snapshot or a forecast column.
17640
+ */
17641
+ presentation?: string | null;
17642
+ /**
17643
+ * Stamped At
17644
+ *
17645
+ * When the close stamped the column; set with 'as_closed'.
17646
+ */
17647
+ stamped_at?: string | null;
17725
17648
  };
17726
17649
 
17727
17650
  /**
@@ -34044,10 +33967,10 @@ export type BackfillPlanHistoryResponses = {
34044
33967
  /**
34045
33968
  * Successful Response
34046
33969
  */
34047
- 200: OperationEnvelopeBackfillPlanHistoryResponse;
33970
+ 202: OperationEnvelope;
34048
33971
  };
34049
33972
 
34050
- export type BackfillPlanHistoryResponse2 = BackfillPlanHistoryResponses[keyof BackfillPlanHistoryResponses];
33973
+ export type BackfillPlanHistoryResponse = BackfillPlanHistoryResponses[keyof BackfillPlanHistoryResponses];
34051
33974
 
34052
33975
  export type PromoteObligationsData = {
34053
33976
  body: PromoteObligationsRequest;
package/sdk.gen.d.ts CHANGED
@@ -1078,7 +1078,7 @@ export declare const createEventBlock: <ThrowOnError extends boolean = false>(op
1078
1078
  /**
1079
1079
  * Update Event Block
1080
1080
  *
1081
- * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; a bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
1081
+ * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler (else the matching event handler's template) fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; an event with a handler cannot skip to pending or fulfilled without rows. A bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
1082
1082
  *
1083
1083
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1084
1084
  */
@@ -1150,7 +1150,7 @@ export declare const refreshReconciliations: <ThrowOnError extends boolean = fal
1150
1150
  /**
1151
1151
  * Record Statement Balance
1152
1152
  *
1153
- * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off. Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
1153
+ * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; one dated before the statement's own cycle is listed as `stale_outstanding` and does not, since the bank should have cleared it by now, so the difference stays until it clears, is voided or is re-dated; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off, and recording it again without one keeps the document already attached (an empty string detaches it). Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
1154
1154
  *
1155
1155
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1156
1156
  */
@@ -1238,7 +1238,7 @@ export declare const reopenPeriod: <ThrowOnError extends boolean = false>(option
1238
1238
  /**
1239
1239
  * Backfill Plan History
1240
1240
  *
1241
- * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists.
1241
+ * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists. Runs on the background worker, since a chunk recloses up to 24 months: returns a `pending` envelope at once, and the result — the outcome per month and `remaining_periods`, or a refusal under `error` — arrives on `/v1/operations/{operation_id}/stream`.
1242
1242
  *
1243
1243
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1244
1244
  */
package/sdk.gen.js CHANGED
@@ -2215,7 +2215,7 @@ exports.createEventBlock = createEventBlock;
2215
2215
  /**
2216
2216
  * Update Event Block
2217
2217
  *
2218
- * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; a bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
2218
+ * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler (else the matching event handler's template) fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; an event with a handler cannot skip to pending or fulfilled without rows. A bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
2219
2219
  *
2220
2220
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2221
2221
  */
@@ -2368,7 +2368,7 @@ exports.refreshReconciliations = refreshReconciliations;
2368
2368
  /**
2369
2369
  * Record Statement Balance
2370
2370
  *
2371
- * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off. Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
2371
+ * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; one dated before the statement's own cycle is listed as `stale_outstanding` and does not, since the bank should have cleared it by now, so the difference stays until it clears, is voided or is re-dated; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off, and recording it again without one keeps the document already attached (an empty string detaches it). Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
2372
2372
  *
2373
2373
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2374
2374
  */
@@ -2555,7 +2555,7 @@ exports.reopenPeriod = reopenPeriod;
2555
2555
  /**
2556
2556
  * Backfill Plan History
2557
2557
  *
2558
- * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists.
2558
+ * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists. Runs on the background worker, since a chunk recloses up to 24 months: returns a `pending` envelope at once, and the result — the outcome per month and `remaining_periods`, or a refusal under `error` — arrives on `/v1/operations/{operation_id}/stream`.
2559
2559
  *
2560
2560
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2561
2561
  */
package/sdk.gen.ts CHANGED
@@ -2226,7 +2226,7 @@ export const createEventBlock = <ThrowOnError extends boolean = false>(options:
2226
2226
  /**
2227
2227
  * Update Event Block
2228
2228
  *
2229
- * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; a bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
2229
+ * Apply a status transition (captured → classified | committed | voided) and/or field corrections (description, effective_at, metadata_patch) to an existing event block. Only supplied fields are updated. captured → classified records an account choice without posting — for a bank-feed line, patch metadata.classified_element_id (or accept_suggestion: true) in the same call. When the transition is captured/classified → committed, the registered Python handler (else the matching event handler's template) fires against the captured metadata to produce the GL rows, unless it already wrote them when the event was created; an event with a handler cannot skip to pending or fulfilled without rows. A bank-feed line with no account chosen and no matching rule is refused. Errors from the handler (validation, element resolution, closed period, unbalanced lines) surface as 422 here so the inbox UI can display the failure reason without retry. A bank line's flow is a second classification beside its account, overriding the account's default flow on the cash flow and equity statements: patch `classified_flow_qname` (or `flow_qname` on each `classified_allocations` part) with an rs-gaap flow concept such as `rs-gaap:ProceedsFromIssuanceOfLongTermDebt`. On a line that has already posted, this re-tags its lines in place, in a closed month too, since no balance moves; an empty string clears it. A payment or bank line records the invoices or bills it settles with `discharge_allocations` (positive cents per document, together at most its amount) or one `discharges_event_id`; each is checked: an invoice for money in, a bill for money out, on its own entity, not voided.
2230
2230
  *
2231
2231
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2232
2232
  */
@@ -2379,7 +2379,7 @@ export const refreshReconciliations = <ThrowOnError extends boolean = false>(opt
2379
2379
  /**
2380
2380
  * Record Statement Balance
2381
2381
  *
2382
- * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off. Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
2382
+ * Record the ending balance of a statement (a bank, card or loan statement) for one balance-sheet account, and reconcile the account to it. Give the balance as the statement shows it, as a positive number in the account's normal direction, with the statement's ending date. The ledger's balance at that date is set beside it, counting the drafts the close will post, and the result is recorded on the account's statement reconciliation for the period the statement ends in. On an account a bank feed keeps, ledger lines that did not come from the feed and are dated on or before the statement are listed as outstanding and adjust the statement balance, since the bank had not cleared them; one dated before the statement's own cycle is listed as `stale_outstanding` and does not, since the bank should have cleared it by now, so the difference stays until it clears, is voided or is re-dated; a statement ending before the period's last day is carried to it by the feed's own lines (`roll_forward`). Attach the statement as evidence by passing the `document_id` of its stored file (create-document-upload, then complete-document-upload); recording it again with another document lapses a sign-off, and recording it again without one keeps the document already attached (an empty string detaches it). Writes no books. The first statement recorded for an account creates its reconciliation, which does not hold the close: turn `required_for_close` on with set-reconciliation-policy to make every period's close wait for a statement on that account. Recording the same account and date again replaces the earlier balance; when more than one statement ends in a period, the one with the latest date stands. Recording a balance that differs from one already signed off lapses that sign-off. A difference left after the outstanding lines is activity one side has and the other does not yet, or an error on either. Returns the reconciliation's standing for the period.
2383
2383
  *
2384
2384
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2385
2385
  */
@@ -2566,7 +2566,7 @@ export const reopenPeriod = <ThrowOnError extends boolean = false>(options: Opti
2566
2566
  /**
2567
2567
  * Backfill Plan History
2568
2568
  *
2569
- * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists.
2569
+ * Compile monthly statement history behind the close boundary — the plan's historical columns. Seeds any missing FiscalPeriod rows (baseline-closed) back to the clamped `start_period`, then restamps each month lacking canonical statement FactSets by running the real reopen → reclose cycle (balance validation, statement rules, and audit events per month). Chunked: at most `max_periods` months per call, oldest first — loop until `remaining_periods` comes back empty. Idempotent: already-stamped months are never touched. Months holding draft entries are skipped, never posted. `start_period` is clamped to the earliest month with ledger data, so deep-history tenants only backfill what actually exists. Runs on the background worker, since a chunk recloses up to 24 months: returns a `pending` envelope at once, and the result — the outcome per month and `remaining_periods`, or a refusal under `error` — arrives on `/v1/operations/{operation_id}/stream`.
2570
2570
  *
2571
2571
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
2572
2572
  */