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