@firela/api-types 0.0.0-canary.8c68ebbe → 0.0.0-canary.90dabcd7
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 +2429 -1237
- package/dist/index.d.ts +2429 -1237
- package/dist/index.js +33 -5
- package/dist/index.mjs +33 -5
- package/package.json +1 -1
- package/src/generated/schemas.gen.ts +2636 -1341
- package/src/generated/services.gen.ts +1251 -774
- package/src/generated/types.gen.ts +5403 -1337
|
@@ -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,
|
|
@@ -97,6 +99,18 @@ import type {
|
|
|
97
99
|
CommodityControllerGetOrCreateResponse,
|
|
98
100
|
CommodityControllerBulkCreateData,
|
|
99
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,
|
|
100
114
|
RecurringRuleControllerCreateData,
|
|
101
115
|
RecurringRuleControllerCreateResponse,
|
|
102
116
|
RecurringRuleControllerFindAllData,
|
|
@@ -129,26 +143,14 @@ import type {
|
|
|
129
143
|
ExpectedTransactionControllerEnterNowResponse,
|
|
130
144
|
ForecastControllerGetForecastData,
|
|
131
145
|
ForecastControllerGetForecastResponse,
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
TransactionRuleControllerExportData,
|
|
141
|
-
TransactionRuleControllerExportResponse,
|
|
142
|
-
TransactionRuleControllerGetStatisticsData,
|
|
143
|
-
TransactionRuleControllerGetStatisticsResponse,
|
|
144
|
-
TransactionRuleControllerGetDetailData,
|
|
145
|
-
TransactionRuleControllerGetDetailResponse,
|
|
146
|
-
TransactionRuleControllerUpdateData,
|
|
147
|
-
TransactionRuleControllerUpdateResponse,
|
|
148
|
-
TransactionRuleControllerDeleteData,
|
|
149
|
-
TransactionRuleControllerDeleteResponse,
|
|
150
|
-
TransactionRuleControllerTestData,
|
|
151
|
-
TransactionRuleControllerTestResponse,
|
|
146
|
+
ReportingControllerGetPortfolioTrendsData,
|
|
147
|
+
ReportingControllerGetPortfolioTrendsResponse,
|
|
148
|
+
ReportingControllerGetCashFlowTrendsData,
|
|
149
|
+
ReportingControllerGetCashFlowTrendsResponse,
|
|
150
|
+
ReportingControllerGenerateSnapshotData,
|
|
151
|
+
ReportingControllerGenerateSnapshotResponse,
|
|
152
|
+
ReportingControllerBackfillSnapshotsData,
|
|
153
|
+
ReportingControllerBackfillSnapshotsResponse,
|
|
152
154
|
UserControllerDeleteOwnUserData,
|
|
153
155
|
UserControllerDeleteOwnUserResponse,
|
|
154
156
|
UserControllerGetUserData,
|
|
@@ -171,6 +173,28 @@ import type {
|
|
|
171
173
|
PropertyControllerUpdateResponse,
|
|
172
174
|
PropertyControllerDeleteData,
|
|
173
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
|
+
CategoryCatalogControllerListData,
|
|
197
|
+
CategoryCatalogControllerListResponse,
|
|
174
198
|
EventControllerCreateData,
|
|
175
199
|
EventControllerCreateResponse,
|
|
176
200
|
EventControllerFindAllData,
|
|
@@ -181,6 +205,18 @@ import type {
|
|
|
181
205
|
EventControllerUpdateResponse,
|
|
182
206
|
EventControllerDeleteData,
|
|
183
207
|
EventControllerDeleteResponse,
|
|
208
|
+
EventControllerGetSliceData,
|
|
209
|
+
EventControllerGetSliceResponse,
|
|
210
|
+
OnboardingControllerBootstrapData,
|
|
211
|
+
OnboardingControllerBootstrapResponse,
|
|
212
|
+
ReconciliationControllerComputeData,
|
|
213
|
+
ReconciliationControllerComputeResponse,
|
|
214
|
+
ReconciliationControllerAssertData,
|
|
215
|
+
ReconciliationControllerAssertResponse,
|
|
216
|
+
ReconciliationControllerPadData,
|
|
217
|
+
ReconciliationControllerPadResponse,
|
|
218
|
+
ReconciliationControllerHistoryData,
|
|
219
|
+
ReconciliationControllerHistoryResponse,
|
|
184
220
|
ExportControllerExportBeancountResponse,
|
|
185
221
|
FileImportControllerImportFileData,
|
|
186
222
|
FileImportControllerImportFileResponse,
|
|
@@ -194,22 +230,20 @@ import type {
|
|
|
194
230
|
ImporterConfigControllerUpdateConfigResponse,
|
|
195
231
|
ImporterConfigControllerResetConfigData,
|
|
196
232
|
ImporterConfigControllerResetConfigResponse,
|
|
197
|
-
PlatformControllerFindAllResponse,
|
|
198
|
-
PlatformControllerCreateData,
|
|
199
|
-
PlatformControllerCreateResponse,
|
|
200
|
-
PlatformControllerGetPlatformListResponse,
|
|
201
|
-
PlatformControllerMatchPlatformsData,
|
|
202
|
-
PlatformControllerMatchPlatformsResponse,
|
|
203
|
-
PlatformControllerUpdateData,
|
|
204
|
-
PlatformControllerUpdateResponse,
|
|
205
|
-
PlatformControllerDeleteData,
|
|
206
|
-
PlatformControllerDeleteResponse,
|
|
207
233
|
ProviderSyncControllerSyncData,
|
|
208
234
|
ProviderSyncControllerSyncResponse,
|
|
209
235
|
ProviderSyncControllerGetSupportedProvidersData,
|
|
210
236
|
ProviderSyncControllerGetSupportedProvidersResponse,
|
|
211
237
|
ProviderSyncControllerIsProviderSupportedData,
|
|
212
238
|
ProviderSyncControllerIsProviderSupportedResponse,
|
|
239
|
+
ExternalAccountLinkControllerCreateData,
|
|
240
|
+
ExternalAccountLinkControllerCreateResponse,
|
|
241
|
+
ExternalAccountLinkControllerFindAllData,
|
|
242
|
+
ExternalAccountLinkControllerFindAllResponse,
|
|
243
|
+
ExternalAccountLinkControllerFindOneData,
|
|
244
|
+
ExternalAccountLinkControllerFindOneResponse,
|
|
245
|
+
ExternalAccountLinkControllerRemoveData,
|
|
246
|
+
ExternalAccountLinkControllerRemoveResponse,
|
|
213
247
|
TelemetryControllerReportTelemetryData,
|
|
214
248
|
TelemetryControllerReportTelemetryResponse,
|
|
215
249
|
TelemetryControllerReportCoverageMissData,
|
|
@@ -222,32 +256,27 @@ import type {
|
|
|
222
256
|
NlpControllerClearSessionResponse,
|
|
223
257
|
NlpControllerGetSessionData,
|
|
224
258
|
NlpControllerGetSessionResponse,
|
|
259
|
+
PlatformControllerFindAllResponse,
|
|
260
|
+
PlatformControllerCreateData,
|
|
261
|
+
PlatformControllerCreateResponse,
|
|
262
|
+
PlatformControllerGetPlatformListData,
|
|
263
|
+
PlatformControllerGetPlatformListResponse,
|
|
264
|
+
PlatformControllerMatchPlatformsData,
|
|
265
|
+
PlatformControllerMatchPlatformsResponse,
|
|
266
|
+
PlatformControllerUpdateData,
|
|
267
|
+
PlatformControllerUpdateResponse,
|
|
268
|
+
PlatformControllerDeleteData,
|
|
269
|
+
PlatformControllerDeleteResponse,
|
|
225
270
|
DashboardControllerGetNetWorthData,
|
|
226
271
|
DashboardControllerGetNetWorthResponse,
|
|
227
272
|
DashboardControllerGetAccountsData,
|
|
228
273
|
DashboardControllerGetAccountsResponse,
|
|
229
274
|
DashboardControllerGetCashFlowData,
|
|
230
275
|
DashboardControllerGetCashFlowResponse,
|
|
276
|
+
DashboardControllerGetExpensesData,
|
|
277
|
+
DashboardControllerGetExpensesResponse,
|
|
231
278
|
HoldingPnlControllerGetHoldingPnlData,
|
|
232
279
|
HoldingPnlControllerGetHoldingPnlResponse,
|
|
233
|
-
PriceControllerCreateData,
|
|
234
|
-
PriceControllerCreateResponse,
|
|
235
|
-
PriceControllerFindAllData,
|
|
236
|
-
PriceControllerFindAllResponse,
|
|
237
|
-
PriceControllerFindOneData,
|
|
238
|
-
PriceControllerFindOneResponse,
|
|
239
|
-
PriceControllerUpdateData,
|
|
240
|
-
PriceControllerUpdateResponse,
|
|
241
|
-
PriceControllerDeleteData,
|
|
242
|
-
PriceControllerDeleteResponse,
|
|
243
|
-
PriceControllerBulkCreateData,
|
|
244
|
-
PriceControllerBulkCreateResponse,
|
|
245
|
-
ReportingControllerGetPortfolioTrendsData,
|
|
246
|
-
ReportingControllerGetPortfolioTrendsResponse,
|
|
247
|
-
ReportingControllerGenerateSnapshotData,
|
|
248
|
-
ReportingControllerGenerateSnapshotResponse,
|
|
249
|
-
ReportingControllerBackfillSnapshotsData,
|
|
250
|
-
ReportingControllerBackfillSnapshotsResponse,
|
|
251
280
|
ApiKeysControllerCreateApiKeyResponse,
|
|
252
281
|
AuthControllerAccessTokenLoginData,
|
|
253
282
|
AuthControllerAccessTokenLoginResponse,
|
|
@@ -262,7 +291,11 @@ import type {
|
|
|
262
291
|
HealthControllerResetCircuitBreakerData,
|
|
263
292
|
HealthControllerResetCircuitBreakerResponse,
|
|
264
293
|
HealthControllerGetMetricsResponse,
|
|
265
|
-
InfoControllerGetInfoResponse
|
|
294
|
+
InfoControllerGetInfoResponse,
|
|
295
|
+
SymbolControllerSearchData,
|
|
296
|
+
SymbolControllerSearchResponse,
|
|
297
|
+
SymbolControllerGetQuoteData,
|
|
298
|
+
SymbolControllerGetQuoteResponse
|
|
266
299
|
} from './types.gen';
|
|
267
300
|
|
|
268
301
|
export class BeanAccountsService {
|
|
@@ -300,7 +333,7 @@ export class BeanAccountsService {
|
|
|
300
333
|
* @param data.type Filter by account type
|
|
301
334
|
* @param data.status Filter by status
|
|
302
335
|
* @param data.isCustom Filter by custom (user-created) accounts only
|
|
303
|
-
* @param data.search Search term for path
|
|
336
|
+
* @param data.search Search term for account path
|
|
304
337
|
* @param data.limit Maximum number of results
|
|
305
338
|
* @param data.offset Number of results to skip
|
|
306
339
|
* @returns AccountListResponseDto Accounts retrieved successfully
|
|
@@ -381,7 +414,7 @@ export class BeanAccountsService {
|
|
|
381
414
|
|
|
382
415
|
/**
|
|
383
416
|
* Delete account
|
|
384
|
-
* Deletes an account (only if no transactions)
|
|
417
|
+
* Deletes an account (only if no active transactions; voided/superseded residual postings are cleaned up)
|
|
385
418
|
* @param data The data for the request.
|
|
386
419
|
* @param data.id Account UUID
|
|
387
420
|
* @param data.region Region code for tenant context
|
|
@@ -400,7 +433,7 @@ export class BeanAccountsService {
|
|
|
400
433
|
},
|
|
401
434
|
errors: {
|
|
402
435
|
404: 'Account not found',
|
|
403
|
-
409: 'Account has transactions and cannot be deleted'
|
|
436
|
+
409: 'Account has active transactions and cannot be deleted'
|
|
404
437
|
}
|
|
405
438
|
});
|
|
406
439
|
}
|
|
@@ -462,6 +495,35 @@ export class BeanAccountsService {
|
|
|
462
495
|
}
|
|
463
496
|
});
|
|
464
497
|
}
|
|
498
|
+
|
|
499
|
+
/**
|
|
500
|
+
* Post an opening-balance transaction
|
|
501
|
+
* 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.
|
|
502
|
+
* @param data The data for the request.
|
|
503
|
+
* @param data.id Account UUID
|
|
504
|
+
* @param data.region Region code for tenant context
|
|
505
|
+
* @param data.requestBody
|
|
506
|
+
* @returns OpeningBalanceResultDto Opening-balance transaction created
|
|
507
|
+
* @throws ApiError
|
|
508
|
+
*/
|
|
509
|
+
public static accountControllerAddOpeningBalance(
|
|
510
|
+
data: AccountControllerAddOpeningBalanceData
|
|
511
|
+
): CancelablePromise<AccountControllerAddOpeningBalanceResponse> {
|
|
512
|
+
return __request(OpenAPI, {
|
|
513
|
+
method: 'POST',
|
|
514
|
+
url: '/api/v1/{region}/bean/accounts/{id}/opening-balance',
|
|
515
|
+
path: {
|
|
516
|
+
id: data.id,
|
|
517
|
+
region: data.region
|
|
518
|
+
},
|
|
519
|
+
body: data.requestBody,
|
|
520
|
+
mediaType: 'application/json',
|
|
521
|
+
errors: {
|
|
522
|
+
404: 'Account not found',
|
|
523
|
+
409: 'An opening balance already exists for this account'
|
|
524
|
+
}
|
|
525
|
+
});
|
|
526
|
+
}
|
|
465
527
|
}
|
|
466
528
|
|
|
467
529
|
export class BeanAccountStandardsService {
|
|
@@ -493,7 +555,7 @@ export class BeanAccountStandardsService {
|
|
|
493
555
|
|
|
494
556
|
/**
|
|
495
557
|
* Get template metadata for an account path
|
|
496
|
-
* Returns
|
|
558
|
+
* Returns root type for a template path.
|
|
497
559
|
* @param data The data for the request.
|
|
498
560
|
* @param data.region Region code for tenant context
|
|
499
561
|
* @param data.path Account path to check
|
|
@@ -579,6 +641,7 @@ export class BeanTransactionsService {
|
|
|
579
641
|
* @param data.status Filter by transaction status
|
|
580
642
|
* @param data.search Search in narration and payee fields (max 200 chars)
|
|
581
643
|
* @param data.accountId Filter by account ID (transactions with postings to this account)
|
|
644
|
+
* @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
|
|
582
645
|
* @returns TransactionListResponseDto Transaction list
|
|
583
646
|
* @throws ApiError
|
|
584
647
|
*/
|
|
@@ -598,7 +661,8 @@ export class BeanTransactionsService {
|
|
|
598
661
|
dateTo: data.dateTo,
|
|
599
662
|
status: data.status,
|
|
600
663
|
search: data.search,
|
|
601
|
-
accountId: data.accountId
|
|
664
|
+
accountId: data.accountId,
|
|
665
|
+
category: data.category
|
|
602
666
|
},
|
|
603
667
|
errors: {
|
|
604
668
|
400: 'Validation failed',
|
|
@@ -786,7 +850,7 @@ export class BeanBalancesService {
|
|
|
786
850
|
* Query account balance
|
|
787
851
|
* Calculate account balance at a specific date for a single currency
|
|
788
852
|
* @param data The data for the request.
|
|
789
|
-
* @param data.account Account name (e.g., "Assets:
|
|
853
|
+
* @param data.account Account name (e.g., "Assets:Checking")
|
|
790
854
|
* @param data.region Region code for tenant context
|
|
791
855
|
* @param data.date Date to calculate balance at (ISO 8601 format)
|
|
792
856
|
* @param data.currency Currency to query (e.g., "USD", "CNY")
|
|
@@ -1507,155 +1571,322 @@ export class BeanCommoditiesService {
|
|
|
1507
1571
|
}
|
|
1508
1572
|
}
|
|
1509
1573
|
|
|
1510
|
-
export class
|
|
1574
|
+
export class BeanPricesService {
|
|
1511
1575
|
/**
|
|
1512
|
-
* Create a new
|
|
1513
|
-
* Creates a new
|
|
1576
|
+
* Create a new price
|
|
1577
|
+
* Creates a new price entry for the authenticated user
|
|
1514
1578
|
* @param data The data for the request.
|
|
1515
1579
|
* @param data.region Region code for tenant context
|
|
1516
1580
|
* @param data.requestBody
|
|
1517
|
-
* @returns
|
|
1581
|
+
* @returns PriceResponseDto Price created successfully
|
|
1518
1582
|
* @throws ApiError
|
|
1519
1583
|
*/
|
|
1520
|
-
public static
|
|
1521
|
-
data:
|
|
1522
|
-
): CancelablePromise<
|
|
1584
|
+
public static priceControllerCreate(
|
|
1585
|
+
data: PriceControllerCreateData
|
|
1586
|
+
): CancelablePromise<PriceControllerCreateResponse> {
|
|
1523
1587
|
return __request(OpenAPI, {
|
|
1524
1588
|
method: 'POST',
|
|
1525
|
-
url: '/api/v1/{region}/bean/
|
|
1589
|
+
url: '/api/v1/{region}/bean/prices',
|
|
1526
1590
|
path: {
|
|
1527
1591
|
region: data.region
|
|
1528
1592
|
},
|
|
1529
1593
|
body: data.requestBody,
|
|
1530
1594
|
mediaType: 'application/json',
|
|
1531
1595
|
errors: {
|
|
1532
|
-
|
|
1533
|
-
409: '
|
|
1596
|
+
404: 'Currency or quoteCurrency commodity not found',
|
|
1597
|
+
409: 'Price already exists for this currency pair and date'
|
|
1534
1598
|
}
|
|
1535
1599
|
});
|
|
1536
1600
|
}
|
|
1537
1601
|
|
|
1538
1602
|
/**
|
|
1539
|
-
* List
|
|
1540
|
-
* Returns all
|
|
1603
|
+
* List user prices
|
|
1604
|
+
* Returns all price entries for the authenticated user with optional filtering
|
|
1541
1605
|
* @param data The data for the request.
|
|
1542
1606
|
* @param data.region Region code for tenant context
|
|
1543
|
-
* @param data.
|
|
1544
|
-
* @param data.
|
|
1545
|
-
* @param data.
|
|
1546
|
-
* @
|
|
1607
|
+
* @param data.currency Filter by currency (e.g., BTC, AAPL, USD)
|
|
1608
|
+
* @param data.quoteCurrency Filter by quote currency (pricing currency, e.g., USD, CNY)
|
|
1609
|
+
* @param data.dateFrom Filter prices from this date (ISO 8601 format)
|
|
1610
|
+
* @param data.dateTo Filter prices to this date (ISO 8601 format)
|
|
1611
|
+
* @param data.search Search term for currency or quoteCurrency (case-insensitive partial match)
|
|
1612
|
+
* @param data.page Page number for pagination (default: 1)
|
|
1613
|
+
* @param data.limit Number of items per page (default: 20, max: 100)
|
|
1614
|
+
* @returns PriceListResponseDto Prices retrieved successfully
|
|
1547
1615
|
* @throws ApiError
|
|
1548
1616
|
*/
|
|
1549
|
-
public static
|
|
1550
|
-
data:
|
|
1551
|
-
): CancelablePromise<
|
|
1617
|
+
public static priceControllerFindAll(
|
|
1618
|
+
data: PriceControllerFindAllData
|
|
1619
|
+
): CancelablePromise<PriceControllerFindAllResponse> {
|
|
1552
1620
|
return __request(OpenAPI, {
|
|
1553
1621
|
method: 'GET',
|
|
1554
|
-
url: '/api/v1/{region}/bean/
|
|
1622
|
+
url: '/api/v1/{region}/bean/prices',
|
|
1555
1623
|
path: {
|
|
1556
1624
|
region: data.region
|
|
1557
1625
|
},
|
|
1558
1626
|
query: {
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1627
|
+
currency: data.currency,
|
|
1628
|
+
quoteCurrency: data.quoteCurrency,
|
|
1629
|
+
dateFrom: data.dateFrom,
|
|
1630
|
+
dateTo: data.dateTo,
|
|
1631
|
+
search: data.search,
|
|
1632
|
+
page: data.page,
|
|
1633
|
+
limit: data.limit
|
|
1562
1634
|
}
|
|
1563
1635
|
});
|
|
1564
1636
|
}
|
|
1565
1637
|
|
|
1566
1638
|
/**
|
|
1567
|
-
*
|
|
1568
|
-
*
|
|
1639
|
+
* Get price by ID
|
|
1640
|
+
* Returns a single price entry by its ID
|
|
1569
1641
|
* @param data The data for the request.
|
|
1570
|
-
* @param data.
|
|
1642
|
+
* @param data.id Price ID
|
|
1571
1643
|
* @param data.region Region code for tenant context
|
|
1572
|
-
* @
|
|
1573
|
-
* @returns RecurringRuleResponseDto Rule created successfully
|
|
1644
|
+
* @returns PriceResponseDto Price retrieved successfully
|
|
1574
1645
|
* @throws ApiError
|
|
1575
1646
|
*/
|
|
1576
|
-
public static
|
|
1577
|
-
data:
|
|
1578
|
-
): CancelablePromise<
|
|
1647
|
+
public static priceControllerFindOne(
|
|
1648
|
+
data: PriceControllerFindOneData
|
|
1649
|
+
): CancelablePromise<PriceControllerFindOneResponse> {
|
|
1579
1650
|
return __request(OpenAPI, {
|
|
1580
|
-
method: '
|
|
1581
|
-
url: '/api/v1/{region}/bean/
|
|
1651
|
+
method: 'GET',
|
|
1652
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1582
1653
|
path: {
|
|
1583
|
-
|
|
1654
|
+
id: data.id,
|
|
1584
1655
|
region: data.region
|
|
1585
1656
|
},
|
|
1586
|
-
body: data.requestBody,
|
|
1587
|
-
mediaType: 'application/json',
|
|
1588
1657
|
errors: {
|
|
1589
|
-
404: '
|
|
1590
|
-
409: 'Rule with same name already exists or transaction already linked'
|
|
1658
|
+
404: 'Price not found'
|
|
1591
1659
|
}
|
|
1592
1660
|
});
|
|
1593
1661
|
}
|
|
1594
1662
|
|
|
1595
1663
|
/**
|
|
1596
|
-
*
|
|
1597
|
-
*
|
|
1664
|
+
* Update a price
|
|
1665
|
+
* Updates an existing price entry
|
|
1598
1666
|
* @param data The data for the request.
|
|
1599
|
-
* @param data.id
|
|
1667
|
+
* @param data.id Price ID
|
|
1600
1668
|
* @param data.region Region code for tenant context
|
|
1601
|
-
* @
|
|
1669
|
+
* @param data.requestBody
|
|
1670
|
+
* @returns PriceResponseDto Price updated successfully
|
|
1602
1671
|
* @throws ApiError
|
|
1603
1672
|
*/
|
|
1604
|
-
public static
|
|
1605
|
-
data:
|
|
1606
|
-
): CancelablePromise<
|
|
1673
|
+
public static priceControllerUpdate(
|
|
1674
|
+
data: PriceControllerUpdateData
|
|
1675
|
+
): CancelablePromise<PriceControllerUpdateResponse> {
|
|
1607
1676
|
return __request(OpenAPI, {
|
|
1608
|
-
method: '
|
|
1609
|
-
url: '/api/v1/{region}/bean/
|
|
1677
|
+
method: 'PUT',
|
|
1678
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1610
1679
|
path: {
|
|
1611
1680
|
id: data.id,
|
|
1612
1681
|
region: data.region
|
|
1613
1682
|
},
|
|
1683
|
+
body: data.requestBody,
|
|
1684
|
+
mediaType: 'application/json',
|
|
1614
1685
|
errors: {
|
|
1615
|
-
404: '
|
|
1686
|
+
404: 'Price not found',
|
|
1687
|
+
409: 'Updated price conflicts with existing price'
|
|
1616
1688
|
}
|
|
1617
1689
|
});
|
|
1618
1690
|
}
|
|
1619
1691
|
|
|
1620
1692
|
/**
|
|
1621
|
-
*
|
|
1622
|
-
*
|
|
1693
|
+
* Delete a price
|
|
1694
|
+
* Deletes a price entry (hard delete)
|
|
1623
1695
|
* @param data The data for the request.
|
|
1624
|
-
* @param data.id
|
|
1696
|
+
* @param data.id Price ID
|
|
1625
1697
|
* @param data.region Region code for tenant context
|
|
1626
|
-
* @
|
|
1627
|
-
* @returns RecurringRuleResponseDto Rule updated successfully
|
|
1698
|
+
* @returns void Price deleted successfully
|
|
1628
1699
|
* @throws ApiError
|
|
1629
1700
|
*/
|
|
1630
|
-
public static
|
|
1631
|
-
data:
|
|
1632
|
-
): CancelablePromise<
|
|
1701
|
+
public static priceControllerDelete(
|
|
1702
|
+
data: PriceControllerDeleteData
|
|
1703
|
+
): CancelablePromise<PriceControllerDeleteResponse> {
|
|
1633
1704
|
return __request(OpenAPI, {
|
|
1634
|
-
method: '
|
|
1635
|
-
url: '/api/v1/{region}/bean/
|
|
1705
|
+
method: 'DELETE',
|
|
1706
|
+
url: '/api/v1/{region}/bean/prices/{id}',
|
|
1636
1707
|
path: {
|
|
1637
1708
|
id: data.id,
|
|
1638
1709
|
region: data.region
|
|
1639
1710
|
},
|
|
1640
|
-
body: data.requestBody,
|
|
1641
|
-
mediaType: 'application/json',
|
|
1642
1711
|
errors: {
|
|
1643
|
-
|
|
1644
|
-
404: 'Rule not found'
|
|
1712
|
+
404: 'Price not found'
|
|
1645
1713
|
}
|
|
1646
1714
|
});
|
|
1647
1715
|
}
|
|
1648
1716
|
|
|
1649
1717
|
/**
|
|
1650
|
-
*
|
|
1651
|
-
*
|
|
1718
|
+
* Bulk create prices
|
|
1719
|
+
* Creates multiple price entries at once (skips duplicates)
|
|
1652
1720
|
* @param data The data for the request.
|
|
1653
|
-
* @param data.id Rule ID
|
|
1654
1721
|
* @param data.region Region code for tenant context
|
|
1655
|
-
* @
|
|
1722
|
+
* @param data.requestBody
|
|
1723
|
+
* @returns PriceResponseDto Prices created successfully
|
|
1656
1724
|
* @throws ApiError
|
|
1657
1725
|
*/
|
|
1658
|
-
public static
|
|
1726
|
+
public static priceControllerBulkCreate(
|
|
1727
|
+
data: PriceControllerBulkCreateData
|
|
1728
|
+
): CancelablePromise<PriceControllerBulkCreateResponse> {
|
|
1729
|
+
return __request(OpenAPI, {
|
|
1730
|
+
method: 'POST',
|
|
1731
|
+
url: '/api/v1/{region}/bean/prices/bulk',
|
|
1732
|
+
path: {
|
|
1733
|
+
region: data.region
|
|
1734
|
+
},
|
|
1735
|
+
body: data.requestBody,
|
|
1736
|
+
mediaType: 'application/json'
|
|
1737
|
+
});
|
|
1738
|
+
}
|
|
1739
|
+
}
|
|
1740
|
+
|
|
1741
|
+
export class RecurringRulesService {
|
|
1742
|
+
/**
|
|
1743
|
+
* Create a new recurring rule
|
|
1744
|
+
* Creates a new recurring transaction rule for the authenticated user
|
|
1745
|
+
* @param data The data for the request.
|
|
1746
|
+
* @param data.region Region code for tenant context
|
|
1747
|
+
* @param data.requestBody
|
|
1748
|
+
* @returns RecurringRuleResponseDto Rule created successfully
|
|
1749
|
+
* @throws ApiError
|
|
1750
|
+
*/
|
|
1751
|
+
public static recurringRuleControllerCreate(
|
|
1752
|
+
data: RecurringRuleControllerCreateData
|
|
1753
|
+
): CancelablePromise<RecurringRuleControllerCreateResponse> {
|
|
1754
|
+
return __request(OpenAPI, {
|
|
1755
|
+
method: 'POST',
|
|
1756
|
+
url: '/api/v1/{region}/bean/recurring-rules',
|
|
1757
|
+
path: {
|
|
1758
|
+
region: data.region
|
|
1759
|
+
},
|
|
1760
|
+
body: data.requestBody,
|
|
1761
|
+
mediaType: 'application/json',
|
|
1762
|
+
errors: {
|
|
1763
|
+
400: 'Invalid input data (e.g., autoCreate without accounts)',
|
|
1764
|
+
409: 'Rule with same name already exists'
|
|
1765
|
+
}
|
|
1766
|
+
});
|
|
1767
|
+
}
|
|
1768
|
+
|
|
1769
|
+
/**
|
|
1770
|
+
* List recurring rules
|
|
1771
|
+
* Returns all recurring rules for the authenticated user with optional filtering
|
|
1772
|
+
* @param data The data for the request.
|
|
1773
|
+
* @param data.region Region code for tenant context
|
|
1774
|
+
* @param data.isActive Filter by active status
|
|
1775
|
+
* @param data.frequency Filter by frequency (WEEKLY, MONTHLY, etc.)
|
|
1776
|
+
* @param data.hasAutoCreate Filter by autoCreate enabled
|
|
1777
|
+
* @returns RecurringRuleResponseDto Rules retrieved successfully
|
|
1778
|
+
* @throws ApiError
|
|
1779
|
+
*/
|
|
1780
|
+
public static recurringRuleControllerFindAll(
|
|
1781
|
+
data: RecurringRuleControllerFindAllData
|
|
1782
|
+
): CancelablePromise<RecurringRuleControllerFindAllResponse> {
|
|
1783
|
+
return __request(OpenAPI, {
|
|
1784
|
+
method: 'GET',
|
|
1785
|
+
url: '/api/v1/{region}/bean/recurring-rules',
|
|
1786
|
+
path: {
|
|
1787
|
+
region: data.region
|
|
1788
|
+
},
|
|
1789
|
+
query: {
|
|
1790
|
+
isActive: data.isActive,
|
|
1791
|
+
frequency: data.frequency,
|
|
1792
|
+
hasAutoCreate: data.hasAutoCreate
|
|
1793
|
+
}
|
|
1794
|
+
});
|
|
1795
|
+
}
|
|
1796
|
+
|
|
1797
|
+
/**
|
|
1798
|
+
* Create recurring rule from transaction
|
|
1799
|
+
* Auto-creates a recurring rule using transaction data. User only confirms frequency.
|
|
1800
|
+
* @param data The data for the request.
|
|
1801
|
+
* @param data.transactionId Source transaction ID
|
|
1802
|
+
* @param data.region Region code for tenant context
|
|
1803
|
+
* @param data.requestBody
|
|
1804
|
+
* @returns RecurringRuleResponseDto Rule created successfully
|
|
1805
|
+
* @throws ApiError
|
|
1806
|
+
*/
|
|
1807
|
+
public static recurringRuleControllerCreateFromTransaction(
|
|
1808
|
+
data: RecurringRuleControllerCreateFromTransactionData
|
|
1809
|
+
): CancelablePromise<RecurringRuleControllerCreateFromTransactionResponse> {
|
|
1810
|
+
return __request(OpenAPI, {
|
|
1811
|
+
method: 'POST',
|
|
1812
|
+
url: '/api/v1/{region}/bean/recurring-rules/from-transaction/{transactionId}',
|
|
1813
|
+
path: {
|
|
1814
|
+
transactionId: data.transactionId,
|
|
1815
|
+
region: data.region
|
|
1816
|
+
},
|
|
1817
|
+
body: data.requestBody,
|
|
1818
|
+
mediaType: 'application/json',
|
|
1819
|
+
errors: {
|
|
1820
|
+
404: 'Transaction not found',
|
|
1821
|
+
409: 'Rule with same name already exists or transaction already linked'
|
|
1822
|
+
}
|
|
1823
|
+
});
|
|
1824
|
+
}
|
|
1825
|
+
|
|
1826
|
+
/**
|
|
1827
|
+
* Get recurring rule by ID
|
|
1828
|
+
* Returns a specific recurring rule with its details
|
|
1829
|
+
* @param data The data for the request.
|
|
1830
|
+
* @param data.id Rule ID
|
|
1831
|
+
* @param data.region Region code for tenant context
|
|
1832
|
+
* @returns RecurringRuleResponseDto Rule retrieved successfully
|
|
1833
|
+
* @throws ApiError
|
|
1834
|
+
*/
|
|
1835
|
+
public static recurringRuleControllerFindOne(
|
|
1836
|
+
data: RecurringRuleControllerFindOneData
|
|
1837
|
+
): CancelablePromise<RecurringRuleControllerFindOneResponse> {
|
|
1838
|
+
return __request(OpenAPI, {
|
|
1839
|
+
method: 'GET',
|
|
1840
|
+
url: '/api/v1/{region}/bean/recurring-rules/{id}',
|
|
1841
|
+
path: {
|
|
1842
|
+
id: data.id,
|
|
1843
|
+
region: data.region
|
|
1844
|
+
},
|
|
1845
|
+
errors: {
|
|
1846
|
+
404: 'Rule not found'
|
|
1847
|
+
}
|
|
1848
|
+
});
|
|
1849
|
+
}
|
|
1850
|
+
|
|
1851
|
+
/**
|
|
1852
|
+
* Update recurring rule
|
|
1853
|
+
* Updates an existing recurring rule
|
|
1854
|
+
* @param data The data for the request.
|
|
1855
|
+
* @param data.id Rule ID
|
|
1856
|
+
* @param data.region Region code for tenant context
|
|
1857
|
+
* @param data.requestBody
|
|
1858
|
+
* @returns RecurringRuleResponseDto Rule updated successfully
|
|
1859
|
+
* @throws ApiError
|
|
1860
|
+
*/
|
|
1861
|
+
public static recurringRuleControllerUpdate(
|
|
1862
|
+
data: RecurringRuleControllerUpdateData
|
|
1863
|
+
): CancelablePromise<RecurringRuleControllerUpdateResponse> {
|
|
1864
|
+
return __request(OpenAPI, {
|
|
1865
|
+
method: 'PATCH',
|
|
1866
|
+
url: '/api/v1/{region}/bean/recurring-rules/{id}',
|
|
1867
|
+
path: {
|
|
1868
|
+
id: data.id,
|
|
1869
|
+
region: data.region
|
|
1870
|
+
},
|
|
1871
|
+
body: data.requestBody,
|
|
1872
|
+
mediaType: 'application/json',
|
|
1873
|
+
errors: {
|
|
1874
|
+
400: 'Invalid input data',
|
|
1875
|
+
404: 'Rule not found'
|
|
1876
|
+
}
|
|
1877
|
+
});
|
|
1878
|
+
}
|
|
1879
|
+
|
|
1880
|
+
/**
|
|
1881
|
+
* Delete recurring rule
|
|
1882
|
+
* Soft deletes a recurring rule (sets isActive to false)
|
|
1883
|
+
* @param data The data for the request.
|
|
1884
|
+
* @param data.id Rule ID
|
|
1885
|
+
* @param data.region Region code for tenant context
|
|
1886
|
+
* @returns void Rule deleted successfully
|
|
1887
|
+
* @throws ApiError
|
|
1888
|
+
*/
|
|
1889
|
+
public static recurringRuleControllerDelete(
|
|
1659
1890
|
data: RecurringRuleControllerDeleteData
|
|
1660
1891
|
): CancelablePromise<RecurringRuleControllerDeleteResponse> {
|
|
1661
1892
|
return __request(OpenAPI, {
|
|
@@ -1937,279 +2168,158 @@ export class RecurringForecastService {
|
|
|
1937
2168
|
}
|
|
1938
2169
|
}
|
|
1939
2170
|
|
|
1940
|
-
export class
|
|
2171
|
+
export class ReportingService {
|
|
1941
2172
|
/**
|
|
1942
|
-
*
|
|
1943
|
-
*
|
|
2173
|
+
* Get portfolio value trends
|
|
2174
|
+
*
|
|
2175
|
+
* Returns time series data of portfolio net worth.
|
|
2176
|
+
*
|
|
2177
|
+
* **Multi-currency Support:**
|
|
2178
|
+
* - `series[].byCurrency` - Currency breakdown for each data point
|
|
2179
|
+
* - `byCurrency` - Separate time series grouped by currency
|
|
2180
|
+
* - `warnings` - Exchange rate warnings if conversion failed
|
|
2181
|
+
*
|
|
2182
|
+
* **Parameters:**
|
|
2183
|
+
* - `period`: Time period (1m, 3m, 6m, 1y)
|
|
2184
|
+
* - `granularity`: Data granularity (day, week, month)
|
|
2185
|
+
*
|
|
1944
2186
|
* @param data The data for the request.
|
|
1945
2187
|
* @param data.region Region code for tenant context
|
|
1946
|
-
* @param data.
|
|
1947
|
-
* @
|
|
2188
|
+
* @param data.period Time period
|
|
2189
|
+
* @param data.granularity Data granularity
|
|
2190
|
+
* @returns PortfolioTrendsResponseDto Trends retrieved successfully
|
|
1948
2191
|
* @throws ApiError
|
|
1949
2192
|
*/
|
|
1950
|
-
public static
|
|
1951
|
-
data:
|
|
1952
|
-
): CancelablePromise<
|
|
2193
|
+
public static reportingControllerGetPortfolioTrends(
|
|
2194
|
+
data: ReportingControllerGetPortfolioTrendsData
|
|
2195
|
+
): CancelablePromise<ReportingControllerGetPortfolioTrendsResponse> {
|
|
1953
2196
|
return __request(OpenAPI, {
|
|
1954
|
-
method: '
|
|
1955
|
-
url: '/api/v1/{region}/
|
|
2197
|
+
method: 'GET',
|
|
2198
|
+
url: '/api/v1/{region}/reporting/portfolio/trends',
|
|
1956
2199
|
path: {
|
|
1957
2200
|
region: data.region
|
|
1958
2201
|
},
|
|
1959
|
-
|
|
1960
|
-
|
|
2202
|
+
query: {
|
|
2203
|
+
period: data.period,
|
|
2204
|
+
granularity: data.granularity
|
|
2205
|
+
},
|
|
1961
2206
|
errors: {
|
|
1962
|
-
|
|
1963
|
-
401: 'Unauthorized',
|
|
1964
|
-
409: 'Resource conflict - another process is updating this rule'
|
|
2207
|
+
401: 'User not authenticated'
|
|
1965
2208
|
}
|
|
1966
2209
|
});
|
|
1967
2210
|
}
|
|
1968
2211
|
|
|
1969
2212
|
/**
|
|
1970
|
-
* Get
|
|
2213
|
+
* Get cash-flow trends
|
|
2214
|
+
*
|
|
2215
|
+
* Monthly income / expense / netSavings over a fixed N-month window
|
|
2216
|
+
* (current month + N−1 prior). Missing months are zero-filled (flow metric).
|
|
2217
|
+
*
|
|
2218
|
+
* **Parameters:**
|
|
2219
|
+
* - `period`: 1m | 3m | 6m | 1y (default 6m)
|
|
2220
|
+
* - `granularity`: accepted for API symmetry; v1 returns month buckets
|
|
2221
|
+
*
|
|
1971
2222
|
* @param data The data for the request.
|
|
1972
2223
|
* @param data.region Region code for tenant context
|
|
1973
|
-
* @param data.
|
|
1974
|
-
* @param data.
|
|
1975
|
-
* @
|
|
1976
|
-
* @param data.learningSource Filter by learning source. Omit this parameter or pass empty string to get manually created rules (learningSource is null in database).
|
|
1977
|
-
* @param data.autoApplyEnabled Filter by auto-apply status
|
|
1978
|
-
* @returns TransactionRuleListResponseDto List of rules
|
|
2224
|
+
* @param data.period Time period
|
|
2225
|
+
* @param data.granularity Data granularity (accepted for API symmetry; v1 returns month buckets)
|
|
2226
|
+
* @returns CashFlowTrendsResponseDto Cash-flow trends retrieved successfully
|
|
1979
2227
|
* @throws ApiError
|
|
1980
2228
|
*/
|
|
1981
|
-
public static
|
|
1982
|
-
data:
|
|
1983
|
-
): CancelablePromise<
|
|
2229
|
+
public static reportingControllerGetCashFlowTrends(
|
|
2230
|
+
data: ReportingControllerGetCashFlowTrendsData
|
|
2231
|
+
): CancelablePromise<ReportingControllerGetCashFlowTrendsResponse> {
|
|
1984
2232
|
return __request(OpenAPI, {
|
|
1985
2233
|
method: 'GET',
|
|
1986
|
-
url: '/api/v1/{region}/
|
|
2234
|
+
url: '/api/v1/{region}/reporting/cash-flow/trends',
|
|
1987
2235
|
path: {
|
|
1988
2236
|
region: data.region
|
|
1989
2237
|
},
|
|
1990
2238
|
query: {
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
enabled: data.enabled,
|
|
1994
|
-
learningSource: data.learningSource,
|
|
1995
|
-
autoApplyEnabled: data.autoApplyEnabled
|
|
2239
|
+
period: data.period,
|
|
2240
|
+
granularity: data.granularity
|
|
1996
2241
|
},
|
|
1997
2242
|
errors: {
|
|
1998
|
-
401: '
|
|
2243
|
+
401: 'User not authenticated'
|
|
1999
2244
|
}
|
|
2000
2245
|
});
|
|
2001
2246
|
}
|
|
2002
2247
|
|
|
2003
2248
|
/**
|
|
2004
|
-
*
|
|
2249
|
+
* Generate portfolio snapshot
|
|
2250
|
+
*
|
|
2251
|
+
* Manually generate a portfolio snapshot for a specific date.
|
|
2252
|
+
*
|
|
2253
|
+
* **Multi-currency Support:**
|
|
2254
|
+
* - Fetches balances grouped by currency
|
|
2255
|
+
* - Uses user's baseCurrency setting for conversion
|
|
2256
|
+
* - Stores exchange rates and warnings
|
|
2257
|
+
*
|
|
2258
|
+
* **Use Cases:**
|
|
2259
|
+
* - Testing snapshot generation
|
|
2260
|
+
* - Force regeneration after data correction
|
|
2261
|
+
* - Initial setup for new users
|
|
2262
|
+
*
|
|
2005
2263
|
* @param data The data for the request.
|
|
2006
2264
|
* @param data.region Region code for tenant context
|
|
2007
|
-
* @param data.requestBody
|
|
2008
|
-
* @returns
|
|
2265
|
+
* @param data.requestBody Optional date (defaults to today)
|
|
2266
|
+
* @returns GenerateSnapshotResponse Snapshot generated successfully
|
|
2009
2267
|
* @throws ApiError
|
|
2010
2268
|
*/
|
|
2011
|
-
public static
|
|
2012
|
-
data:
|
|
2013
|
-
): CancelablePromise<
|
|
2269
|
+
public static reportingControllerGenerateSnapshot(
|
|
2270
|
+
data: ReportingControllerGenerateSnapshotData
|
|
2271
|
+
): CancelablePromise<ReportingControllerGenerateSnapshotResponse> {
|
|
2014
2272
|
return __request(OpenAPI, {
|
|
2015
2273
|
method: 'POST',
|
|
2016
|
-
url: '/api/v1/{region}/
|
|
2017
|
-
path: {
|
|
2018
|
-
region: data.region
|
|
2019
|
-
},
|
|
2020
|
-
body: data.requestBody,
|
|
2021
|
-
mediaType: 'application/json',
|
|
2022
|
-
errors: {
|
|
2023
|
-
400: 'Validation failed',
|
|
2024
|
-
401: 'Unauthorized'
|
|
2025
|
-
}
|
|
2026
|
-
});
|
|
2027
|
-
}
|
|
2028
|
-
|
|
2029
|
-
/**
|
|
2030
|
-
* Bulk create transaction rules
|
|
2031
|
-
* @param data The data for the request.
|
|
2032
|
-
* @param data.region Region code for tenant context
|
|
2033
|
-
* @param data.requestBody
|
|
2034
|
-
* @returns BulkCreateRulesResponseDto Bulk create completed
|
|
2035
|
-
* @throws ApiError
|
|
2036
|
-
*/
|
|
2037
|
-
public static transactionRuleControllerBulkCreate(
|
|
2038
|
-
data: TransactionRuleControllerBulkCreateData
|
|
2039
|
-
): CancelablePromise<TransactionRuleControllerBulkCreateResponse> {
|
|
2040
|
-
return __request(OpenAPI, {
|
|
2041
|
-
method: 'POST',
|
|
2042
|
-
url: '/api/v1/{region}/bean/transaction-rules/bulk',
|
|
2043
|
-
path: {
|
|
2044
|
-
region: data.region
|
|
2045
|
-
},
|
|
2046
|
-
body: data.requestBody,
|
|
2047
|
-
mediaType: 'application/json',
|
|
2048
|
-
errors: {
|
|
2049
|
-
400: 'Invalid bulk create data',
|
|
2050
|
-
401: 'Unauthorized'
|
|
2051
|
-
}
|
|
2052
|
-
});
|
|
2053
|
-
}
|
|
2054
|
-
|
|
2055
|
-
/**
|
|
2056
|
-
* Export transaction rules
|
|
2057
|
-
* @param data The data for the request.
|
|
2058
|
-
* @param data.format Export format (currently only JSON supported)
|
|
2059
|
-
* @param data.region Region code for tenant context
|
|
2060
|
-
* @returns ExportRulesResponseDto Exported rules
|
|
2061
|
-
* @throws ApiError
|
|
2062
|
-
*/
|
|
2063
|
-
public static transactionRuleControllerExport(
|
|
2064
|
-
data: TransactionRuleControllerExportData
|
|
2065
|
-
): CancelablePromise<TransactionRuleControllerExportResponse> {
|
|
2066
|
-
return __request(OpenAPI, {
|
|
2067
|
-
method: 'GET',
|
|
2068
|
-
url: '/api/v1/{region}/bean/transaction-rules/export/{format}',
|
|
2069
|
-
path: {
|
|
2070
|
-
format: data.format,
|
|
2071
|
-
region: data.region
|
|
2072
|
-
},
|
|
2073
|
-
errors: {
|
|
2074
|
-
400: 'Unsupported format',
|
|
2075
|
-
401: 'Unauthorized'
|
|
2076
|
-
}
|
|
2077
|
-
});
|
|
2078
|
-
}
|
|
2079
|
-
|
|
2080
|
-
/**
|
|
2081
|
-
* Get transaction rule statistics
|
|
2082
|
-
* @param data The data for the request.
|
|
2083
|
-
* @param data.period Statistics time period
|
|
2084
|
-
* @param data.region Region code for tenant context
|
|
2085
|
-
* @returns RuleStatisticsResponseDto Rule statistics
|
|
2086
|
-
* @throws ApiError
|
|
2087
|
-
*/
|
|
2088
|
-
public static transactionRuleControllerGetStatistics(
|
|
2089
|
-
data: TransactionRuleControllerGetStatisticsData
|
|
2090
|
-
): CancelablePromise<TransactionRuleControllerGetStatisticsResponse> {
|
|
2091
|
-
return __request(OpenAPI, {
|
|
2092
|
-
method: 'GET',
|
|
2093
|
-
url: '/api/v1/{region}/bean/transaction-rules/statistics/{period}',
|
|
2094
|
-
path: {
|
|
2095
|
-
period: data.period,
|
|
2096
|
-
region: data.region
|
|
2097
|
-
},
|
|
2098
|
-
errors: {
|
|
2099
|
-
401: 'Unauthorized'
|
|
2100
|
-
}
|
|
2101
|
-
});
|
|
2102
|
-
}
|
|
2103
|
-
|
|
2104
|
-
/**
|
|
2105
|
-
* Get transaction rule detail
|
|
2106
|
-
* @param data The data for the request.
|
|
2107
|
-
* @param data.ruleId Rule ID
|
|
2108
|
-
* @param data.region Region code for tenant context
|
|
2109
|
-
* @returns TransactionRuleResponseDto Rule details
|
|
2110
|
-
* @throws ApiError
|
|
2111
|
-
*/
|
|
2112
|
-
public static transactionRuleControllerGetDetail(
|
|
2113
|
-
data: TransactionRuleControllerGetDetailData
|
|
2114
|
-
): CancelablePromise<TransactionRuleControllerGetDetailResponse> {
|
|
2115
|
-
return __request(OpenAPI, {
|
|
2116
|
-
method: 'GET',
|
|
2117
|
-
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2118
|
-
path: {
|
|
2119
|
-
ruleId: data.ruleId,
|
|
2120
|
-
region: data.region
|
|
2121
|
-
},
|
|
2122
|
-
errors: {
|
|
2123
|
-
401: 'Unauthorized',
|
|
2124
|
-
403: 'Forbidden - not owner of rule',
|
|
2125
|
-
404: 'Rule not found'
|
|
2126
|
-
}
|
|
2127
|
-
});
|
|
2128
|
-
}
|
|
2129
|
-
|
|
2130
|
-
/**
|
|
2131
|
-
* Update a transaction rule
|
|
2132
|
-
* @param data The data for the request.
|
|
2133
|
-
* @param data.ruleId Rule ID to update
|
|
2134
|
-
* @param data.region Region code for tenant context
|
|
2135
|
-
* @param data.requestBody
|
|
2136
|
-
* @returns TransactionRuleResponseDto Rule updated successfully
|
|
2137
|
-
* @throws ApiError
|
|
2138
|
-
*/
|
|
2139
|
-
public static transactionRuleControllerUpdate(
|
|
2140
|
-
data: TransactionRuleControllerUpdateData
|
|
2141
|
-
): CancelablePromise<TransactionRuleControllerUpdateResponse> {
|
|
2142
|
-
return __request(OpenAPI, {
|
|
2143
|
-
method: 'PUT',
|
|
2144
|
-
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2274
|
+
url: '/api/v1/{region}/reporting/snapshots/generate',
|
|
2145
2275
|
path: {
|
|
2146
|
-
ruleId: data.ruleId,
|
|
2147
2276
|
region: data.region
|
|
2148
2277
|
},
|
|
2149
2278
|
body: data.requestBody,
|
|
2150
2279
|
mediaType: 'application/json',
|
|
2151
2280
|
errors: {
|
|
2152
|
-
400: '
|
|
2153
|
-
401: '
|
|
2154
|
-
403: 'Forbidden - not owner of rule',
|
|
2155
|
-
404: 'Rule not found',
|
|
2156
|
-
409: 'Resource conflict - rule is being modified by another process'
|
|
2157
|
-
}
|
|
2158
|
-
});
|
|
2159
|
-
}
|
|
2160
|
-
|
|
2161
|
-
/**
|
|
2162
|
-
* Delete a transaction rule
|
|
2163
|
-
* @param data The data for the request.
|
|
2164
|
-
* @param data.ruleId Rule ID to delete
|
|
2165
|
-
* @param data.region Region code for tenant context
|
|
2166
|
-
* @returns void Rule deleted successfully
|
|
2167
|
-
* @throws ApiError
|
|
2168
|
-
*/
|
|
2169
|
-
public static transactionRuleControllerDelete(
|
|
2170
|
-
data: TransactionRuleControllerDeleteData
|
|
2171
|
-
): CancelablePromise<TransactionRuleControllerDeleteResponse> {
|
|
2172
|
-
return __request(OpenAPI, {
|
|
2173
|
-
method: 'DELETE',
|
|
2174
|
-
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2175
|
-
path: {
|
|
2176
|
-
ruleId: data.ruleId,
|
|
2177
|
-
region: data.region
|
|
2178
|
-
},
|
|
2179
|
-
errors: {
|
|
2180
|
-
401: 'Unauthorized',
|
|
2181
|
-
403: 'Forbidden - not owner of rule',
|
|
2182
|
-
404: 'Rule not found',
|
|
2183
|
-
409: 'Resource conflict - rule is being modified by another process'
|
|
2281
|
+
400: 'Invalid date format',
|
|
2282
|
+
401: 'User not authenticated'
|
|
2184
2283
|
}
|
|
2185
2284
|
});
|
|
2186
2285
|
}
|
|
2187
2286
|
|
|
2188
2287
|
/**
|
|
2189
|
-
*
|
|
2288
|
+
* Backfill portfolio snapshots
|
|
2289
|
+
*
|
|
2290
|
+
* Generate snapshots for a date range (historical data backfill).
|
|
2291
|
+
*
|
|
2292
|
+
* **Multi-currency Support:**
|
|
2293
|
+
* - Each snapshot includes multi-currency data
|
|
2294
|
+
* - Uses exchange rates available at generation time
|
|
2295
|
+
* - Warnings stored for missing exchange rates
|
|
2296
|
+
*
|
|
2297
|
+
* **Best Practices:**
|
|
2298
|
+
* - Use for initial setup after account configuration
|
|
2299
|
+
* - Run during low-traffic periods for large date ranges
|
|
2300
|
+
* - Existing snapshots are skipped (not regenerated)
|
|
2301
|
+
*
|
|
2190
2302
|
* @param data The data for the request.
|
|
2191
|
-
* @param data.ruleId Rule ID to test
|
|
2192
2303
|
* @param data.region Region code for tenant context
|
|
2193
2304
|
* @param data.requestBody
|
|
2194
|
-
* @returns
|
|
2305
|
+
* @returns BackfillSnapshotsResponse Backfill completed successfully
|
|
2195
2306
|
* @throws ApiError
|
|
2196
2307
|
*/
|
|
2197
|
-
public static
|
|
2198
|
-
data:
|
|
2199
|
-
): CancelablePromise<
|
|
2308
|
+
public static reportingControllerBackfillSnapshots(
|
|
2309
|
+
data: ReportingControllerBackfillSnapshotsData
|
|
2310
|
+
): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
|
|
2200
2311
|
return __request(OpenAPI, {
|
|
2201
2312
|
method: 'POST',
|
|
2202
|
-
url: '/api/v1/{region}/
|
|
2313
|
+
url: '/api/v1/{region}/reporting/snapshots/backfill',
|
|
2203
2314
|
path: {
|
|
2204
|
-
ruleId: data.ruleId,
|
|
2205
2315
|
region: data.region
|
|
2206
2316
|
},
|
|
2207
2317
|
body: data.requestBody,
|
|
2208
2318
|
mediaType: 'application/json',
|
|
2209
2319
|
errors: {
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2320
|
+
400: 'Invalid date format or range',
|
|
2321
|
+
401: 'User not authenticated',
|
|
2322
|
+
409: 'Backfill already in progress for this user'
|
|
2213
2323
|
}
|
|
2214
2324
|
});
|
|
2215
2325
|
}
|
|
@@ -2241,7 +2351,7 @@ export class UsersService {
|
|
|
2241
2351
|
* Get current authenticated user
|
|
2242
2352
|
* @param data The data for the request.
|
|
2243
2353
|
* @param data.acceptLanguage
|
|
2244
|
-
* @returns
|
|
2354
|
+
* @returns UserResponseDto User retrieved successfully
|
|
2245
2355
|
* @throws ApiError
|
|
2246
2356
|
*/
|
|
2247
2357
|
public static userControllerGetUser(
|
|
@@ -2261,7 +2371,7 @@ export class UsersService {
|
|
|
2261
2371
|
* Create a new account with auto-generated access token. Protected by Cloudflare Turnstile to prevent automated signup (when enabled).
|
|
2262
2372
|
* @param data The data for the request.
|
|
2263
2373
|
* @param data.requestBody
|
|
2264
|
-
* @returns
|
|
2374
|
+
* @returns SignupResponseDto User created successfully
|
|
2265
2375
|
* @throws ApiError
|
|
2266
2376
|
*/
|
|
2267
2377
|
public static userControllerSignupUser(
|
|
@@ -2470,67 +2580,373 @@ export class PropertiesService {
|
|
|
2470
2580
|
}
|
|
2471
2581
|
}
|
|
2472
2582
|
|
|
2473
|
-
export class
|
|
2583
|
+
export class BeanTransactionRulesService {
|
|
2474
2584
|
/**
|
|
2475
|
-
* Create a new
|
|
2476
|
-
* Creates a new
|
|
2585
|
+
* Create a new transaction rule (or upsert if upsertByPayee=true)
|
|
2586
|
+
* Creates a new rule. If upsertByPayee=true, updates existing rule matching payeeKeywords[0] instead of creating duplicate.
|
|
2477
2587
|
* @param data The data for the request.
|
|
2478
|
-
* @param data.region Region code for tenant context
|
|
2588
|
+
* @param data.region Region code for tenant context
|
|
2479
2589
|
* @param data.requestBody
|
|
2480
|
-
* @returns
|
|
2590
|
+
* @returns TransactionRuleResponseDto Rule updated successfully (upsert mode)
|
|
2481
2591
|
* @throws ApiError
|
|
2482
2592
|
*/
|
|
2483
|
-
public static
|
|
2484
|
-
data:
|
|
2485
|
-
): CancelablePromise<
|
|
2593
|
+
public static transactionRuleControllerCreate(
|
|
2594
|
+
data: TransactionRuleControllerCreateData
|
|
2595
|
+
): CancelablePromise<TransactionRuleControllerCreateResponse> {
|
|
2486
2596
|
return __request(OpenAPI, {
|
|
2487
2597
|
method: 'POST',
|
|
2488
|
-
url: '/api/v1/{region}/bean/
|
|
2598
|
+
url: '/api/v1/{region}/bean/transaction-rules',
|
|
2489
2599
|
path: {
|
|
2490
2600
|
region: data.region
|
|
2491
2601
|
},
|
|
2492
2602
|
body: data.requestBody,
|
|
2493
2603
|
mediaType: 'application/json',
|
|
2494
2604
|
errors: {
|
|
2495
|
-
|
|
2605
|
+
400: 'Validation failed',
|
|
2606
|
+
401: 'Unauthorized',
|
|
2607
|
+
409: 'Resource conflict - another process is updating this rule'
|
|
2496
2608
|
}
|
|
2497
2609
|
});
|
|
2498
2610
|
}
|
|
2499
2611
|
|
|
2500
2612
|
/**
|
|
2501
|
-
*
|
|
2502
|
-
* Returns life events for the authenticated user with optional filtering by type, description search, and date range.
|
|
2613
|
+
* Get all transaction rules for user
|
|
2503
2614
|
* @param data The data for the request.
|
|
2504
|
-
* @param data.region Region code for tenant context
|
|
2505
|
-
* @param data.
|
|
2506
|
-
* @param data.
|
|
2507
|
-
* @param data.
|
|
2508
|
-
* @param data.
|
|
2509
|
-
* @param data.
|
|
2510
|
-
* @
|
|
2511
|
-
* @returns EventListResponseDto Life events retrieved successfully
|
|
2615
|
+
* @param data.region Region code for tenant context
|
|
2616
|
+
* @param data.limit Max results per page (default: 20, max: 100)
|
|
2617
|
+
* @param data.offset Pagination offset (default: 0)
|
|
2618
|
+
* @param data.enabled Filter by enabled status
|
|
2619
|
+
* @param data.learningSource Filter by learning source. Omit this parameter or pass empty string to get manually created rules (learningSource is null in database).
|
|
2620
|
+
* @param data.autoApplyEnabled Filter by auto-apply status
|
|
2621
|
+
* @returns TransactionRuleListResponseDto List of rules
|
|
2512
2622
|
* @throws ApiError
|
|
2513
2623
|
*/
|
|
2514
|
-
public static
|
|
2515
|
-
data:
|
|
2516
|
-
): CancelablePromise<
|
|
2624
|
+
public static transactionRuleControllerList(
|
|
2625
|
+
data: TransactionRuleControllerListData
|
|
2626
|
+
): CancelablePromise<TransactionRuleControllerListResponse> {
|
|
2517
2627
|
return __request(OpenAPI, {
|
|
2518
2628
|
method: 'GET',
|
|
2519
|
-
url: '/api/v1/{region}/bean/
|
|
2629
|
+
url: '/api/v1/{region}/bean/transaction-rules',
|
|
2520
2630
|
path: {
|
|
2521
2631
|
region: data.region
|
|
2522
2632
|
},
|
|
2523
2633
|
query: {
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2634
|
+
limit: data.limit,
|
|
2635
|
+
offset: data.offset,
|
|
2636
|
+
enabled: data.enabled,
|
|
2637
|
+
learningSource: data.learningSource,
|
|
2638
|
+
autoApplyEnabled: data.autoApplyEnabled
|
|
2639
|
+
},
|
|
2640
|
+
errors: {
|
|
2641
|
+
401: 'Unauthorized'
|
|
2642
|
+
}
|
|
2643
|
+
});
|
|
2644
|
+
}
|
|
2645
|
+
|
|
2646
|
+
/**
|
|
2647
|
+
* Validate transaction rule configuration
|
|
2648
|
+
* @param data The data for the request.
|
|
2649
|
+
* @param data.region Region code for tenant context
|
|
2650
|
+
* @param data.requestBody
|
|
2651
|
+
* @returns ValidateRuleResponseDto Validation result
|
|
2652
|
+
* @throws ApiError
|
|
2653
|
+
*/
|
|
2654
|
+
public static transactionRuleControllerValidate(
|
|
2655
|
+
data: TransactionRuleControllerValidateData
|
|
2656
|
+
): CancelablePromise<TransactionRuleControllerValidateResponse> {
|
|
2657
|
+
return __request(OpenAPI, {
|
|
2658
|
+
method: 'POST',
|
|
2659
|
+
url: '/api/v1/{region}/bean/transaction-rules/validate',
|
|
2660
|
+
path: {
|
|
2661
|
+
region: data.region
|
|
2662
|
+
},
|
|
2663
|
+
body: data.requestBody,
|
|
2664
|
+
mediaType: 'application/json',
|
|
2665
|
+
errors: {
|
|
2666
|
+
400: 'Validation failed',
|
|
2667
|
+
401: 'Unauthorized'
|
|
2668
|
+
}
|
|
2669
|
+
});
|
|
2670
|
+
}
|
|
2671
|
+
|
|
2672
|
+
/**
|
|
2673
|
+
* Bulk create transaction rules
|
|
2674
|
+
* @param data The data for the request.
|
|
2675
|
+
* @param data.region Region code for tenant context
|
|
2676
|
+
* @param data.requestBody
|
|
2677
|
+
* @returns BulkCreateRulesResponseDto Bulk create completed
|
|
2678
|
+
* @throws ApiError
|
|
2679
|
+
*/
|
|
2680
|
+
public static transactionRuleControllerBulkCreate(
|
|
2681
|
+
data: TransactionRuleControllerBulkCreateData
|
|
2682
|
+
): CancelablePromise<TransactionRuleControllerBulkCreateResponse> {
|
|
2683
|
+
return __request(OpenAPI, {
|
|
2684
|
+
method: 'POST',
|
|
2685
|
+
url: '/api/v1/{region}/bean/transaction-rules/bulk',
|
|
2686
|
+
path: {
|
|
2687
|
+
region: data.region
|
|
2688
|
+
},
|
|
2689
|
+
body: data.requestBody,
|
|
2690
|
+
mediaType: 'application/json',
|
|
2691
|
+
errors: {
|
|
2692
|
+
400: 'Invalid bulk create data',
|
|
2693
|
+
401: 'Unauthorized'
|
|
2694
|
+
}
|
|
2695
|
+
});
|
|
2696
|
+
}
|
|
2697
|
+
|
|
2698
|
+
/**
|
|
2699
|
+
* Export transaction rules
|
|
2700
|
+
* @param data The data for the request.
|
|
2701
|
+
* @param data.format Export format (currently only JSON supported)
|
|
2702
|
+
* @param data.region Region code for tenant context
|
|
2703
|
+
* @returns ExportRulesResponseDto Exported rules
|
|
2704
|
+
* @throws ApiError
|
|
2705
|
+
*/
|
|
2706
|
+
public static transactionRuleControllerExport(
|
|
2707
|
+
data: TransactionRuleControllerExportData
|
|
2708
|
+
): CancelablePromise<TransactionRuleControllerExportResponse> {
|
|
2709
|
+
return __request(OpenAPI, {
|
|
2710
|
+
method: 'GET',
|
|
2711
|
+
url: '/api/v1/{region}/bean/transaction-rules/export/{format}',
|
|
2712
|
+
path: {
|
|
2713
|
+
format: data.format,
|
|
2714
|
+
region: data.region
|
|
2715
|
+
},
|
|
2716
|
+
errors: {
|
|
2717
|
+
400: 'Unsupported format',
|
|
2718
|
+
401: 'Unauthorized'
|
|
2719
|
+
}
|
|
2720
|
+
});
|
|
2721
|
+
}
|
|
2722
|
+
|
|
2723
|
+
/**
|
|
2724
|
+
* Get transaction rule statistics
|
|
2725
|
+
* @param data The data for the request.
|
|
2726
|
+
* @param data.period Statistics time period
|
|
2727
|
+
* @param data.region Region code for tenant context
|
|
2728
|
+
* @returns RuleStatisticsResponseDto Rule statistics
|
|
2729
|
+
* @throws ApiError
|
|
2730
|
+
*/
|
|
2731
|
+
public static transactionRuleControllerGetStatistics(
|
|
2732
|
+
data: TransactionRuleControllerGetStatisticsData
|
|
2733
|
+
): CancelablePromise<TransactionRuleControllerGetStatisticsResponse> {
|
|
2734
|
+
return __request(OpenAPI, {
|
|
2735
|
+
method: 'GET',
|
|
2736
|
+
url: '/api/v1/{region}/bean/transaction-rules/statistics/{period}',
|
|
2737
|
+
path: {
|
|
2738
|
+
period: data.period,
|
|
2739
|
+
region: data.region
|
|
2740
|
+
},
|
|
2741
|
+
errors: {
|
|
2742
|
+
401: 'Unauthorized'
|
|
2743
|
+
}
|
|
2744
|
+
});
|
|
2745
|
+
}
|
|
2746
|
+
|
|
2747
|
+
/**
|
|
2748
|
+
* Get transaction rule detail
|
|
2749
|
+
* @param data The data for the request.
|
|
2750
|
+
* @param data.ruleId Rule ID
|
|
2751
|
+
* @param data.region Region code for tenant context
|
|
2752
|
+
* @returns TransactionRuleResponseDto Rule details
|
|
2753
|
+
* @throws ApiError
|
|
2754
|
+
*/
|
|
2755
|
+
public static transactionRuleControllerGetDetail(
|
|
2756
|
+
data: TransactionRuleControllerGetDetailData
|
|
2757
|
+
): CancelablePromise<TransactionRuleControllerGetDetailResponse> {
|
|
2758
|
+
return __request(OpenAPI, {
|
|
2759
|
+
method: 'GET',
|
|
2760
|
+
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2761
|
+
path: {
|
|
2762
|
+
ruleId: data.ruleId,
|
|
2763
|
+
region: data.region
|
|
2764
|
+
},
|
|
2765
|
+
errors: {
|
|
2766
|
+
401: 'Unauthorized',
|
|
2767
|
+
403: 'Forbidden - not owner of rule',
|
|
2768
|
+
404: 'Rule not found'
|
|
2769
|
+
}
|
|
2770
|
+
});
|
|
2771
|
+
}
|
|
2772
|
+
|
|
2773
|
+
/**
|
|
2774
|
+
* Update a transaction rule
|
|
2775
|
+
* @param data The data for the request.
|
|
2776
|
+
* @param data.ruleId Rule ID to update
|
|
2777
|
+
* @param data.region Region code for tenant context
|
|
2778
|
+
* @param data.requestBody
|
|
2779
|
+
* @returns TransactionRuleResponseDto Rule updated successfully
|
|
2780
|
+
* @throws ApiError
|
|
2781
|
+
*/
|
|
2782
|
+
public static transactionRuleControllerUpdate(
|
|
2783
|
+
data: TransactionRuleControllerUpdateData
|
|
2784
|
+
): CancelablePromise<TransactionRuleControllerUpdateResponse> {
|
|
2785
|
+
return __request(OpenAPI, {
|
|
2786
|
+
method: 'PUT',
|
|
2787
|
+
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2788
|
+
path: {
|
|
2789
|
+
ruleId: data.ruleId,
|
|
2790
|
+
region: data.region
|
|
2791
|
+
},
|
|
2792
|
+
body: data.requestBody,
|
|
2793
|
+
mediaType: 'application/json',
|
|
2794
|
+
errors: {
|
|
2795
|
+
400: 'Validation failed',
|
|
2796
|
+
401: 'Unauthorized',
|
|
2797
|
+
403: 'Forbidden - not owner of rule',
|
|
2798
|
+
404: 'Rule not found',
|
|
2799
|
+
409: 'Resource conflict - rule is being modified by another process'
|
|
2800
|
+
}
|
|
2801
|
+
});
|
|
2802
|
+
}
|
|
2803
|
+
|
|
2804
|
+
/**
|
|
2805
|
+
* Delete a transaction rule
|
|
2806
|
+
* @param data The data for the request.
|
|
2807
|
+
* @param data.ruleId Rule ID to delete
|
|
2808
|
+
* @param data.region Region code for tenant context
|
|
2809
|
+
* @returns void Rule deleted successfully
|
|
2810
|
+
* @throws ApiError
|
|
2811
|
+
*/
|
|
2812
|
+
public static transactionRuleControllerDelete(
|
|
2813
|
+
data: TransactionRuleControllerDeleteData
|
|
2814
|
+
): CancelablePromise<TransactionRuleControllerDeleteResponse> {
|
|
2815
|
+
return __request(OpenAPI, {
|
|
2816
|
+
method: 'DELETE',
|
|
2817
|
+
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
|
|
2818
|
+
path: {
|
|
2819
|
+
ruleId: data.ruleId,
|
|
2820
|
+
region: data.region
|
|
2821
|
+
},
|
|
2822
|
+
errors: {
|
|
2823
|
+
401: 'Unauthorized',
|
|
2824
|
+
403: 'Forbidden - not owner of rule',
|
|
2825
|
+
404: 'Rule not found',
|
|
2826
|
+
409: 'Resource conflict - rule is being modified by another process'
|
|
2827
|
+
}
|
|
2828
|
+
});
|
|
2829
|
+
}
|
|
2830
|
+
|
|
2831
|
+
/**
|
|
2832
|
+
* Test rule matching
|
|
2833
|
+
* @param data The data for the request.
|
|
2834
|
+
* @param data.ruleId Rule ID to test
|
|
2835
|
+
* @param data.region Region code for tenant context
|
|
2836
|
+
* @param data.requestBody
|
|
2837
|
+
* @returns TestRuleResponseDto Test result
|
|
2838
|
+
* @throws ApiError
|
|
2839
|
+
*/
|
|
2840
|
+
public static transactionRuleControllerTest(
|
|
2841
|
+
data: TransactionRuleControllerTestData
|
|
2842
|
+
): CancelablePromise<TransactionRuleControllerTestResponse> {
|
|
2843
|
+
return __request(OpenAPI, {
|
|
2844
|
+
method: 'POST',
|
|
2845
|
+
url: '/api/v1/{region}/bean/transaction-rules/{ruleId}/test',
|
|
2846
|
+
path: {
|
|
2847
|
+
ruleId: data.ruleId,
|
|
2848
|
+
region: data.region
|
|
2849
|
+
},
|
|
2850
|
+
body: data.requestBody,
|
|
2851
|
+
mediaType: 'application/json',
|
|
2852
|
+
errors: {
|
|
2853
|
+
401: 'Unauthorized',
|
|
2854
|
+
403: 'Forbidden - not owner of rule',
|
|
2855
|
+
404: 'Rule not found'
|
|
2856
|
+
}
|
|
2857
|
+
});
|
|
2858
|
+
}
|
|
2859
|
+
}
|
|
2860
|
+
|
|
2861
|
+
export class BeanCategoryCatalogService {
|
|
2862
|
+
/**
|
|
2863
|
+
* List category catalog for a region
|
|
2864
|
+
* Returns the region-scoped category slugs (expense/income/investment/banking/transfer/payment) for the NLP result picker. CN-exclusive payment instruments (huabei/baitiao) appear only under /cn.
|
|
2865
|
+
* @param data The data for the request.
|
|
2866
|
+
* @param data.region Region code for tenant context
|
|
2867
|
+
* @param data.scenario Filter by scenario
|
|
2868
|
+
* @param data.routeBearing Filter by routeBearing (entity-router route() consumes it)
|
|
2869
|
+
* @returns CategoryCatalogListResponseDto Category catalog retrieved successfully
|
|
2870
|
+
* @throws ApiError
|
|
2871
|
+
*/
|
|
2872
|
+
public static categoryCatalogControllerList(
|
|
2873
|
+
data: CategoryCatalogControllerListData
|
|
2874
|
+
): CancelablePromise<CategoryCatalogControllerListResponse> {
|
|
2875
|
+
return __request(OpenAPI, {
|
|
2876
|
+
method: 'GET',
|
|
2877
|
+
url: '/api/v1/{region}/bean/categories',
|
|
2878
|
+
path: {
|
|
2879
|
+
region: data.region
|
|
2880
|
+
},
|
|
2881
|
+
query: {
|
|
2882
|
+
scenario: data.scenario,
|
|
2883
|
+
routeBearing: data.routeBearing
|
|
2884
|
+
}
|
|
2885
|
+
});
|
|
2886
|
+
}
|
|
2887
|
+
}
|
|
2888
|
+
|
|
2889
|
+
export class LifeEventsService {
|
|
2890
|
+
/**
|
|
2891
|
+
* Create a new life event
|
|
2892
|
+
* Creates a new life event entry for the authenticated user. Returns ETag header carrying the row updatedAt.
|
|
2893
|
+
* @param data The data for the request.
|
|
2894
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2895
|
+
* @param data.requestBody
|
|
2896
|
+
* @returns EventResponseDto Life event created successfully
|
|
2897
|
+
* @throws ApiError
|
|
2898
|
+
*/
|
|
2899
|
+
public static eventControllerCreate(
|
|
2900
|
+
data: EventControllerCreateData
|
|
2901
|
+
): CancelablePromise<EventControllerCreateResponse> {
|
|
2902
|
+
return __request(OpenAPI, {
|
|
2903
|
+
method: 'POST',
|
|
2904
|
+
url: '/api/v1/{region}/bean/events',
|
|
2905
|
+
path: {
|
|
2906
|
+
region: data.region
|
|
2907
|
+
},
|
|
2908
|
+
body: data.requestBody,
|
|
2909
|
+
mediaType: 'application/json',
|
|
2910
|
+
errors: {
|
|
2911
|
+
409: 'Life event already exists for this (userId, type, date) combination'
|
|
2912
|
+
}
|
|
2913
|
+
});
|
|
2914
|
+
}
|
|
2915
|
+
|
|
2916
|
+
/**
|
|
2917
|
+
* List user life events
|
|
2918
|
+
* Returns life events for the authenticated user with optional filtering by type, description search, and date range.
|
|
2919
|
+
* @param data The data for the request.
|
|
2920
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
2921
|
+
* @param data.type Filter by life event type (exact match)
|
|
2922
|
+
* @param data.q Search term for description (case-insensitive partial match)
|
|
2923
|
+
* @param data.from Filter life events from this date (ISO 8601 format)
|
|
2924
|
+
* @param data.to Filter life events to this date (ISO 8601 format)
|
|
2925
|
+
* @param data.page Page number for pagination (default: 1)
|
|
2926
|
+
* @param data.limit Number of items per page (default: 20, max: 100)
|
|
2927
|
+
* @returns EventListResponseDto Life events retrieved successfully
|
|
2928
|
+
* @throws ApiError
|
|
2929
|
+
*/
|
|
2930
|
+
public static eventControllerFindAll(
|
|
2931
|
+
data: EventControllerFindAllData
|
|
2932
|
+
): CancelablePromise<EventControllerFindAllResponse> {
|
|
2933
|
+
return __request(OpenAPI, {
|
|
2934
|
+
method: 'GET',
|
|
2935
|
+
url: '/api/v1/{region}/bean/events',
|
|
2936
|
+
path: {
|
|
2937
|
+
region: data.region
|
|
2938
|
+
},
|
|
2939
|
+
query: {
|
|
2940
|
+
type: data.type,
|
|
2941
|
+
q: data.q,
|
|
2942
|
+
from: data.from,
|
|
2943
|
+
to: data.to,
|
|
2944
|
+
page: data.page,
|
|
2945
|
+
limit: data.limit
|
|
2946
|
+
}
|
|
2947
|
+
});
|
|
2948
|
+
}
|
|
2949
|
+
|
|
2534
2950
|
/**
|
|
2535
2951
|
* Get life event by ID
|
|
2536
2952
|
* Returns a single life event by its ID. Returns ETag header.
|
|
@@ -2611,6 +3027,171 @@ export class LifeEventsService {
|
|
|
2611
3027
|
}
|
|
2612
3028
|
});
|
|
2613
3029
|
}
|
|
3030
|
+
|
|
3031
|
+
/**
|
|
3032
|
+
* Slice time-series by a life event (Phase 79)
|
|
3033
|
+
* Returns aggregated time-series for postings matching accountPattern within the half-open date range of the given life event.
|
|
3034
|
+
* @param data The data for the request.
|
|
3035
|
+
* @param data.id Life event ID
|
|
3036
|
+
* @param data.accountPattern
|
|
3037
|
+
* @param data.granularity
|
|
3038
|
+
* @param data.region Region code for tenant context (decorative for life events)
|
|
3039
|
+
* @returns unknown Time-series sliced by the life event range
|
|
3040
|
+
* @throws ApiError
|
|
3041
|
+
*/
|
|
3042
|
+
public static eventControllerGetSlice(
|
|
3043
|
+
data: EventControllerGetSliceData
|
|
3044
|
+
): CancelablePromise<EventControllerGetSliceResponse> {
|
|
3045
|
+
return __request(OpenAPI, {
|
|
3046
|
+
method: 'GET',
|
|
3047
|
+
url: '/api/v1/{region}/bean/events/{id}/slice',
|
|
3048
|
+
path: {
|
|
3049
|
+
id: data.id,
|
|
3050
|
+
region: data.region
|
|
3051
|
+
},
|
|
3052
|
+
query: {
|
|
3053
|
+
accountPattern: data.accountPattern,
|
|
3054
|
+
granularity: data.granularity
|
|
3055
|
+
},
|
|
3056
|
+
errors: {
|
|
3057
|
+
400: 'accountPattern query param is empty',
|
|
3058
|
+
404: 'Life event not found'
|
|
3059
|
+
}
|
|
3060
|
+
});
|
|
3061
|
+
}
|
|
3062
|
+
}
|
|
3063
|
+
|
|
3064
|
+
export class OnboardingService {
|
|
3065
|
+
/**
|
|
3066
|
+
* Bootstrap core accounts + register asset accounts with opening balances (ADR-0113)
|
|
3067
|
+
* @param data The data for the request.
|
|
3068
|
+
* @param data.region Region code for tenant context
|
|
3069
|
+
* @param data.requestBody
|
|
3070
|
+
* @returns unknown Onboarding bootstrap result.
|
|
3071
|
+
* @throws ApiError
|
|
3072
|
+
*/
|
|
3073
|
+
public static onboardingControllerBootstrap(
|
|
3074
|
+
data: OnboardingControllerBootstrapData
|
|
3075
|
+
): CancelablePromise<OnboardingControllerBootstrapResponse> {
|
|
3076
|
+
return __request(OpenAPI, {
|
|
3077
|
+
method: 'POST',
|
|
3078
|
+
url: '/api/v1/{region}/bean/onboarding',
|
|
3079
|
+
path: {
|
|
3080
|
+
region: data.region
|
|
3081
|
+
},
|
|
3082
|
+
body: data.requestBody,
|
|
3083
|
+
mediaType: 'application/json',
|
|
3084
|
+
errors: {
|
|
3085
|
+
422: 'Invalid region/account path/duplicate paths.'
|
|
3086
|
+
}
|
|
3087
|
+
});
|
|
3088
|
+
}
|
|
3089
|
+
}
|
|
3090
|
+
|
|
3091
|
+
export class BalanceReconciliationService {
|
|
3092
|
+
/**
|
|
3093
|
+
* Preview reconciliation (book vs actual)
|
|
3094
|
+
* Computes book balance, diff, Beancount-inferred tolerance, and suggested action without persisting.
|
|
3095
|
+
* @param data The data for the request.
|
|
3096
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3097
|
+
* @param data.requestBody
|
|
3098
|
+
* @returns ReconciliationComputeResultDto Reconciliation preview
|
|
3099
|
+
* @throws ApiError
|
|
3100
|
+
*/
|
|
3101
|
+
public static reconciliationControllerCompute(
|
|
3102
|
+
data: ReconciliationControllerComputeData
|
|
3103
|
+
): CancelablePromise<ReconciliationControllerComputeResponse> {
|
|
3104
|
+
return __request(OpenAPI, {
|
|
3105
|
+
method: 'POST',
|
|
3106
|
+
url: '/api/v1/{region}/bean/reconciliations',
|
|
3107
|
+
path: {
|
|
3108
|
+
region: data.region
|
|
3109
|
+
},
|
|
3110
|
+
body: data.requestBody,
|
|
3111
|
+
mediaType: 'application/json',
|
|
3112
|
+
errors: {
|
|
3113
|
+
404: 'Account not found'
|
|
3114
|
+
}
|
|
3115
|
+
});
|
|
3116
|
+
}
|
|
3117
|
+
|
|
3118
|
+
/**
|
|
3119
|
+
* Record a balance assertion
|
|
3120
|
+
* Persists the reconciliation as a BeanBalance assertion (amount = actual, diffAmount = book − actual). Re-reconciling the same day/currency upserts.
|
|
3121
|
+
* @param data The data for the request.
|
|
3122
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3123
|
+
* @param data.requestBody
|
|
3124
|
+
* @returns ReconciliationRecordDto Balance assertion recorded
|
|
3125
|
+
* @throws ApiError
|
|
3126
|
+
*/
|
|
3127
|
+
public static reconciliationControllerAssert(
|
|
3128
|
+
data: ReconciliationControllerAssertData
|
|
3129
|
+
): CancelablePromise<ReconciliationControllerAssertResponse> {
|
|
3130
|
+
return __request(OpenAPI, {
|
|
3131
|
+
method: 'POST',
|
|
3132
|
+
url: '/api/v1/{region}/bean/reconciliations/assert',
|
|
3133
|
+
path: {
|
|
3134
|
+
region: data.region
|
|
3135
|
+
},
|
|
3136
|
+
body: data.requestBody,
|
|
3137
|
+
mediaType: 'application/json',
|
|
3138
|
+
errors: {
|
|
3139
|
+
404: 'Account not found'
|
|
3140
|
+
}
|
|
3141
|
+
});
|
|
3142
|
+
}
|
|
3143
|
+
|
|
3144
|
+
/**
|
|
3145
|
+
* Generate a pad adjusting entry
|
|
3146
|
+
* 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.
|
|
3147
|
+
* @param data The data for the request.
|
|
3148
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3149
|
+
* @param data.requestBody
|
|
3150
|
+
* @returns PadResultDto Pad adjusting entry generated
|
|
3151
|
+
* @throws ApiError
|
|
3152
|
+
*/
|
|
3153
|
+
public static reconciliationControllerPad(
|
|
3154
|
+
data: ReconciliationControllerPadData
|
|
3155
|
+
): CancelablePromise<ReconciliationControllerPadResponse> {
|
|
3156
|
+
return __request(OpenAPI, {
|
|
3157
|
+
method: 'POST',
|
|
3158
|
+
url: '/api/v1/{region}/bean/reconciliations/pad',
|
|
3159
|
+
path: {
|
|
3160
|
+
region: data.region
|
|
3161
|
+
},
|
|
3162
|
+
body: data.requestBody,
|
|
3163
|
+
mediaType: 'application/json',
|
|
3164
|
+
errors: {
|
|
3165
|
+
400: 'Book already within tolerance — no pad needed',
|
|
3166
|
+
404: 'Account not found'
|
|
3167
|
+
}
|
|
3168
|
+
});
|
|
3169
|
+
}
|
|
3170
|
+
|
|
3171
|
+
/**
|
|
3172
|
+
* List reconciliation history for an account
|
|
3173
|
+
* Returns recorded balance assertions (most recent first). The latest drives the account-detail "Last <date>" badge.
|
|
3174
|
+
* @param data The data for the request.
|
|
3175
|
+
* @param data.accountId BeanAccount id
|
|
3176
|
+
* @param data.region Region code for tenant context (decorative for reconciliation)
|
|
3177
|
+
* @returns ReconciliationRecordDto Reconciliation history
|
|
3178
|
+
* @throws ApiError
|
|
3179
|
+
*/
|
|
3180
|
+
public static reconciliationControllerHistory(
|
|
3181
|
+
data: ReconciliationControllerHistoryData
|
|
3182
|
+
): CancelablePromise<ReconciliationControllerHistoryResponse> {
|
|
3183
|
+
return __request(OpenAPI, {
|
|
3184
|
+
method: 'GET',
|
|
3185
|
+
url: '/api/v1/{region}/bean/accounts/{accountId}/reconciliations',
|
|
3186
|
+
path: {
|
|
3187
|
+
accountId: data.accountId,
|
|
3188
|
+
region: data.region
|
|
3189
|
+
},
|
|
3190
|
+
errors: {
|
|
3191
|
+
404: 'Account not found'
|
|
3192
|
+
}
|
|
3193
|
+
});
|
|
3194
|
+
}
|
|
2614
3195
|
}
|
|
2615
3196
|
|
|
2616
3197
|
export class BeanExportService {
|
|
@@ -2751,156 +3332,41 @@ export class BeanImportService {
|
|
|
2751
3332
|
): CancelablePromise<ImporterConfigControllerUpdateConfigResponse> {
|
|
2752
3333
|
return __request(OpenAPI, {
|
|
2753
3334
|
method: 'PUT',
|
|
2754
|
-
url: '/api/v1/{region}/bean/import/config/{importerId}',
|
|
2755
|
-
path: {
|
|
2756
|
-
importerId: data.importerId,
|
|
2757
|
-
region: data.region
|
|
2758
|
-
},
|
|
2759
|
-
body: data.requestBody,
|
|
2760
|
-
mediaType: 'application/json',
|
|
2761
|
-
errors: {
|
|
2762
|
-
400: 'Invalid input - Validation failed',
|
|
2763
|
-
404: 'Configuration not found'
|
|
2764
|
-
}
|
|
2765
|
-
});
|
|
2766
|
-
}
|
|
2767
|
-
|
|
2768
|
-
/**
|
|
2769
|
-
* Reset configuration to default
|
|
2770
|
-
* Resets the configuration for the specified importer to default values. This operation overwrites all existing configuration.
|
|
2771
|
-
* @param data The data for the request.
|
|
2772
|
-
* @param data.importerId Importer identifier. Supported importers: alipay, alipay-web, wechat, boc, boc-credit, ccb, cmb, cmbc, cmbc-credit, icbc, icbc-credit, hsbc-hk-credit, hsbc-hk-debit
|
|
2773
|
-
* @param data.region Region code for tenant context
|
|
2774
|
-
* @returns ImporterConfigDto Configuration reset successfully
|
|
2775
|
-
* @throws ApiError
|
|
2776
|
-
*/
|
|
2777
|
-
public static importerConfigControllerResetConfig(
|
|
2778
|
-
data: ImporterConfigControllerResetConfigData
|
|
2779
|
-
): CancelablePromise<ImporterConfigControllerResetConfigResponse> {
|
|
2780
|
-
return __request(OpenAPI, {
|
|
2781
|
-
method: 'POST',
|
|
2782
|
-
url: '/api/v1/{region}/bean/import/config/{importerId}/reset',
|
|
2783
|
-
path: {
|
|
2784
|
-
importerId: data.importerId,
|
|
2785
|
-
region: data.region
|
|
2786
|
-
},
|
|
2787
|
-
errors: {
|
|
2788
|
-
400: 'Invalid input - Unsupported importer'
|
|
2789
|
-
}
|
|
2790
|
-
});
|
|
2791
|
-
}
|
|
2792
|
-
}
|
|
2793
|
-
|
|
2794
|
-
export class BeanPlatformsService {
|
|
2795
|
-
/**
|
|
2796
|
-
* Get all platforms with statistics
|
|
2797
|
-
* @returns unknown List of platforms with binding and account counts
|
|
2798
|
-
* @throws ApiError
|
|
2799
|
-
*/
|
|
2800
|
-
public static platformControllerFindAll(): CancelablePromise<PlatformControllerFindAllResponse> {
|
|
2801
|
-
return __request(OpenAPI, {
|
|
2802
|
-
method: 'GET',
|
|
2803
|
-
url: '/api/v1/bean/platforms'
|
|
2804
|
-
});
|
|
2805
|
-
}
|
|
2806
|
-
|
|
2807
|
-
/**
|
|
2808
|
-
* Create a new platform
|
|
2809
|
-
* @param data The data for the request.
|
|
2810
|
-
* @param data.requestBody
|
|
2811
|
-
* @returns unknown Platform created successfully
|
|
2812
|
-
* @throws ApiError
|
|
2813
|
-
*/
|
|
2814
|
-
public static platformControllerCreate(
|
|
2815
|
-
data: PlatformControllerCreateData
|
|
2816
|
-
): CancelablePromise<PlatformControllerCreateResponse> {
|
|
2817
|
-
return __request(OpenAPI, {
|
|
2818
|
-
method: 'POST',
|
|
2819
|
-
url: '/api/v1/bean/platforms',
|
|
2820
|
-
body: data.requestBody,
|
|
2821
|
-
mediaType: 'application/json',
|
|
2822
|
-
errors: {
|
|
2823
|
-
409: 'Platform already exists'
|
|
2824
|
-
}
|
|
2825
|
-
});
|
|
2826
|
-
}
|
|
2827
|
-
|
|
2828
|
-
/**
|
|
2829
|
-
* Get platform list for current user
|
|
2830
|
-
* @returns unknown List of platforms with user binding status
|
|
2831
|
-
* @throws ApiError
|
|
2832
|
-
*/
|
|
2833
|
-
public static platformControllerGetPlatformList(): CancelablePromise<PlatformControllerGetPlatformListResponse> {
|
|
2834
|
-
return __request(OpenAPI, {
|
|
2835
|
-
method: 'GET',
|
|
2836
|
-
url: '/api/v1/bean/platforms/list'
|
|
2837
|
-
});
|
|
2838
|
-
}
|
|
2839
|
-
|
|
2840
|
-
/**
|
|
2841
|
-
* Match platforms by name or alias
|
|
2842
|
-
* @param data The data for the request.
|
|
2843
|
-
* @param data.q Search query — Chinese name, English name, or abbreviation
|
|
2844
|
-
* @param data.region Region code for category override lookup
|
|
2845
|
-
* @returns unknown List of matching platforms with suggested segment names
|
|
2846
|
-
* @throws ApiError
|
|
2847
|
-
*/
|
|
2848
|
-
public static platformControllerMatchPlatforms(
|
|
2849
|
-
data: PlatformControllerMatchPlatformsData
|
|
2850
|
-
): CancelablePromise<PlatformControllerMatchPlatformsResponse> {
|
|
2851
|
-
return __request(OpenAPI, {
|
|
2852
|
-
method: 'GET',
|
|
2853
|
-
url: '/api/v1/bean/platforms/match',
|
|
2854
|
-
query: {
|
|
2855
|
-
q: data.q,
|
|
2856
|
-
region: data.region
|
|
2857
|
-
}
|
|
2858
|
-
});
|
|
2859
|
-
}
|
|
2860
|
-
|
|
2861
|
-
/**
|
|
2862
|
-
* Update a platform
|
|
2863
|
-
* @param data The data for the request.
|
|
2864
|
-
* @param data.id Platform ID
|
|
2865
|
-
* @param data.requestBody
|
|
2866
|
-
* @returns unknown Platform updated successfully
|
|
2867
|
-
* @throws ApiError
|
|
2868
|
-
*/
|
|
2869
|
-
public static platformControllerUpdate(
|
|
2870
|
-
data: PlatformControllerUpdateData
|
|
2871
|
-
): CancelablePromise<PlatformControllerUpdateResponse> {
|
|
2872
|
-
return __request(OpenAPI, {
|
|
2873
|
-
method: 'PUT',
|
|
2874
|
-
url: '/api/v1/bean/platforms/{id}',
|
|
3335
|
+
url: '/api/v1/{region}/bean/import/config/{importerId}',
|
|
2875
3336
|
path: {
|
|
2876
|
-
|
|
3337
|
+
importerId: data.importerId,
|
|
3338
|
+
region: data.region
|
|
2877
3339
|
},
|
|
2878
3340
|
body: data.requestBody,
|
|
2879
3341
|
mediaType: 'application/json',
|
|
2880
3342
|
errors: {
|
|
2881
|
-
|
|
3343
|
+
400: 'Invalid input - Validation failed',
|
|
3344
|
+
404: 'Configuration not found'
|
|
2882
3345
|
}
|
|
2883
3346
|
});
|
|
2884
3347
|
}
|
|
2885
3348
|
|
|
2886
3349
|
/**
|
|
2887
|
-
*
|
|
3350
|
+
* Reset configuration to default
|
|
3351
|
+
* Resets the configuration for the specified importer to default values. This operation overwrites all existing configuration.
|
|
2888
3352
|
* @param data The data for the request.
|
|
2889
|
-
* @param data.
|
|
2890
|
-
* @
|
|
3353
|
+
* @param data.importerId Importer identifier. Supported importers: alipay, alipay-web, wechat, boc, boc-credit, ccb, cmb, cmbc, cmbc-credit, icbc, icbc-credit, hsbc-hk-credit, hsbc-hk-debit
|
|
3354
|
+
* @param data.region Region code for tenant context
|
|
3355
|
+
* @returns ImporterConfigDto Configuration reset successfully
|
|
2891
3356
|
* @throws ApiError
|
|
2892
3357
|
*/
|
|
2893
|
-
public static
|
|
2894
|
-
data:
|
|
2895
|
-
): CancelablePromise<
|
|
3358
|
+
public static importerConfigControllerResetConfig(
|
|
3359
|
+
data: ImporterConfigControllerResetConfigData
|
|
3360
|
+
): CancelablePromise<ImporterConfigControllerResetConfigResponse> {
|
|
2896
3361
|
return __request(OpenAPI, {
|
|
2897
|
-
method: '
|
|
2898
|
-
url: '/api/v1/bean/
|
|
3362
|
+
method: 'POST',
|
|
3363
|
+
url: '/api/v1/{region}/bean/import/config/{importerId}/reset',
|
|
2899
3364
|
path: {
|
|
2900
|
-
|
|
3365
|
+
importerId: data.importerId,
|
|
3366
|
+
region: data.region
|
|
2901
3367
|
},
|
|
2902
3368
|
errors: {
|
|
2903
|
-
|
|
3369
|
+
400: 'Invalid input - Unsupported importer'
|
|
2904
3370
|
}
|
|
2905
3371
|
});
|
|
2906
3372
|
}
|
|
@@ -3006,6 +3472,101 @@ export class ProviderSyncService {
|
|
|
3006
3472
|
}
|
|
3007
3473
|
}
|
|
3008
3474
|
|
|
3475
|
+
export class ExternalAccountLinksService {
|
|
3476
|
+
/**
|
|
3477
|
+
* Create an external account → BeanAccount mapping (ADR-0113)
|
|
3478
|
+
* @param data The data for the request.
|
|
3479
|
+
* @param data.region Region code for tenant context
|
|
3480
|
+
* @param data.requestBody
|
|
3481
|
+
* @returns ExternalAccountLinkResponseDto Link created.
|
|
3482
|
+
* @throws ApiError
|
|
3483
|
+
*/
|
|
3484
|
+
public static externalAccountLinkControllerCreate(
|
|
3485
|
+
data: ExternalAccountLinkControllerCreateData
|
|
3486
|
+
): CancelablePromise<ExternalAccountLinkControllerCreateResponse> {
|
|
3487
|
+
return __request(OpenAPI, {
|
|
3488
|
+
method: 'POST',
|
|
3489
|
+
url: '/api/v1/{region}/bean/external-account-links',
|
|
3490
|
+
path: {
|
|
3491
|
+
region: data.region
|
|
3492
|
+
},
|
|
3493
|
+
body: data.requestBody,
|
|
3494
|
+
mediaType: 'application/json',
|
|
3495
|
+
errors: {
|
|
3496
|
+
422: 'beanAccountId not owned, or an active link already exists.'
|
|
3497
|
+
}
|
|
3498
|
+
});
|
|
3499
|
+
}
|
|
3500
|
+
|
|
3501
|
+
/**
|
|
3502
|
+
* List the user's active external account links
|
|
3503
|
+
* @param data The data for the request.
|
|
3504
|
+
* @param data.provider
|
|
3505
|
+
* @param data.region Region code for tenant context
|
|
3506
|
+
* @returns ExternalAccountLinkListResponseDto Links retrieved.
|
|
3507
|
+
* @throws ApiError
|
|
3508
|
+
*/
|
|
3509
|
+
public static externalAccountLinkControllerFindAll(
|
|
3510
|
+
data: ExternalAccountLinkControllerFindAllData
|
|
3511
|
+
): CancelablePromise<ExternalAccountLinkControllerFindAllResponse> {
|
|
3512
|
+
return __request(OpenAPI, {
|
|
3513
|
+
method: 'GET',
|
|
3514
|
+
url: '/api/v1/{region}/bean/external-account-links',
|
|
3515
|
+
path: {
|
|
3516
|
+
region: data.region
|
|
3517
|
+
},
|
|
3518
|
+
query: {
|
|
3519
|
+
provider: data.provider
|
|
3520
|
+
}
|
|
3521
|
+
});
|
|
3522
|
+
}
|
|
3523
|
+
|
|
3524
|
+
/**
|
|
3525
|
+
* Get a single external account link
|
|
3526
|
+
* @param data The data for the request.
|
|
3527
|
+
* @param data.id
|
|
3528
|
+
* @param data.region Region code for tenant context
|
|
3529
|
+
* @returns ExternalAccountLinkResponseDto Link retrieved.
|
|
3530
|
+
* @throws ApiError
|
|
3531
|
+
*/
|
|
3532
|
+
public static externalAccountLinkControllerFindOne(
|
|
3533
|
+
data: ExternalAccountLinkControllerFindOneData
|
|
3534
|
+
): CancelablePromise<ExternalAccountLinkControllerFindOneResponse> {
|
|
3535
|
+
return __request(OpenAPI, {
|
|
3536
|
+
method: 'GET',
|
|
3537
|
+
url: '/api/v1/{region}/bean/external-account-links/{id}',
|
|
3538
|
+
path: {
|
|
3539
|
+
id: data.id,
|
|
3540
|
+
region: data.region
|
|
3541
|
+
},
|
|
3542
|
+
errors: {
|
|
3543
|
+
422: 'Link not found or not owned by the user.'
|
|
3544
|
+
}
|
|
3545
|
+
});
|
|
3546
|
+
}
|
|
3547
|
+
|
|
3548
|
+
/**
|
|
3549
|
+
* Soft-delete (disconnect) an external account link
|
|
3550
|
+
* @param data The data for the request.
|
|
3551
|
+
* @param data.id
|
|
3552
|
+
* @param data.region Region code for tenant context
|
|
3553
|
+
* @returns void Link soft-deleted; historical transactions are unaffected.
|
|
3554
|
+
* @throws ApiError
|
|
3555
|
+
*/
|
|
3556
|
+
public static externalAccountLinkControllerRemove(
|
|
3557
|
+
data: ExternalAccountLinkControllerRemoveData
|
|
3558
|
+
): CancelablePromise<ExternalAccountLinkControllerRemoveResponse> {
|
|
3559
|
+
return __request(OpenAPI, {
|
|
3560
|
+
method: 'DELETE',
|
|
3561
|
+
url: '/api/v1/{region}/bean/external-account-links/{id}',
|
|
3562
|
+
path: {
|
|
3563
|
+
id: data.id,
|
|
3564
|
+
region: data.region
|
|
3565
|
+
}
|
|
3566
|
+
});
|
|
3567
|
+
}
|
|
3568
|
+
}
|
|
3569
|
+
|
|
3009
3570
|
export class ImportTelemetryService {
|
|
3010
3571
|
/**
|
|
3011
3572
|
* Receive anonymous parser failure telemetry
|
|
@@ -3164,411 +3725,277 @@ export class BeanNlpService {
|
|
|
3164
3725
|
}
|
|
3165
3726
|
}
|
|
3166
3727
|
|
|
3167
|
-
export class
|
|
3168
|
-
/**
|
|
3169
|
-
* Get net worth overview
|
|
3170
|
-
* Returns total net worth with breakdown of assets and liabilities
|
|
3171
|
-
* @param data The data for the request.
|
|
3172
|
-
* @param data.region Region code for tenant context
|
|
3173
|
-
* @param data.date Date for balance calculation (ISO 8601 format)
|
|
3174
|
-
* @returns NetWorthResponseDto Net worth retrieved successfully
|
|
3175
|
-
* @throws ApiError
|
|
3176
|
-
*/
|
|
3177
|
-
public static dashboardControllerGetNetWorth(
|
|
3178
|
-
data: DashboardControllerGetNetWorthData
|
|
3179
|
-
): CancelablePromise<DashboardControllerGetNetWorthResponse> {
|
|
3180
|
-
return __request(OpenAPI, {
|
|
3181
|
-
method: 'GET',
|
|
3182
|
-
url: '/api/v1/{region}/dashboard/net-worth',
|
|
3183
|
-
path: {
|
|
3184
|
-
region: data.region
|
|
3185
|
-
},
|
|
3186
|
-
query: {
|
|
3187
|
-
date: data.date
|
|
3188
|
-
},
|
|
3189
|
-
errors: {
|
|
3190
|
-
401: 'User not authenticated'
|
|
3191
|
-
}
|
|
3192
|
-
});
|
|
3193
|
-
}
|
|
3194
|
-
|
|
3728
|
+
export class BeanPlatformsService {
|
|
3195
3729
|
/**
|
|
3196
|
-
* Get
|
|
3197
|
-
*
|
|
3198
|
-
* @param data The data for the request.
|
|
3199
|
-
* @param data.region Region code for tenant context
|
|
3200
|
-
* @param data.groupBy Grouping strategy
|
|
3201
|
-
* @param data.date Date for balance calculation (ISO 8601 format)
|
|
3202
|
-
* @param data.accountId Scope to a single account (only valid with groupBy=holdingAssetClass, ADR-0105 §6)
|
|
3203
|
-
* @returns unknown Accounts retrieved successfully. Response type depends on groupBy parameter.
|
|
3730
|
+
* Get all platforms with statistics
|
|
3731
|
+
* @returns unknown List of platforms with binding and account counts
|
|
3204
3732
|
* @throws ApiError
|
|
3205
3733
|
*/
|
|
3206
|
-
public static
|
|
3207
|
-
data: DashboardControllerGetAccountsData
|
|
3208
|
-
): CancelablePromise<DashboardControllerGetAccountsResponse> {
|
|
3734
|
+
public static platformControllerFindAll(): CancelablePromise<PlatformControllerFindAllResponse> {
|
|
3209
3735
|
return __request(OpenAPI, {
|
|
3210
3736
|
method: 'GET',
|
|
3211
|
-
url: '/api/v1/
|
|
3212
|
-
path: {
|
|
3213
|
-
region: data.region
|
|
3214
|
-
},
|
|
3215
|
-
query: {
|
|
3216
|
-
groupBy: data.groupBy,
|
|
3217
|
-
date: data.date,
|
|
3218
|
-
accountId: data.accountId
|
|
3219
|
-
},
|
|
3220
|
-
errors: {
|
|
3221
|
-
401: 'User not authenticated'
|
|
3222
|
-
}
|
|
3737
|
+
url: '/api/v1/bean/platforms'
|
|
3223
3738
|
});
|
|
3224
3739
|
}
|
|
3225
3740
|
|
|
3226
3741
|
/**
|
|
3227
|
-
*
|
|
3228
|
-
* Returns income, expenses, and savings for a monthly period
|
|
3742
|
+
* Create a new platform
|
|
3229
3743
|
* @param data The data for the request.
|
|
3230
|
-
* @param data.
|
|
3231
|
-
* @
|
|
3232
|
-
* @returns CashFlowResponseDto Cash flow retrieved successfully
|
|
3744
|
+
* @param data.requestBody
|
|
3745
|
+
* @returns unknown Platform created successfully
|
|
3233
3746
|
* @throws ApiError
|
|
3234
3747
|
*/
|
|
3235
|
-
public static
|
|
3236
|
-
data:
|
|
3237
|
-
): CancelablePromise<
|
|
3748
|
+
public static platformControllerCreate(
|
|
3749
|
+
data: PlatformControllerCreateData
|
|
3750
|
+
): CancelablePromise<PlatformControllerCreateResponse> {
|
|
3238
3751
|
return __request(OpenAPI, {
|
|
3239
|
-
method: '
|
|
3240
|
-
url: '/api/v1/
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
},
|
|
3244
|
-
query: {
|
|
3245
|
-
period: data.period
|
|
3246
|
-
},
|
|
3752
|
+
method: 'POST',
|
|
3753
|
+
url: '/api/v1/bean/platforms',
|
|
3754
|
+
body: data.requestBody,
|
|
3755
|
+
mediaType: 'application/json',
|
|
3247
3756
|
errors: {
|
|
3248
|
-
|
|
3249
|
-
401: 'User not authenticated'
|
|
3757
|
+
409: 'Platform already exists'
|
|
3250
3758
|
}
|
|
3251
3759
|
});
|
|
3252
3760
|
}
|
|
3253
|
-
}
|
|
3254
3761
|
|
|
3255
|
-
export class InvestmentService {
|
|
3256
3762
|
/**
|
|
3257
|
-
* Get
|
|
3258
|
-
* Average-cost unrealized P&L per account × commodity, plus cumulative realized P&L on sold lots (method = FIFO | average, default average).
|
|
3763
|
+
* Get platform list for current user
|
|
3259
3764
|
* @param data The data for the request.
|
|
3260
|
-
* @param data.region Region code
|
|
3261
|
-
* @
|
|
3262
|
-
* @param data.accountId Scope to a single account
|
|
3263
|
-
* @param data.method Realized-P&L lot-matching method (default average). Does not affect the average-cost unrealized basis.
|
|
3264
|
-
* @returns HoldingPnlResponseDto Holding P&L retrieved successfully
|
|
3765
|
+
* @param data.region Region code (ISO 3166-1 alpha-2) that biases within-type-bucket ordering (local-region platforms first). Case-insensitive — stored/compared UPPERCASE ("cn" == "CN").
|
|
3766
|
+
* @returns PlatformListItemDto List of platforms with user binding status
|
|
3265
3767
|
* @throws ApiError
|
|
3266
3768
|
*/
|
|
3267
|
-
public static
|
|
3268
|
-
data:
|
|
3269
|
-
): CancelablePromise<
|
|
3769
|
+
public static platformControllerGetPlatformList(
|
|
3770
|
+
data: PlatformControllerGetPlatformListData = {}
|
|
3771
|
+
): CancelablePromise<PlatformControllerGetPlatformListResponse> {
|
|
3270
3772
|
return __request(OpenAPI, {
|
|
3271
3773
|
method: 'GET',
|
|
3272
|
-
url: '/api/v1/
|
|
3273
|
-
path: {
|
|
3274
|
-
region: data.region
|
|
3275
|
-
},
|
|
3774
|
+
url: '/api/v1/bean/platforms/list',
|
|
3276
3775
|
query: {
|
|
3277
|
-
asOf: data.asOf,
|
|
3278
|
-
accountId: data.accountId,
|
|
3279
|
-
method: data.method
|
|
3280
|
-
},
|
|
3281
|
-
errors: {
|
|
3282
|
-
400: 'Invalid asOf format/value/future date, invalid accountId format, or unsupported method',
|
|
3283
|
-
401: 'User not authenticated'
|
|
3284
|
-
}
|
|
3285
|
-
});
|
|
3286
|
-
}
|
|
3287
|
-
}
|
|
3288
|
-
|
|
3289
|
-
export class BeanPricesService {
|
|
3290
|
-
/**
|
|
3291
|
-
* Create a new price
|
|
3292
|
-
* Creates a new price entry for the authenticated user
|
|
3293
|
-
* @param data The data for the request.
|
|
3294
|
-
* @param data.region Region code for tenant context
|
|
3295
|
-
* @param data.requestBody
|
|
3296
|
-
* @returns PriceResponseDto Price created successfully
|
|
3297
|
-
* @throws ApiError
|
|
3298
|
-
*/
|
|
3299
|
-
public static priceControllerCreate(
|
|
3300
|
-
data: PriceControllerCreateData
|
|
3301
|
-
): CancelablePromise<PriceControllerCreateResponse> {
|
|
3302
|
-
return __request(OpenAPI, {
|
|
3303
|
-
method: 'POST',
|
|
3304
|
-
url: '/api/v1/{region}/bean/prices',
|
|
3305
|
-
path: {
|
|
3306
3776
|
region: data.region
|
|
3307
|
-
},
|
|
3308
|
-
body: data.requestBody,
|
|
3309
|
-
mediaType: 'application/json',
|
|
3310
|
-
errors: {
|
|
3311
|
-
404: 'Currency or quoteCurrency commodity not found',
|
|
3312
|
-
409: 'Price already exists for this currency pair and date'
|
|
3313
3777
|
}
|
|
3314
3778
|
});
|
|
3315
3779
|
}
|
|
3316
3780
|
|
|
3317
3781
|
/**
|
|
3318
|
-
*
|
|
3319
|
-
* Returns all price entries for the authenticated user with optional filtering
|
|
3782
|
+
* Match platforms by name or alias
|
|
3320
3783
|
* @param data The data for the request.
|
|
3321
|
-
* @param data.
|
|
3322
|
-
* @param data.
|
|
3323
|
-
* @
|
|
3324
|
-
* @param data.dateFrom Filter prices from this date (ISO 8601 format)
|
|
3325
|
-
* @param data.dateTo Filter prices to this date (ISO 8601 format)
|
|
3326
|
-
* @param data.search Search term for currency or quoteCurrency (case-insensitive partial match)
|
|
3327
|
-
* @param data.page Page number for pagination (default: 1)
|
|
3328
|
-
* @param data.limit Number of items per page (default: 20, max: 100)
|
|
3329
|
-
* @returns PriceListResponseDto Prices retrieved successfully
|
|
3784
|
+
* @param data.q Search query — Chinese name, English name, or abbreviation
|
|
3785
|
+
* @param data.region Region code (ISO 3166-1 alpha-2) that biases within-tier ordering (local-region platforms first); also the intended categoryOverrides key. Case-insensitive — stored/compared UPPERCASE ("cn" == "CN").
|
|
3786
|
+
* @returns PlatformMatchResponseDto Matching platforms with overall match type and truncation flag
|
|
3330
3787
|
* @throws ApiError
|
|
3331
3788
|
*/
|
|
3332
|
-
public static
|
|
3333
|
-
data:
|
|
3334
|
-
): CancelablePromise<
|
|
3789
|
+
public static platformControllerMatchPlatforms(
|
|
3790
|
+
data: PlatformControllerMatchPlatformsData
|
|
3791
|
+
): CancelablePromise<PlatformControllerMatchPlatformsResponse> {
|
|
3335
3792
|
return __request(OpenAPI, {
|
|
3336
3793
|
method: 'GET',
|
|
3337
|
-
url: '/api/v1/
|
|
3338
|
-
path: {
|
|
3339
|
-
region: data.region
|
|
3340
|
-
},
|
|
3794
|
+
url: '/api/v1/bean/platforms/match',
|
|
3341
3795
|
query: {
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
dateFrom: data.dateFrom,
|
|
3345
|
-
dateTo: data.dateTo,
|
|
3346
|
-
search: data.search,
|
|
3347
|
-
page: data.page,
|
|
3348
|
-
limit: data.limit
|
|
3796
|
+
q: data.q,
|
|
3797
|
+
region: data.region
|
|
3349
3798
|
}
|
|
3350
3799
|
});
|
|
3351
3800
|
}
|
|
3352
3801
|
|
|
3353
3802
|
/**
|
|
3354
|
-
*
|
|
3355
|
-
* Returns a single price entry by its ID
|
|
3803
|
+
* Update a platform
|
|
3356
3804
|
* @param data The data for the request.
|
|
3357
|
-
* @param data.id
|
|
3358
|
-
* @param data.
|
|
3359
|
-
* @returns
|
|
3805
|
+
* @param data.id Platform ID
|
|
3806
|
+
* @param data.requestBody
|
|
3807
|
+
* @returns unknown Platform updated successfully
|
|
3360
3808
|
* @throws ApiError
|
|
3361
3809
|
*/
|
|
3362
|
-
public static
|
|
3363
|
-
data:
|
|
3364
|
-
): CancelablePromise<
|
|
3810
|
+
public static platformControllerUpdate(
|
|
3811
|
+
data: PlatformControllerUpdateData
|
|
3812
|
+
): CancelablePromise<PlatformControllerUpdateResponse> {
|
|
3365
3813
|
return __request(OpenAPI, {
|
|
3366
|
-
method: '
|
|
3367
|
-
url: '/api/v1/
|
|
3814
|
+
method: 'PUT',
|
|
3815
|
+
url: '/api/v1/bean/platforms/{id}',
|
|
3368
3816
|
path: {
|
|
3369
|
-
id: data.id
|
|
3370
|
-
region: data.region
|
|
3817
|
+
id: data.id
|
|
3371
3818
|
},
|
|
3819
|
+
body: data.requestBody,
|
|
3820
|
+
mediaType: 'application/json',
|
|
3372
3821
|
errors: {
|
|
3373
|
-
404: '
|
|
3822
|
+
404: 'Platform not found'
|
|
3374
3823
|
}
|
|
3375
3824
|
});
|
|
3376
3825
|
}
|
|
3377
3826
|
|
|
3378
3827
|
/**
|
|
3379
|
-
*
|
|
3380
|
-
* Updates an existing price entry
|
|
3828
|
+
* Delete a platform
|
|
3381
3829
|
* @param data The data for the request.
|
|
3382
|
-
* @param data.id
|
|
3383
|
-
* @
|
|
3384
|
-
* @param data.requestBody
|
|
3385
|
-
* @returns PriceResponseDto Price updated successfully
|
|
3830
|
+
* @param data.id Platform ID
|
|
3831
|
+
* @returns void Platform deleted successfully
|
|
3386
3832
|
* @throws ApiError
|
|
3387
3833
|
*/
|
|
3388
|
-
public static
|
|
3389
|
-
data:
|
|
3390
|
-
): CancelablePromise<
|
|
3834
|
+
public static platformControllerDelete(
|
|
3835
|
+
data: PlatformControllerDeleteData
|
|
3836
|
+
): CancelablePromise<PlatformControllerDeleteResponse> {
|
|
3391
3837
|
return __request(OpenAPI, {
|
|
3392
|
-
method: '
|
|
3393
|
-
url: '/api/v1/
|
|
3838
|
+
method: 'DELETE',
|
|
3839
|
+
url: '/api/v1/bean/platforms/{id}',
|
|
3394
3840
|
path: {
|
|
3395
|
-
id: data.id
|
|
3396
|
-
region: data.region
|
|
3841
|
+
id: data.id
|
|
3397
3842
|
},
|
|
3398
|
-
body: data.requestBody,
|
|
3399
|
-
mediaType: 'application/json',
|
|
3400
3843
|
errors: {
|
|
3401
|
-
404: '
|
|
3402
|
-
409: 'Updated price conflicts with existing price'
|
|
3844
|
+
404: 'Platform not found'
|
|
3403
3845
|
}
|
|
3404
3846
|
});
|
|
3405
3847
|
}
|
|
3848
|
+
}
|
|
3406
3849
|
|
|
3850
|
+
export class DashboardService {
|
|
3407
3851
|
/**
|
|
3408
|
-
*
|
|
3409
|
-
*
|
|
3852
|
+
* Get net worth overview
|
|
3853
|
+
* Returns total net worth with breakdown of assets and liabilities
|
|
3410
3854
|
* @param data The data for the request.
|
|
3411
|
-
* @param data.id Price ID
|
|
3412
3855
|
* @param data.region Region code for tenant context
|
|
3413
|
-
* @
|
|
3856
|
+
* @param data.date Date for balance calculation (ISO 8601 format)
|
|
3857
|
+
* @returns NetWorthResponseDto Net worth retrieved successfully
|
|
3414
3858
|
* @throws ApiError
|
|
3415
3859
|
*/
|
|
3416
|
-
public static
|
|
3417
|
-
data:
|
|
3418
|
-
): CancelablePromise<
|
|
3860
|
+
public static dashboardControllerGetNetWorth(
|
|
3861
|
+
data: DashboardControllerGetNetWorthData
|
|
3862
|
+
): CancelablePromise<DashboardControllerGetNetWorthResponse> {
|
|
3419
3863
|
return __request(OpenAPI, {
|
|
3420
|
-
method: '
|
|
3421
|
-
url: '/api/v1/{region}/
|
|
3864
|
+
method: 'GET',
|
|
3865
|
+
url: '/api/v1/{region}/dashboard/net-worth',
|
|
3422
3866
|
path: {
|
|
3423
|
-
id: data.id,
|
|
3424
3867
|
region: data.region
|
|
3425
3868
|
},
|
|
3869
|
+
query: {
|
|
3870
|
+
date: data.date
|
|
3871
|
+
},
|
|
3426
3872
|
errors: {
|
|
3427
|
-
|
|
3873
|
+
401: 'User not authenticated'
|
|
3428
3874
|
}
|
|
3429
3875
|
});
|
|
3430
3876
|
}
|
|
3431
3877
|
|
|
3432
3878
|
/**
|
|
3433
|
-
*
|
|
3434
|
-
*
|
|
3879
|
+
* Get accounts grouped by platform
|
|
3880
|
+
* Returns accounts with balances grouped by financial platform
|
|
3435
3881
|
* @param data The data for the request.
|
|
3436
3882
|
* @param data.region Region code for tenant context
|
|
3437
|
-
* @param data.
|
|
3438
|
-
* @
|
|
3883
|
+
* @param data.groupBy Grouping strategy
|
|
3884
|
+
* @param data.date Date for balance calculation (ISO 8601 format)
|
|
3885
|
+
* @param data.accountId Scope to a single account (only valid with groupBy=holdingAssetClass, ADR-0105 §6)
|
|
3886
|
+
* @returns unknown Accounts retrieved successfully. Response type depends on groupBy parameter.
|
|
3439
3887
|
* @throws ApiError
|
|
3440
3888
|
*/
|
|
3441
|
-
public static
|
|
3442
|
-
data:
|
|
3443
|
-
): CancelablePromise<
|
|
3889
|
+
public static dashboardControllerGetAccounts(
|
|
3890
|
+
data: DashboardControllerGetAccountsData
|
|
3891
|
+
): CancelablePromise<DashboardControllerGetAccountsResponse> {
|
|
3444
3892
|
return __request(OpenAPI, {
|
|
3445
|
-
method: '
|
|
3446
|
-
url: '/api/v1/{region}/
|
|
3893
|
+
method: 'GET',
|
|
3894
|
+
url: '/api/v1/{region}/dashboard/accounts',
|
|
3447
3895
|
path: {
|
|
3448
3896
|
region: data.region
|
|
3449
3897
|
},
|
|
3450
|
-
|
|
3451
|
-
|
|
3898
|
+
query: {
|
|
3899
|
+
groupBy: data.groupBy,
|
|
3900
|
+
date: data.date,
|
|
3901
|
+
accountId: data.accountId
|
|
3902
|
+
},
|
|
3903
|
+
errors: {
|
|
3904
|
+
401: 'User not authenticated'
|
|
3905
|
+
}
|
|
3452
3906
|
});
|
|
3453
3907
|
}
|
|
3454
|
-
}
|
|
3455
3908
|
|
|
3456
|
-
export class ReportingService {
|
|
3457
3909
|
/**
|
|
3458
|
-
* Get
|
|
3459
|
-
*
|
|
3460
|
-
* Returns time series data of portfolio net worth.
|
|
3461
|
-
*
|
|
3462
|
-
* **Multi-currency Support:**
|
|
3463
|
-
* - `series[].byCurrency` - Currency breakdown for each data point
|
|
3464
|
-
* - `byCurrency` - Separate time series grouped by currency
|
|
3465
|
-
* - `warnings` - Exchange rate warnings if conversion failed
|
|
3466
|
-
*
|
|
3467
|
-
* **Parameters:**
|
|
3468
|
-
* - `period`: Time period (1m, 3m, 6m, 1y)
|
|
3469
|
-
* - `granularity`: Data granularity (day, week, month)
|
|
3470
|
-
*
|
|
3910
|
+
* Get cash flow summary
|
|
3911
|
+
* Returns income, expenses, and savings for a monthly period
|
|
3471
3912
|
* @param data The data for the request.
|
|
3913
|
+
* @param data.period Period in YYYY-MM format
|
|
3472
3914
|
* @param data.region Region code for tenant context
|
|
3473
|
-
* @
|
|
3474
|
-
* @param data.granularity Data granularity
|
|
3475
|
-
* @returns PortfolioTrendsResponseDto Trends retrieved successfully
|
|
3915
|
+
* @returns CashFlowResponseDto Cash flow retrieved successfully
|
|
3476
3916
|
* @throws ApiError
|
|
3477
3917
|
*/
|
|
3478
|
-
public static
|
|
3479
|
-
data:
|
|
3480
|
-
): CancelablePromise<
|
|
3918
|
+
public static dashboardControllerGetCashFlow(
|
|
3919
|
+
data: DashboardControllerGetCashFlowData
|
|
3920
|
+
): CancelablePromise<DashboardControllerGetCashFlowResponse> {
|
|
3481
3921
|
return __request(OpenAPI, {
|
|
3482
3922
|
method: 'GET',
|
|
3483
|
-
url: '/api/v1/{region}/
|
|
3923
|
+
url: '/api/v1/{region}/dashboard/cash-flow',
|
|
3484
3924
|
path: {
|
|
3485
3925
|
region: data.region
|
|
3486
3926
|
},
|
|
3487
3927
|
query: {
|
|
3488
|
-
period: data.period
|
|
3489
|
-
granularity: data.granularity
|
|
3928
|
+
period: data.period
|
|
3490
3929
|
},
|
|
3491
3930
|
errors: {
|
|
3931
|
+
400: 'Invalid period format',
|
|
3492
3932
|
401: 'User not authenticated'
|
|
3493
3933
|
}
|
|
3494
3934
|
});
|
|
3495
3935
|
}
|
|
3496
3936
|
|
|
3497
3937
|
/**
|
|
3498
|
-
*
|
|
3499
|
-
*
|
|
3500
|
-
* Manually generate a portfolio snapshot for a specific date.
|
|
3501
|
-
*
|
|
3502
|
-
* **Multi-currency Support:**
|
|
3503
|
-
* - Fetches balances grouped by currency
|
|
3504
|
-
* - Uses user's baseCurrency setting for conversion
|
|
3505
|
-
* - Stores exchange rates and warnings
|
|
3506
|
-
*
|
|
3507
|
-
* **Use Cases:**
|
|
3508
|
-
* - Testing snapshot generation
|
|
3509
|
-
* - Force regeneration after data correction
|
|
3510
|
-
* - Initial setup for new users
|
|
3511
|
-
*
|
|
3938
|
+
* Get expenses/income grouped by functional category
|
|
3939
|
+
* 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)
|
|
3512
3940
|
* @param data The data for the request.
|
|
3513
3941
|
* @param data.region Region code for tenant context
|
|
3514
|
-
* @param data.
|
|
3515
|
-
* @
|
|
3942
|
+
* @param data.groupBy Grouping strategy
|
|
3943
|
+
* @param data.period Time window (1m = current calendar month)
|
|
3944
|
+
* @param data.flow Account root to aggregate (expense → ^Expenses:, income → ^Income:)
|
|
3945
|
+
* @returns ExpensesByCategoryResponseDto Expenses retrieved successfully
|
|
3516
3946
|
* @throws ApiError
|
|
3517
3947
|
*/
|
|
3518
|
-
public static
|
|
3519
|
-
data:
|
|
3520
|
-
): CancelablePromise<
|
|
3948
|
+
public static dashboardControllerGetExpenses(
|
|
3949
|
+
data: DashboardControllerGetExpensesData
|
|
3950
|
+
): CancelablePromise<DashboardControllerGetExpensesResponse> {
|
|
3521
3951
|
return __request(OpenAPI, {
|
|
3522
|
-
method: '
|
|
3523
|
-
url: '/api/v1/{region}/
|
|
3952
|
+
method: 'GET',
|
|
3953
|
+
url: '/api/v1/{region}/dashboard/expenses',
|
|
3524
3954
|
path: {
|
|
3525
3955
|
region: data.region
|
|
3526
3956
|
},
|
|
3527
|
-
|
|
3528
|
-
|
|
3957
|
+
query: {
|
|
3958
|
+
groupBy: data.groupBy,
|
|
3959
|
+
period: data.period,
|
|
3960
|
+
flow: data.flow
|
|
3961
|
+
},
|
|
3529
3962
|
errors: {
|
|
3530
|
-
400: 'Invalid
|
|
3963
|
+
400: 'Invalid groupBy or period',
|
|
3531
3964
|
401: 'User not authenticated'
|
|
3532
3965
|
}
|
|
3533
3966
|
});
|
|
3534
3967
|
}
|
|
3968
|
+
}
|
|
3535
3969
|
|
|
3970
|
+
export class InvestmentService {
|
|
3536
3971
|
/**
|
|
3537
|
-
*
|
|
3538
|
-
*
|
|
3539
|
-
* Generate snapshots for a date range (historical data backfill).
|
|
3540
|
-
*
|
|
3541
|
-
* **Multi-currency Support:**
|
|
3542
|
-
* - Each snapshot includes multi-currency data
|
|
3543
|
-
* - Uses exchange rates available at generation time
|
|
3544
|
-
* - Warnings stored for missing exchange rates
|
|
3545
|
-
*
|
|
3546
|
-
* **Best Practices:**
|
|
3547
|
-
* - Use for initial setup after account configuration
|
|
3548
|
-
* - Run during low-traffic periods for large date ranges
|
|
3549
|
-
* - Existing snapshots are skipped (not regenerated)
|
|
3550
|
-
*
|
|
3972
|
+
* Get per-holding unrealized + realized P&L
|
|
3973
|
+
* Average-cost unrealized P&L per account × commodity, plus cumulative realized P&L on sold lots (method = FIFO | average, default average).
|
|
3551
3974
|
* @param data The data for the request.
|
|
3552
3975
|
* @param data.region Region code for tenant context
|
|
3553
|
-
* @param data.
|
|
3554
|
-
* @
|
|
3976
|
+
* @param data.asOf As-of date (ISO 8601), defaults to today
|
|
3977
|
+
* @param data.accountId Scope to a single account
|
|
3978
|
+
* @param data.method Realized-P&L lot-matching method (default average). Does not affect the average-cost unrealized basis.
|
|
3979
|
+
* @returns HoldingPnlResponseDto Holding P&L retrieved successfully
|
|
3555
3980
|
* @throws ApiError
|
|
3556
3981
|
*/
|
|
3557
|
-
public static
|
|
3558
|
-
data:
|
|
3559
|
-
): CancelablePromise<
|
|
3982
|
+
public static holdingPnlControllerGetHoldingPnl(
|
|
3983
|
+
data: HoldingPnlControllerGetHoldingPnlData
|
|
3984
|
+
): CancelablePromise<HoldingPnlControllerGetHoldingPnlResponse> {
|
|
3560
3985
|
return __request(OpenAPI, {
|
|
3561
|
-
method: '
|
|
3562
|
-
url: '/api/v1/{region}/
|
|
3986
|
+
method: 'GET',
|
|
3987
|
+
url: '/api/v1/{region}/investment/holdings/pnl',
|
|
3563
3988
|
path: {
|
|
3564
3989
|
region: data.region
|
|
3565
3990
|
},
|
|
3566
|
-
|
|
3567
|
-
|
|
3991
|
+
query: {
|
|
3992
|
+
asOf: data.asOf,
|
|
3993
|
+
accountId: data.accountId,
|
|
3994
|
+
method: data.method
|
|
3995
|
+
},
|
|
3568
3996
|
errors: {
|
|
3569
|
-
400: 'Invalid date format or
|
|
3570
|
-
401: 'User not authenticated'
|
|
3571
|
-
409: 'Backfill already in progress for this user'
|
|
3997
|
+
400: 'Invalid asOf format/value/future date, invalid accountId format, or unsupported method',
|
|
3998
|
+
401: 'User not authenticated'
|
|
3572
3999
|
}
|
|
3573
4000
|
});
|
|
3574
4001
|
}
|
|
@@ -3597,7 +4024,7 @@ export class AuthService {
|
|
|
3597
4024
|
* Anonymous login with access token
|
|
3598
4025
|
* @param data The data for the request.
|
|
3599
4026
|
* @param data.requestBody
|
|
3600
|
-
* @returns
|
|
4027
|
+
* @returns AnonymousLoginResponseDto Login successful
|
|
3601
4028
|
* @throws ApiError
|
|
3602
4029
|
*/
|
|
3603
4030
|
public static authControllerAccessTokenLogin(
|
|
@@ -3784,3 +4211,53 @@ export class InfoService {
|
|
|
3784
4211
|
});
|
|
3785
4212
|
}
|
|
3786
4213
|
}
|
|
4214
|
+
|
|
4215
|
+
export class MarketDataService {
|
|
4216
|
+
/**
|
|
4217
|
+
* Search market symbols by name or code
|
|
4218
|
+
* Ranked search over the openbb catalog. Empty `q` returns [].
|
|
4219
|
+
* @param data The data for the request.
|
|
4220
|
+
* @param data.q Search term — matched against symbol and instrument name. Empty string returns [].
|
|
4221
|
+
* @param data.limit Maximum number of results (clamped 1..50)
|
|
4222
|
+
* @param data.exchange Filter by exchange code (e.g. US, HK, SS, SZ)
|
|
4223
|
+
* @param data.assetType Filter by OpenBB asset_type (e.g. stock, etf)
|
|
4224
|
+
* @returns SymbolSearchResultDto Ranked search results
|
|
4225
|
+
* @throws ApiError
|
|
4226
|
+
*/
|
|
4227
|
+
public static symbolControllerSearch(
|
|
4228
|
+
data: SymbolControllerSearchData
|
|
4229
|
+
): CancelablePromise<SymbolControllerSearchResponse> {
|
|
4230
|
+
return __request(OpenAPI, {
|
|
4231
|
+
method: 'GET',
|
|
4232
|
+
url: '/api/v1/market/symbols/search',
|
|
4233
|
+
query: {
|
|
4234
|
+
q: data.q,
|
|
4235
|
+
limit: data.limit,
|
|
4236
|
+
exchange: data.exchange,
|
|
4237
|
+
assetType: data.assetType
|
|
4238
|
+
}
|
|
4239
|
+
});
|
|
4240
|
+
}
|
|
4241
|
+
|
|
4242
|
+
/**
|
|
4243
|
+
* Get a market symbol quote
|
|
4244
|
+
* @param data The data for the request.
|
|
4245
|
+
* @param data.symbol
|
|
4246
|
+
* @returns SymbolQuoteDto Symbol quote
|
|
4247
|
+
* @throws ApiError
|
|
4248
|
+
*/
|
|
4249
|
+
public static symbolControllerGetQuote(
|
|
4250
|
+
data: SymbolControllerGetQuoteData
|
|
4251
|
+
): CancelablePromise<SymbolControllerGetQuoteResponse> {
|
|
4252
|
+
return __request(OpenAPI, {
|
|
4253
|
+
method: 'GET',
|
|
4254
|
+
url: '/api/v1/market/symbols/{symbol}/quote',
|
|
4255
|
+
path: {
|
|
4256
|
+
symbol: data.symbol
|
|
4257
|
+
},
|
|
4258
|
+
errors: {
|
|
4259
|
+
404: 'Symbol not found in the openbb catalog'
|
|
4260
|
+
}
|
|
4261
|
+
});
|
|
4262
|
+
}
|
|
4263
|
+
}
|