@firela/api-types 0.0.0-canary.ba0a88d9 → 0.0.0-canary.bd624c6e
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/dist/index.d.mts +4636 -2545
- package/dist/index.d.ts +4636 -2545
- package/dist/index.js +90 -6
- package/dist/index.mjs +90 -6
- package/package.json +2 -3
- package/src/generated/schemas.gen.ts +2598 -557
- package/src/generated/services.gen.ts +1332 -405
- package/src/generated/types.gen.ts +5244 -2874
|
@@ -17,6 +17,8 @@ import type {
|
|
|
17
17
|
AccountControllerCloseResponse,
|
|
18
18
|
AccountControllerReopenData,
|
|
19
19
|
AccountControllerReopenResponse,
|
|
20
|
+
AccountControllerAddOpeningBalanceData,
|
|
21
|
+
AccountControllerAddOpeningBalanceResponse,
|
|
20
22
|
AccountStandardsControllerGetTemplatesData,
|
|
21
23
|
AccountStandardsControllerGetTemplatesResponse,
|
|
22
24
|
AccountStandardsControllerGetTemplateMetadataData,
|
|
@@ -29,6 +31,10 @@ import type {
|
|
|
29
31
|
TransactionControllerListResponse,
|
|
30
32
|
TransactionControllerCreateBatchData,
|
|
31
33
|
TransactionControllerCreateBatchResponse,
|
|
34
|
+
TransactionControllerCorrectData,
|
|
35
|
+
TransactionControllerCorrectResponse,
|
|
36
|
+
TransactionControllerSuggestTagsData,
|
|
37
|
+
TransactionControllerSuggestTagsResponse,
|
|
32
38
|
TransactionControllerGetDetailData,
|
|
33
39
|
TransactionControllerGetDetailResponse,
|
|
34
40
|
TransactionControllerUpdateData,
|
|
@@ -93,6 +99,18 @@ import type {
|
|
|
93
99
|
CommodityControllerGetOrCreateResponse,
|
|
94
100
|
CommodityControllerBulkCreateData,
|
|
95
101
|
CommodityControllerBulkCreateResponse,
|
|
102
|
+
PriceControllerCreateData,
|
|
103
|
+
PriceControllerCreateResponse,
|
|
104
|
+
PriceControllerFindAllData,
|
|
105
|
+
PriceControllerFindAllResponse,
|
|
106
|
+
PriceControllerFindOneData,
|
|
107
|
+
PriceControllerFindOneResponse,
|
|
108
|
+
PriceControllerUpdateData,
|
|
109
|
+
PriceControllerUpdateResponse,
|
|
110
|
+
PriceControllerDeleteData,
|
|
111
|
+
PriceControllerDeleteResponse,
|
|
112
|
+
PriceControllerBulkCreateData,
|
|
113
|
+
PriceControllerBulkCreateResponse,
|
|
96
114
|
RecurringRuleControllerCreateData,
|
|
97
115
|
RecurringRuleControllerCreateResponse,
|
|
98
116
|
RecurringRuleControllerFindAllData,
|
|
@@ -125,26 +143,14 @@ import type {
|
|
|
125
143
|
ExpectedTransactionControllerEnterNowResponse,
|
|
126
144
|
ForecastControllerGetForecastData,
|
|
127
145
|
ForecastControllerGetForecastResponse,
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
TransactionRuleControllerExportData,
|
|
137
|
-
TransactionRuleControllerExportResponse,
|
|
138
|
-
TransactionRuleControllerGetStatisticsData,
|
|
139
|
-
TransactionRuleControllerGetStatisticsResponse,
|
|
140
|
-
TransactionRuleControllerGetDetailData,
|
|
141
|
-
TransactionRuleControllerGetDetailResponse,
|
|
142
|
-
TransactionRuleControllerUpdateData,
|
|
143
|
-
TransactionRuleControllerUpdateResponse,
|
|
144
|
-
TransactionRuleControllerDeleteData,
|
|
145
|
-
TransactionRuleControllerDeleteResponse,
|
|
146
|
-
TransactionRuleControllerTestData,
|
|
147
|
-
TransactionRuleControllerTestResponse,
|
|
146
|
+
ReportingControllerGetPortfolioTrendsData,
|
|
147
|
+
ReportingControllerGetPortfolioTrendsResponse,
|
|
148
|
+
ReportingControllerGetCashFlowTrendsData,
|
|
149
|
+
ReportingControllerGetCashFlowTrendsResponse,
|
|
150
|
+
ReportingControllerGenerateSnapshotData,
|
|
151
|
+
ReportingControllerGenerateSnapshotResponse,
|
|
152
|
+
ReportingControllerBackfillSnapshotsData,
|
|
153
|
+
ReportingControllerBackfillSnapshotsResponse,
|
|
148
154
|
UserControllerDeleteOwnUserData,
|
|
149
155
|
UserControllerDeleteOwnUserResponse,
|
|
150
156
|
UserControllerGetUserData,
|
|
@@ -167,6 +173,48 @@ import type {
|
|
|
167
173
|
PropertyControllerUpdateResponse,
|
|
168
174
|
PropertyControllerDeleteData,
|
|
169
175
|
PropertyControllerDeleteResponse,
|
|
176
|
+
TransactionRuleControllerCreateData,
|
|
177
|
+
TransactionRuleControllerCreateResponse,
|
|
178
|
+
TransactionRuleControllerListData,
|
|
179
|
+
TransactionRuleControllerListResponse,
|
|
180
|
+
TransactionRuleControllerValidateData,
|
|
181
|
+
TransactionRuleControllerValidateResponse,
|
|
182
|
+
TransactionRuleControllerBulkCreateData,
|
|
183
|
+
TransactionRuleControllerBulkCreateResponse,
|
|
184
|
+
TransactionRuleControllerExportData,
|
|
185
|
+
TransactionRuleControllerExportResponse,
|
|
186
|
+
TransactionRuleControllerGetStatisticsData,
|
|
187
|
+
TransactionRuleControllerGetStatisticsResponse,
|
|
188
|
+
TransactionRuleControllerGetDetailData,
|
|
189
|
+
TransactionRuleControllerGetDetailResponse,
|
|
190
|
+
TransactionRuleControllerUpdateData,
|
|
191
|
+
TransactionRuleControllerUpdateResponse,
|
|
192
|
+
TransactionRuleControllerDeleteData,
|
|
193
|
+
TransactionRuleControllerDeleteResponse,
|
|
194
|
+
TransactionRuleControllerTestData,
|
|
195
|
+
TransactionRuleControllerTestResponse,
|
|
196
|
+
EventControllerCreateData,
|
|
197
|
+
EventControllerCreateResponse,
|
|
198
|
+
EventControllerFindAllData,
|
|
199
|
+
EventControllerFindAllResponse,
|
|
200
|
+
EventControllerFindOneData,
|
|
201
|
+
EventControllerFindOneResponse,
|
|
202
|
+
EventControllerUpdateData,
|
|
203
|
+
EventControllerUpdateResponse,
|
|
204
|
+
EventControllerDeleteData,
|
|
205
|
+
EventControllerDeleteResponse,
|
|
206
|
+
EventControllerGetSliceData,
|
|
207
|
+
EventControllerGetSliceResponse,
|
|
208
|
+
OnboardingControllerBootstrapData,
|
|
209
|
+
OnboardingControllerBootstrapResponse,
|
|
210
|
+
ReconciliationControllerComputeData,
|
|
211
|
+
ReconciliationControllerComputeResponse,
|
|
212
|
+
ReconciliationControllerAssertData,
|
|
213
|
+
ReconciliationControllerAssertResponse,
|
|
214
|
+
ReconciliationControllerPadData,
|
|
215
|
+
ReconciliationControllerPadResponse,
|
|
216
|
+
ReconciliationControllerHistoryData,
|
|
217
|
+
ReconciliationControllerHistoryResponse,
|
|
170
218
|
ExportControllerExportBeancountResponse,
|
|
171
219
|
FileImportControllerImportFileData,
|
|
172
220
|
FileImportControllerImportFileResponse,
|
|
@@ -180,42 +228,52 @@ import type {
|
|
|
180
228
|
ImporterConfigControllerUpdateConfigResponse,
|
|
181
229
|
ImporterConfigControllerResetConfigData,
|
|
182
230
|
ImporterConfigControllerResetConfigResponse,
|
|
183
|
-
PlatformControllerFindAllResponse,
|
|
184
|
-
PlatformControllerCreateData,
|
|
185
|
-
PlatformControllerCreateResponse,
|
|
186
|
-
PlatformControllerGetPlatformListResponse,
|
|
187
|
-
PlatformControllerMatchPlatformsData,
|
|
188
|
-
PlatformControllerMatchPlatformsResponse,
|
|
189
|
-
PlatformControllerUpdateData,
|
|
190
|
-
PlatformControllerUpdateResponse,
|
|
191
|
-
PlatformControllerDeleteData,
|
|
192
|
-
PlatformControllerDeleteResponse,
|
|
193
231
|
ProviderSyncControllerSyncData,
|
|
194
232
|
ProviderSyncControllerSyncResponse,
|
|
195
233
|
ProviderSyncControllerGetSupportedProvidersData,
|
|
196
234
|
ProviderSyncControllerGetSupportedProvidersResponse,
|
|
197
235
|
ProviderSyncControllerIsProviderSupportedData,
|
|
198
236
|
ProviderSyncControllerIsProviderSupportedResponse,
|
|
237
|
+
ExternalAccountLinkControllerCreateData,
|
|
238
|
+
ExternalAccountLinkControllerCreateResponse,
|
|
239
|
+
ExternalAccountLinkControllerFindAllData,
|
|
240
|
+
ExternalAccountLinkControllerFindAllResponse,
|
|
241
|
+
ExternalAccountLinkControllerFindOneData,
|
|
242
|
+
ExternalAccountLinkControllerFindOneResponse,
|
|
243
|
+
ExternalAccountLinkControllerRemoveData,
|
|
244
|
+
ExternalAccountLinkControllerRemoveResponse,
|
|
199
245
|
TelemetryControllerReportTelemetryData,
|
|
200
246
|
TelemetryControllerReportTelemetryResponse,
|
|
247
|
+
TelemetryControllerReportCoverageMissData,
|
|
248
|
+
TelemetryControllerReportCoverageMissResponse,
|
|
249
|
+
TelemetryControllerGetCoverageMetricsData,
|
|
250
|
+
TelemetryControllerGetCoverageMetricsResponse,
|
|
201
251
|
NlpControllerProcessNaturalLanguageData,
|
|
202
252
|
NlpControllerProcessNaturalLanguageResponse,
|
|
203
253
|
NlpControllerClearSessionData,
|
|
204
254
|
NlpControllerClearSessionResponse,
|
|
205
255
|
NlpControllerGetSessionData,
|
|
206
256
|
NlpControllerGetSessionResponse,
|
|
257
|
+
PlatformControllerFindAllResponse,
|
|
258
|
+
PlatformControllerCreateData,
|
|
259
|
+
PlatformControllerCreateResponse,
|
|
260
|
+
PlatformControllerGetPlatformListResponse,
|
|
261
|
+
PlatformControllerMatchPlatformsData,
|
|
262
|
+
PlatformControllerMatchPlatformsResponse,
|
|
263
|
+
PlatformControllerUpdateData,
|
|
264
|
+
PlatformControllerUpdateResponse,
|
|
265
|
+
PlatformControllerDeleteData,
|
|
266
|
+
PlatformControllerDeleteResponse,
|
|
207
267
|
DashboardControllerGetNetWorthData,
|
|
208
268
|
DashboardControllerGetNetWorthResponse,
|
|
209
269
|
DashboardControllerGetAccountsData,
|
|
210
270
|
DashboardControllerGetAccountsResponse,
|
|
211
271
|
DashboardControllerGetCashFlowData,
|
|
212
272
|
DashboardControllerGetCashFlowResponse,
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
ReportingControllerBackfillSnapshotsData,
|
|
218
|
-
ReportingControllerBackfillSnapshotsResponse,
|
|
273
|
+
DashboardControllerGetExpensesData,
|
|
274
|
+
DashboardControllerGetExpensesResponse,
|
|
275
|
+
HoldingPnlControllerGetHoldingPnlData,
|
|
276
|
+
HoldingPnlControllerGetHoldingPnlResponse,
|
|
219
277
|
ApiKeysControllerCreateApiKeyResponse,
|
|
220
278
|
AuthControllerAccessTokenLoginData,
|
|
221
279
|
AuthControllerAccessTokenLoginResponse,
|
|
@@ -230,7 +288,11 @@ import type {
|
|
|
230
288
|
HealthControllerResetCircuitBreakerData,
|
|
231
289
|
HealthControllerResetCircuitBreakerResponse,
|
|
232
290
|
HealthControllerGetMetricsResponse,
|
|
233
|
-
InfoControllerGetInfoResponse
|
|
291
|
+
InfoControllerGetInfoResponse,
|
|
292
|
+
SymbolControllerSearchData,
|
|
293
|
+
SymbolControllerSearchResponse,
|
|
294
|
+
SymbolControllerGetQuoteData,
|
|
295
|
+
SymbolControllerGetQuoteResponse
|
|
234
296
|
} from './types.gen';
|
|
235
297
|
|
|
236
298
|
export class BeanAccountsService {
|
|
@@ -268,7 +330,7 @@ export class BeanAccountsService {
|
|
|
268
330
|
* @param data.type Filter by account type
|
|
269
331
|
* @param data.status Filter by status
|
|
270
332
|
* @param data.isCustom Filter by custom (user-created) accounts only
|
|
271
|
-
* @param data.search Search term for path
|
|
333
|
+
* @param data.search Search term for account path
|
|
272
334
|
* @param data.limit Maximum number of results
|
|
273
335
|
* @param data.offset Number of results to skip
|
|
274
336
|
* @returns AccountListResponseDto Accounts retrieved successfully
|
|
@@ -349,7 +411,7 @@ export class BeanAccountsService {
|
|
|
349
411
|
|
|
350
412
|
/**
|
|
351
413
|
* Delete account
|
|
352
|
-
* Deletes an account (only if no transactions)
|
|
414
|
+
* Deletes an account (only if no active transactions; voided/superseded residual postings are cleaned up)
|
|
353
415
|
* @param data The data for the request.
|
|
354
416
|
* @param data.id Account UUID
|
|
355
417
|
* @param data.region Region code for tenant context
|
|
@@ -368,7 +430,7 @@ export class BeanAccountsService {
|
|
|
368
430
|
},
|
|
369
431
|
errors: {
|
|
370
432
|
404: 'Account not found',
|
|
371
|
-
409: 'Account has transactions and cannot be deleted'
|
|
433
|
+
409: 'Account has active transactions and cannot be deleted'
|
|
372
434
|
}
|
|
373
435
|
});
|
|
374
436
|
}
|
|
@@ -430,6 +492,35 @@ export class BeanAccountsService {
|
|
|
430
492
|
}
|
|
431
493
|
});
|
|
432
494
|
}
|
|
495
|
+
|
|
496
|
+
/**
|
|
497
|
+
* Post an opening-balance transaction
|
|
498
|
+
* Posts a double-entry opening-balance transaction against Equity:Opening-Balances for an existing Assets/Liabilities account. At most one active opening balance per account.
|
|
499
|
+
* @param data The data for the request.
|
|
500
|
+
* @param data.id Account UUID
|
|
501
|
+
* @param data.region Region code for tenant context
|
|
502
|
+
* @param data.requestBody
|
|
503
|
+
* @returns OpeningBalanceResultDto Opening-balance transaction created
|
|
504
|
+
* @throws ApiError
|
|
505
|
+
*/
|
|
506
|
+
public static accountControllerAddOpeningBalance(
|
|
507
|
+
data: AccountControllerAddOpeningBalanceData
|
|
508
|
+
): CancelablePromise<AccountControllerAddOpeningBalanceResponse> {
|
|
509
|
+
return __request(OpenAPI, {
|
|
510
|
+
method: 'POST',
|
|
511
|
+
url: '/api/v1/{region}/bean/accounts/{id}/opening-balance',
|
|
512
|
+
path: {
|
|
513
|
+
id: data.id,
|
|
514
|
+
region: data.region
|
|
515
|
+
},
|
|
516
|
+
body: data.requestBody,
|
|
517
|
+
mediaType: 'application/json',
|
|
518
|
+
errors: {
|
|
519
|
+
404: 'Account not found',
|
|
520
|
+
409: 'An opening balance already exists for this account'
|
|
521
|
+
}
|
|
522
|
+
});
|
|
523
|
+
}
|
|
433
524
|
}
|
|
434
525
|
|
|
435
526
|
export class BeanAccountStandardsService {
|
|
@@ -461,7 +552,7 @@ export class BeanAccountStandardsService {
|
|
|
461
552
|
|
|
462
553
|
/**
|
|
463
554
|
* Get template metadata for an account path
|
|
464
|
-
* Returns
|
|
555
|
+
* Returns root type for a template path.
|
|
465
556
|
* @param data The data for the request.
|
|
466
557
|
* @param data.region Region code for tenant context
|
|
467
558
|
* @param data.path Account path to check
|
|
@@ -547,6 +638,7 @@ export class BeanTransactionsService {
|
|
|
547
638
|
* @param data.status Filter by transaction status
|
|
548
639
|
* @param data.search Search in narration and payee fields (max 200 chars)
|
|
549
640
|
* @param data.accountId Filter by account ID (transactions with postings to this account)
|
|
641
|
+
* @param data.category Filter by ADR-0075 functional category (Group segment); matches any posting to an Expenses/Income account whose derived Group segment equals this value
|
|
550
642
|
* @returns TransactionListResponseDto Transaction list
|
|
551
643
|
* @throws ApiError
|
|
552
644
|
*/
|
|
@@ -566,7 +658,8 @@ export class BeanTransactionsService {
|
|
|
566
658
|
dateTo: data.dateTo,
|
|
567
659
|
status: data.status,
|
|
568
660
|
search: data.search,
|
|
569
|
-
accountId: data.accountId
|
|
661
|
+
accountId: data.accountId,
|
|
662
|
+
category: data.category
|
|
570
663
|
},
|
|
571
664
|
errors: {
|
|
572
665
|
400: 'Validation failed',
|
|
@@ -603,6 +696,68 @@ export class BeanTransactionsService {
|
|
|
603
696
|
});
|
|
604
697
|
}
|
|
605
698
|
|
|
699
|
+
/**
|
|
700
|
+
* Correct (supersede) a transaction
|
|
701
|
+
* Atomically voids the original (SUPERSEDED) and creates a replacement through the full validation pipeline.
|
|
702
|
+
* @param data The data for the request.
|
|
703
|
+
* @param data.id Original transaction ID to correct
|
|
704
|
+
* @param data.region Region code for tenant context
|
|
705
|
+
* @param data.requestBody
|
|
706
|
+
* @returns TransactionDetailDto Corrected transaction created
|
|
707
|
+
* @throws ApiError
|
|
708
|
+
*/
|
|
709
|
+
public static transactionControllerCorrect(
|
|
710
|
+
data: TransactionControllerCorrectData
|
|
711
|
+
): CancelablePromise<TransactionControllerCorrectResponse> {
|
|
712
|
+
return __request(OpenAPI, {
|
|
713
|
+
method: 'POST',
|
|
714
|
+
url: '/api/v1/{region}/bean/transactions/{id}/correct',
|
|
715
|
+
path: {
|
|
716
|
+
id: data.id,
|
|
717
|
+
region: data.region
|
|
718
|
+
},
|
|
719
|
+
body: data.requestBody,
|
|
720
|
+
mediaType: 'application/json',
|
|
721
|
+
errors: {
|
|
722
|
+
404: 'Original transaction not found',
|
|
723
|
+
409: 'Original no longer ACTIVE (concurrent modification)',
|
|
724
|
+
422: 'Pipeline validation failed (does not balance, invalid accounts)'
|
|
725
|
+
}
|
|
726
|
+
});
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
/**
|
|
730
|
+
* Suggest transaction tags
|
|
731
|
+
* Returns distinct tags from the user ACTIVE transactions, sorted by usage, for autocomplete. Optional q performs a case-insensitive prefix match.
|
|
732
|
+
* @param data The data for the request.
|
|
733
|
+
* @param data.region Region code for tenant context
|
|
734
|
+
* @param data.q Prefix match, case-insensitive (max 50 chars)
|
|
735
|
+
* @param data.sort usage (default) or name
|
|
736
|
+
* @param data.limit Max suggestions (1-100, default 10)
|
|
737
|
+
* @returns TagSuggestionsResponseDto Tag suggestions
|
|
738
|
+
* @throws ApiError
|
|
739
|
+
*/
|
|
740
|
+
public static transactionControllerSuggestTags(
|
|
741
|
+
data: TransactionControllerSuggestTagsData
|
|
742
|
+
): CancelablePromise<TransactionControllerSuggestTagsResponse> {
|
|
743
|
+
return __request(OpenAPI, {
|
|
744
|
+
method: 'GET',
|
|
745
|
+
url: '/api/v1/{region}/bean/transactions/tags',
|
|
746
|
+
path: {
|
|
747
|
+
region: data.region
|
|
748
|
+
},
|
|
749
|
+
query: {
|
|
750
|
+
q: data.q,
|
|
751
|
+
sort: data.sort,
|
|
752
|
+
limit: data.limit
|
|
753
|
+
},
|
|
754
|
+
errors: {
|
|
755
|
+
400: 'Validation failed',
|
|
756
|
+
401: 'Authentication required'
|
|
757
|
+
}
|
|
758
|
+
});
|
|
759
|
+
}
|
|
760
|
+
|
|
606
761
|
/**
|
|
607
762
|
* Get transaction detail
|
|
608
763
|
* Returns transaction details including all postings
|
|
@@ -692,7 +847,7 @@ export class BeanBalancesService {
|
|
|
692
847
|
* Query account balance
|
|
693
848
|
* Calculate account balance at a specific date for a single currency
|
|
694
849
|
* @param data The data for the request.
|
|
695
|
-
* @param data.account Account name (e.g., "Assets:
|
|
850
|
+
* @param data.account Account name (e.g., "Assets:Checking")
|
|
696
851
|
* @param data.region Region code for tenant context
|
|
697
852
|
* @param data.date Date to calculate balance at (ISO 8601 format)
|
|
698
853
|
* @param data.currency Currency to query (e.g., "USD", "CNY")
|
|
@@ -1413,6 +1568,173 @@ export class BeanCommoditiesService {
|
|
|
1413
1568
|
}
|
|
1414
1569
|
}
|
|
1415
1570
|
|
|
1571
|
+
export class BeanPricesService {
|
|
1572
|
+
/**
|
|
1573
|
+
* Create a new price
|
|
1574
|
+
* Creates a new price entry for the authenticated user
|
|
1575
|
+
* @param data The data for the request.
|
|
1576
|
+
* @param data.region Region code for tenant context
|
|
1577
|
+
* @param data.requestBody
|
|
1578
|
+
* @returns PriceResponseDto Price created successfully
|
|
1579
|
+
* @throws ApiError
|
|
1580
|
+
*/
|
|
1581
|
+
public static priceControllerCreate(
|
|
1582
|
+
data: PriceControllerCreateData
|
|
1583
|
+
): CancelablePromise<PriceControllerCreateResponse> {
|
|
1584
|
+
return __request(OpenAPI, {
|
|
1585
|
+
method: 'POST',
|
|
1586
|
+
url: '/api/v1/{region}/bean/prices',
|
|
1587
|
+
path: {
|
|
1588
|
+
region: data.region
|
|
1589
|
+
},
|
|
1590
|
+
body: data.requestBody,
|
|
1591
|
+
mediaType: 'application/json',
|
|
1592
|
+
errors: {
|
|
1593
|
+
404: 'Currency or quoteCurrency commodity not found',
|
|
1594
|
+
409: 'Price already exists for this currency pair and date'
|
|
1595
|
+
}
|
|
1596
|
+
});
|
|
1597
|
+
}
|
|
1598
|
+
|
|
1599
|
+
/**
|
|
1600
|
+
* List user prices
|
|
1601
|
+
* Returns all price entries for the authenticated user with optional filtering
|
|
1602
|
+
* @param data The data for the request.
|
|
1603
|
+
* @param data.region Region code for tenant context
|
|
1604
|
+
* @param data.currency Filter by currency (e.g., BTC, AAPL, USD)
|
|
1605
|
+
* @param data.quoteCurrency Filter by quote currency (pricing currency, e.g., USD, CNY)
|
|
1606
|
+
* @param data.dateFrom Filter prices from this date (ISO 8601 format)
|
|
1607
|
+
* @param data.dateTo Filter prices to this date (ISO 8601 format)
|
|
1608
|
+
* @param data.search Search term for currency or quoteCurrency (case-insensitive partial match)
|
|
1609
|
+
* @param data.page Page number for pagination (default: 1)
|
|
1610
|
+
* @param data.limit Number of items per page (default: 20, max: 100)
|
|
1611
|
+
* @returns PriceListResponseDto Prices retrieved successfully
|
|
1612
|
+
* @throws ApiError
|
|
1613
|
+
*/
|
|
1614
|
+
public static priceControllerFindAll(
|
|
1615
|
+
data: PriceControllerFindAllData
|
|
1616
|
+
): CancelablePromise<PriceControllerFindAllResponse> {
|
|
1617
|
+
return __request(OpenAPI, {
|
|
1618
|
+
method: 'GET',
|
|
1619
|
+
url: '/api/v1/{region}/bean/prices',
|
|
1620
|
+
path: {
|
|
1621
|
+
region: data.region
|
|
1622
|
+
},
|
|
1623
|
+
query: {
|
|
1624
|
+
currency: data.currency,
|
|
1625
|
+
quoteCurrency: data.quoteCurrency,
|
|
1626
|
+
dateFrom: data.dateFrom,
|
|
1627
|
+
dateTo: data.dateTo,
|
|
1628
|
+
search: data.search,
|
|
1629
|
+
page: data.page,
|
|
1630
|
+
limit: data.limit
|
|
1631
|
+
}
|
|
1632
|
+
});
|
|
1633
|
+
}
|
|
1634
|
+
|
|
1635
|
+
/**
|
|
1636
|
+
* Get price by ID
|
|
1637
|
+
* Returns a single price entry by its ID
|
|
1638
|
+
* @param data The data for the request.
|
|
1639
|
+
* @param data.id Price ID
|
|
1640
|
+
* @param data.region Region code for tenant context
|
|
1641
|
+
* @returns PriceResponseDto Price retrieved successfully
|
|
1642
|
+
* @throws ApiError
|
|
1643
|
+
*/
|
|
1644
|
+
public static priceControllerFindOne(
|
|
1645
|
+
data: PriceControllerFindOneData
|
|
1646
|
+
): CancelablePromise<PriceControllerFindOneResponse> {
|
|
1647
|
+
return __request(OpenAPI, {
|
|
1648
|
+
method: 'GET',
|
|
1649
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1650
|
+
path: {
|
|
1651
|
+
id: data.id,
|
|
1652
|
+
region: data.region
|
|
1653
|
+
},
|
|
1654
|
+
errors: {
|
|
1655
|
+
404: 'Price not found'
|
|
1656
|
+
}
|
|
1657
|
+
});
|
|
1658
|
+
}
|
|
1659
|
+
|
|
1660
|
+
/**
|
|
1661
|
+
* Update a price
|
|
1662
|
+
* Updates an existing price entry
|
|
1663
|
+
* @param data The data for the request.
|
|
1664
|
+
* @param data.id Price ID
|
|
1665
|
+
* @param data.region Region code for tenant context
|
|
1666
|
+
* @param data.requestBody
|
|
1667
|
+
* @returns PriceResponseDto Price updated successfully
|
|
1668
|
+
* @throws ApiError
|
|
1669
|
+
*/
|
|
1670
|
+
public static priceControllerUpdate(
|
|
1671
|
+
data: PriceControllerUpdateData
|
|
1672
|
+
): CancelablePromise<PriceControllerUpdateResponse> {
|
|
1673
|
+
return __request(OpenAPI, {
|
|
1674
|
+
method: 'PUT',
|
|
1675
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1676
|
+
path: {
|
|
1677
|
+
id: data.id,
|
|
1678
|
+
region: data.region
|
|
1679
|
+
},
|
|
1680
|
+
body: data.requestBody,
|
|
1681
|
+
mediaType: 'application/json',
|
|
1682
|
+
errors: {
|
|
1683
|
+
404: 'Price not found',
|
|
1684
|
+
409: 'Updated price conflicts with existing price'
|
|
1685
|
+
}
|
|
1686
|
+
});
|
|
1687
|
+
}
|
|
1688
|
+
|
|
1689
|
+
/**
|
|
1690
|
+
* Delete a price
|
|
1691
|
+
* Deletes a price entry (hard delete)
|
|
1692
|
+
* @param data The data for the request.
|
|
1693
|
+
* @param data.id Price ID
|
|
1694
|
+
* @param data.region Region code for tenant context
|
|
1695
|
+
* @returns void Price deleted successfully
|
|
1696
|
+
* @throws ApiError
|
|
1697
|
+
*/
|
|
1698
|
+
public static priceControllerDelete(
|
|
1699
|
+
data: PriceControllerDeleteData
|
|
1700
|
+
): CancelablePromise<PriceControllerDeleteResponse> {
|
|
1701
|
+
return __request(OpenAPI, {
|
|
1702
|
+
method: 'DELETE',
|
|
1703
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1704
|
+
path: {
|
|
1705
|
+
id: data.id,
|
|
1706
|
+
region: data.region
|
|
1707
|
+
},
|
|
1708
|
+
errors: {
|
|
1709
|
+
404: 'Price not found'
|
|
1710
|
+
}
|
|
1711
|
+
});
|
|
1712
|
+
}
|
|
1713
|
+
|
|
1714
|
+
/**
|
|
1715
|
+
* Bulk create prices
|
|
1716
|
+
* Creates multiple price entries at once (skips duplicates)
|
|
1717
|
+
* @param data The data for the request.
|
|
1718
|
+
* @param data.region Region code for tenant context
|
|
1719
|
+
* @param data.requestBody
|
|
1720
|
+
* @returns PriceResponseDto Prices created successfully
|
|
1721
|
+
* @throws ApiError
|
|
1722
|
+
*/
|
|
1723
|
+
public static priceControllerBulkCreate(
|
|
1724
|
+
data: PriceControllerBulkCreateData
|
|
1725
|
+
): CancelablePromise<PriceControllerBulkCreateResponse> {
|
|
1726
|
+
return __request(OpenAPI, {
|
|
1727
|
+
method: 'POST',
|
|
1728
|
+
url: '/api/v1/{region}/bean/prices/bulk',
|
|
1729
|
+
path: {
|
|
1730
|
+
region: data.region
|
|
1731
|
+
},
|
|
1732
|
+
body: data.requestBody,
|
|
1733
|
+
mediaType: 'application/json'
|
|
1734
|
+
});
|
|
1735
|
+
}
|
|
1736
|
+
}
|
|
1737
|
+
|
|
1416
1738
|
export class RecurringRulesService {
|
|
1417
1739
|
/**
|
|
1418
1740
|
* Create a new recurring rule
|
|
@@ -1843,22 +2165,434 @@ export class RecurringForecastService {
|
|
|
1843
2165
|
}
|
|
1844
2166
|
}
|
|
1845
2167
|
|
|
1846
|
-
export class
|
|
2168
|
+
export class ReportingService {
|
|
1847
2169
|
/**
|
|
1848
|
-
*
|
|
1849
|
-
*
|
|
1850
|
-
*
|
|
1851
|
-
*
|
|
1852
|
-
*
|
|
1853
|
-
*
|
|
1854
|
-
*
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
2170
|
+
* Get portfolio value trends
|
|
2171
|
+
*
|
|
2172
|
+
* Returns time series data of portfolio net worth.
|
|
2173
|
+
*
|
|
2174
|
+
* **Multi-currency Support:**
|
|
2175
|
+
* - `series[].byCurrency` - Currency breakdown for each data point
|
|
2176
|
+
* - `byCurrency` - Separate time series grouped by currency
|
|
2177
|
+
* - `warnings` - Exchange rate warnings if conversion failed
|
|
2178
|
+
*
|
|
2179
|
+
* **Parameters:**
|
|
2180
|
+
* - `period`: Time period (1m, 3m, 6m, 1y)
|
|
2181
|
+
* - `granularity`: Data granularity (day, week, month)
|
|
2182
|
+
*
|
|
2183
|
+
* @param data The data for the request.
|
|
2184
|
+
* @param data.region Region code for tenant context
|
|
2185
|
+
* @param data.period Time period
|
|
2186
|
+
* @param data.granularity Data granularity
|
|
2187
|
+
* @returns PortfolioTrendsResponseDto Trends retrieved successfully
|
|
2188
|
+
* @throws ApiError
|
|
2189
|
+
*/
|
|
2190
|
+
public static reportingControllerGetPortfolioTrends(
|
|
2191
|
+
data: ReportingControllerGetPortfolioTrendsData
|
|
2192
|
+
): CancelablePromise<ReportingControllerGetPortfolioTrendsResponse> {
|
|
2193
|
+
return __request(OpenAPI, {
|
|
2194
|
+
method: 'GET',
|
|
2195
|
+
url: '/api/v1/{region}/reporting/portfolio/trends',
|
|
2196
|
+
path: {
|
|
2197
|
+
region: data.region
|
|
2198
|
+
},
|
|
2199
|
+
query: {
|
|
2200
|
+
period: data.period,
|
|
2201
|
+
granularity: data.granularity
|
|
2202
|
+
},
|
|
2203
|
+
errors: {
|
|
2204
|
+
401: 'User not authenticated'
|
|
2205
|
+
}
|
|
2206
|
+
});
|
|
2207
|
+
}
|
|
2208
|
+
|
|
2209
|
+
/**
|
|
2210
|
+
* Get cash-flow trends
|
|
2211
|
+
*
|
|
2212
|
+
* Monthly income / expense / netSavings over a fixed N-month window
|
|
2213
|
+
* (current month + N−1 prior). Missing months are zero-filled (flow metric).
|
|
2214
|
+
*
|
|
2215
|
+
* **Parameters:**
|
|
2216
|
+
* - `period`: 1m | 3m | 6m | 1y (default 6m)
|
|
2217
|
+
* - `granularity`: accepted for API symmetry; v1 returns month buckets
|
|
2218
|
+
*
|
|
2219
|
+
* @param data The data for the request.
|
|
2220
|
+
* @param data.region Region code for tenant context
|
|
2221
|
+
* @param data.period Time period
|
|
2222
|
+
* @param data.granularity Data granularity (accepted for API symmetry; v1 returns month buckets)
|
|
2223
|
+
* @returns CashFlowTrendsResponseDto Cash-flow trends retrieved successfully
|
|
2224
|
+
* @throws ApiError
|
|
2225
|
+
*/
|
|
2226
|
+
public static reportingControllerGetCashFlowTrends(
|
|
2227
|
+
data: ReportingControllerGetCashFlowTrendsData
|
|
2228
|
+
): CancelablePromise<ReportingControllerGetCashFlowTrendsResponse> {
|
|
2229
|
+
return __request(OpenAPI, {
|
|
2230
|
+
method: 'GET',
|
|
2231
|
+
url: '/api/v1/{region}/reporting/cash-flow/trends',
|
|
2232
|
+
path: {
|
|
2233
|
+
region: data.region
|
|
2234
|
+
},
|
|
2235
|
+
query: {
|
|
2236
|
+
period: data.period,
|
|
2237
|
+
granularity: data.granularity
|
|
2238
|
+
},
|
|
2239
|
+
errors: {
|
|
2240
|
+
401: 'User not authenticated'
|
|
2241
|
+
}
|
|
2242
|
+
});
|
|
2243
|
+
}
|
|
2244
|
+
|
|
2245
|
+
/**
|
|
2246
|
+
* Generate portfolio snapshot
|
|
2247
|
+
*
|
|
2248
|
+
* Manually generate a portfolio snapshot for a specific date.
|
|
2249
|
+
*
|
|
2250
|
+
* **Multi-currency Support:**
|
|
2251
|
+
* - Fetches balances grouped by currency
|
|
2252
|
+
* - Uses user's baseCurrency setting for conversion
|
|
2253
|
+
* - Stores exchange rates and warnings
|
|
2254
|
+
*
|
|
2255
|
+
* **Use Cases:**
|
|
2256
|
+
* - Testing snapshot generation
|
|
2257
|
+
* - Force regeneration after data correction
|
|
2258
|
+
* - Initial setup for new users
|
|
2259
|
+
*
|
|
2260
|
+
* @param data The data for the request.
|
|
2261
|
+
* @param data.region Region code for tenant context
|
|
2262
|
+
* @param data.requestBody Optional date (defaults to today)
|
|
2263
|
+
* @returns GenerateSnapshotResponse Snapshot generated successfully
|
|
2264
|
+
* @throws ApiError
|
|
2265
|
+
*/
|
|
2266
|
+
public static reportingControllerGenerateSnapshot(
|
|
2267
|
+
data: ReportingControllerGenerateSnapshotData
|
|
2268
|
+
): CancelablePromise<ReportingControllerGenerateSnapshotResponse> {
|
|
2269
|
+
return __request(OpenAPI, {
|
|
2270
|
+
method: 'POST',
|
|
2271
|
+
url: '/api/v1/{region}/reporting/snapshots/generate',
|
|
2272
|
+
path: {
|
|
2273
|
+
region: data.region
|
|
2274
|
+
},
|
|
2275
|
+
body: data.requestBody,
|
|
2276
|
+
mediaType: 'application/json',
|
|
2277
|
+
errors: {
|
|
2278
|
+
400: 'Invalid date format',
|
|
2279
|
+
401: 'User not authenticated'
|
|
2280
|
+
}
|
|
2281
|
+
});
|
|
2282
|
+
}
|
|
2283
|
+
|
|
2284
|
+
/**
|
|
2285
|
+
* Backfill portfolio snapshots
|
|
2286
|
+
*
|
|
2287
|
+
* Generate snapshots for a date range (historical data backfill).
|
|
2288
|
+
*
|
|
2289
|
+
* **Multi-currency Support:**
|
|
2290
|
+
* - Each snapshot includes multi-currency data
|
|
2291
|
+
* - Uses exchange rates available at generation time
|
|
2292
|
+
* - Warnings stored for missing exchange rates
|
|
2293
|
+
*
|
|
2294
|
+
* **Best Practices:**
|
|
2295
|
+
* - Use for initial setup after account configuration
|
|
2296
|
+
* - Run during low-traffic periods for large date ranges
|
|
2297
|
+
* - Existing snapshots are skipped (not regenerated)
|
|
2298
|
+
*
|
|
2299
|
+
* @param data The data for the request.
|
|
2300
|
+
* @param data.region Region code for tenant context
|
|
2301
|
+
* @param data.requestBody
|
|
2302
|
+
* @returns BackfillSnapshotsResponse Backfill completed successfully
|
|
2303
|
+
* @throws ApiError
|
|
2304
|
+
*/
|
|
2305
|
+
public static reportingControllerBackfillSnapshots(
|
|
2306
|
+
data: ReportingControllerBackfillSnapshotsData
|
|
2307
|
+
): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
|
|
2308
|
+
return __request(OpenAPI, {
|
|
2309
|
+
method: 'POST',
|
|
2310
|
+
url: '/api/v1/{region}/reporting/snapshots/backfill',
|
|
2311
|
+
path: {
|
|
2312
|
+
region: data.region
|
|
2313
|
+
},
|
|
2314
|
+
body: data.requestBody,
|
|
2315
|
+
mediaType: 'application/json',
|
|
2316
|
+
errors: {
|
|
2317
|
+
400: 'Invalid date format or range',
|
|
2318
|
+
401: 'User not authenticated',
|
|
2319
|
+
409: 'Backfill already in progress for this user'
|
|
2320
|
+
}
|
|
2321
|
+
});
|
|
2322
|
+
}
|
|
2323
|
+
}
|
|
2324
|
+
|
|
2325
|
+
export class UsersService {
|
|
2326
|
+
/**
|
|
2327
|
+
* Delete own user account
|
|
2328
|
+
* @param data The data for the request.
|
|
2329
|
+
* @param data.requestBody
|
|
2330
|
+
* @returns void User deleted successfully
|
|
2331
|
+
* @throws ApiError
|
|
2332
|
+
*/
|
|
2333
|
+
public static userControllerDeleteOwnUser(
|
|
2334
|
+
data: UserControllerDeleteOwnUserData
|
|
2335
|
+
): CancelablePromise<UserControllerDeleteOwnUserResponse> {
|
|
2336
|
+
return __request(OpenAPI, {
|
|
2337
|
+
method: 'DELETE',
|
|
2338
|
+
url: '/api/v1/users',
|
|
2339
|
+
body: data.requestBody,
|
|
2340
|
+
mediaType: 'application/json',
|
|
2341
|
+
errors: {
|
|
2342
|
+
403: 'Invalid access token'
|
|
2343
|
+
}
|
|
2344
|
+
});
|
|
2345
|
+
}
|
|
2346
|
+
|
|
2347
|
+
/**
|
|
2348
|
+
* Get current authenticated user
|
|
2349
|
+
* @param data The data for the request.
|
|
2350
|
+
* @param data.acceptLanguage
|
|
2351
|
+
* @returns unknown User retrieved successfully
|
|
2352
|
+
* @throws ApiError
|
|
2353
|
+
*/
|
|
2354
|
+
public static userControllerGetUser(
|
|
2355
|
+
data: UserControllerGetUserData
|
|
2356
|
+
): CancelablePromise<UserControllerGetUserResponse> {
|
|
2357
|
+
return __request(OpenAPI, {
|
|
2358
|
+
method: 'GET',
|
|
2359
|
+
url: '/api/v1/users',
|
|
2360
|
+
headers: {
|
|
2361
|
+
'accept-language': data.acceptLanguage
|
|
2362
|
+
}
|
|
2363
|
+
});
|
|
2364
|
+
}
|
|
2365
|
+
|
|
2366
|
+
/**
|
|
2367
|
+
* Sign up new user
|
|
2368
|
+
* Create a new account with auto-generated access token. Protected by Cloudflare Turnstile to prevent automated signup (when enabled).
|
|
2369
|
+
* @param data The data for the request.
|
|
2370
|
+
* @param data.requestBody
|
|
2371
|
+
* @returns SignupResponseDto User created successfully
|
|
2372
|
+
* @throws ApiError
|
|
2373
|
+
*/
|
|
2374
|
+
public static userControllerSignupUser(
|
|
2375
|
+
data: UserControllerSignupUserData
|
|
2376
|
+
): CancelablePromise<UserControllerSignupUserResponse> {
|
|
2377
|
+
return __request(OpenAPI, {
|
|
2378
|
+
method: 'POST',
|
|
2379
|
+
url: '/api/v1/users',
|
|
2380
|
+
body: data.requestBody,
|
|
2381
|
+
mediaType: 'application/json',
|
|
2382
|
+
errors: {
|
|
2383
|
+
400: 'Invalid Turnstile token (when Turnstile is enabled)',
|
|
2384
|
+
403: 'User signup is disabled'
|
|
2385
|
+
}
|
|
2386
|
+
});
|
|
2387
|
+
}
|
|
2388
|
+
|
|
2389
|
+
/**
|
|
2390
|
+
* Delete user by ID (admin only)
|
|
2391
|
+
* @param data The data for the request.
|
|
2392
|
+
* @param data.id User ID to delete
|
|
2393
|
+
* @returns void User deleted successfully
|
|
2394
|
+
* @throws ApiError
|
|
2395
|
+
*/
|
|
2396
|
+
public static userControllerDeleteUser(
|
|
2397
|
+
data: UserControllerDeleteUserData
|
|
2398
|
+
): CancelablePromise<UserControllerDeleteUserResponse> {
|
|
2399
|
+
return __request(OpenAPI, {
|
|
2400
|
+
method: 'DELETE',
|
|
2401
|
+
url: '/api/v1/users/{id}',
|
|
2402
|
+
path: {
|
|
2403
|
+
id: data.id
|
|
2404
|
+
},
|
|
2405
|
+
errors: {
|
|
2406
|
+
403: 'Cannot delete own account or insufficient permissions'
|
|
2407
|
+
}
|
|
2408
|
+
});
|
|
2409
|
+
}
|
|
2410
|
+
|
|
2411
|
+
/**
|
|
2412
|
+
* Get user info by user ID
|
|
2413
|
+
* @param data The data for the request.
|
|
2414
|
+
* @param data.id User ID
|
|
2415
|
+
* @returns unknown User info retrieved successfully
|
|
2416
|
+
* @throws ApiError
|
|
2417
|
+
*/
|
|
2418
|
+
public static userControllerGetUserInfo(
|
|
2419
|
+
data: UserControllerGetUserInfoData
|
|
2420
|
+
): CancelablePromise<UserControllerGetUserInfoResponse> {
|
|
2421
|
+
return __request(OpenAPI, {
|
|
2422
|
+
method: 'GET',
|
|
2423
|
+
url: '/api/v1/users/{id}/info',
|
|
2424
|
+
path: {
|
|
2425
|
+
id: data.id
|
|
2426
|
+
},
|
|
2427
|
+
errors: {
|
|
2428
|
+
403: 'Cannot access other user info without admin permission'
|
|
2429
|
+
}
|
|
2430
|
+
});
|
|
2431
|
+
}
|
|
2432
|
+
|
|
2433
|
+
/**
|
|
2434
|
+
* Update user settings
|
|
2435
|
+
* @param data The data for the request.
|
|
2436
|
+
* @param data.requestBody
|
|
2437
|
+
* @returns unknown Settings updated successfully
|
|
2438
|
+
* @throws ApiError
|
|
2439
|
+
*/
|
|
2440
|
+
public static userControllerUpdateUserSetting(
|
|
2441
|
+
data: UserControllerUpdateUserSettingData
|
|
2442
|
+
): CancelablePromise<UserControllerUpdateUserSettingResponse> {
|
|
2443
|
+
return __request(OpenAPI, {
|
|
2444
|
+
method: 'PUT',
|
|
2445
|
+
url: '/api/v1/users/setting',
|
|
2446
|
+
body: data.requestBody,
|
|
2447
|
+
mediaType: 'application/json',
|
|
2448
|
+
errors: {
|
|
2449
|
+
403: 'Insufficient permissions'
|
|
2450
|
+
}
|
|
2451
|
+
});
|
|
2452
|
+
}
|
|
2453
|
+
|
|
2454
|
+
/**
|
|
2455
|
+
* Get all user settings paginated (admin only)
|
|
2456
|
+
* @param data The data for the request.
|
|
2457
|
+
* @param data.pageNo Page number
|
|
2458
|
+
* @param data.pageSize Page size
|
|
2459
|
+
* @returns unknown Settings list retrieved successfully
|
|
2460
|
+
* @throws ApiError
|
|
2461
|
+
*/
|
|
2462
|
+
public static userControllerGetAllUserSettingsByPage(
|
|
2463
|
+
data: UserControllerGetAllUserSettingsByPageData
|
|
2464
|
+
): CancelablePromise<UserControllerGetAllUserSettingsByPageResponse> {
|
|
2465
|
+
return __request(OpenAPI, {
|
|
2466
|
+
method: 'GET',
|
|
2467
|
+
url: '/api/v1/users/settings-by-page',
|
|
2468
|
+
query: {
|
|
2469
|
+
pageNo: data.pageNo,
|
|
2470
|
+
pageSize: data.pageSize
|
|
2471
|
+
}
|
|
2472
|
+
});
|
|
2473
|
+
}
|
|
2474
|
+
|
|
2475
|
+
/**
|
|
2476
|
+
* Get asset and liability summary for current user
|
|
2477
|
+
* @returns unknown Summary retrieved successfully
|
|
2478
|
+
* @throws ApiError
|
|
2479
|
+
*/
|
|
2480
|
+
public static userControllerGetAssetLiabilitySummary(): CancelablePromise<UserControllerGetAssetLiabilitySummaryResponse> {
|
|
2481
|
+
return __request(OpenAPI, {
|
|
2482
|
+
method: 'GET',
|
|
2483
|
+
url: '/api/v1/users/asset-liability-summary'
|
|
2484
|
+
});
|
|
2485
|
+
}
|
|
2486
|
+
}
|
|
2487
|
+
|
|
2488
|
+
export class PropertiesService {
|
|
2489
|
+
/**
|
|
2490
|
+
* Get all system properties
|
|
2491
|
+
* @returns unknown Properties retrieved successfully
|
|
2492
|
+
* @throws ApiError
|
|
2493
|
+
*/
|
|
2494
|
+
public static propertyControllerGetAll(): CancelablePromise<PropertyControllerGetAllResponse> {
|
|
2495
|
+
return __request(OpenAPI, {
|
|
2496
|
+
method: 'GET',
|
|
2497
|
+
url: '/api/v1/admin/properties',
|
|
2498
|
+
errors: {
|
|
2499
|
+
401: 'Unauthorized',
|
|
2500
|
+
403: 'Forbidden - insufficient permissions'
|
|
2501
|
+
}
|
|
2502
|
+
});
|
|
2503
|
+
}
|
|
2504
|
+
|
|
2505
|
+
/**
|
|
2506
|
+
* Get property by key
|
|
2507
|
+
* @param data The data for the request.
|
|
2508
|
+
* @param data.key Property key
|
|
2509
|
+
* @returns unknown Property retrieved successfully
|
|
2510
|
+
* @throws ApiError
|
|
2511
|
+
*/
|
|
2512
|
+
public static propertyControllerGetByKey(
|
|
2513
|
+
data: PropertyControllerGetByKeyData
|
|
2514
|
+
): CancelablePromise<PropertyControllerGetByKeyResponse> {
|
|
2515
|
+
return __request(OpenAPI, {
|
|
2516
|
+
method: 'GET',
|
|
2517
|
+
url: '/api/v1/admin/properties/{key}',
|
|
2518
|
+
path: {
|
|
2519
|
+
key: data.key
|
|
2520
|
+
},
|
|
2521
|
+
errors: {
|
|
2522
|
+
401: 'Unauthorized',
|
|
2523
|
+
403: 'Forbidden - insufficient permissions',
|
|
2524
|
+
404: 'Property not found'
|
|
2525
|
+
}
|
|
2526
|
+
});
|
|
2527
|
+
}
|
|
2528
|
+
|
|
2529
|
+
/**
|
|
2530
|
+
* Update a system property
|
|
2531
|
+
* @param data The data for the request.
|
|
2532
|
+
* @param data.key Property key
|
|
2533
|
+
* @param data.requestBody
|
|
2534
|
+
* @returns unknown Property updated successfully
|
|
2535
|
+
* @throws ApiError
|
|
2536
|
+
*/
|
|
2537
|
+
public static propertyControllerUpdate(
|
|
2538
|
+
data: PropertyControllerUpdateData
|
|
2539
|
+
): CancelablePromise<PropertyControllerUpdateResponse> {
|
|
2540
|
+
return __request(OpenAPI, {
|
|
2541
|
+
method: 'PUT',
|
|
2542
|
+
url: '/api/v1/admin/properties/{key}',
|
|
2543
|
+
path: {
|
|
2544
|
+
key: data.key
|
|
2545
|
+
},
|
|
2546
|
+
body: data.requestBody,
|
|
2547
|
+
mediaType: 'application/json',
|
|
2548
|
+
errors: {
|
|
2549
|
+
401: 'Unauthorized',
|
|
2550
|
+
403: 'Forbidden - insufficient permissions'
|
|
2551
|
+
}
|
|
2552
|
+
});
|
|
2553
|
+
}
|
|
2554
|
+
|
|
2555
|
+
/**
|
|
2556
|
+
* Delete a system property
|
|
2557
|
+
* @param data The data for the request.
|
|
2558
|
+
* @param data.key Property key
|
|
2559
|
+
* @returns void Property deleted successfully
|
|
2560
|
+
* @throws ApiError
|
|
2561
|
+
*/
|
|
2562
|
+
public static propertyControllerDelete(
|
|
2563
|
+
data: PropertyControllerDeleteData
|
|
2564
|
+
): CancelablePromise<PropertyControllerDeleteResponse> {
|
|
2565
|
+
return __request(OpenAPI, {
|
|
2566
|
+
method: 'DELETE',
|
|
2567
|
+
url: '/api/v1/admin/properties/{key}',
|
|
2568
|
+
path: {
|
|
2569
|
+
key: data.key
|
|
2570
|
+
},
|
|
2571
|
+
errors: {
|
|
2572
|
+
401: 'Unauthorized',
|
|
2573
|
+
403: 'Forbidden - insufficient permissions',
|
|
2574
|
+
404: 'Property not found'
|
|
2575
|
+
}
|
|
2576
|
+
});
|
|
2577
|
+
}
|
|
2578
|
+
}
|
|
2579
|
+
|
|
2580
|
+
export class BeanTransactionRulesService {
|
|
2581
|
+
/**
|
|
2582
|
+
* Create a new transaction rule (or upsert if upsertByPayee=true)
|
|
2583
|
+
* Creates a new rule. If upsertByPayee=true, updates existing rule matching payeeKeywords[0] instead of creating duplicate.
|
|
2584
|
+
* @param data The data for the request.
|
|
2585
|
+
* @param data.region Region code for tenant context
|
|
2586
|
+
* @param data.requestBody
|
|
2587
|
+
* @returns TransactionRuleResponseDto Rule updated successfully (upsert mode)
|
|
2588
|
+
* @throws ApiError
|
|
2589
|
+
*/
|
|
2590
|
+
public static transactionRuleControllerCreate(
|
|
2591
|
+
data: TransactionRuleControllerCreateData
|
|
2592
|
+
): CancelablePromise<TransactionRuleControllerCreateResponse> {
|
|
2593
|
+
return __request(OpenAPI, {
|
|
2594
|
+
method: 'POST',
|
|
2595
|
+
url: '/api/v1/{region}/bean/transaction-rules',
|
|
1862
2596
|
path: {
|
|
1863
2597
|
region: data.region
|
|
1864
2598
|
},
|
|
@@ -2121,256 +2855,309 @@ export class BeanTransactionRulesService {
|
|
|
2121
2855
|
}
|
|
2122
2856
|
}
|
|
2123
2857
|
|
|
2124
|
-
export class
|
|
2858
|
+
export class LifeEventsService {
|
|
2125
2859
|
/**
|
|
2126
|
-
*
|
|
2860
|
+
* Create a new life event
|
|
2861
|
+
* Creates a new life event entry for the authenticated user. Returns ETag header carrying the row updatedAt.
|
|
2127
2862
|
* @param data The data for the request.
|
|
2863
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2128
2864
|
* @param data.requestBody
|
|
2129
|
-
* @returns
|
|
2865
|
+
* @returns EventResponseDto Life event created successfully
|
|
2130
2866
|
* @throws ApiError
|
|
2131
2867
|
*/
|
|
2132
|
-
public static
|
|
2133
|
-
data:
|
|
2134
|
-
): CancelablePromise<
|
|
2868
|
+
public static eventControllerCreate(
|
|
2869
|
+
data: EventControllerCreateData
|
|
2870
|
+
): CancelablePromise<EventControllerCreateResponse> {
|
|
2135
2871
|
return __request(OpenAPI, {
|
|
2136
|
-
method: '
|
|
2137
|
-
url: '/api/v1/
|
|
2872
|
+
method: 'POST',
|
|
2873
|
+
url: '/api/v1/{region}/bean/events',
|
|
2874
|
+
path: {
|
|
2875
|
+
region: data.region
|
|
2876
|
+
},
|
|
2138
2877
|
body: data.requestBody,
|
|
2139
2878
|
mediaType: 'application/json',
|
|
2140
2879
|
errors: {
|
|
2141
|
-
|
|
2880
|
+
409: 'Life event already exists for this (userId, type, date) combination'
|
|
2142
2881
|
}
|
|
2143
2882
|
});
|
|
2144
2883
|
}
|
|
2145
2884
|
|
|
2146
2885
|
/**
|
|
2147
|
-
*
|
|
2886
|
+
* List user life events
|
|
2887
|
+
* Returns life events for the authenticated user with optional filtering by type, description search, and date range.
|
|
2148
2888
|
* @param data The data for the request.
|
|
2149
|
-
* @param data.
|
|
2150
|
-
* @
|
|
2889
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2890
|
+
* @param data.type Filter by life event type (exact match)
|
|
2891
|
+
* @param data.q Search term for description (case-insensitive partial match)
|
|
2892
|
+
* @param data.from Filter life events from this date (ISO 8601 format)
|
|
2893
|
+
* @param data.to Filter life events to this date (ISO 8601 format)
|
|
2894
|
+
* @param data.page Page number for pagination (default: 1)
|
|
2895
|
+
* @param data.limit Number of items per page (default: 20, max: 100)
|
|
2896
|
+
* @returns EventListResponseDto Life events retrieved successfully
|
|
2151
2897
|
* @throws ApiError
|
|
2152
2898
|
*/
|
|
2153
|
-
public static
|
|
2154
|
-
data:
|
|
2155
|
-
): CancelablePromise<
|
|
2899
|
+
public static eventControllerFindAll(
|
|
2900
|
+
data: EventControllerFindAllData
|
|
2901
|
+
): CancelablePromise<EventControllerFindAllResponse> {
|
|
2156
2902
|
return __request(OpenAPI, {
|
|
2157
2903
|
method: 'GET',
|
|
2158
|
-
url: '/api/v1/
|
|
2159
|
-
|
|
2160
|
-
|
|
2904
|
+
url: '/api/v1/{region}/bean/events',
|
|
2905
|
+
path: {
|
|
2906
|
+
region: data.region
|
|
2907
|
+
},
|
|
2908
|
+
query: {
|
|
2909
|
+
type: data.type,
|
|
2910
|
+
q: data.q,
|
|
2911
|
+
from: data.from,
|
|
2912
|
+
to: data.to,
|
|
2913
|
+
page: data.page,
|
|
2914
|
+
limit: data.limit
|
|
2161
2915
|
}
|
|
2162
2916
|
});
|
|
2163
2917
|
}
|
|
2164
2918
|
|
|
2165
2919
|
/**
|
|
2166
|
-
*
|
|
2167
|
-
*
|
|
2920
|
+
* Get life event by ID
|
|
2921
|
+
* Returns a single life event by its ID. Returns ETag header.
|
|
2168
2922
|
* @param data The data for the request.
|
|
2169
|
-
* @param data.
|
|
2170
|
-
* @
|
|
2923
|
+
* @param data.id Life event ID
|
|
2924
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2925
|
+
* @returns EventResponseDto Life event retrieved successfully
|
|
2171
2926
|
* @throws ApiError
|
|
2172
2927
|
*/
|
|
2173
|
-
public static
|
|
2174
|
-
data:
|
|
2175
|
-
): CancelablePromise<
|
|
2928
|
+
public static eventControllerFindOne(
|
|
2929
|
+
data: EventControllerFindOneData
|
|
2930
|
+
): CancelablePromise<EventControllerFindOneResponse> {
|
|
2176
2931
|
return __request(OpenAPI, {
|
|
2177
|
-
method: '
|
|
2178
|
-
url: '/api/v1/
|
|
2179
|
-
|
|
2180
|
-
|
|
2932
|
+
method: 'GET',
|
|
2933
|
+
url: '/api/v1/{region}/bean/events/{id}',
|
|
2934
|
+
path: {
|
|
2935
|
+
id: data.id,
|
|
2936
|
+
region: data.region
|
|
2937
|
+
},
|
|
2181
2938
|
errors: {
|
|
2182
|
-
|
|
2183
|
-
403: 'User signup is disabled'
|
|
2939
|
+
404: 'Life event not found'
|
|
2184
2940
|
}
|
|
2185
2941
|
});
|
|
2186
2942
|
}
|
|
2187
2943
|
|
|
2188
2944
|
/**
|
|
2189
|
-
*
|
|
2945
|
+
* Update a life event
|
|
2946
|
+
* Updates an existing life event. If If-Match header is provided, performs optimistic concurrency check; mismatched updatedAt returns 412.
|
|
2190
2947
|
* @param data The data for the request.
|
|
2191
|
-
* @param data.id
|
|
2192
|
-
* @
|
|
2948
|
+
* @param data.id Life event ID
|
|
2949
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2950
|
+
* @param data.requestBody
|
|
2951
|
+
* @returns EventResponseDto Life event updated successfully
|
|
2193
2952
|
* @throws ApiError
|
|
2194
2953
|
*/
|
|
2195
|
-
public static
|
|
2196
|
-
data:
|
|
2197
|
-
): CancelablePromise<
|
|
2954
|
+
public static eventControllerUpdate(
|
|
2955
|
+
data: EventControllerUpdateData
|
|
2956
|
+
): CancelablePromise<EventControllerUpdateResponse> {
|
|
2198
2957
|
return __request(OpenAPI, {
|
|
2199
|
-
method: '
|
|
2200
|
-
url: '/api/v1/
|
|
2958
|
+
method: 'PUT',
|
|
2959
|
+
url: '/api/v1/{region}/bean/events/{id}',
|
|
2201
2960
|
path: {
|
|
2202
|
-
id: data.id
|
|
2961
|
+
id: data.id,
|
|
2962
|
+
region: data.region
|
|
2203
2963
|
},
|
|
2964
|
+
body: data.requestBody,
|
|
2965
|
+
mediaType: 'application/json',
|
|
2204
2966
|
errors: {
|
|
2205
|
-
|
|
2967
|
+
400: 'If-Match header is not a valid ISO 8601 date',
|
|
2968
|
+
404: 'Life event not found',
|
|
2969
|
+
409: 'Updated event conflicts with an existing (userId, type, date) combination',
|
|
2970
|
+
412: 'If-Match precondition failed (updatedAt mismatch)'
|
|
2206
2971
|
}
|
|
2207
2972
|
});
|
|
2208
2973
|
}
|
|
2209
2974
|
|
|
2210
2975
|
/**
|
|
2211
|
-
*
|
|
2976
|
+
* Delete a life event
|
|
2977
|
+
* Deletes a life event entry (hard delete). Returns 204.
|
|
2212
2978
|
* @param data The data for the request.
|
|
2213
|
-
* @param data.id
|
|
2214
|
-
* @
|
|
2979
|
+
* @param data.id Life event ID
|
|
2980
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2981
|
+
* @returns void Life event deleted successfully
|
|
2215
2982
|
* @throws ApiError
|
|
2216
2983
|
*/
|
|
2217
|
-
public static
|
|
2218
|
-
data:
|
|
2219
|
-
): CancelablePromise<
|
|
2984
|
+
public static eventControllerDelete(
|
|
2985
|
+
data: EventControllerDeleteData
|
|
2986
|
+
): CancelablePromise<EventControllerDeleteResponse> {
|
|
2220
2987
|
return __request(OpenAPI, {
|
|
2221
|
-
method: '
|
|
2222
|
-
url: '/api/v1/
|
|
2988
|
+
method: 'DELETE',
|
|
2989
|
+
url: '/api/v1/{region}/bean/events/{id}',
|
|
2223
2990
|
path: {
|
|
2224
|
-
id: data.id
|
|
2991
|
+
id: data.id,
|
|
2992
|
+
region: data.region
|
|
2225
2993
|
},
|
|
2226
2994
|
errors: {
|
|
2227
|
-
|
|
2995
|
+
404: 'Life event not found'
|
|
2228
2996
|
}
|
|
2229
2997
|
});
|
|
2230
2998
|
}
|
|
2231
2999
|
|
|
2232
3000
|
/**
|
|
2233
|
-
*
|
|
3001
|
+
* Slice time-series by a life event (Phase 79)
|
|
3002
|
+
* Returns aggregated time-series for postings matching accountPattern within the half-open date range of the given life event.
|
|
2234
3003
|
* @param data The data for the request.
|
|
2235
|
-
* @param data.
|
|
2236
|
-
* @
|
|
3004
|
+
* @param data.id Life event ID
|
|
3005
|
+
* @param data.accountPattern
|
|
3006
|
+
* @param data.granularity
|
|
3007
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
3008
|
+
* @returns unknown Time-series sliced by the life event range
|
|
2237
3009
|
* @throws ApiError
|
|
2238
3010
|
*/
|
|
2239
|
-
public static
|
|
2240
|
-
data:
|
|
2241
|
-
): CancelablePromise<
|
|
3011
|
+
public static eventControllerGetSlice(
|
|
3012
|
+
data: EventControllerGetSliceData
|
|
3013
|
+
): CancelablePromise<EventControllerGetSliceResponse> {
|
|
2242
3014
|
return __request(OpenAPI, {
|
|
2243
|
-
method: '
|
|
2244
|
-
url: '/api/v1/
|
|
2245
|
-
|
|
2246
|
-
|
|
3015
|
+
method: 'GET',
|
|
3016
|
+
url: '/api/v1/{region}/bean/events/{id}/slice',
|
|
3017
|
+
path: {
|
|
3018
|
+
id: data.id,
|
|
3019
|
+
region: data.region
|
|
3020
|
+
},
|
|
3021
|
+
query: {
|
|
3022
|
+
accountPattern: data.accountPattern,
|
|
3023
|
+
granularity: data.granularity
|
|
3024
|
+
},
|
|
2247
3025
|
errors: {
|
|
2248
|
-
|
|
3026
|
+
400: 'accountPattern query param is empty',
|
|
3027
|
+
404: 'Life event not found'
|
|
2249
3028
|
}
|
|
2250
3029
|
});
|
|
2251
3030
|
}
|
|
3031
|
+
}
|
|
2252
3032
|
|
|
3033
|
+
export class OnboardingService {
|
|
2253
3034
|
/**
|
|
2254
|
-
*
|
|
3035
|
+
* Bootstrap core accounts + register asset accounts with opening balances (ADR-0113)
|
|
2255
3036
|
* @param data The data for the request.
|
|
2256
|
-
* @param data.
|
|
2257
|
-
* @param data.
|
|
2258
|
-
* @returns unknown
|
|
3037
|
+
* @param data.region Region code for tenant context
|
|
3038
|
+
* @param data.requestBody
|
|
3039
|
+
* @returns unknown Onboarding bootstrap result.
|
|
2259
3040
|
* @throws ApiError
|
|
2260
3041
|
*/
|
|
2261
|
-
public static
|
|
2262
|
-
data:
|
|
2263
|
-
): CancelablePromise<
|
|
3042
|
+
public static onboardingControllerBootstrap(
|
|
3043
|
+
data: OnboardingControllerBootstrapData
|
|
3044
|
+
): CancelablePromise<OnboardingControllerBootstrapResponse> {
|
|
2264
3045
|
return __request(OpenAPI, {
|
|
2265
|
-
method: '
|
|
2266
|
-
url: '/api/v1/
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
3046
|
+
method: 'POST',
|
|
3047
|
+
url: '/api/v1/{region}/bean/onboarding',
|
|
3048
|
+
path: {
|
|
3049
|
+
region: data.region
|
|
3050
|
+
},
|
|
3051
|
+
body: data.requestBody,
|
|
3052
|
+
mediaType: 'application/json',
|
|
3053
|
+
errors: {
|
|
3054
|
+
422: 'Invalid region/account path/duplicate paths.'
|
|
2270
3055
|
}
|
|
2271
3056
|
});
|
|
2272
3057
|
}
|
|
2273
|
-
|
|
2274
|
-
/**
|
|
2275
|
-
* Get asset and liability summary for current user
|
|
2276
|
-
* @returns unknown Summary retrieved successfully
|
|
2277
|
-
* @throws ApiError
|
|
2278
|
-
*/
|
|
2279
|
-
public static userControllerGetAssetLiabilitySummary(): CancelablePromise<UserControllerGetAssetLiabilitySummaryResponse> {
|
|
2280
|
-
return __request(OpenAPI, {
|
|
2281
|
-
method: 'GET',
|
|
2282
|
-
url: '/api/v1/users/asset-liability-summary'
|
|
2283
|
-
});
|
|
2284
|
-
}
|
|
2285
3058
|
}
|
|
2286
3059
|
|
|
2287
|
-
export class
|
|
3060
|
+
export class BalanceReconciliationService {
|
|
2288
3061
|
/**
|
|
2289
|
-
*
|
|
2290
|
-
*
|
|
3062
|
+
* Preview reconciliation (book vs actual)
|
|
3063
|
+
* Computes book balance, diff, Beancount-inferred tolerance, and suggested action without persisting.
|
|
3064
|
+
* @param data The data for the request.
|
|
3065
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3066
|
+
* @param data.requestBody
|
|
3067
|
+
* @returns ReconciliationComputeResultDto Reconciliation preview
|
|
2291
3068
|
* @throws ApiError
|
|
2292
3069
|
*/
|
|
2293
|
-
public static
|
|
3070
|
+
public static reconciliationControllerCompute(
|
|
3071
|
+
data: ReconciliationControllerComputeData
|
|
3072
|
+
): CancelablePromise<ReconciliationControllerComputeResponse> {
|
|
2294
3073
|
return __request(OpenAPI, {
|
|
2295
|
-
method: '
|
|
2296
|
-
url: '/api/v1/
|
|
3074
|
+
method: 'POST',
|
|
3075
|
+
url: '/api/v1/{region}/bean/reconciliations',
|
|
3076
|
+
path: {
|
|
3077
|
+
region: data.region
|
|
3078
|
+
},
|
|
3079
|
+
body: data.requestBody,
|
|
3080
|
+
mediaType: 'application/json',
|
|
2297
3081
|
errors: {
|
|
2298
|
-
|
|
2299
|
-
403: 'Forbidden - insufficient permissions'
|
|
3082
|
+
404: 'Account not found'
|
|
2300
3083
|
}
|
|
2301
3084
|
});
|
|
2302
3085
|
}
|
|
2303
3086
|
|
|
2304
3087
|
/**
|
|
2305
|
-
*
|
|
3088
|
+
* Record a balance assertion
|
|
3089
|
+
* Persists the reconciliation as a BeanBalance assertion (amount = actual, diffAmount = book − actual). Re-reconciling the same day/currency upserts.
|
|
2306
3090
|
* @param data The data for the request.
|
|
2307
|
-
* @param data.
|
|
2308
|
-
* @
|
|
3091
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3092
|
+
* @param data.requestBody
|
|
3093
|
+
* @returns ReconciliationRecordDto Balance assertion recorded
|
|
2309
3094
|
* @throws ApiError
|
|
2310
3095
|
*/
|
|
2311
|
-
public static
|
|
2312
|
-
data:
|
|
2313
|
-
): CancelablePromise<
|
|
2314
|
-
return __request(OpenAPI, {
|
|
2315
|
-
method: '
|
|
2316
|
-
url: '/api/v1/
|
|
3096
|
+
public static reconciliationControllerAssert(
|
|
3097
|
+
data: ReconciliationControllerAssertData
|
|
3098
|
+
): CancelablePromise<ReconciliationControllerAssertResponse> {
|
|
3099
|
+
return __request(OpenAPI, {
|
|
3100
|
+
method: 'POST',
|
|
3101
|
+
url: '/api/v1/{region}/bean/reconciliations/assert',
|
|
2317
3102
|
path: {
|
|
2318
|
-
|
|
3103
|
+
region: data.region
|
|
2319
3104
|
},
|
|
3105
|
+
body: data.requestBody,
|
|
3106
|
+
mediaType: 'application/json',
|
|
2320
3107
|
errors: {
|
|
2321
|
-
|
|
2322
|
-
403: 'Forbidden - insufficient permissions',
|
|
2323
|
-
404: 'Property not found'
|
|
3108
|
+
404: 'Account not found'
|
|
2324
3109
|
}
|
|
2325
3110
|
});
|
|
2326
3111
|
}
|
|
2327
3112
|
|
|
2328
3113
|
/**
|
|
2329
|
-
*
|
|
3114
|
+
* Generate a pad adjusting entry
|
|
3115
|
+
* When book is outside tolerance, synthesizes a Beancount pad transaction (flag P) booking the diff from source_account and persists it. Source defaults to Equity:Opening-Balances.
|
|
2330
3116
|
* @param data The data for the request.
|
|
2331
|
-
* @param data.
|
|
3117
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
2332
3118
|
* @param data.requestBody
|
|
2333
|
-
* @returns
|
|
3119
|
+
* @returns PadResultDto Pad adjusting entry generated
|
|
2334
3120
|
* @throws ApiError
|
|
2335
3121
|
*/
|
|
2336
|
-
public static
|
|
2337
|
-
data:
|
|
2338
|
-
): CancelablePromise<
|
|
3122
|
+
public static reconciliationControllerPad(
|
|
3123
|
+
data: ReconciliationControllerPadData
|
|
3124
|
+
): CancelablePromise<ReconciliationControllerPadResponse> {
|
|
2339
3125
|
return __request(OpenAPI, {
|
|
2340
|
-
method: '
|
|
2341
|
-
url: '/api/v1/
|
|
3126
|
+
method: 'POST',
|
|
3127
|
+
url: '/api/v1/{region}/bean/reconciliations/pad',
|
|
2342
3128
|
path: {
|
|
2343
|
-
|
|
3129
|
+
region: data.region
|
|
2344
3130
|
},
|
|
2345
3131
|
body: data.requestBody,
|
|
2346
3132
|
mediaType: 'application/json',
|
|
2347
3133
|
errors: {
|
|
2348
|
-
|
|
2349
|
-
|
|
3134
|
+
400: 'Book already within tolerance — no pad needed',
|
|
3135
|
+
404: 'Account not found'
|
|
2350
3136
|
}
|
|
2351
3137
|
});
|
|
2352
3138
|
}
|
|
2353
3139
|
|
|
2354
3140
|
/**
|
|
2355
|
-
*
|
|
3141
|
+
* List reconciliation history for an account
|
|
3142
|
+
* Returns recorded balance assertions (most recent first). The latest drives the account-detail "Last <date>" badge.
|
|
2356
3143
|
* @param data The data for the request.
|
|
2357
|
-
* @param data.
|
|
2358
|
-
* @
|
|
3144
|
+
* @param data.accountId BeanAccount id
|
|
3145
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3146
|
+
* @returns ReconciliationRecordDto Reconciliation history
|
|
2359
3147
|
* @throws ApiError
|
|
2360
3148
|
*/
|
|
2361
|
-
public static
|
|
2362
|
-
data:
|
|
2363
|
-
): CancelablePromise<
|
|
3149
|
+
public static reconciliationControllerHistory(
|
|
3150
|
+
data: ReconciliationControllerHistoryData
|
|
3151
|
+
): CancelablePromise<ReconciliationControllerHistoryResponse> {
|
|
2364
3152
|
return __request(OpenAPI, {
|
|
2365
|
-
method: '
|
|
2366
|
-
url: '/api/v1/
|
|
3153
|
+
method: 'GET',
|
|
3154
|
+
url: '/api/v1/{region}/bean/accounts/{accountId}/reconciliations',
|
|
2367
3155
|
path: {
|
|
2368
|
-
|
|
3156
|
+
accountId: data.accountId,
|
|
3157
|
+
region: data.region
|
|
2369
3158
|
},
|
|
2370
3159
|
errors: {
|
|
2371
|
-
|
|
2372
|
-
403: 'Forbidden - insufficient permissions',
|
|
2373
|
-
404: 'Property not found'
|
|
3160
|
+
404: 'Account not found'
|
|
2374
3161
|
}
|
|
2375
3162
|
});
|
|
2376
3163
|
}
|
|
@@ -2554,243 +3341,271 @@ export class BeanImportService {
|
|
|
2554
3341
|
}
|
|
2555
3342
|
}
|
|
2556
3343
|
|
|
2557
|
-
export class
|
|
2558
|
-
/**
|
|
2559
|
-
* Get all platforms with statistics
|
|
2560
|
-
* @returns unknown List of platforms with binding and account counts
|
|
2561
|
-
* @throws ApiError
|
|
2562
|
-
*/
|
|
2563
|
-
public static platformControllerFindAll(): CancelablePromise<PlatformControllerFindAllResponse> {
|
|
2564
|
-
return __request(OpenAPI, {
|
|
2565
|
-
method: 'GET',
|
|
2566
|
-
url: '/api/v1/bean/platforms'
|
|
2567
|
-
});
|
|
2568
|
-
}
|
|
2569
|
-
|
|
3344
|
+
export class ProviderSyncService {
|
|
2570
3345
|
/**
|
|
2571
|
-
*
|
|
3346
|
+
* Sync transactions from financial data provider
|
|
3347
|
+
*
|
|
3348
|
+
* Accepts raw transactions from external financial data providers, transforms them to Beancount format, and processes them through the ingestion pipeline.
|
|
3349
|
+
*
|
|
3350
|
+
* **Supported Providers:**
|
|
3351
|
+
* - **plaid**: Plaid API (US, Canada, Europe)
|
|
3352
|
+
* - **teller**: Teller API (US)
|
|
3353
|
+
* - **truelayer**: TrueLayer Open Banking (UK, Europe)
|
|
3354
|
+
* - **gocardless**: GoCardless Bank Account Data (Europe)
|
|
3355
|
+
* - **simplefin**: SimpleFIN (Self-hosted)
|
|
3356
|
+
* - **yodlee**: Yodlee (Global)
|
|
3357
|
+
* - **beancount-direct**: Beancount format transactions
|
|
3358
|
+
* - **parsed-bill**: Client-side parsed bill transactions
|
|
3359
|
+
*
|
|
3360
|
+
* **Processing Flow:**
|
|
3361
|
+
* 1. Transform raw data via provider adapter
|
|
3362
|
+
* 2. Validate transaction format
|
|
3363
|
+
* 3. Deduplicate using originalId
|
|
3364
|
+
* 4. Classify using rule engine
|
|
3365
|
+
* 5. Route low-confidence to Review Center
|
|
3366
|
+
* 6. Persist validated transactions
|
|
3367
|
+
*
|
|
2572
3368
|
* @param data The data for the request.
|
|
3369
|
+
* @param data.providerName Provider name
|
|
3370
|
+
* @param data.region Region code for tenant context
|
|
2573
3371
|
* @param data.requestBody
|
|
2574
|
-
* @returns
|
|
3372
|
+
* @returns ProviderSyncResponseDto Sync completed successfully
|
|
2575
3373
|
* @throws ApiError
|
|
2576
3374
|
*/
|
|
2577
|
-
public static
|
|
2578
|
-
data:
|
|
2579
|
-
): CancelablePromise<
|
|
3375
|
+
public static providerSyncControllerSync(
|
|
3376
|
+
data: ProviderSyncControllerSyncData
|
|
3377
|
+
): CancelablePromise<ProviderSyncControllerSyncResponse> {
|
|
2580
3378
|
return __request(OpenAPI, {
|
|
2581
3379
|
method: 'POST',
|
|
2582
|
-
url: '/api/v1/bean/
|
|
3380
|
+
url: '/api/v1/{region}/bean/import/provider/{providerName}/sync',
|
|
3381
|
+
path: {
|
|
3382
|
+
providerName: data.providerName,
|
|
3383
|
+
region: data.region
|
|
3384
|
+
},
|
|
2583
3385
|
body: data.requestBody,
|
|
2584
3386
|
mediaType: 'application/json',
|
|
2585
3387
|
errors: {
|
|
2586
|
-
|
|
3388
|
+
400: 'Invalid request data',
|
|
3389
|
+
401: 'Missing or invalid authentication',
|
|
3390
|
+
404: 'Provider not supported'
|
|
2587
3391
|
}
|
|
2588
3392
|
});
|
|
2589
3393
|
}
|
|
2590
3394
|
|
|
2591
3395
|
/**
|
|
2592
|
-
* Get
|
|
2593
|
-
*
|
|
3396
|
+
* Get supported providers
|
|
3397
|
+
* Returns a list of all providers supported by the sync endpoint.
|
|
3398
|
+
* @param data The data for the request.
|
|
3399
|
+
* @param data.region Region code for tenant context
|
|
3400
|
+
* @returns SupportedProvidersResponseDto List of supported providers
|
|
2594
3401
|
* @throws ApiError
|
|
2595
3402
|
*/
|
|
2596
|
-
public static
|
|
3403
|
+
public static providerSyncControllerGetSupportedProviders(
|
|
3404
|
+
data: ProviderSyncControllerGetSupportedProvidersData
|
|
3405
|
+
): CancelablePromise<ProviderSyncControllerGetSupportedProvidersResponse> {
|
|
2597
3406
|
return __request(OpenAPI, {
|
|
2598
3407
|
method: 'GET',
|
|
2599
|
-
url: '/api/v1/bean/
|
|
3408
|
+
url: '/api/v1/{region}/bean/import/provider/supported',
|
|
3409
|
+
path: {
|
|
3410
|
+
region: data.region
|
|
3411
|
+
},
|
|
3412
|
+
errors: {
|
|
3413
|
+
401: 'Missing or invalid authentication'
|
|
3414
|
+
}
|
|
2600
3415
|
});
|
|
2601
3416
|
}
|
|
2602
3417
|
|
|
2603
3418
|
/**
|
|
2604
|
-
*
|
|
3419
|
+
* Check if provider is supported
|
|
3420
|
+
* Returns whether a specific provider is supported.
|
|
2605
3421
|
* @param data The data for the request.
|
|
2606
|
-
* @param data.
|
|
2607
|
-
* @param data.region Region code for
|
|
2608
|
-
* @returns unknown
|
|
3422
|
+
* @param data.providerName Provider name to check
|
|
3423
|
+
* @param data.region Region code for tenant context
|
|
3424
|
+
* @returns unknown Provider support status
|
|
2609
3425
|
* @throws ApiError
|
|
2610
3426
|
*/
|
|
2611
|
-
public static
|
|
2612
|
-
data:
|
|
2613
|
-
): CancelablePromise<
|
|
3427
|
+
public static providerSyncControllerIsProviderSupported(
|
|
3428
|
+
data: ProviderSyncControllerIsProviderSupportedData
|
|
3429
|
+
): CancelablePromise<ProviderSyncControllerIsProviderSupportedResponse> {
|
|
2614
3430
|
return __request(OpenAPI, {
|
|
2615
3431
|
method: 'GET',
|
|
2616
|
-
url: '/api/v1/bean/
|
|
2617
|
-
|
|
2618
|
-
|
|
3432
|
+
url: '/api/v1/{region}/bean/import/provider/{providerName}/supported',
|
|
3433
|
+
path: {
|
|
3434
|
+
providerName: data.providerName,
|
|
2619
3435
|
region: data.region
|
|
3436
|
+
},
|
|
3437
|
+
errors: {
|
|
3438
|
+
401: 'Missing or invalid authentication'
|
|
2620
3439
|
}
|
|
2621
3440
|
});
|
|
2622
3441
|
}
|
|
3442
|
+
}
|
|
2623
3443
|
|
|
3444
|
+
export class ExternalAccountLinksService {
|
|
2624
3445
|
/**
|
|
2625
|
-
*
|
|
3446
|
+
* Create an external account → BeanAccount mapping (ADR-0113)
|
|
2626
3447
|
* @param data The data for the request.
|
|
2627
|
-
* @param data.
|
|
3448
|
+
* @param data.region Region code for tenant context
|
|
2628
3449
|
* @param data.requestBody
|
|
2629
|
-
* @returns
|
|
3450
|
+
* @returns ExternalAccountLinkResponseDto Link created.
|
|
2630
3451
|
* @throws ApiError
|
|
2631
3452
|
*/
|
|
2632
|
-
public static
|
|
2633
|
-
data:
|
|
2634
|
-
): CancelablePromise<
|
|
3453
|
+
public static externalAccountLinkControllerCreate(
|
|
3454
|
+
data: ExternalAccountLinkControllerCreateData
|
|
3455
|
+
): CancelablePromise<ExternalAccountLinkControllerCreateResponse> {
|
|
2635
3456
|
return __request(OpenAPI, {
|
|
2636
|
-
method: '
|
|
2637
|
-
url: '/api/v1/bean/
|
|
3457
|
+
method: 'POST',
|
|
3458
|
+
url: '/api/v1/{region}/bean/external-account-links',
|
|
2638
3459
|
path: {
|
|
2639
|
-
|
|
3460
|
+
region: data.region
|
|
2640
3461
|
},
|
|
2641
3462
|
body: data.requestBody,
|
|
2642
3463
|
mediaType: 'application/json',
|
|
2643
3464
|
errors: {
|
|
2644
|
-
|
|
3465
|
+
422: 'beanAccountId not owned, or an active link already exists.'
|
|
2645
3466
|
}
|
|
2646
3467
|
});
|
|
2647
3468
|
}
|
|
2648
3469
|
|
|
2649
3470
|
/**
|
|
2650
|
-
*
|
|
3471
|
+
* List the user's active external account links
|
|
2651
3472
|
* @param data The data for the request.
|
|
2652
|
-
* @param data.
|
|
2653
|
-
* @
|
|
3473
|
+
* @param data.provider
|
|
3474
|
+
* @param data.region Region code for tenant context
|
|
3475
|
+
* @returns ExternalAccountLinkListResponseDto Links retrieved.
|
|
2654
3476
|
* @throws ApiError
|
|
2655
3477
|
*/
|
|
2656
|
-
public static
|
|
2657
|
-
data:
|
|
2658
|
-
): CancelablePromise<
|
|
3478
|
+
public static externalAccountLinkControllerFindAll(
|
|
3479
|
+
data: ExternalAccountLinkControllerFindAllData
|
|
3480
|
+
): CancelablePromise<ExternalAccountLinkControllerFindAllResponse> {
|
|
2659
3481
|
return __request(OpenAPI, {
|
|
2660
|
-
method: '
|
|
2661
|
-
url: '/api/v1/bean/
|
|
3482
|
+
method: 'GET',
|
|
3483
|
+
url: '/api/v1/{region}/bean/external-account-links',
|
|
2662
3484
|
path: {
|
|
2663
|
-
|
|
3485
|
+
region: data.region
|
|
2664
3486
|
},
|
|
2665
|
-
|
|
2666
|
-
|
|
3487
|
+
query: {
|
|
3488
|
+
provider: data.provider
|
|
2667
3489
|
}
|
|
2668
3490
|
});
|
|
2669
3491
|
}
|
|
2670
|
-
}
|
|
2671
3492
|
|
|
2672
|
-
export class ProviderSyncService {
|
|
2673
3493
|
/**
|
|
2674
|
-
*
|
|
2675
|
-
*
|
|
2676
|
-
* Accepts raw transactions from external financial data providers, transforms them to Beancount format, and processes them through the ingestion pipeline.
|
|
2677
|
-
*
|
|
2678
|
-
* **Supported Providers:**
|
|
2679
|
-
* - **plaid**: Plaid API (US, Canada, Europe)
|
|
2680
|
-
* - **teller**: Teller API (US)
|
|
2681
|
-
* - **truelayer**: TrueLayer Open Banking (UK, Europe)
|
|
2682
|
-
* - **gocardless**: GoCardless Bank Account Data (Europe)
|
|
2683
|
-
* - **simplefin**: SimpleFIN (Self-hosted)
|
|
2684
|
-
* - **yodlee**: Yodlee (Global)
|
|
2685
|
-
* - **beancount-direct**: Beancount format transactions
|
|
2686
|
-
* - **parsed-bill**: Client-side parsed bill transactions
|
|
2687
|
-
*
|
|
2688
|
-
* **Processing Flow:**
|
|
2689
|
-
* 1. Transform raw data via provider adapter
|
|
2690
|
-
* 2. Validate transaction format
|
|
2691
|
-
* 3. Deduplicate using originalId
|
|
2692
|
-
* 4. Classify using rule engine
|
|
2693
|
-
* 5. Route low-confidence to Review Center
|
|
2694
|
-
* 6. Persist validated transactions
|
|
2695
|
-
*
|
|
3494
|
+
* Get a single external account link
|
|
2696
3495
|
* @param data The data for the request.
|
|
2697
|
-
* @param data.
|
|
2698
|
-
* @param data.region Region code
|
|
2699
|
-
* @
|
|
2700
|
-
* @returns ProviderSyncResponseDto Sync completed successfully
|
|
3496
|
+
* @param data.id
|
|
3497
|
+
* @param data.region Region code for tenant context
|
|
3498
|
+
* @returns ExternalAccountLinkResponseDto Link retrieved.
|
|
2701
3499
|
* @throws ApiError
|
|
2702
3500
|
*/
|
|
2703
|
-
public static
|
|
2704
|
-
data:
|
|
2705
|
-
): CancelablePromise<
|
|
3501
|
+
public static externalAccountLinkControllerFindOne(
|
|
3502
|
+
data: ExternalAccountLinkControllerFindOneData
|
|
3503
|
+
): CancelablePromise<ExternalAccountLinkControllerFindOneResponse> {
|
|
2706
3504
|
return __request(OpenAPI, {
|
|
2707
|
-
method: '
|
|
2708
|
-
url: '/api/v1/{region}/bean/
|
|
3505
|
+
method: 'GET',
|
|
3506
|
+
url: '/api/v1/{region}/bean/external-account-links/{id}',
|
|
2709
3507
|
path: {
|
|
2710
|
-
|
|
3508
|
+
id: data.id,
|
|
2711
3509
|
region: data.region
|
|
2712
3510
|
},
|
|
2713
|
-
body: data.requestBody,
|
|
2714
|
-
mediaType: 'application/json',
|
|
2715
3511
|
errors: {
|
|
2716
|
-
|
|
2717
|
-
401: 'Missing or invalid authentication',
|
|
2718
|
-
404: 'Provider not supported'
|
|
3512
|
+
422: 'Link not found or not owned by the user.'
|
|
2719
3513
|
}
|
|
2720
3514
|
});
|
|
2721
3515
|
}
|
|
2722
3516
|
|
|
2723
3517
|
/**
|
|
2724
|
-
*
|
|
2725
|
-
* Returns a list of all providers supported by the sync endpoint.
|
|
3518
|
+
* Soft-delete (disconnect) an external account link
|
|
2726
3519
|
* @param data The data for the request.
|
|
3520
|
+
* @param data.id
|
|
2727
3521
|
* @param data.region Region code for tenant context
|
|
2728
|
-
* @returns
|
|
3522
|
+
* @returns void Link soft-deleted; historical transactions are unaffected.
|
|
2729
3523
|
* @throws ApiError
|
|
2730
3524
|
*/
|
|
2731
|
-
public static
|
|
2732
|
-
data:
|
|
2733
|
-
): CancelablePromise<
|
|
3525
|
+
public static externalAccountLinkControllerRemove(
|
|
3526
|
+
data: ExternalAccountLinkControllerRemoveData
|
|
3527
|
+
): CancelablePromise<ExternalAccountLinkControllerRemoveResponse> {
|
|
2734
3528
|
return __request(OpenAPI, {
|
|
2735
|
-
method: '
|
|
2736
|
-
url: '/api/v1/{region}/bean/
|
|
3529
|
+
method: 'DELETE',
|
|
3530
|
+
url: '/api/v1/{region}/bean/external-account-links/{id}',
|
|
3531
|
+
path: {
|
|
3532
|
+
id: data.id,
|
|
3533
|
+
region: data.region
|
|
3534
|
+
}
|
|
3535
|
+
});
|
|
3536
|
+
}
|
|
3537
|
+
}
|
|
3538
|
+
|
|
3539
|
+
export class ImportTelemetryService {
|
|
3540
|
+
/**
|
|
3541
|
+
* Receive anonymous parser failure telemetry
|
|
3542
|
+
* @param data The data for the request.
|
|
3543
|
+
* @param data.region Region code for tenant context
|
|
3544
|
+
* @param data.requestBody
|
|
3545
|
+
* @returns unknown Telemetry report received
|
|
3546
|
+
* @throws ApiError
|
|
3547
|
+
*/
|
|
3548
|
+
public static telemetryControllerReportTelemetry(
|
|
3549
|
+
data: TelemetryControllerReportTelemetryData
|
|
3550
|
+
): CancelablePromise<TelemetryControllerReportTelemetryResponse> {
|
|
3551
|
+
return __request(OpenAPI, {
|
|
3552
|
+
method: 'POST',
|
|
3553
|
+
url: '/api/v1/{region}/bean/import/parser-telemetry',
|
|
2737
3554
|
path: {
|
|
2738
3555
|
region: data.region
|
|
2739
3556
|
},
|
|
3557
|
+
body: data.requestBody,
|
|
3558
|
+
mediaType: 'application/json',
|
|
2740
3559
|
errors: {
|
|
2741
|
-
401: '
|
|
3560
|
+
401: 'Unauthorized'
|
|
2742
3561
|
}
|
|
2743
3562
|
});
|
|
2744
3563
|
}
|
|
2745
3564
|
|
|
2746
3565
|
/**
|
|
2747
|
-
*
|
|
2748
|
-
* Returns whether a specific provider is supported.
|
|
3566
|
+
* Receive anonymous zero-hit coverage miss report
|
|
2749
3567
|
* @param data The data for the request.
|
|
2750
|
-
* @param data.providerName Provider name to check
|
|
2751
3568
|
* @param data.region Region code for tenant context
|
|
2752
|
-
* @
|
|
3569
|
+
* @param data.requestBody
|
|
3570
|
+
* @returns unknown Coverage miss report received
|
|
2753
3571
|
* @throws ApiError
|
|
2754
3572
|
*/
|
|
2755
|
-
public static
|
|
2756
|
-
data:
|
|
2757
|
-
): CancelablePromise<
|
|
3573
|
+
public static telemetryControllerReportCoverageMiss(
|
|
3574
|
+
data: TelemetryControllerReportCoverageMissData
|
|
3575
|
+
): CancelablePromise<TelemetryControllerReportCoverageMissResponse> {
|
|
2758
3576
|
return __request(OpenAPI, {
|
|
2759
|
-
method: '
|
|
2760
|
-
url: '/api/v1/{region}/bean/import/
|
|
3577
|
+
method: 'POST',
|
|
3578
|
+
url: '/api/v1/{region}/bean/import/parser-coverage-miss',
|
|
2761
3579
|
path: {
|
|
2762
|
-
providerName: data.providerName,
|
|
2763
3580
|
region: data.region
|
|
2764
3581
|
},
|
|
3582
|
+
body: data.requestBody,
|
|
3583
|
+
mediaType: 'application/json',
|
|
2765
3584
|
errors: {
|
|
2766
|
-
401: '
|
|
3585
|
+
401: 'Unauthorized'
|
|
2767
3586
|
}
|
|
2768
3587
|
});
|
|
2769
3588
|
}
|
|
2770
|
-
}
|
|
2771
3589
|
|
|
2772
|
-
export class ImportTelemetryService {
|
|
2773
3590
|
/**
|
|
2774
|
-
*
|
|
3591
|
+
* Coverage metrics (uncovered format aggregation)
|
|
2775
3592
|
* @param data The data for the request.
|
|
2776
3593
|
* @param data.region Region code for tenant context
|
|
2777
|
-
* @param data.
|
|
2778
|
-
* @returns unknown
|
|
3594
|
+
* @param data.topN Top-N uncovered formats (default 10)
|
|
3595
|
+
* @returns unknown Coverage metrics
|
|
2779
3596
|
* @throws ApiError
|
|
2780
3597
|
*/
|
|
2781
|
-
public static
|
|
2782
|
-
data:
|
|
2783
|
-
): CancelablePromise<
|
|
3598
|
+
public static telemetryControllerGetCoverageMetrics(
|
|
3599
|
+
data: TelemetryControllerGetCoverageMetricsData
|
|
3600
|
+
): CancelablePromise<TelemetryControllerGetCoverageMetricsResponse> {
|
|
2784
3601
|
return __request(OpenAPI, {
|
|
2785
|
-
method: '
|
|
2786
|
-
url: '/api/v1/{region}/bean/import/parser-
|
|
3602
|
+
method: 'GET',
|
|
3603
|
+
url: '/api/v1/{region}/bean/import/parser-coverage-metrics',
|
|
2787
3604
|
path: {
|
|
2788
3605
|
region: data.region
|
|
2789
3606
|
},
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
errors: {
|
|
2793
|
-
401: 'Unauthorized'
|
|
3607
|
+
query: {
|
|
3608
|
+
topN: data.topN
|
|
2794
3609
|
}
|
|
2795
3610
|
});
|
|
2796
3611
|
}
|
|
@@ -2879,6 +3694,121 @@ export class BeanNlpService {
|
|
|
2879
3694
|
}
|
|
2880
3695
|
}
|
|
2881
3696
|
|
|
3697
|
+
export class BeanPlatformsService {
|
|
3698
|
+
/**
|
|
3699
|
+
* Get all platforms with statistics
|
|
3700
|
+
* @returns unknown List of platforms with binding and account counts
|
|
3701
|
+
* @throws ApiError
|
|
3702
|
+
*/
|
|
3703
|
+
public static platformControllerFindAll(): CancelablePromise<PlatformControllerFindAllResponse> {
|
|
3704
|
+
return __request(OpenAPI, {
|
|
3705
|
+
method: 'GET',
|
|
3706
|
+
url: '/api/v1/bean/platforms'
|
|
3707
|
+
});
|
|
3708
|
+
}
|
|
3709
|
+
|
|
3710
|
+
/**
|
|
3711
|
+
* Create a new platform
|
|
3712
|
+
* @param data The data for the request.
|
|
3713
|
+
* @param data.requestBody
|
|
3714
|
+
* @returns unknown Platform created successfully
|
|
3715
|
+
* @throws ApiError
|
|
3716
|
+
*/
|
|
3717
|
+
public static platformControllerCreate(
|
|
3718
|
+
data: PlatformControllerCreateData
|
|
3719
|
+
): CancelablePromise<PlatformControllerCreateResponse> {
|
|
3720
|
+
return __request(OpenAPI, {
|
|
3721
|
+
method: 'POST',
|
|
3722
|
+
url: '/api/v1/bean/platforms',
|
|
3723
|
+
body: data.requestBody,
|
|
3724
|
+
mediaType: 'application/json',
|
|
3725
|
+
errors: {
|
|
3726
|
+
409: 'Platform already exists'
|
|
3727
|
+
}
|
|
3728
|
+
});
|
|
3729
|
+
}
|
|
3730
|
+
|
|
3731
|
+
/**
|
|
3732
|
+
* Get platform list for current user
|
|
3733
|
+
* @returns PlatformListItemDto List of platforms with user binding status
|
|
3734
|
+
* @throws ApiError
|
|
3735
|
+
*/
|
|
3736
|
+
public static platformControllerGetPlatformList(): CancelablePromise<PlatformControllerGetPlatformListResponse> {
|
|
3737
|
+
return __request(OpenAPI, {
|
|
3738
|
+
method: 'GET',
|
|
3739
|
+
url: '/api/v1/bean/platforms/list'
|
|
3740
|
+
});
|
|
3741
|
+
}
|
|
3742
|
+
|
|
3743
|
+
/**
|
|
3744
|
+
* Match platforms by name or alias
|
|
3745
|
+
* @param data The data for the request.
|
|
3746
|
+
* @param data.q Search query — Chinese name, English name, or abbreviation
|
|
3747
|
+
* @param data.region Region code for category override lookup
|
|
3748
|
+
* @returns PlatformMatchResponseDto Matching platforms with overall match type and truncation flag
|
|
3749
|
+
* @throws ApiError
|
|
3750
|
+
*/
|
|
3751
|
+
public static platformControllerMatchPlatforms(
|
|
3752
|
+
data: PlatformControllerMatchPlatformsData
|
|
3753
|
+
): CancelablePromise<PlatformControllerMatchPlatformsResponse> {
|
|
3754
|
+
return __request(OpenAPI, {
|
|
3755
|
+
method: 'GET',
|
|
3756
|
+
url: '/api/v1/bean/platforms/match',
|
|
3757
|
+
query: {
|
|
3758
|
+
q: data.q,
|
|
3759
|
+
region: data.region
|
|
3760
|
+
}
|
|
3761
|
+
});
|
|
3762
|
+
}
|
|
3763
|
+
|
|
3764
|
+
/**
|
|
3765
|
+
* Update a platform
|
|
3766
|
+
* @param data The data for the request.
|
|
3767
|
+
* @param data.id Platform ID
|
|
3768
|
+
* @param data.requestBody
|
|
3769
|
+
* @returns unknown Platform updated successfully
|
|
3770
|
+
* @throws ApiError
|
|
3771
|
+
*/
|
|
3772
|
+
public static platformControllerUpdate(
|
|
3773
|
+
data: PlatformControllerUpdateData
|
|
3774
|
+
): CancelablePromise<PlatformControllerUpdateResponse> {
|
|
3775
|
+
return __request(OpenAPI, {
|
|
3776
|
+
method: 'PUT',
|
|
3777
|
+
url: '/api/v1/bean/platforms/{id}',
|
|
3778
|
+
path: {
|
|
3779
|
+
id: data.id
|
|
3780
|
+
},
|
|
3781
|
+
body: data.requestBody,
|
|
3782
|
+
mediaType: 'application/json',
|
|
3783
|
+
errors: {
|
|
3784
|
+
404: 'Platform not found'
|
|
3785
|
+
}
|
|
3786
|
+
});
|
|
3787
|
+
}
|
|
3788
|
+
|
|
3789
|
+
/**
|
|
3790
|
+
* Delete a platform
|
|
3791
|
+
* @param data The data for the request.
|
|
3792
|
+
* @param data.id Platform ID
|
|
3793
|
+
* @returns void Platform deleted successfully
|
|
3794
|
+
* @throws ApiError
|
|
3795
|
+
*/
|
|
3796
|
+
public static platformControllerDelete(
|
|
3797
|
+
data: PlatformControllerDeleteData
|
|
3798
|
+
): CancelablePromise<PlatformControllerDeleteResponse> {
|
|
3799
|
+
return __request(OpenAPI, {
|
|
3800
|
+
method: 'DELETE',
|
|
3801
|
+
url: '/api/v1/bean/platforms/{id}',
|
|
3802
|
+
path: {
|
|
3803
|
+
id: data.id
|
|
3804
|
+
},
|
|
3805
|
+
errors: {
|
|
3806
|
+
404: 'Platform not found'
|
|
3807
|
+
}
|
|
3808
|
+
});
|
|
3809
|
+
}
|
|
3810
|
+
}
|
|
3811
|
+
|
|
2882
3812
|
export class DashboardService {
|
|
2883
3813
|
/**
|
|
2884
3814
|
* Get net worth overview
|
|
@@ -2914,6 +3844,7 @@ export class DashboardService {
|
|
|
2914
3844
|
* @param data.region Region code for tenant context
|
|
2915
3845
|
* @param data.groupBy Grouping strategy
|
|
2916
3846
|
* @param data.date Date for balance calculation (ISO 8601 format)
|
|
3847
|
+
* @param data.accountId Scope to a single account (only valid with groupBy=holdingAssetClass, ADR-0105 §6)
|
|
2917
3848
|
* @returns unknown Accounts retrieved successfully. Response type depends on groupBy parameter.
|
|
2918
3849
|
* @throws ApiError
|
|
2919
3850
|
*/
|
|
@@ -2928,7 +3859,8 @@ export class DashboardService {
|
|
|
2928
3859
|
},
|
|
2929
3860
|
query: {
|
|
2930
3861
|
groupBy: data.groupBy,
|
|
2931
|
-
date: data.date
|
|
3862
|
+
date: data.date,
|
|
3863
|
+
accountId: data.accountId
|
|
2932
3864
|
},
|
|
2933
3865
|
errors: {
|
|
2934
3866
|
401: 'User not authenticated'
|
|
@@ -2963,124 +3895,69 @@ export class DashboardService {
|
|
|
2963
3895
|
}
|
|
2964
3896
|
});
|
|
2965
3897
|
}
|
|
2966
|
-
}
|
|
2967
3898
|
|
|
2968
|
-
export class ReportingService {
|
|
2969
3899
|
/**
|
|
2970
|
-
* Get
|
|
2971
|
-
*
|
|
2972
|
-
* Returns time series data of portfolio net worth.
|
|
2973
|
-
*
|
|
2974
|
-
* **Multi-currency Support:**
|
|
2975
|
-
* - `series[].byCurrency` - Currency breakdown for each data point
|
|
2976
|
-
* - `byCurrency` - Separate time series grouped by currency
|
|
2977
|
-
* - `warnings` - Exchange rate warnings if conversion failed
|
|
2978
|
-
*
|
|
2979
|
-
* **Parameters:**
|
|
2980
|
-
* - `period`: Time period (1m, 3m, 6m, 1y)
|
|
2981
|
-
* - `granularity`: Data granularity (day, week, month)
|
|
2982
|
-
*
|
|
3900
|
+
* Get expenses/income grouped by functional category
|
|
3901
|
+
* Returns amounts pre-aggregated by functional category (account-path Group segment) with server-side multi-currency conversion. flow=expense (default) aggregates ^Expenses: accounts; flow=income aggregates ^Income: accounts (issue #518)
|
|
2983
3902
|
* @param data The data for the request.
|
|
2984
3903
|
* @param data.region Region code for tenant context
|
|
2985
|
-
* @param data.
|
|
2986
|
-
* @param data.
|
|
2987
|
-
* @
|
|
3904
|
+
* @param data.groupBy Grouping strategy
|
|
3905
|
+
* @param data.period Time window (1m = current calendar month)
|
|
3906
|
+
* @param data.flow Account root to aggregate (expense → ^Expenses:, income → ^Income:)
|
|
3907
|
+
* @returns ExpensesByCategoryResponseDto Expenses retrieved successfully
|
|
2988
3908
|
* @throws ApiError
|
|
2989
3909
|
*/
|
|
2990
|
-
public static
|
|
2991
|
-
data:
|
|
2992
|
-
): CancelablePromise<
|
|
3910
|
+
public static dashboardControllerGetExpenses(
|
|
3911
|
+
data: DashboardControllerGetExpensesData
|
|
3912
|
+
): CancelablePromise<DashboardControllerGetExpensesResponse> {
|
|
2993
3913
|
return __request(OpenAPI, {
|
|
2994
3914
|
method: 'GET',
|
|
2995
|
-
url: '/api/v1/{region}/
|
|
3915
|
+
url: '/api/v1/{region}/dashboard/expenses',
|
|
2996
3916
|
path: {
|
|
2997
3917
|
region: data.region
|
|
2998
3918
|
},
|
|
2999
3919
|
query: {
|
|
3920
|
+
groupBy: data.groupBy,
|
|
3000
3921
|
period: data.period,
|
|
3001
|
-
|
|
3922
|
+
flow: data.flow
|
|
3002
3923
|
},
|
|
3003
3924
|
errors: {
|
|
3925
|
+
400: 'Invalid groupBy or period',
|
|
3004
3926
|
401: 'User not authenticated'
|
|
3005
3927
|
}
|
|
3006
3928
|
});
|
|
3007
3929
|
}
|
|
3930
|
+
}
|
|
3008
3931
|
|
|
3932
|
+
export class InvestmentService {
|
|
3009
3933
|
/**
|
|
3010
|
-
*
|
|
3011
|
-
*
|
|
3012
|
-
* Manually generate a portfolio snapshot for a specific date.
|
|
3013
|
-
*
|
|
3014
|
-
* **Multi-currency Support:**
|
|
3015
|
-
* - Fetches balances grouped by currency
|
|
3016
|
-
* - Uses user's baseCurrency setting for conversion
|
|
3017
|
-
* - Stores exchange rates and warnings
|
|
3018
|
-
*
|
|
3019
|
-
* **Use Cases:**
|
|
3020
|
-
* - Testing snapshot generation
|
|
3021
|
-
* - Force regeneration after data correction
|
|
3022
|
-
* - Initial setup for new users
|
|
3023
|
-
*
|
|
3934
|
+
* Get per-holding unrealized + realized P&L
|
|
3935
|
+
* Average-cost unrealized P&L per account × commodity, plus cumulative realized P&L on sold lots (method = FIFO | average, default average).
|
|
3024
3936
|
* @param data The data for the request.
|
|
3025
3937
|
* @param data.region Region code for tenant context
|
|
3026
|
-
* @param data.
|
|
3027
|
-
* @
|
|
3938
|
+
* @param data.asOf As-of date (ISO 8601), defaults to today
|
|
3939
|
+
* @param data.accountId Scope to a single account
|
|
3940
|
+
* @param data.method Realized-P&L lot-matching method (default average). Does not affect the average-cost unrealized basis.
|
|
3941
|
+
* @returns HoldingPnlResponseDto Holding P&L retrieved successfully
|
|
3028
3942
|
* @throws ApiError
|
|
3029
3943
|
*/
|
|
3030
|
-
public static
|
|
3031
|
-
data:
|
|
3032
|
-
): CancelablePromise<
|
|
3944
|
+
public static holdingPnlControllerGetHoldingPnl(
|
|
3945
|
+
data: HoldingPnlControllerGetHoldingPnlData
|
|
3946
|
+
): CancelablePromise<HoldingPnlControllerGetHoldingPnlResponse> {
|
|
3033
3947
|
return __request(OpenAPI, {
|
|
3034
|
-
method: '
|
|
3035
|
-
url: '/api/v1/{region}/
|
|
3948
|
+
method: 'GET',
|
|
3949
|
+
url: '/api/v1/{region}/investment/holdings/pnl',
|
|
3036
3950
|
path: {
|
|
3037
3951
|
region: data.region
|
|
3038
3952
|
},
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
401: 'User not authenticated'
|
|
3044
|
-
}
|
|
3045
|
-
});
|
|
3046
|
-
}
|
|
3047
|
-
|
|
3048
|
-
/**
|
|
3049
|
-
* Backfill portfolio snapshots
|
|
3050
|
-
*
|
|
3051
|
-
* Generate snapshots for a date range (historical data backfill).
|
|
3052
|
-
*
|
|
3053
|
-
* **Multi-currency Support:**
|
|
3054
|
-
* - Each snapshot includes multi-currency data
|
|
3055
|
-
* - Uses exchange rates available at generation time
|
|
3056
|
-
* - Warnings stored for missing exchange rates
|
|
3057
|
-
*
|
|
3058
|
-
* **Best Practices:**
|
|
3059
|
-
* - Use for initial setup after account configuration
|
|
3060
|
-
* - Run during low-traffic periods for large date ranges
|
|
3061
|
-
* - Existing snapshots are skipped (not regenerated)
|
|
3062
|
-
*
|
|
3063
|
-
* @param data The data for the request.
|
|
3064
|
-
* @param data.region Region code for tenant context
|
|
3065
|
-
* @param data.requestBody
|
|
3066
|
-
* @returns BackfillSnapshotsResponse Backfill completed successfully
|
|
3067
|
-
* @throws ApiError
|
|
3068
|
-
*/
|
|
3069
|
-
public static reportingControllerBackfillSnapshots(
|
|
3070
|
-
data: ReportingControllerBackfillSnapshotsData
|
|
3071
|
-
): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
|
|
3072
|
-
return __request(OpenAPI, {
|
|
3073
|
-
method: 'POST',
|
|
3074
|
-
url: '/api/v1/{region}/reporting/snapshots/backfill',
|
|
3075
|
-
path: {
|
|
3076
|
-
region: data.region
|
|
3953
|
+
query: {
|
|
3954
|
+
asOf: data.asOf,
|
|
3955
|
+
accountId: data.accountId,
|
|
3956
|
+
method: data.method
|
|
3077
3957
|
},
|
|
3078
|
-
body: data.requestBody,
|
|
3079
|
-
mediaType: 'application/json',
|
|
3080
3958
|
errors: {
|
|
3081
|
-
400: 'Invalid date format or
|
|
3082
|
-
401: 'User not authenticated'
|
|
3083
|
-
409: 'Backfill already in progress for this user'
|
|
3959
|
+
400: 'Invalid asOf format/value/future date, invalid accountId format, or unsupported method',
|
|
3960
|
+
401: 'User not authenticated'
|
|
3084
3961
|
}
|
|
3085
3962
|
});
|
|
3086
3963
|
}
|
|
@@ -3109,7 +3986,7 @@ export class AuthService {
|
|
|
3109
3986
|
* Anonymous login with access token
|
|
3110
3987
|
* @param data The data for the request.
|
|
3111
3988
|
* @param data.requestBody
|
|
3112
|
-
* @returns
|
|
3989
|
+
* @returns AnonymousLoginResponseDto Login successful
|
|
3113
3990
|
* @throws ApiError
|
|
3114
3991
|
*/
|
|
3115
3992
|
public static authControllerAccessTokenLogin(
|
|
@@ -3296,3 +4173,53 @@ export class InfoService {
|
|
|
3296
4173
|
});
|
|
3297
4174
|
}
|
|
3298
4175
|
}
|
|
4176
|
+
|
|
4177
|
+
export class MarketDataService {
|
|
4178
|
+
/**
|
|
4179
|
+
* Search market symbols by name or code
|
|
4180
|
+
* Ranked search over the openbb catalog. Empty `q` returns [].
|
|
4181
|
+
* @param data The data for the request.
|
|
4182
|
+
* @param data.q Search term — matched against symbol and instrument name. Empty string returns [].
|
|
4183
|
+
* @param data.limit Maximum number of results (clamped 1..50)
|
|
4184
|
+
* @param data.exchange Filter by exchange code (e.g. US, HK, SS, SZ)
|
|
4185
|
+
* @param data.assetType Filter by OpenBB asset_type (e.g. stock, etf)
|
|
4186
|
+
* @returns SymbolSearchResultDto Ranked search results
|
|
4187
|
+
* @throws ApiError
|
|
4188
|
+
*/
|
|
4189
|
+
public static symbolControllerSearch(
|
|
4190
|
+
data: SymbolControllerSearchData
|
|
4191
|
+
): CancelablePromise<SymbolControllerSearchResponse> {
|
|
4192
|
+
return __request(OpenAPI, {
|
|
4193
|
+
method: 'GET',
|
|
4194
|
+
url: '/api/v1/market/symbols/search',
|
|
4195
|
+
query: {
|
|
4196
|
+
q: data.q,
|
|
4197
|
+
limit: data.limit,
|
|
4198
|
+
exchange: data.exchange,
|
|
4199
|
+
assetType: data.assetType
|
|
4200
|
+
}
|
|
4201
|
+
});
|
|
4202
|
+
}
|
|
4203
|
+
|
|
4204
|
+
/**
|
|
4205
|
+
* Get a market symbol quote
|
|
4206
|
+
* @param data The data for the request.
|
|
4207
|
+
* @param data.symbol
|
|
4208
|
+
* @returns SymbolQuoteDto Symbol quote
|
|
4209
|
+
* @throws ApiError
|
|
4210
|
+
*/
|
|
4211
|
+
public static symbolControllerGetQuote(
|
|
4212
|
+
data: SymbolControllerGetQuoteData
|
|
4213
|
+
): CancelablePromise<SymbolControllerGetQuoteResponse> {
|
|
4214
|
+
return __request(OpenAPI, {
|
|
4215
|
+
method: 'GET',
|
|
4216
|
+
url: '/api/v1/market/symbols/{symbol}/quote',
|
|
4217
|
+
path: {
|
|
4218
|
+
symbol: data.symbol
|
|
4219
|
+
},
|
|
4220
|
+
errors: {
|
|
4221
|
+
404: 'Symbol not found in the openbb catalog'
|
|
4222
|
+
}
|
|
4223
|
+
});
|
|
4224
|
+
}
|
|
4225
|
+
}
|