@firela/api-types 0.0.0-canary.a7bda42 → 0.0.0-canary.b3b7767b

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.
Files changed (47) hide show
  1. package/dist/index.d.mts +6619 -0
  2. package/dist/index.d.ts +6619 -2
  3. package/dist/index.js +1237 -3
  4. package/dist/index.mjs +1204 -0
  5. package/package.json +27 -13
  6. package/src/generated/core/ApiError.ts +25 -0
  7. package/src/generated/core/ApiRequestOptions.ts +20 -0
  8. package/src/generated/core/ApiResult.ts +7 -0
  9. package/src/generated/core/CancelablePromise.ts +126 -0
  10. package/src/generated/core/OpenAPI.ts +56 -0
  11. package/src/generated/core/request.ts +391 -0
  12. package/{dist/generated/index.d.ts → src/generated/index.ts} +1 -1
  13. package/src/generated/schemas.gen.ts +4918 -0
  14. package/src/generated/services.gen.ts +3361 -0
  15. package/src/generated/types.gen.ts +6887 -0
  16. package/src/index.ts +12 -0
  17. package/README.md +0 -40
  18. package/dist/generated/core/ApiError.d.ts +0 -11
  19. package/dist/generated/core/ApiError.d.ts.map +0 -1
  20. package/dist/generated/core/ApiError.js +0 -11
  21. package/dist/generated/core/ApiRequestOptions.d.ts +0 -14
  22. package/dist/generated/core/ApiRequestOptions.d.ts.map +0 -1
  23. package/dist/generated/core/ApiRequestOptions.js +0 -1
  24. package/dist/generated/core/ApiResult.d.ts +0 -8
  25. package/dist/generated/core/ApiResult.d.ts.map +0 -1
  26. package/dist/generated/core/ApiResult.js +0 -1
  27. package/dist/generated/core/CancelablePromise.d.ts +0 -27
  28. package/dist/generated/core/CancelablePromise.d.ts.map +0 -1
  29. package/dist/generated/core/CancelablePromise.js +0 -88
  30. package/dist/generated/core/OpenAPI.d.ts +0 -28
  31. package/dist/generated/core/OpenAPI.d.ts.map +0 -1
  32. package/dist/generated/core/OpenAPI.js +0 -29
  33. package/dist/generated/core/request.d.ts +0 -30
  34. package/dist/generated/core/request.d.ts.map +0 -1
  35. package/dist/generated/core/request.js +0 -297
  36. package/dist/generated/index.d.ts.map +0 -1
  37. package/dist/generated/index.js +0 -7
  38. package/dist/generated/schemas.gen.d.ts +0 -771
  39. package/dist/generated/schemas.gen.d.ts.map +0 -1
  40. package/dist/generated/schemas.gen.js +0 -771
  41. package/dist/generated/services.gen.d.ts +0 -313
  42. package/dist/generated/services.gen.d.ts.map +0 -1
  43. package/dist/generated/services.gen.js +0 -705
  44. package/dist/generated/types.gen.d.ts +0 -1159
  45. package/dist/generated/types.gen.d.ts.map +0 -1
  46. package/dist/generated/types.gen.js +0 -2
  47. package/dist/index.d.ts.map +0 -1
@@ -0,0 +1,3361 @@
1
+ // This file is auto-generated by @hey-api/openapi-ts
2
+ import type { CancelablePromise } from './core/CancelablePromise';
3
+ import { OpenAPI } from './core/OpenAPI';
4
+ import { request as __request } from './core/request';
5
+ import type {
6
+ AccountControllerCreateData,
7
+ AccountControllerCreateResponse,
8
+ AccountControllerFindAllData,
9
+ AccountControllerFindAllResponse,
10
+ AccountControllerFindOneData,
11
+ AccountControllerFindOneResponse,
12
+ AccountControllerUpdateData,
13
+ AccountControllerUpdateResponse,
14
+ AccountControllerDeleteData,
15
+ AccountControllerDeleteResponse,
16
+ AccountControllerCloseData,
17
+ AccountControllerCloseResponse,
18
+ AccountControllerReopenData,
19
+ AccountControllerReopenResponse,
20
+ TransactionControllerCreateData,
21
+ TransactionControllerCreateResponse,
22
+ TransactionControllerListData,
23
+ TransactionControllerListResponse,
24
+ TransactionControllerData,
25
+ TransactionControllerResponse,
26
+ TransactionControllerGetDetailData,
27
+ TransactionControllerGetDetailResponse,
28
+ TransactionControllerUpdateData,
29
+ TransactionControllerUpdateResponse,
30
+ TransactionController1Data,
31
+ TransactionController1Response,
32
+ AccountStandardsControllerGetTemplatesData,
33
+ AccountStandardsControllerGetTemplatesResponse,
34
+ AccountStandardsControllerGetRegionsData,
35
+ AccountStandardsControllerGetRegionsResponse,
36
+ BalanceControllerGetBalanceData,
37
+ BalanceControllerGetBalanceResponse,
38
+ BalanceControllerGetMultiCurrencyBalanceData,
39
+ BalanceControllerGetMultiCurrencyBalanceResponse,
40
+ ReviewControllerFindAllData,
41
+ ReviewControllerFindAllResponse,
42
+ ReviewControllerGetStatsData,
43
+ ReviewControllerGetStatsResponse,
44
+ ReviewControllerFindOneData,
45
+ ReviewControllerFindOneResponse,
46
+ ReviewControllerData,
47
+ ReviewControllerResponse,
48
+ ReviewController1Data,
49
+ ReviewController1Response,
50
+ ReviewController2Data,
51
+ ReviewController2Response,
52
+ PayeeControllerData,
53
+ PayeeControllerResponse,
54
+ PayeeControllerFindAllData,
55
+ PayeeControllerFindAllResponse,
56
+ PayeeControllerAutocompleteData,
57
+ PayeeControllerAutocompleteResponse,
58
+ PayeeControllerGetTopPayeesData,
59
+ PayeeControllerGetTopPayeesResponse,
60
+ PayeeControllerFindOneData,
61
+ PayeeControllerFindOneResponse,
62
+ PayeeController1Data,
63
+ PayeeController1Response,
64
+ PayeeController2Data,
65
+ PayeeController2Response,
66
+ PayeeProfileAdminControllerData,
67
+ PayeeProfileAdminControllerResponse,
68
+ PayeeProfileAdminControllerFindAllData,
69
+ PayeeProfileAdminControllerFindAllResponse,
70
+ PayeeProfileAdminControllerFindOneData,
71
+ PayeeProfileAdminControllerFindOneResponse,
72
+ PayeeProfileAdminController1Data,
73
+ PayeeProfileAdminController1Response,
74
+ PayeeProfileAdminController2Data,
75
+ PayeeProfileAdminController2Response,
76
+ PayeeProfileAdminController3Data,
77
+ PayeeProfileAdminController3Response,
78
+ PayeeProfileAdminController4Data,
79
+ PayeeProfileAdminController4Response,
80
+ CommodityControllerData,
81
+ CommodityControllerResponse,
82
+ CommodityControllerFindAllData,
83
+ CommodityControllerFindAllResponse,
84
+ CommodityControllerFindOneData,
85
+ CommodityControllerFindOneResponse,
86
+ CommodityController1Data,
87
+ CommodityController1Response,
88
+ CommodityController2Data,
89
+ CommodityController2Response,
90
+ CommodityController3Data,
91
+ CommodityController3Response,
92
+ CommodityController4Data,
93
+ CommodityController4Response,
94
+ RecurringRuleControllerData,
95
+ RecurringRuleControllerResponse,
96
+ RecurringRuleControllerFindAllData,
97
+ RecurringRuleControllerFindAllResponse,
98
+ RecurringRuleController1Data,
99
+ RecurringRuleController1Response,
100
+ RecurringRuleControllerFindOneData,
101
+ RecurringRuleControllerFindOneResponse,
102
+ RecurringRuleController2Data,
103
+ RecurringRuleController2Response,
104
+ RecurringRuleController3Data,
105
+ RecurringRuleController3Response,
106
+ RecurringRuleControllerGetWithStatsData,
107
+ RecurringRuleControllerGetWithStatsResponse,
108
+ ExpectedTransactionControllerFindAllData,
109
+ ExpectedTransactionControllerFindAllResponse,
110
+ ExpectedTransactionControllerFindOverdueData,
111
+ ExpectedTransactionControllerFindOverdueResponse,
112
+ ExpectedTransactionControllerFindOneData,
113
+ ExpectedTransactionControllerFindOneResponse,
114
+ ExpectedTransactionControllerData,
115
+ ExpectedTransactionControllerResponse,
116
+ ExpectedTransactionController1Data,
117
+ ExpectedTransactionController1Response,
118
+ ExpectedTransactionController2Data,
119
+ ExpectedTransactionController2Response,
120
+ ExpectedTransactionController3Data,
121
+ ExpectedTransactionController3Response,
122
+ ExpectedTransactionController4Data,
123
+ ExpectedTransactionController4Response,
124
+ ForecastControllerGetForecastData,
125
+ ForecastControllerGetForecastResponse,
126
+ TransactionRuleControllerData,
127
+ TransactionRuleControllerResponse,
128
+ TransactionRuleControllerListData,
129
+ TransactionRuleControllerListResponse,
130
+ TransactionRuleControllerValidateData,
131
+ TransactionRuleControllerValidateResponse,
132
+ TransactionRuleController1Data,
133
+ TransactionRuleController1Response,
134
+ TransactionRuleControllerExportData,
135
+ TransactionRuleControllerExportResponse,
136
+ TransactionRuleControllerGetStatisticsData,
137
+ TransactionRuleControllerGetStatisticsResponse,
138
+ TransactionRuleControllerGetDetailData,
139
+ TransactionRuleControllerGetDetailResponse,
140
+ TransactionRuleController2Data,
141
+ TransactionRuleController2Response,
142
+ TransactionRuleController3Data,
143
+ TransactionRuleController3Response,
144
+ TransactionRuleControllerTestData,
145
+ TransactionRuleControllerTestResponse,
146
+ UserControllerDeleteOwnUserData,
147
+ UserControllerDeleteOwnUserResponse,
148
+ UserControllerGetUserData,
149
+ UserControllerGetUserResponse,
150
+ UserControllerSignupUserData,
151
+ UserControllerSignupUserResponse,
152
+ UserControllerDeleteUserData,
153
+ UserControllerDeleteUserResponse,
154
+ UserControllerGetUserInfoData,
155
+ UserControllerGetUserInfoResponse,
156
+ UserControllerUpdateUserSettingData,
157
+ UserControllerUpdateUserSettingResponse,
158
+ UserControllerGetAllUserSettingsByPageData,
159
+ UserControllerGetAllUserSettingsByPageResponse,
160
+ UserControllerGetAssetLiabilitySummaryData,
161
+ UserControllerGetAssetLiabilitySummaryResponse,
162
+ PropertyControllerGetAllData,
163
+ PropertyControllerGetAllResponse,
164
+ PropertyControllerGetByKeyData,
165
+ PropertyControllerGetByKeyResponse,
166
+ PropertyControllerData,
167
+ PropertyControllerResponse,
168
+ PropertyController1Data,
169
+ PropertyController1Response,
170
+ FileImportControllerImportFileData,
171
+ FileImportControllerImportFileResponse,
172
+ FileImportControllerIdentifyFileData,
173
+ FileImportControllerIdentifyFileResponse,
174
+ ImporterConfigControllerGetConfigData,
175
+ ImporterConfigControllerGetConfigResponse,
176
+ ImporterConfigControllerData,
177
+ ImporterConfigControllerResponse,
178
+ ImporterConfigController1Data,
179
+ ImporterConfigController1Response,
180
+ ProviderSyncControllerSyncData,
181
+ ProviderSyncControllerSyncResponse,
182
+ ProviderSyncControllerGetSupportedProvidersData,
183
+ ProviderSyncControllerGetSupportedProvidersResponse,
184
+ ProviderSyncControllerIsProviderSupportedData,
185
+ ProviderSyncControllerIsProviderSupportedResponse,
186
+ TelemetryControllerReportTelemetryData,
187
+ TelemetryControllerReportTelemetryResponse,
188
+ NlpControllerProcessNaturalLanguageData,
189
+ NlpControllerProcessNaturalLanguageResponse,
190
+ NlpControllerClearSessionData,
191
+ NlpControllerClearSessionResponse,
192
+ NlpControllerGetSessionData,
193
+ NlpControllerGetSessionResponse,
194
+ PlatformControllerFindAllData,
195
+ PlatformControllerFindAllResponse,
196
+ PlatformControllerData,
197
+ PlatformControllerResponse,
198
+ PlatformControllerGetPlatformListData,
199
+ PlatformControllerGetPlatformListResponse,
200
+ PlatformController1Data,
201
+ PlatformController1Response,
202
+ PlatformController2Data,
203
+ PlatformController2Response,
204
+ SymbolControllerLookupSymbolData,
205
+ SymbolControllerLookupSymbolResponse,
206
+ SymbolControllerGetSymbolDataData,
207
+ SymbolControllerGetSymbolDataResponse,
208
+ SymbolControllerGatherSymbolForDateData,
209
+ SymbolControllerGatherSymbolForDateResponse,
210
+ SymbolControllerData,
211
+ SymbolControllerResponse,
212
+ CacheControllerFlushCacheData,
213
+ CacheControllerFlushCacheResponse,
214
+ DashboardControllerGetNetWorthData,
215
+ DashboardControllerGetNetWorthResponse,
216
+ DashboardControllerGetAccountsData,
217
+ DashboardControllerGetAccountsResponse,
218
+ DashboardControllerGetCashFlowData,
219
+ DashboardControllerGetCashFlowResponse,
220
+ ReportingControllerGetPortfolioTrendsData,
221
+ ReportingControllerGetPortfolioTrendsResponse,
222
+ ReportingControllerGenerateSnapshotData,
223
+ ReportingControllerGenerateSnapshotResponse,
224
+ ReportingControllerBackfillSnapshotsData,
225
+ ReportingControllerBackfillSnapshotsResponse,
226
+ ApiKeysControllerData,
227
+ ApiKeysControllerResponse,
228
+ AuthControllerAccessTokenLoginData,
229
+ AuthControllerAccessTokenLoginResponse,
230
+ ExchangeRateControllerGetExchangeRateData,
231
+ ExchangeRateControllerGetExchangeRateResponse,
232
+ HealthControllerGetHealthData,
233
+ HealthControllerGetHealthResponse,
234
+ HealthControllerCheckDatabaseData,
235
+ HealthControllerCheckDatabaseResponse,
236
+ HealthControllerCheckRedisData,
237
+ HealthControllerCheckRedisResponse,
238
+ HealthControllerGetCircuitBreakersHealthData,
239
+ HealthControllerGetCircuitBreakersHealthResponse,
240
+ HealthControllerResetCircuitBreakerData,
241
+ HealthControllerResetCircuitBreakerResponse,
242
+ HealthControllerGetMetricsData,
243
+ HealthControllerGetMetricsResponse,
244
+ HealthControllerGetHealthOfDataEnhancerData,
245
+ HealthControllerGetHealthOfDataEnhancerResponse,
246
+ HealthControllerCheckDataProvidersData,
247
+ HealthControllerCheckDataProvidersResponse,
248
+ HealthControllerGetHealthOfDataProviderData,
249
+ HealthControllerGetHealthOfDataProviderResponse,
250
+ InfoControllerGetInfoData,
251
+ InfoControllerGetInfoResponse,
252
+ LogoControllerGetLogoByDataSourceAndSymbolData,
253
+ LogoControllerGetLogoByDataSourceAndSymbolResponse,
254
+ LogoControllerGetLogoByUrlData,
255
+ LogoControllerGetLogoByUrlResponse,
256
+ MarketDataControllerGetMarketDataBySymbolData,
257
+ MarketDataControllerGetMarketDataBySymbolResponse,
258
+ MarketDataControllerData,
259
+ MarketDataControllerResponse
260
+ } from './types.gen';
261
+
262
+ export class BeanAccountsService {
263
+ /**
264
+ * Create a new account
265
+ * Creates a new account (Beancount Open directive)
266
+ * @param data The data for the request.
267
+ * @param data.region Region code for tenant context
268
+ * @param data.requestBody
269
+ * @returns AccountResponseDto Account created successfully
270
+ * @throws ApiError
271
+ */
272
+ public static accountControllerCreate(
273
+ data: AccountControllerCreateData
274
+ ): CancelablePromise<AccountControllerCreateResponse> {
275
+ return __request(OpenAPI, {
276
+ method: 'POST',
277
+ url: '/api/v1/{region}/bean/accounts',
278
+ path: {
279
+ region: data.region
280
+ },
281
+ body: data.requestBody,
282
+ mediaType: 'application/json',
283
+ errors: {
284
+ 409: 'Account already exists'
285
+ }
286
+ });
287
+ }
288
+
289
+ /**
290
+ * List accounts
291
+ * Returns all accounts with optional filtering
292
+ * @param data The data for the request.
293
+ * @param data.region Region code for tenant context
294
+ * @param data.type Filter by account type
295
+ * @param data.status Filter by status
296
+ * @param data.isCustom Filter by custom (user-created) accounts only
297
+ * @param data.search Search term for path or i18nKey
298
+ * @param data.limit Maximum number of results
299
+ * @param data.offset Number of results to skip
300
+ * @returns AccountListResponseDto Accounts retrieved successfully
301
+ * @throws ApiError
302
+ */
303
+ public static accountControllerFindAll(
304
+ data: AccountControllerFindAllData
305
+ ): CancelablePromise<AccountControllerFindAllResponse> {
306
+ return __request(OpenAPI, {
307
+ method: 'GET',
308
+ url: '/api/v1/{region}/bean/accounts',
309
+ path: {
310
+ region: data.region
311
+ },
312
+ query: {
313
+ type: data.type,
314
+ status: data.status,
315
+ isCustom: data.isCustom,
316
+ search: data.search,
317
+ limit: data.limit,
318
+ offset: data.offset
319
+ }
320
+ });
321
+ }
322
+
323
+ /**
324
+ * Get account by ID
325
+ * Returns a specific account
326
+ * @param data The data for the request.
327
+ * @param data.id Account UUID
328
+ * @param data.region Region code for tenant context
329
+ * @returns AccountResponseDto Account retrieved successfully
330
+ * @throws ApiError
331
+ */
332
+ public static accountControllerFindOne(
333
+ data: AccountControllerFindOneData
334
+ ): CancelablePromise<AccountControllerFindOneResponse> {
335
+ return __request(OpenAPI, {
336
+ method: 'GET',
337
+ url: '/api/v1/{region}/bean/accounts/{id}',
338
+ path: {
339
+ id: data.id,
340
+ region: data.region
341
+ },
342
+ errors: {
343
+ 404: 'Account not found'
344
+ }
345
+ });
346
+ }
347
+
348
+ /**
349
+ * Update account
350
+ * Updates account metadata (path cannot be changed)
351
+ * @param data The data for the request.
352
+ * @param data.id Account UUID
353
+ * @param data.region Region code for tenant context
354
+ * @param data.requestBody
355
+ * @returns AccountResponseDto Account updated successfully
356
+ * @throws ApiError
357
+ */
358
+ public static accountControllerUpdate(
359
+ data: AccountControllerUpdateData
360
+ ): CancelablePromise<AccountControllerUpdateResponse> {
361
+ return __request(OpenAPI, {
362
+ method: 'PUT',
363
+ url: '/api/v1/{region}/bean/accounts/{id}',
364
+ path: {
365
+ id: data.id,
366
+ region: data.region
367
+ },
368
+ body: data.requestBody,
369
+ mediaType: 'application/json',
370
+ errors: {
371
+ 404: 'Account not found'
372
+ }
373
+ });
374
+ }
375
+
376
+ /**
377
+ * Delete account
378
+ * Deletes an account (only if no transactions)
379
+ * @param data The data for the request.
380
+ * @param data.id Account UUID
381
+ * @param data.region Region code for tenant context
382
+ * @returns void Account deleted successfully
383
+ * @throws ApiError
384
+ */
385
+ public static accountControllerDelete(
386
+ data: AccountControllerDeleteData
387
+ ): CancelablePromise<AccountControllerDeleteResponse> {
388
+ return __request(OpenAPI, {
389
+ method: 'DELETE',
390
+ url: '/api/v1/{region}/bean/accounts/{id}',
391
+ path: {
392
+ id: data.id,
393
+ region: data.region
394
+ },
395
+ errors: {
396
+ 404: 'Account not found',
397
+ 409: 'Account has transactions and cannot be deleted'
398
+ }
399
+ });
400
+ }
401
+
402
+ /**
403
+ * Close account
404
+ * Closes an account (Beancount Close directive)
405
+ * @param data The data for the request.
406
+ * @param data.id Account UUID
407
+ * @param data.region Region code for tenant context
408
+ * @param data.requestBody
409
+ * @returns AccountResponseDto Account closed successfully
410
+ * @throws ApiError
411
+ */
412
+ public static accountControllerClose(
413
+ data: AccountControllerCloseData
414
+ ): CancelablePromise<AccountControllerCloseResponse> {
415
+ return __request(OpenAPI, {
416
+ method: 'POST',
417
+ url: '/api/v1/{region}/bean/accounts/{id}/close',
418
+ path: {
419
+ id: data.id,
420
+ region: data.region
421
+ },
422
+ body: data.requestBody,
423
+ mediaType: 'application/json',
424
+ errors: {
425
+ 400: 'Account is already closed',
426
+ 404: 'Account not found'
427
+ }
428
+ });
429
+ }
430
+
431
+ /**
432
+ * Reopen account
433
+ * Reopens a previously closed account
434
+ * @param data The data for the request.
435
+ * @param data.id Account UUID
436
+ * @param data.region Region code for tenant context
437
+ * @param data.requestBody
438
+ * @returns AccountResponseDto Account reopened successfully
439
+ * @throws ApiError
440
+ */
441
+ public static accountControllerReopen(
442
+ data: AccountControllerReopenData
443
+ ): CancelablePromise<AccountControllerReopenResponse> {
444
+ return __request(OpenAPI, {
445
+ method: 'POST',
446
+ url: '/api/v1/{region}/bean/accounts/{id}/reopen',
447
+ path: {
448
+ id: data.id,
449
+ region: data.region
450
+ },
451
+ body: data.requestBody,
452
+ mediaType: 'application/json',
453
+ errors: {
454
+ 400: 'Account is not closed',
455
+ 404: 'Account not found'
456
+ }
457
+ });
458
+ }
459
+ }
460
+
461
+ export class BeanTransactionsService {
462
+ /**
463
+ * @deprecated
464
+ * Create transaction (DEPRECATED)
465
+ * DEPRECATED: Use POST /:region/bean/import/provider/:name/sync instead. This endpoint skips dedup, rule matching, and review branching.
466
+ * @param data The data for the request.
467
+ * @param data.region Region code for tenant context
468
+ * @param data.requestBody Transaction data with postings
469
+ * @returns TransactionResponseDto Transaction created successfully
470
+ * @throws ApiError
471
+ */
472
+ public static transactionControllerCreate(
473
+ data: TransactionControllerCreateData
474
+ ): CancelablePromise<TransactionControllerCreateResponse> {
475
+ return __request(OpenAPI, {
476
+ method: 'POST',
477
+ url: '/api/v1/{region}/bean/transactions',
478
+ path: {
479
+ region: data.region
480
+ },
481
+ body: data.requestBody,
482
+ mediaType: 'application/json',
483
+ errors: {
484
+ 400: 'Validation failed',
485
+ 401: 'Authentication required',
486
+ 422: 'Semantic validation failed (transaction does not balance, invalid accounts)',
487
+ 500: 'Unexpected server error'
488
+ }
489
+ });
490
+ }
491
+
492
+ /**
493
+ * List transactions
494
+ * Returns a paginated list of transactions with optional filters
495
+ * @param data The data for the request.
496
+ * @param data.region Region code for tenant context
497
+ * @param data.limit Number of items per page (1-100, default: 20)
498
+ * @param data.offset Number of items to skip (default: 0)
499
+ * @param data.dateFrom Filter by start date (inclusive), format: YYYY-MM-DD
500
+ * @param data.dateTo Filter by end date (inclusive), format: YYYY-MM-DD
501
+ * @param data.status Filter by transaction status
502
+ * @param data.search Search in narration and payee fields (max 200 chars)
503
+ * @param data.accountId Filter by account ID (transactions with postings to this account)
504
+ * @returns TransactionListResponseDto Transaction list
505
+ * @throws ApiError
506
+ */
507
+ public static transactionControllerList(
508
+ data: TransactionControllerListData
509
+ ): CancelablePromise<TransactionControllerListResponse> {
510
+ return __request(OpenAPI, {
511
+ method: 'GET',
512
+ url: '/api/v1/{region}/bean/transactions',
513
+ path: {
514
+ region: data.region
515
+ },
516
+ query: {
517
+ limit: data.limit,
518
+ offset: data.offset,
519
+ dateFrom: data.dateFrom,
520
+ dateTo: data.dateTo,
521
+ status: data.status,
522
+ search: data.search,
523
+ accountId: data.accountId
524
+ },
525
+ errors: {
526
+ 401: 'Authentication required'
527
+ }
528
+ });
529
+ }
530
+
531
+ /**
532
+ * @param data The data for the request.
533
+ * @param data.region Region code for tenant context
534
+ * @returns unknown
535
+ * @throws ApiError
536
+ */
537
+ public static transactionController(
538
+ data: TransactionControllerData
539
+ ): CancelablePromise<TransactionControllerResponse> {
540
+ return __request(OpenAPI, {
541
+ method: 'POST',
542
+ url: '/api/v1/{region}/bean/transactions/batch',
543
+ path: {
544
+ region: data.region
545
+ }
546
+ });
547
+ }
548
+
549
+ /**
550
+ * Get transaction detail
551
+ * Returns transaction details including all postings
552
+ * @param data The data for the request.
553
+ * @param data.id Transaction ID
554
+ * @param data.region Region code for tenant context
555
+ * @returns TransactionDetailDto Transaction detail
556
+ * @throws ApiError
557
+ */
558
+ public static transactionControllerGetDetail(
559
+ data: TransactionControllerGetDetailData
560
+ ): CancelablePromise<TransactionControllerGetDetailResponse> {
561
+ return __request(OpenAPI, {
562
+ method: 'GET',
563
+ url: '/api/v1/{region}/bean/transactions/{id}',
564
+ path: {
565
+ id: data.id,
566
+ region: data.region
567
+ },
568
+ errors: {
569
+ 401: 'Authentication required',
570
+ 404: 'Transaction not found'
571
+ }
572
+ });
573
+ }
574
+
575
+ /**
576
+ * Update transaction metadata
577
+ * Updates transaction metadata (flag, payee, narration, tags, links, meta). Postings cannot be modified.
578
+ * @param data The data for the request.
579
+ * @param data.id Transaction ID
580
+ * @param data.region Region code for tenant context
581
+ * @param data.requestBody Fields to update (all optional)
582
+ * @returns TransactionDetailDto Transaction updated successfully
583
+ * @throws ApiError
584
+ */
585
+ public static transactionControllerUpdate(
586
+ data: TransactionControllerUpdateData
587
+ ): CancelablePromise<TransactionControllerUpdateResponse> {
588
+ return __request(OpenAPI, {
589
+ method: 'PATCH',
590
+ url: '/api/v1/{region}/bean/transactions/{id}',
591
+ path: {
592
+ id: data.id,
593
+ region: data.region
594
+ },
595
+ body: data.requestBody,
596
+ mediaType: 'application/json',
597
+ errors: {
598
+ 400: 'Cannot update voided transaction',
599
+ 401: 'Authentication required',
600
+ 404: 'Transaction not found'
601
+ }
602
+ });
603
+ }
604
+
605
+ /**
606
+ * @param data The data for the request.
607
+ * @param data.region Region code for tenant context
608
+ * @returns void
609
+ * @throws ApiError
610
+ */
611
+ public static transactionController1(
612
+ data: TransactionController1Data
613
+ ): CancelablePromise<TransactionController1Response> {
614
+ return __request(OpenAPI, {
615
+ method: 'DELETE',
616
+ url: '/api/v1/{region}/bean/transactions/{id}',
617
+ path: {
618
+ region: data.region
619
+ }
620
+ });
621
+ }
622
+ }
623
+
624
+ export class BeanAccountStandardsService {
625
+ /**
626
+ * Get account templates
627
+ * Returns predefined account templates for a region. Supports filtering by account type and search term.
628
+ * @param data The data for the request.
629
+ * @param data.region Region code (cn, us, de)
630
+ * @param data.type Filter by account type
631
+ * @param data.search Search term for path or description
632
+ * @returns AccountStandardListResponseDto Account templates retrieved successfully
633
+ * @throws ApiError
634
+ */
635
+ public static accountStandardsControllerGetTemplates(
636
+ data: AccountStandardsControllerGetTemplatesData
637
+ ): CancelablePromise<AccountStandardsControllerGetTemplatesResponse> {
638
+ return __request(OpenAPI, {
639
+ method: 'GET',
640
+ url: '/api/v1/{region}/bean/account-standards',
641
+ path: {
642
+ region: data.region
643
+ },
644
+ query: {
645
+ type: data.type,
646
+ search: data.search
647
+ }
648
+ });
649
+ }
650
+
651
+ /**
652
+ * Get available regions with hierarchy
653
+ * Returns supported regions with inheritance metadata
654
+ * @param data The data for the request.
655
+ * @param data.region Region code (cn, us, de)
656
+ * @returns RegionsMetadataResponseDto Regions metadata retrieved successfully
657
+ * @throws ApiError
658
+ */
659
+ public static accountStandardsControllerGetRegions(
660
+ data: AccountStandardsControllerGetRegionsData
661
+ ): CancelablePromise<AccountStandardsControllerGetRegionsResponse> {
662
+ return __request(OpenAPI, {
663
+ method: 'GET',
664
+ url: '/api/v1/{region}/bean/account-standards/regions',
665
+ path: {
666
+ region: data.region
667
+ }
668
+ });
669
+ }
670
+ }
671
+
672
+ export class BeanBalancesService {
673
+ /**
674
+ * Query account balance
675
+ * Calculate account balance at a specific date for a single currency
676
+ * @param data The data for the request.
677
+ * @param data.account Account name (e.g., "Assets:Bank:Checking")
678
+ * @param data.region Region code (cn, us, de)
679
+ * @param data.date Date to calculate balance at (ISO 8601 format)
680
+ * @param data.currency Currency to query (e.g., "USD", "CNY")
681
+ * @returns BalanceResponseDto Balance calculated successfully
682
+ * @throws ApiError
683
+ */
684
+ public static balanceControllerGetBalance(
685
+ data: BalanceControllerGetBalanceData
686
+ ): CancelablePromise<BalanceControllerGetBalanceResponse> {
687
+ return __request(OpenAPI, {
688
+ method: 'GET',
689
+ url: '/api/v1/{region}/bean/balances',
690
+ path: {
691
+ region: data.region
692
+ },
693
+ query: {
694
+ account: data.account,
695
+ date: data.date,
696
+ currency: data.currency
697
+ },
698
+ errors: {
699
+ 400: 'Invalid query parameters',
700
+ 401: 'User not authenticated'
701
+ }
702
+ });
703
+ }
704
+
705
+ /**
706
+ * Query multi-currency account balance
707
+ * Calculate account balances for all currencies at a specific date
708
+ * @param data The data for the request.
709
+ * @param data.region Region code (cn, us, de)
710
+ * @returns MultiCurrencyBalanceResponseDto Balances calculated successfully
711
+ * @throws ApiError
712
+ */
713
+ public static balanceControllerGetMultiCurrencyBalance(
714
+ data: BalanceControllerGetMultiCurrencyBalanceData
715
+ ): CancelablePromise<BalanceControllerGetMultiCurrencyBalanceResponse> {
716
+ return __request(OpenAPI, {
717
+ method: 'GET',
718
+ url: '/api/v1/{region}/bean/balances/multi-currency',
719
+ path: {
720
+ region: data.region
721
+ },
722
+ errors: {
723
+ 400: 'Invalid query parameters',
724
+ 401: 'User not authenticated'
725
+ }
726
+ });
727
+ }
728
+ }
729
+
730
+ export class BeanReviewsService {
731
+ /**
732
+ * List pending reviews
733
+ * @param data The data for the request.
734
+ * @param data.region Region code (cn, us, de)
735
+ * @param data.type Filter by review type
736
+ * @param data.confidenceLevel Filter by confidence level
737
+ * @param data.sortBy Sort order
738
+ * @param data.page Page number (default: 1)
739
+ * @param data.limit Items per page (1-100, default: 20)
740
+ * @returns ReviewListResponseDto
741
+ * @throws ApiError
742
+ */
743
+ public static reviewControllerFindAll(
744
+ data: ReviewControllerFindAllData
745
+ ): CancelablePromise<ReviewControllerFindAllResponse> {
746
+ return __request(OpenAPI, {
747
+ method: 'GET',
748
+ url: '/api/v1/{region}/bean/reviews',
749
+ path: {
750
+ region: data.region
751
+ },
752
+ query: {
753
+ type: data.type,
754
+ confidenceLevel: data.confidenceLevel,
755
+ sortBy: data.sortBy,
756
+ page: data.page,
757
+ limit: data.limit
758
+ }
759
+ });
760
+ }
761
+
762
+ /**
763
+ * Get review statistics
764
+ * @param data The data for the request.
765
+ * @param data.region Region code (cn, us, de)
766
+ * @returns ReviewStatsDto
767
+ * @throws ApiError
768
+ */
769
+ public static reviewControllerGetStats(
770
+ data: ReviewControllerGetStatsData
771
+ ): CancelablePromise<ReviewControllerGetStatsResponse> {
772
+ return __request(OpenAPI, {
773
+ method: 'GET',
774
+ url: '/api/v1/{region}/bean/reviews/stats',
775
+ path: {
776
+ region: data.region
777
+ }
778
+ });
779
+ }
780
+
781
+ /**
782
+ * Get review by ID
783
+ * @param data The data for the request.
784
+ * @param data.id Review ID
785
+ * @param data.region Region code (cn, us, de)
786
+ * @returns ReviewDetailDto
787
+ * @throws ApiError
788
+ */
789
+ public static reviewControllerFindOne(
790
+ data: ReviewControllerFindOneData
791
+ ): CancelablePromise<ReviewControllerFindOneResponse> {
792
+ return __request(OpenAPI, {
793
+ method: 'GET',
794
+ url: '/api/v1/{region}/bean/reviews/{id}',
795
+ path: {
796
+ id: data.id,
797
+ region: data.region
798
+ }
799
+ });
800
+ }
801
+
802
+ /**
803
+ * @param data The data for the request.
804
+ * @param data.region Region code (cn, us, de)
805
+ * @returns unknown
806
+ * @throws ApiError
807
+ */
808
+ public static reviewController(
809
+ data: ReviewControllerData
810
+ ): CancelablePromise<ReviewControllerResponse> {
811
+ return __request(OpenAPI, {
812
+ method: 'POST',
813
+ url: '/api/v1/{region}/bean/reviews/{id}/resolve',
814
+ path: {
815
+ region: data.region
816
+ }
817
+ });
818
+ }
819
+
820
+ /**
821
+ * @param data The data for the request.
822
+ * @param data.region Region code (cn, us, de)
823
+ * @returns unknown
824
+ * @throws ApiError
825
+ */
826
+ public static reviewController1(
827
+ data: ReviewController1Data
828
+ ): CancelablePromise<ReviewController1Response> {
829
+ return __request(OpenAPI, {
830
+ method: 'POST',
831
+ url: '/api/v1/{region}/bean/reviews/{id}/undo',
832
+ path: {
833
+ region: data.region
834
+ }
835
+ });
836
+ }
837
+
838
+ /**
839
+ * @param data The data for the request.
840
+ * @param data.region Region code (cn, us, de)
841
+ * @returns unknown
842
+ * @throws ApiError
843
+ */
844
+ public static reviewController2(
845
+ data: ReviewController2Data
846
+ ): CancelablePromise<ReviewController2Response> {
847
+ return __request(OpenAPI, {
848
+ method: 'POST',
849
+ url: '/api/v1/{region}/bean/reviews/batch-resolve',
850
+ path: {
851
+ region: data.region
852
+ }
853
+ });
854
+ }
855
+ }
856
+
857
+ export class BeanPayeesService {
858
+ /**
859
+ * @param data The data for the request.
860
+ * @param data.region Region code (cn, us, de)
861
+ * @returns unknown
862
+ * @throws ApiError
863
+ */
864
+ public static payeeController(
865
+ data: PayeeControllerData
866
+ ): CancelablePromise<PayeeControllerResponse> {
867
+ return __request(OpenAPI, {
868
+ method: 'POST',
869
+ url: '/api/v1/bean/payees',
870
+ path: {
871
+ region: data.region
872
+ }
873
+ });
874
+ }
875
+
876
+ /**
877
+ * List user payees
878
+ * Returns all payee mappings for the authenticated user with optional filtering
879
+ * @param data The data for the request.
880
+ * @param data.region Region code (cn, us, de)
881
+ * @param data.search Search term for payee name (partial match, case-insensitive). Useful for autocomplete.
882
+ * @param data.payee Filter by exact payee name match
883
+ * @param data.category Filter by custom category
884
+ * @param data.tag Filter by custom tag (returns payees that have this tag)
885
+ * @param data.isActive Filter by active status. Defaults to true (show only active payees).
886
+ * @returns PayeeListResponseDto Payees retrieved successfully
887
+ * @throws ApiError
888
+ */
889
+ public static payeeControllerFindAll(
890
+ data: PayeeControllerFindAllData
891
+ ): CancelablePromise<PayeeControllerFindAllResponse> {
892
+ return __request(OpenAPI, {
893
+ method: 'GET',
894
+ url: '/api/v1/bean/payees',
895
+ path: {
896
+ region: data.region
897
+ },
898
+ query: {
899
+ search: data.search,
900
+ payee: data.payee,
901
+ category: data.category,
902
+ tag: data.tag,
903
+ isActive: data.isActive
904
+ }
905
+ });
906
+ }
907
+
908
+ /**
909
+ * Get payee autocomplete suggestions
910
+ * Returns active payee names matching the query, sorted by recent usage. Used for transaction input autocomplete.
911
+ * @param data The data for the request.
912
+ * @param data.q Search query for payee name (partial match, case-insensitive)
913
+ * @param data.region Region code (cn, us, de)
914
+ * @param data.limit Maximum number of suggestions
915
+ * @returns PayeeAutocompleteResponseDto Autocomplete suggestions retrieved successfully
916
+ * @throws ApiError
917
+ */
918
+ public static payeeControllerAutocomplete(
919
+ data: PayeeControllerAutocompleteData
920
+ ): CancelablePromise<PayeeControllerAutocompleteResponse> {
921
+ return __request(OpenAPI, {
922
+ method: 'GET',
923
+ url: '/api/v1/bean/payees/autocomplete',
924
+ path: {
925
+ region: data.region
926
+ },
927
+ query: {
928
+ q: data.q,
929
+ limit: data.limit
930
+ }
931
+ });
932
+ }
933
+
934
+ /**
935
+ * Get top payees by usage
936
+ * Returns the most frequently used payees, sorted by use count. Used for statistics and analytics.
937
+ * @param data The data for the request.
938
+ * @param data.region Region code (cn, us, de)
939
+ * @param data.limit Maximum number of results
940
+ * @returns PayeeStatsResponseDto Top payees retrieved successfully
941
+ * @throws ApiError
942
+ */
943
+ public static payeeControllerGetTopPayees(
944
+ data: PayeeControllerGetTopPayeesData
945
+ ): CancelablePromise<PayeeControllerGetTopPayeesResponse> {
946
+ return __request(OpenAPI, {
947
+ method: 'GET',
948
+ url: '/api/v1/bean/payees/top',
949
+ path: {
950
+ region: data.region
951
+ },
952
+ query: {
953
+ limit: data.limit
954
+ }
955
+ });
956
+ }
957
+
958
+ /**
959
+ * Get payee by ID
960
+ * Returns a specific payee mapping by its UUID
961
+ * @param data The data for the request.
962
+ * @param data.id Payee UUID
963
+ * @param data.region Region code (cn, us, de)
964
+ * @returns PayeeResponseDto Payee retrieved successfully
965
+ * @throws ApiError
966
+ */
967
+ public static payeeControllerFindOne(
968
+ data: PayeeControllerFindOneData
969
+ ): CancelablePromise<PayeeControllerFindOneResponse> {
970
+ return __request(OpenAPI, {
971
+ method: 'GET',
972
+ url: '/api/v1/bean/payees/{id}',
973
+ path: {
974
+ id: data.id,
975
+ region: data.region
976
+ },
977
+ errors: {
978
+ 403: 'Payee belongs to another user',
979
+ 404: 'Payee not found'
980
+ }
981
+ });
982
+ }
983
+
984
+ /**
985
+ * @param data The data for the request.
986
+ * @param data.region Region code (cn, us, de)
987
+ * @returns unknown
988
+ * @throws ApiError
989
+ */
990
+ public static payeeController1(
991
+ data: PayeeController1Data
992
+ ): CancelablePromise<PayeeController1Response> {
993
+ return __request(OpenAPI, {
994
+ method: 'PUT',
995
+ url: '/api/v1/bean/payees/{id}',
996
+ path: {
997
+ region: data.region
998
+ }
999
+ });
1000
+ }
1001
+
1002
+ /**
1003
+ * @param data The data for the request.
1004
+ * @param data.region Region code (cn, us, de)
1005
+ * @returns void
1006
+ * @throws ApiError
1007
+ */
1008
+ public static payeeController2(
1009
+ data: PayeeController2Data
1010
+ ): CancelablePromise<PayeeController2Response> {
1011
+ return __request(OpenAPI, {
1012
+ method: 'DELETE',
1013
+ url: '/api/v1/bean/payees/{id}',
1014
+ path: {
1015
+ region: data.region
1016
+ }
1017
+ });
1018
+ }
1019
+ }
1020
+
1021
+ export class AdminPayeeProfilesService {
1022
+ /**
1023
+ * @param data The data for the request.
1024
+ * @param data.region Region code (cn, us, de)
1025
+ * @returns unknown
1026
+ * @throws ApiError
1027
+ */
1028
+ public static payeeProfileAdminController(
1029
+ data: PayeeProfileAdminControllerData
1030
+ ): CancelablePromise<PayeeProfileAdminControllerResponse> {
1031
+ return __request(OpenAPI, {
1032
+ method: 'POST',
1033
+ url: '/api/v1/admin/payee-profiles',
1034
+ path: {
1035
+ region: data.region
1036
+ }
1037
+ });
1038
+ }
1039
+
1040
+ /**
1041
+ * List payee profiles (Admin only)
1042
+ * Returns all payee profiles with optional filtering by category, country, verification status, etc.
1043
+ * @param data The data for the request.
1044
+ * @param data.region Region code (cn, us, de)
1045
+ * @param data.search Search term for canonical name and aliases (case-insensitive)
1046
+ * @param data.category Filter by category
1047
+ * @param data.country Filter by country (ISO 3166-1 alpha-2)
1048
+ * @param data.isActive Filter by active status (default: true - show only active)
1049
+ * @param data.verified Filter by verification status. true = verified only, false = unverified only
1050
+ * @param data.dataSource Filter by data source
1051
+ * @returns PayeeProfileListResponseDto Payee profiles retrieved successfully
1052
+ * @throws ApiError
1053
+ */
1054
+ public static payeeProfileAdminControllerFindAll(
1055
+ data: PayeeProfileAdminControllerFindAllData
1056
+ ): CancelablePromise<PayeeProfileAdminControllerFindAllResponse> {
1057
+ return __request(OpenAPI, {
1058
+ method: 'GET',
1059
+ url: '/api/v1/admin/payee-profiles',
1060
+ path: {
1061
+ region: data.region
1062
+ },
1063
+ query: {
1064
+ search: data.search,
1065
+ category: data.category,
1066
+ country: data.country,
1067
+ isActive: data.isActive,
1068
+ verified: data.verified,
1069
+ dataSource: data.dataSource
1070
+ },
1071
+ errors: {
1072
+ 403: 'Admin access required'
1073
+ }
1074
+ });
1075
+ }
1076
+
1077
+ /**
1078
+ * Get payee profile by ID (Admin only)
1079
+ * Returns a single payee profile by its ID.
1080
+ * @param data The data for the request.
1081
+ * @param data.id Payee profile ID (UUID)
1082
+ * @param data.region Region code (cn, us, de)
1083
+ * @returns PayeeProfileResponseDto Payee profile retrieved successfully
1084
+ * @throws ApiError
1085
+ */
1086
+ public static payeeProfileAdminControllerFindOne(
1087
+ data: PayeeProfileAdminControllerFindOneData
1088
+ ): CancelablePromise<PayeeProfileAdminControllerFindOneResponse> {
1089
+ return __request(OpenAPI, {
1090
+ method: 'GET',
1091
+ url: '/api/v1/admin/payee-profiles/{id}',
1092
+ path: {
1093
+ id: data.id,
1094
+ region: data.region
1095
+ },
1096
+ errors: {
1097
+ 403: 'Admin access required',
1098
+ 404: 'Payee profile not found'
1099
+ }
1100
+ });
1101
+ }
1102
+
1103
+ /**
1104
+ * @param data The data for the request.
1105
+ * @param data.region Region code (cn, us, de)
1106
+ * @returns unknown
1107
+ * @throws ApiError
1108
+ */
1109
+ public static payeeProfileAdminController1(
1110
+ data: PayeeProfileAdminController1Data
1111
+ ): CancelablePromise<PayeeProfileAdminController1Response> {
1112
+ return __request(OpenAPI, {
1113
+ method: 'PUT',
1114
+ url: '/api/v1/admin/payee-profiles/{id}',
1115
+ path: {
1116
+ region: data.region
1117
+ }
1118
+ });
1119
+ }
1120
+
1121
+ /**
1122
+ * @param data The data for the request.
1123
+ * @param data.region Region code (cn, us, de)
1124
+ * @returns void
1125
+ * @throws ApiError
1126
+ */
1127
+ public static payeeProfileAdminController2(
1128
+ data: PayeeProfileAdminController2Data
1129
+ ): CancelablePromise<PayeeProfileAdminController2Response> {
1130
+ return __request(OpenAPI, {
1131
+ method: 'DELETE',
1132
+ url: '/api/v1/admin/payee-profiles/{id}',
1133
+ path: {
1134
+ region: data.region
1135
+ }
1136
+ });
1137
+ }
1138
+
1139
+ /**
1140
+ * @param data The data for the request.
1141
+ * @param data.region Region code (cn, us, de)
1142
+ * @returns unknown
1143
+ * @throws ApiError
1144
+ */
1145
+ public static payeeProfileAdminController3(
1146
+ data: PayeeProfileAdminController3Data
1147
+ ): CancelablePromise<PayeeProfileAdminController3Response> {
1148
+ return __request(OpenAPI, {
1149
+ method: 'POST',
1150
+ url: '/api/v1/admin/payee-profiles/{id}/verify',
1151
+ path: {
1152
+ region: data.region
1153
+ }
1154
+ });
1155
+ }
1156
+
1157
+ /**
1158
+ * @param data The data for the request.
1159
+ * @param data.region Region code (cn, us, de)
1160
+ * @returns unknown
1161
+ * @throws ApiError
1162
+ */
1163
+ public static payeeProfileAdminController4(
1164
+ data: PayeeProfileAdminController4Data
1165
+ ): CancelablePromise<PayeeProfileAdminController4Response> {
1166
+ return __request(OpenAPI, {
1167
+ method: 'DELETE',
1168
+ url: '/api/v1/admin/payee-profiles/{id}/verify',
1169
+ path: {
1170
+ region: data.region
1171
+ }
1172
+ });
1173
+ }
1174
+ }
1175
+
1176
+ export class BeanCommoditiesService {
1177
+ /**
1178
+ * @param data The data for the request.
1179
+ * @param data.region Region code (cn, us, de)
1180
+ * @returns unknown
1181
+ * @throws ApiError
1182
+ */
1183
+ public static commodityController(
1184
+ data: CommodityControllerData
1185
+ ): CancelablePromise<CommodityControllerResponse> {
1186
+ return __request(OpenAPI, {
1187
+ method: 'POST',
1188
+ url: '/api/v1/{region}/bean/commodities',
1189
+ path: {
1190
+ region: data.region
1191
+ }
1192
+ });
1193
+ }
1194
+
1195
+ /**
1196
+ * List user commodities
1197
+ * Returns all commodity definitions for the authenticated user with optional filtering
1198
+ * @param data The data for the request.
1199
+ * @param data.region Region code (cn, us, de)
1200
+ * @param data.search Search term for symbol or metadata fields (partial match). Searches symbol and metadata.name.
1201
+ * @param data.symbol Filter by exact symbol match
1202
+ * @returns CommodityListResponseDto Commodities retrieved successfully
1203
+ * @throws ApiError
1204
+ */
1205
+ public static commodityControllerFindAll(
1206
+ data: CommodityControllerFindAllData
1207
+ ): CancelablePromise<CommodityControllerFindAllResponse> {
1208
+ return __request(OpenAPI, {
1209
+ method: 'GET',
1210
+ url: '/api/v1/{region}/bean/commodities',
1211
+ path: {
1212
+ region: data.region
1213
+ },
1214
+ query: {
1215
+ search: data.search,
1216
+ symbol: data.symbol
1217
+ }
1218
+ });
1219
+ }
1220
+
1221
+ /**
1222
+ * Get commodity by symbol
1223
+ * Returns a specific commodity definition by its symbol
1224
+ * @param data The data for the request.
1225
+ * @param data.symbol Commodity symbol
1226
+ * @param data.region Region code (cn, us, de)
1227
+ * @returns CommodityResponseDto Commodity retrieved successfully
1228
+ * @throws ApiError
1229
+ */
1230
+ public static commodityControllerFindOne(
1231
+ data: CommodityControllerFindOneData
1232
+ ): CancelablePromise<CommodityControllerFindOneResponse> {
1233
+ return __request(OpenAPI, {
1234
+ method: 'GET',
1235
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
1236
+ path: {
1237
+ symbol: data.symbol,
1238
+ region: data.region
1239
+ },
1240
+ errors: {
1241
+ 404: 'Commodity not found'
1242
+ }
1243
+ });
1244
+ }
1245
+
1246
+ /**
1247
+ * @param data The data for the request.
1248
+ * @param data.region Region code (cn, us, de)
1249
+ * @returns unknown
1250
+ * @throws ApiError
1251
+ */
1252
+ public static commodityController1(
1253
+ data: CommodityController1Data
1254
+ ): CancelablePromise<CommodityController1Response> {
1255
+ return __request(OpenAPI, {
1256
+ method: 'PUT',
1257
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
1258
+ path: {
1259
+ region: data.region
1260
+ }
1261
+ });
1262
+ }
1263
+
1264
+ /**
1265
+ * @param data The data for the request.
1266
+ * @param data.region Region code (cn, us, de)
1267
+ * @returns void
1268
+ * @throws ApiError
1269
+ */
1270
+ public static commodityController2(
1271
+ data: CommodityController2Data
1272
+ ): CancelablePromise<CommodityController2Response> {
1273
+ return __request(OpenAPI, {
1274
+ method: 'DELETE',
1275
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
1276
+ path: {
1277
+ region: data.region
1278
+ }
1279
+ });
1280
+ }
1281
+
1282
+ /**
1283
+ * @param data The data for the request.
1284
+ * @param data.region Region code (cn, us, de)
1285
+ * @returns unknown
1286
+ * @throws ApiError
1287
+ */
1288
+ public static commodityController3(
1289
+ data: CommodityController3Data
1290
+ ): CancelablePromise<CommodityController3Response> {
1291
+ return __request(OpenAPI, {
1292
+ method: 'POST',
1293
+ url: '/api/v1/{region}/bean/commodities/{symbol}/ensure',
1294
+ path: {
1295
+ region: data.region
1296
+ }
1297
+ });
1298
+ }
1299
+
1300
+ /**
1301
+ * @param data The data for the request.
1302
+ * @param data.region Region code (cn, us, de)
1303
+ * @returns unknown
1304
+ * @throws ApiError
1305
+ */
1306
+ public static commodityController4(
1307
+ data: CommodityController4Data
1308
+ ): CancelablePromise<CommodityController4Response> {
1309
+ return __request(OpenAPI, {
1310
+ method: 'POST',
1311
+ url: '/api/v1/{region}/bean/commodities/bulk',
1312
+ path: {
1313
+ region: data.region
1314
+ }
1315
+ });
1316
+ }
1317
+ }
1318
+
1319
+ export class RecurringRulesService {
1320
+ /**
1321
+ * @param data The data for the request.
1322
+ * @param data.region Region code (cn, us, de)
1323
+ * @returns unknown
1324
+ * @throws ApiError
1325
+ */
1326
+ public static recurringRuleController(
1327
+ data: RecurringRuleControllerData
1328
+ ): CancelablePromise<RecurringRuleControllerResponse> {
1329
+ return __request(OpenAPI, {
1330
+ method: 'POST',
1331
+ url: '/api/v1/{region}/bean/recurring-rules',
1332
+ path: {
1333
+ region: data.region
1334
+ }
1335
+ });
1336
+ }
1337
+
1338
+ /**
1339
+ * List recurring rules
1340
+ * Returns all recurring rules for the authenticated user with optional filtering
1341
+ * @param data The data for the request.
1342
+ * @param data.region Region code (cn, us, de)
1343
+ * @param data.isActive Filter by active status
1344
+ * @param data.frequency Filter by frequency (WEEKLY, MONTHLY, etc.)
1345
+ * @param data.hasAutoCreate Filter by autoCreate enabled
1346
+ * @returns RecurringRuleResponseDto Rules retrieved successfully
1347
+ * @throws ApiError
1348
+ */
1349
+ public static recurringRuleControllerFindAll(
1350
+ data: RecurringRuleControllerFindAllData
1351
+ ): CancelablePromise<RecurringRuleControllerFindAllResponse> {
1352
+ return __request(OpenAPI, {
1353
+ method: 'GET',
1354
+ url: '/api/v1/{region}/bean/recurring-rules',
1355
+ path: {
1356
+ region: data.region
1357
+ },
1358
+ query: {
1359
+ isActive: data.isActive,
1360
+ frequency: data.frequency,
1361
+ hasAutoCreate: data.hasAutoCreate
1362
+ }
1363
+ });
1364
+ }
1365
+
1366
+ /**
1367
+ * @param data The data for the request.
1368
+ * @param data.region Region code (cn, us, de)
1369
+ * @returns unknown
1370
+ * @throws ApiError
1371
+ */
1372
+ public static recurringRuleController1(
1373
+ data: RecurringRuleController1Data
1374
+ ): CancelablePromise<RecurringRuleController1Response> {
1375
+ return __request(OpenAPI, {
1376
+ method: 'POST',
1377
+ url: '/api/v1/{region}/bean/recurring-rules/from-transaction/{transactionId}',
1378
+ path: {
1379
+ region: data.region
1380
+ }
1381
+ });
1382
+ }
1383
+
1384
+ /**
1385
+ * Get recurring rule by ID
1386
+ * Returns a specific recurring rule with its details
1387
+ * @param data The data for the request.
1388
+ * @param data.id Rule ID
1389
+ * @param data.region Region code (cn, us, de)
1390
+ * @returns RecurringRuleResponseDto Rule retrieved successfully
1391
+ * @throws ApiError
1392
+ */
1393
+ public static recurringRuleControllerFindOne(
1394
+ data: RecurringRuleControllerFindOneData
1395
+ ): CancelablePromise<RecurringRuleControllerFindOneResponse> {
1396
+ return __request(OpenAPI, {
1397
+ method: 'GET',
1398
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
1399
+ path: {
1400
+ id: data.id,
1401
+ region: data.region
1402
+ },
1403
+ errors: {
1404
+ 404: 'Rule not found'
1405
+ }
1406
+ });
1407
+ }
1408
+
1409
+ /**
1410
+ * @param data The data for the request.
1411
+ * @param data.region Region code (cn, us, de)
1412
+ * @returns unknown
1413
+ * @throws ApiError
1414
+ */
1415
+ public static recurringRuleController2(
1416
+ data: RecurringRuleController2Data
1417
+ ): CancelablePromise<RecurringRuleController2Response> {
1418
+ return __request(OpenAPI, {
1419
+ method: 'PATCH',
1420
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
1421
+ path: {
1422
+ region: data.region
1423
+ }
1424
+ });
1425
+ }
1426
+
1427
+ /**
1428
+ * @param data The data for the request.
1429
+ * @param data.region Region code (cn, us, de)
1430
+ * @returns void
1431
+ * @throws ApiError
1432
+ */
1433
+ public static recurringRuleController3(
1434
+ data: RecurringRuleController3Data
1435
+ ): CancelablePromise<RecurringRuleController3Response> {
1436
+ return __request(OpenAPI, {
1437
+ method: 'DELETE',
1438
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
1439
+ path: {
1440
+ region: data.region
1441
+ }
1442
+ });
1443
+ }
1444
+
1445
+ /**
1446
+ * Get rule with statistics
1447
+ * Returns a rule with pending/overdue counts and next expected date
1448
+ * @param data The data for the request.
1449
+ * @param data.id Rule ID
1450
+ * @param data.region Region code (cn, us, de)
1451
+ * @returns RecurringRuleWithStatsResponseDto Rule with stats retrieved successfully
1452
+ * @throws ApiError
1453
+ */
1454
+ public static recurringRuleControllerGetWithStats(
1455
+ data: RecurringRuleControllerGetWithStatsData
1456
+ ): CancelablePromise<RecurringRuleControllerGetWithStatsResponse> {
1457
+ return __request(OpenAPI, {
1458
+ method: 'GET',
1459
+ url: '/api/v1/{region}/bean/recurring-rules/{id}/stats',
1460
+ path: {
1461
+ id: data.id,
1462
+ region: data.region
1463
+ },
1464
+ errors: {
1465
+ 404: 'Rule not found'
1466
+ }
1467
+ });
1468
+ }
1469
+ }
1470
+
1471
+ export class ExpectedTransactionsService {
1472
+ /**
1473
+ * List expected transactions
1474
+ * Returns expected transactions for the authenticated user with optional filtering
1475
+ * @param data The data for the request.
1476
+ * @param data.region Region code (cn, us, de)
1477
+ * @param data.ruleId Filter by recurring rule ID
1478
+ * @param data.status Filter by status (PENDING, COMPLETED, SKIPPED)
1479
+ * @param data.fromDate Filter by date range start (YYYY-MM-DD)
1480
+ * @param data.toDate Filter by date range end (YYYY-MM-DD)
1481
+ * @returns ExpectedTransactionListResponseDto Expected transactions retrieved successfully
1482
+ * @throws ApiError
1483
+ */
1484
+ public static expectedTransactionControllerFindAll(
1485
+ data: ExpectedTransactionControllerFindAllData
1486
+ ): CancelablePromise<ExpectedTransactionControllerFindAllResponse> {
1487
+ return __request(OpenAPI, {
1488
+ method: 'GET',
1489
+ url: '/api/v1/{region}/bean/expected-transactions',
1490
+ path: {
1491
+ region: data.region
1492
+ },
1493
+ query: {
1494
+ ruleId: data.ruleId,
1495
+ status: data.status,
1496
+ fromDate: data.fromDate,
1497
+ toDate: data.toDate
1498
+ }
1499
+ });
1500
+ }
1501
+
1502
+ /**
1503
+ * List overdue expected transactions
1504
+ * Returns all overdue expected transactions (PENDING past tolerance)
1505
+ * @param data The data for the request.
1506
+ * @param data.region Region code (cn, us, de)
1507
+ * @returns ExpectedTransactionListResponseDto Overdue transactions retrieved successfully
1508
+ * @throws ApiError
1509
+ */
1510
+ public static expectedTransactionControllerFindOverdue(
1511
+ data: ExpectedTransactionControllerFindOverdueData
1512
+ ): CancelablePromise<ExpectedTransactionControllerFindOverdueResponse> {
1513
+ return __request(OpenAPI, {
1514
+ method: 'GET',
1515
+ url: '/api/v1/{region}/bean/expected-transactions/overdue',
1516
+ path: {
1517
+ region: data.region
1518
+ }
1519
+ });
1520
+ }
1521
+
1522
+ /**
1523
+ * Get expected transaction by ID
1524
+ * Returns a specific expected transaction with rule details
1525
+ * @param data The data for the request.
1526
+ * @param data.id Expected transaction ID
1527
+ * @param data.region Region code (cn, us, de)
1528
+ * @returns ExpectedTransactionResponseDto Expected transaction retrieved successfully
1529
+ * @throws ApiError
1530
+ */
1531
+ public static expectedTransactionControllerFindOne(
1532
+ data: ExpectedTransactionControllerFindOneData
1533
+ ): CancelablePromise<ExpectedTransactionControllerFindOneResponse> {
1534
+ return __request(OpenAPI, {
1535
+ method: 'GET',
1536
+ url: '/api/v1/{region}/bean/expected-transactions/{id}',
1537
+ path: {
1538
+ id: data.id,
1539
+ region: data.region
1540
+ },
1541
+ errors: {
1542
+ 404: 'Expected transaction not found'
1543
+ }
1544
+ });
1545
+ }
1546
+
1547
+ /**
1548
+ * @param data The data for the request.
1549
+ * @param data.region Region code (cn, us, de)
1550
+ * @returns unknown
1551
+ * @throws ApiError
1552
+ */
1553
+ public static expectedTransactionController(
1554
+ data: ExpectedTransactionControllerData
1555
+ ): CancelablePromise<ExpectedTransactionControllerResponse> {
1556
+ return __request(OpenAPI, {
1557
+ method: 'POST',
1558
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
1559
+ path: {
1560
+ region: data.region
1561
+ }
1562
+ });
1563
+ }
1564
+
1565
+ /**
1566
+ * @param data The data for the request.
1567
+ * @param data.region Region code (cn, us, de)
1568
+ * @returns unknown
1569
+ * @throws ApiError
1570
+ */
1571
+ public static expectedTransactionController1(
1572
+ data: ExpectedTransactionController1Data
1573
+ ): CancelablePromise<ExpectedTransactionController1Response> {
1574
+ return __request(OpenAPI, {
1575
+ method: 'DELETE',
1576
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
1577
+ path: {
1578
+ region: data.region
1579
+ }
1580
+ });
1581
+ }
1582
+
1583
+ /**
1584
+ * @param data The data for the request.
1585
+ * @param data.region Region code (cn, us, de)
1586
+ * @returns unknown
1587
+ * @throws ApiError
1588
+ */
1589
+ public static expectedTransactionController2(
1590
+ data: ExpectedTransactionController2Data
1591
+ ): CancelablePromise<ExpectedTransactionController2Response> {
1592
+ return __request(OpenAPI, {
1593
+ method: 'POST',
1594
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
1595
+ path: {
1596
+ region: data.region
1597
+ }
1598
+ });
1599
+ }
1600
+
1601
+ /**
1602
+ * @param data The data for the request.
1603
+ * @param data.region Region code (cn, us, de)
1604
+ * @returns unknown
1605
+ * @throws ApiError
1606
+ */
1607
+ public static expectedTransactionController3(
1608
+ data: ExpectedTransactionController3Data
1609
+ ): CancelablePromise<ExpectedTransactionController3Response> {
1610
+ return __request(OpenAPI, {
1611
+ method: 'DELETE',
1612
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
1613
+ path: {
1614
+ region: data.region
1615
+ }
1616
+ });
1617
+ }
1618
+
1619
+ /**
1620
+ * @param data The data for the request.
1621
+ * @param data.region Region code (cn, us, de)
1622
+ * @returns unknown
1623
+ * @throws ApiError
1624
+ */
1625
+ public static expectedTransactionController4(
1626
+ data: ExpectedTransactionController4Data
1627
+ ): CancelablePromise<ExpectedTransactionController4Response> {
1628
+ return __request(OpenAPI, {
1629
+ method: 'POST',
1630
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/enter',
1631
+ path: {
1632
+ region: data.region
1633
+ }
1634
+ });
1635
+ }
1636
+ }
1637
+
1638
+ export class RecurringForecastService {
1639
+ /**
1640
+ * Get cash flow forecast
1641
+ * Returns predicted outflows for the next N months based on active recurring rules
1642
+ * @param data The data for the request.
1643
+ * @param data.region Region code (cn, us, de)
1644
+ * @param data.months Number of months to forecast (1-12, default 3)
1645
+ * @returns ForecastResponseDto Forecast retrieved successfully
1646
+ * @throws ApiError
1647
+ */
1648
+ public static forecastControllerGetForecast(
1649
+ data: ForecastControllerGetForecastData
1650
+ ): CancelablePromise<ForecastControllerGetForecastResponse> {
1651
+ return __request(OpenAPI, {
1652
+ method: 'GET',
1653
+ url: '/api/v1/{region}/bean/recurring/forecast',
1654
+ path: {
1655
+ region: data.region
1656
+ },
1657
+ query: {
1658
+ months: data.months
1659
+ }
1660
+ });
1661
+ }
1662
+ }
1663
+
1664
+ export class BeanTransactionRulesService {
1665
+ /**
1666
+ * @param data The data for the request.
1667
+ * @param data.region Region code (cn, us, de)
1668
+ * @returns unknown
1669
+ * @throws ApiError
1670
+ */
1671
+ public static transactionRuleController(
1672
+ data: TransactionRuleControllerData
1673
+ ): CancelablePromise<TransactionRuleControllerResponse> {
1674
+ return __request(OpenAPI, {
1675
+ method: 'POST',
1676
+ url: '/api/v1/{region}/bean/transaction-rules',
1677
+ path: {
1678
+ region: data.region
1679
+ }
1680
+ });
1681
+ }
1682
+
1683
+ /**
1684
+ * Get all transaction rules for user
1685
+ * @param data The data for the request.
1686
+ * @param data.region Region code (cn, us, de)
1687
+ * @param data.limit Max results per page (default: 20, max: 100)
1688
+ * @param data.offset Pagination offset (default: 0)
1689
+ * @param data.enabled Filter by enabled status
1690
+ * @param data.learningSource Filter by learning source. Omit this parameter or pass empty string to get manually created rules (learningSource is null in database).
1691
+ * @param data.autoApplyEnabled Filter by auto-apply status
1692
+ * @returns TransactionRuleListResponseDto List of rules
1693
+ * @throws ApiError
1694
+ */
1695
+ public static transactionRuleControllerList(
1696
+ data: TransactionRuleControllerListData
1697
+ ): CancelablePromise<TransactionRuleControllerListResponse> {
1698
+ return __request(OpenAPI, {
1699
+ method: 'GET',
1700
+ url: '/api/v1/{region}/bean/transaction-rules',
1701
+ path: {
1702
+ region: data.region
1703
+ },
1704
+ query: {
1705
+ limit: data.limit,
1706
+ offset: data.offset,
1707
+ enabled: data.enabled,
1708
+ learningSource: data.learningSource,
1709
+ autoApplyEnabled: data.autoApplyEnabled
1710
+ },
1711
+ errors: {
1712
+ 401: 'Unauthorized'
1713
+ }
1714
+ });
1715
+ }
1716
+
1717
+ /**
1718
+ * Validate transaction rule configuration
1719
+ * @param data The data for the request.
1720
+ * @param data.region Region code (cn, us, de)
1721
+ * @param data.requestBody
1722
+ * @returns ValidateRuleResponseDto Validation result
1723
+ * @throws ApiError
1724
+ */
1725
+ public static transactionRuleControllerValidate(
1726
+ data: TransactionRuleControllerValidateData
1727
+ ): CancelablePromise<TransactionRuleControllerValidateResponse> {
1728
+ return __request(OpenAPI, {
1729
+ method: 'POST',
1730
+ url: '/api/v1/{region}/bean/transaction-rules/validate',
1731
+ path: {
1732
+ region: data.region
1733
+ },
1734
+ body: data.requestBody,
1735
+ mediaType: 'application/json',
1736
+ errors: {
1737
+ 401: 'Unauthorized'
1738
+ }
1739
+ });
1740
+ }
1741
+
1742
+ /**
1743
+ * @param data The data for the request.
1744
+ * @param data.region Region code (cn, us, de)
1745
+ * @returns unknown
1746
+ * @throws ApiError
1747
+ */
1748
+ public static transactionRuleController1(
1749
+ data: TransactionRuleController1Data
1750
+ ): CancelablePromise<TransactionRuleController1Response> {
1751
+ return __request(OpenAPI, {
1752
+ method: 'POST',
1753
+ url: '/api/v1/{region}/bean/transaction-rules/bulk',
1754
+ path: {
1755
+ region: data.region
1756
+ }
1757
+ });
1758
+ }
1759
+
1760
+ /**
1761
+ * Export transaction rules
1762
+ * @param data The data for the request.
1763
+ * @param data.format Export format (currently only JSON supported)
1764
+ * @param data.region Region code (cn, us, de)
1765
+ * @returns ExportRulesResponseDto Exported rules
1766
+ * @throws ApiError
1767
+ */
1768
+ public static transactionRuleControllerExport(
1769
+ data: TransactionRuleControllerExportData
1770
+ ): CancelablePromise<TransactionRuleControllerExportResponse> {
1771
+ return __request(OpenAPI, {
1772
+ method: 'GET',
1773
+ url: '/api/v1/{region}/bean/transaction-rules/export/{format}',
1774
+ path: {
1775
+ format: data.format,
1776
+ region: data.region
1777
+ },
1778
+ errors: {
1779
+ 400: 'Unsupported format',
1780
+ 401: 'Unauthorized'
1781
+ }
1782
+ });
1783
+ }
1784
+
1785
+ /**
1786
+ * Get transaction rule statistics
1787
+ * @param data The data for the request.
1788
+ * @param data.period Statistics time period
1789
+ * @param data.region Region code (cn, us, de)
1790
+ * @returns RuleStatisticsResponseDto Rule statistics
1791
+ * @throws ApiError
1792
+ */
1793
+ public static transactionRuleControllerGetStatistics(
1794
+ data: TransactionRuleControllerGetStatisticsData
1795
+ ): CancelablePromise<TransactionRuleControllerGetStatisticsResponse> {
1796
+ return __request(OpenAPI, {
1797
+ method: 'GET',
1798
+ url: '/api/v1/{region}/bean/transaction-rules/statistics/{period}',
1799
+ path: {
1800
+ period: data.period,
1801
+ region: data.region
1802
+ },
1803
+ errors: {
1804
+ 401: 'Unauthorized'
1805
+ }
1806
+ });
1807
+ }
1808
+
1809
+ /**
1810
+ * Get transaction rule detail
1811
+ * @param data The data for the request.
1812
+ * @param data.ruleId Rule ID
1813
+ * @param data.region Region code (cn, us, de)
1814
+ * @returns TransactionRuleResponseDto Rule details
1815
+ * @throws ApiError
1816
+ */
1817
+ public static transactionRuleControllerGetDetail(
1818
+ data: TransactionRuleControllerGetDetailData
1819
+ ): CancelablePromise<TransactionRuleControllerGetDetailResponse> {
1820
+ return __request(OpenAPI, {
1821
+ method: 'GET',
1822
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1823
+ path: {
1824
+ ruleId: data.ruleId,
1825
+ region: data.region
1826
+ },
1827
+ errors: {
1828
+ 401: 'Unauthorized',
1829
+ 403: 'Forbidden - not owner of rule',
1830
+ 404: 'Rule not found'
1831
+ }
1832
+ });
1833
+ }
1834
+
1835
+ /**
1836
+ * @param data The data for the request.
1837
+ * @param data.region Region code (cn, us, de)
1838
+ * @returns unknown
1839
+ * @throws ApiError
1840
+ */
1841
+ public static transactionRuleController2(
1842
+ data: TransactionRuleController2Data
1843
+ ): CancelablePromise<TransactionRuleController2Response> {
1844
+ return __request(OpenAPI, {
1845
+ method: 'PUT',
1846
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1847
+ path: {
1848
+ region: data.region
1849
+ }
1850
+ });
1851
+ }
1852
+
1853
+ /**
1854
+ * @param data The data for the request.
1855
+ * @param data.region Region code (cn, us, de)
1856
+ * @returns void
1857
+ * @throws ApiError
1858
+ */
1859
+ public static transactionRuleController3(
1860
+ data: TransactionRuleController3Data
1861
+ ): CancelablePromise<TransactionRuleController3Response> {
1862
+ return __request(OpenAPI, {
1863
+ method: 'DELETE',
1864
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1865
+ path: {
1866
+ region: data.region
1867
+ }
1868
+ });
1869
+ }
1870
+
1871
+ /**
1872
+ * Test rule matching
1873
+ * @param data The data for the request.
1874
+ * @param data.ruleId Rule ID to test
1875
+ * @param data.region Region code (cn, us, de)
1876
+ * @param data.requestBody
1877
+ * @returns TestRuleResponseDto Test result
1878
+ * @throws ApiError
1879
+ */
1880
+ public static transactionRuleControllerTest(
1881
+ data: TransactionRuleControllerTestData
1882
+ ): CancelablePromise<TransactionRuleControllerTestResponse> {
1883
+ return __request(OpenAPI, {
1884
+ method: 'POST',
1885
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}/test',
1886
+ path: {
1887
+ ruleId: data.ruleId,
1888
+ region: data.region
1889
+ },
1890
+ body: data.requestBody,
1891
+ mediaType: 'application/json',
1892
+ errors: {
1893
+ 401: 'Unauthorized',
1894
+ 403: 'Forbidden - not owner of rule',
1895
+ 404: 'Rule not found'
1896
+ }
1897
+ });
1898
+ }
1899
+ }
1900
+
1901
+ export class UsersService {
1902
+ /**
1903
+ * Delete own user account
1904
+ * @param data The data for the request.
1905
+ * @param data.region Region code (cn, us, de)
1906
+ * @param data.requestBody
1907
+ * @returns void User deleted successfully
1908
+ * @throws ApiError
1909
+ */
1910
+ public static userControllerDeleteOwnUser(
1911
+ data: UserControllerDeleteOwnUserData
1912
+ ): CancelablePromise<UserControllerDeleteOwnUserResponse> {
1913
+ return __request(OpenAPI, {
1914
+ method: 'DELETE',
1915
+ url: '/api/v1/users',
1916
+ path: {
1917
+ region: data.region
1918
+ },
1919
+ body: data.requestBody,
1920
+ mediaType: 'application/json',
1921
+ errors: {
1922
+ 403: 'Invalid access token'
1923
+ }
1924
+ });
1925
+ }
1926
+
1927
+ /**
1928
+ * Get current authenticated user
1929
+ * @param data The data for the request.
1930
+ * @param data.acceptLanguage
1931
+ * @param data.region Region code (cn, us, de)
1932
+ * @returns unknown User retrieved successfully
1933
+ * @throws ApiError
1934
+ */
1935
+ public static userControllerGetUser(
1936
+ data: UserControllerGetUserData
1937
+ ): CancelablePromise<UserControllerGetUserResponse> {
1938
+ return __request(OpenAPI, {
1939
+ method: 'GET',
1940
+ url: '/api/v1/users',
1941
+ path: {
1942
+ region: data.region
1943
+ },
1944
+ headers: {
1945
+ 'accept-language': data.acceptLanguage
1946
+ }
1947
+ });
1948
+ }
1949
+
1950
+ /**
1951
+ * Sign up new user
1952
+ * Create a new account with auto-generated access token. Protected by Cloudflare Turnstile to prevent automated signup (when enabled).
1953
+ * @param data The data for the request.
1954
+ * @param data.region Region code (cn, us, de)
1955
+ * @param data.requestBody
1956
+ * @returns unknown User created successfully
1957
+ * @throws ApiError
1958
+ */
1959
+ public static userControllerSignupUser(
1960
+ data: UserControllerSignupUserData
1961
+ ): CancelablePromise<UserControllerSignupUserResponse> {
1962
+ return __request(OpenAPI, {
1963
+ method: 'POST',
1964
+ url: '/api/v1/users',
1965
+ path: {
1966
+ region: data.region
1967
+ },
1968
+ body: data.requestBody,
1969
+ mediaType: 'application/json',
1970
+ errors: {
1971
+ 400: 'Invalid Turnstile token (when Turnstile is enabled)',
1972
+ 403: 'User signup is disabled'
1973
+ }
1974
+ });
1975
+ }
1976
+
1977
+ /**
1978
+ * Delete user by ID (admin only)
1979
+ * @param data The data for the request.
1980
+ * @param data.id User ID to delete
1981
+ * @param data.region Region code (cn, us, de)
1982
+ * @returns void User deleted successfully
1983
+ * @throws ApiError
1984
+ */
1985
+ public static userControllerDeleteUser(
1986
+ data: UserControllerDeleteUserData
1987
+ ): CancelablePromise<UserControllerDeleteUserResponse> {
1988
+ return __request(OpenAPI, {
1989
+ method: 'DELETE',
1990
+ url: '/api/v1/users/{id}',
1991
+ path: {
1992
+ id: data.id,
1993
+ region: data.region
1994
+ },
1995
+ errors: {
1996
+ 403: 'Cannot delete own account or insufficient permissions'
1997
+ }
1998
+ });
1999
+ }
2000
+
2001
+ /**
2002
+ * Get user info by user ID
2003
+ * @param data The data for the request.
2004
+ * @param data.id User ID
2005
+ * @param data.region Region code (cn, us, de)
2006
+ * @returns unknown User info retrieved successfully
2007
+ * @throws ApiError
2008
+ */
2009
+ public static userControllerGetUserInfo(
2010
+ data: UserControllerGetUserInfoData
2011
+ ): CancelablePromise<UserControllerGetUserInfoResponse> {
2012
+ return __request(OpenAPI, {
2013
+ method: 'GET',
2014
+ url: '/api/v1/users/{id}/info',
2015
+ path: {
2016
+ id: data.id,
2017
+ region: data.region
2018
+ },
2019
+ errors: {
2020
+ 403: 'Cannot access other user info without admin permission'
2021
+ }
2022
+ });
2023
+ }
2024
+
2025
+ /**
2026
+ * Update user settings
2027
+ * @param data The data for the request.
2028
+ * @param data.region Region code (cn, us, de)
2029
+ * @param data.requestBody
2030
+ * @returns unknown Settings updated successfully
2031
+ * @throws ApiError
2032
+ */
2033
+ public static userControllerUpdateUserSetting(
2034
+ data: UserControllerUpdateUserSettingData
2035
+ ): CancelablePromise<UserControllerUpdateUserSettingResponse> {
2036
+ return __request(OpenAPI, {
2037
+ method: 'PUT',
2038
+ url: '/api/v1/users/setting',
2039
+ path: {
2040
+ region: data.region
2041
+ },
2042
+ body: data.requestBody,
2043
+ mediaType: 'application/json',
2044
+ errors: {
2045
+ 403: 'Insufficient permissions'
2046
+ }
2047
+ });
2048
+ }
2049
+
2050
+ /**
2051
+ * Get all user settings paginated (admin only)
2052
+ * @param data The data for the request.
2053
+ * @param data.pageNo Page number
2054
+ * @param data.pageSize Page size
2055
+ * @param data.region Region code (cn, us, de)
2056
+ * @returns unknown Settings list retrieved successfully
2057
+ * @throws ApiError
2058
+ */
2059
+ public static userControllerGetAllUserSettingsByPage(
2060
+ data: UserControllerGetAllUserSettingsByPageData
2061
+ ): CancelablePromise<UserControllerGetAllUserSettingsByPageResponse> {
2062
+ return __request(OpenAPI, {
2063
+ method: 'GET',
2064
+ url: '/api/v1/users/settings-by-page',
2065
+ path: {
2066
+ region: data.region
2067
+ },
2068
+ query: {
2069
+ pageNo: data.pageNo,
2070
+ pageSize: data.pageSize
2071
+ }
2072
+ });
2073
+ }
2074
+
2075
+ /**
2076
+ * Get asset and liability summary for current user
2077
+ * @param data The data for the request.
2078
+ * @param data.region Region code (cn, us, de)
2079
+ * @returns unknown Summary retrieved successfully
2080
+ * @throws ApiError
2081
+ */
2082
+ public static userControllerGetAssetLiabilitySummary(
2083
+ data: UserControllerGetAssetLiabilitySummaryData
2084
+ ): CancelablePromise<UserControllerGetAssetLiabilitySummaryResponse> {
2085
+ return __request(OpenAPI, {
2086
+ method: 'GET',
2087
+ url: '/api/v1/users/asset-liability-summary',
2088
+ path: {
2089
+ region: data.region
2090
+ }
2091
+ });
2092
+ }
2093
+ }
2094
+
2095
+ export class PropertiesService {
2096
+ /**
2097
+ * Get all system properties
2098
+ * @param data The data for the request.
2099
+ * @param data.region Region code (cn, us, de)
2100
+ * @returns unknown Properties retrieved successfully
2101
+ * @throws ApiError
2102
+ */
2103
+ public static propertyControllerGetAll(
2104
+ data: PropertyControllerGetAllData
2105
+ ): CancelablePromise<PropertyControllerGetAllResponse> {
2106
+ return __request(OpenAPI, {
2107
+ method: 'GET',
2108
+ url: '/api/v1/admin/properties',
2109
+ path: {
2110
+ region: data.region
2111
+ },
2112
+ errors: {
2113
+ 401: 'Unauthorized',
2114
+ 403: 'Forbidden - insufficient permissions'
2115
+ }
2116
+ });
2117
+ }
2118
+
2119
+ /**
2120
+ * Get property by key
2121
+ * @param data The data for the request.
2122
+ * @param data.key Property key
2123
+ * @param data.region Region code (cn, us, de)
2124
+ * @returns unknown Property retrieved successfully
2125
+ * @throws ApiError
2126
+ */
2127
+ public static propertyControllerGetByKey(
2128
+ data: PropertyControllerGetByKeyData
2129
+ ): CancelablePromise<PropertyControllerGetByKeyResponse> {
2130
+ return __request(OpenAPI, {
2131
+ method: 'GET',
2132
+ url: '/api/v1/admin/properties/{key}',
2133
+ path: {
2134
+ key: data.key,
2135
+ region: data.region
2136
+ },
2137
+ errors: {
2138
+ 401: 'Unauthorized',
2139
+ 403: 'Forbidden - insufficient permissions',
2140
+ 404: 'Property not found'
2141
+ }
2142
+ });
2143
+ }
2144
+
2145
+ /**
2146
+ * @param data The data for the request.
2147
+ * @param data.region Region code (cn, us, de)
2148
+ * @returns unknown
2149
+ * @throws ApiError
2150
+ */
2151
+ public static propertyController(
2152
+ data: PropertyControllerData
2153
+ ): CancelablePromise<PropertyControllerResponse> {
2154
+ return __request(OpenAPI, {
2155
+ method: 'PUT',
2156
+ url: '/api/v1/admin/properties/{key}',
2157
+ path: {
2158
+ region: data.region
2159
+ }
2160
+ });
2161
+ }
2162
+
2163
+ /**
2164
+ * @param data The data for the request.
2165
+ * @param data.region Region code (cn, us, de)
2166
+ * @returns void
2167
+ * @throws ApiError
2168
+ */
2169
+ public static propertyController1(
2170
+ data: PropertyController1Data
2171
+ ): CancelablePromise<PropertyController1Response> {
2172
+ return __request(OpenAPI, {
2173
+ method: 'DELETE',
2174
+ url: '/api/v1/admin/properties/{key}',
2175
+ path: {
2176
+ region: data.region
2177
+ }
2178
+ });
2179
+ }
2180
+ }
2181
+
2182
+ export class BeanImportService {
2183
+ /**
2184
+ * Import a bill file
2185
+ * Upload and process a bill file (CSV, PDF, OFX, etc.). The system automatically identifies the file type, extracts transactions, validates them, and stores only validated transactions to the database. Maximum file size: 50MB. Only 1 import per user at a time (concurrent imports rejected with 429).
2186
+ * @param data The data for the request.
2187
+ * @param data.region Region code (cn, us, de)
2188
+ * @param data.formData Bill file to import
2189
+ * @returns ImportResultDto File imported successfully
2190
+ * @throws ApiError
2191
+ */
2192
+ public static fileImportControllerImportFile(
2193
+ data: FileImportControllerImportFileData
2194
+ ): CancelablePromise<FileImportControllerImportFileResponse> {
2195
+ return __request(OpenAPI, {
2196
+ method: 'POST',
2197
+ url: '/api/v1/{region}/bean/import/file',
2198
+ path: {
2199
+ region: data.region
2200
+ },
2201
+ formData: data.formData,
2202
+ mediaType: 'multipart/form-data',
2203
+ errors: {
2204
+ 400: 'Bad request - file-format-unsupported or file-import-failed',
2205
+ 413: 'Payload too large - file exceeds 50MB limit',
2206
+ 429: 'Too many requests - user already has import in progress',
2207
+ 500: 'Internal server error - DATABASE_ERROR'
2208
+ }
2209
+ });
2210
+ }
2211
+
2212
+ /**
2213
+ * Identify file type
2214
+ * Upload a file to check if it can be processed by any registered importer. Does not perform actual import - useful for pre-validation. Uses user-specific importer configuration.
2215
+ * @param data The data for the request.
2216
+ * @param data.region Region code (cn, us, de)
2217
+ * @param data.formData File to identify
2218
+ * @returns IdentifyResultDto File identification result
2219
+ * @throws ApiError
2220
+ */
2221
+ public static fileImportControllerIdentifyFile(
2222
+ data: FileImportControllerIdentifyFileData
2223
+ ): CancelablePromise<FileImportControllerIdentifyFileResponse> {
2224
+ return __request(OpenAPI, {
2225
+ method: 'POST',
2226
+ url: '/api/v1/{region}/bean/import/identify',
2227
+ path: {
2228
+ region: data.region
2229
+ },
2230
+ formData: data.formData,
2231
+ mediaType: 'multipart/form-data',
2232
+ errors: {
2233
+ 400: 'Bad request - No file uploaded'
2234
+ }
2235
+ });
2236
+ }
2237
+
2238
+ /**
2239
+ * Get importer configuration
2240
+ * Returns the current configuration for the specified importer. Creates default configuration if none exists.
2241
+ * @param data The data for the request.
2242
+ * @param data.importerId Importer identifier. Supported importers: alipay, alipay-web, wechat, boc, boc-credit, ccb, cmb, cmbc, cmbc-credit, icbc, icbc-credit, hsbc-hk
2243
+ * @param data.region Region code (cn, us, de)
2244
+ * @returns ImporterConfigDto Configuration retrieved successfully
2245
+ * @throws ApiError
2246
+ */
2247
+ public static importerConfigControllerGetConfig(
2248
+ data: ImporterConfigControllerGetConfigData
2249
+ ): CancelablePromise<ImporterConfigControllerGetConfigResponse> {
2250
+ return __request(OpenAPI, {
2251
+ method: 'GET',
2252
+ url: '/api/v1/{region}/bean/import/config/{importerId}',
2253
+ path: {
2254
+ importerId: data.importerId,
2255
+ region: data.region
2256
+ },
2257
+ errors: {
2258
+ 400: 'Invalid input - Unsupported importer',
2259
+ 401: 'Unauthorized - Authentication required'
2260
+ }
2261
+ });
2262
+ }
2263
+
2264
+ /**
2265
+ * @param data The data for the request.
2266
+ * @param data.region Region code (cn, us, de)
2267
+ * @returns unknown
2268
+ * @throws ApiError
2269
+ */
2270
+ public static importerConfigController(
2271
+ data: ImporterConfigControllerData
2272
+ ): CancelablePromise<ImporterConfigControllerResponse> {
2273
+ return __request(OpenAPI, {
2274
+ method: 'PUT',
2275
+ url: '/api/v1/{region}/bean/import/config/{importerId}',
2276
+ path: {
2277
+ region: data.region
2278
+ }
2279
+ });
2280
+ }
2281
+
2282
+ /**
2283
+ * @param data The data for the request.
2284
+ * @param data.region Region code (cn, us, de)
2285
+ * @returns unknown
2286
+ * @throws ApiError
2287
+ */
2288
+ public static importerConfigController1(
2289
+ data: ImporterConfigController1Data
2290
+ ): CancelablePromise<ImporterConfigController1Response> {
2291
+ return __request(OpenAPI, {
2292
+ method: 'POST',
2293
+ url: '/api/v1/{region}/bean/import/config/{importerId}/reset',
2294
+ path: {
2295
+ region: data.region
2296
+ }
2297
+ });
2298
+ }
2299
+ }
2300
+
2301
+ export class ProviderSyncService {
2302
+ /**
2303
+ * Sync transactions from financial data provider
2304
+ *
2305
+ * Accepts raw transactions from external financial data providers, transforms them to Beancount format, and processes them through the ingestion pipeline.
2306
+ *
2307
+ * **Supported Providers:**
2308
+ * - **plaid**: Plaid API (US, Canada, Europe)
2309
+ * - **teller**: Teller API (US)
2310
+ * - **truelayer**: TrueLayer Open Banking (UK, Europe)
2311
+ * - **gocardless**: GoCardless Bank Account Data (Europe)
2312
+ * - **simplefin**: SimpleFIN (Self-hosted)
2313
+ * - **yodlee**: Yodlee (Global)
2314
+ * - **beancount-direct**: Beancount format transactions
2315
+ * - **parsed-bill**: Client-side parsed bill transactions
2316
+ *
2317
+ * **Processing Flow:**
2318
+ * 1. Transform raw data via provider adapter
2319
+ * 2. Validate transaction format
2320
+ * 3. Deduplicate using originalId
2321
+ * 4. Classify using rule engine
2322
+ * 5. Route low-confidence to Review Center
2323
+ * 6. Persist validated transactions
2324
+ *
2325
+ * @param data The data for the request.
2326
+ * @param data.providerName Provider name
2327
+ * @param data.region Region code
2328
+ * @param data.requestBody
2329
+ * @returns ProviderSyncResponseDto Sync completed successfully
2330
+ * @throws ApiError
2331
+ */
2332
+ public static providerSyncControllerSync(
2333
+ data: ProviderSyncControllerSyncData
2334
+ ): CancelablePromise<ProviderSyncControllerSyncResponse> {
2335
+ return __request(OpenAPI, {
2336
+ method: 'POST',
2337
+ url: '/api/v1/{region}/bean/import/provider/{providerName}/sync',
2338
+ path: {
2339
+ providerName: data.providerName,
2340
+ region: data.region
2341
+ },
2342
+ body: data.requestBody,
2343
+ mediaType: 'application/json',
2344
+ errors: {
2345
+ 400: 'Invalid request data',
2346
+ 401: 'Missing or invalid authentication',
2347
+ 404: 'Provider not supported'
2348
+ }
2349
+ });
2350
+ }
2351
+
2352
+ /**
2353
+ * Get supported providers
2354
+ * Returns a list of all providers supported by the sync endpoint.
2355
+ * @param data The data for the request.
2356
+ * @param data.region Region code (cn, us, de)
2357
+ * @returns SupportedProvidersResponseDto List of supported providers
2358
+ * @throws ApiError
2359
+ */
2360
+ public static providerSyncControllerGetSupportedProviders(
2361
+ data: ProviderSyncControllerGetSupportedProvidersData
2362
+ ): CancelablePromise<ProviderSyncControllerGetSupportedProvidersResponse> {
2363
+ return __request(OpenAPI, {
2364
+ method: 'GET',
2365
+ url: '/api/v1/{region}/bean/import/provider/supported',
2366
+ path: {
2367
+ region: data.region
2368
+ },
2369
+ errors: {
2370
+ 401: 'Missing or invalid authentication'
2371
+ }
2372
+ });
2373
+ }
2374
+
2375
+ /**
2376
+ * Check if provider is supported
2377
+ * Returns whether a specific provider is supported.
2378
+ * @param data The data for the request.
2379
+ * @param data.providerName Provider name to check
2380
+ * @param data.region Region code (cn, us, de)
2381
+ * @returns unknown Provider support status
2382
+ * @throws ApiError
2383
+ */
2384
+ public static providerSyncControllerIsProviderSupported(
2385
+ data: ProviderSyncControllerIsProviderSupportedData
2386
+ ): CancelablePromise<ProviderSyncControllerIsProviderSupportedResponse> {
2387
+ return __request(OpenAPI, {
2388
+ method: 'GET',
2389
+ url: '/api/v1/{region}/bean/import/provider/{providerName}/supported',
2390
+ path: {
2391
+ providerName: data.providerName,
2392
+ region: data.region
2393
+ },
2394
+ errors: {
2395
+ 401: 'Missing or invalid authentication'
2396
+ }
2397
+ });
2398
+ }
2399
+ }
2400
+
2401
+ export class ImportTelemetryService {
2402
+ /**
2403
+ * Receive anonymous parser failure telemetry
2404
+ * @param data The data for the request.
2405
+ * @param data.region Region code (cn, us, de)
2406
+ * @param data.requestBody
2407
+ * @returns unknown Telemetry report received
2408
+ * @throws ApiError
2409
+ */
2410
+ public static telemetryControllerReportTelemetry(
2411
+ data: TelemetryControllerReportTelemetryData
2412
+ ): CancelablePromise<TelemetryControllerReportTelemetryResponse> {
2413
+ return __request(OpenAPI, {
2414
+ method: 'POST',
2415
+ url: '/api/v1/{region}/bean/import/parser-telemetry',
2416
+ path: {
2417
+ region: data.region
2418
+ },
2419
+ body: data.requestBody,
2420
+ mediaType: 'application/json',
2421
+ errors: {
2422
+ 401: 'Unauthorized'
2423
+ }
2424
+ });
2425
+ }
2426
+ }
2427
+
2428
+ export class BeanNlpService {
2429
+ /**
2430
+ * Process natural language input
2431
+ * Parse natural language text (Chinese/English) describing a transaction. Supports multi-turn dialogue for collecting missing information. When confidence < 0.75, returns "confirm" action requiring user verification. User can reply with confirmation words (确认/yes/ok) or provide corrections. Examples: "yesterday Starbucks spent 35 yuan", "today lunch 28 yuan", "spent $50 at Walmart"
2432
+ * @param data The data for the request.
2433
+ * @param data.region Region code (cn, us, de)
2434
+ * @param data.requestBody Natural language transaction input with optional session ID
2435
+ * @returns NlpResponseDto NLP processing result - either created transaction or asking for more info
2436
+ * @throws ApiError
2437
+ */
2438
+ public static nlpControllerProcessNaturalLanguage(
2439
+ data: NlpControllerProcessNaturalLanguageData
2440
+ ): CancelablePromise<NlpControllerProcessNaturalLanguageResponse> {
2441
+ return __request(OpenAPI, {
2442
+ method: 'POST',
2443
+ url: '/api/v1/{region}/bean/nlp/process',
2444
+ path: {
2445
+ region: data.region
2446
+ },
2447
+ body: data.requestBody,
2448
+ mediaType: 'application/json',
2449
+ errors: {
2450
+ 400: 'Invalid input',
2451
+ 401: 'Unauthorized'
2452
+ }
2453
+ });
2454
+ }
2455
+
2456
+ /**
2457
+ * Clear dialogue session
2458
+ * Clear the current NLP dialogue session. Use this to cancel an ongoing multi-turn dialogue.
2459
+ * @param data The data for the request.
2460
+ * @param data.region Region code (cn, us, de)
2461
+ * @param data.sessionId Specific session ID to clear (defaults to user session)
2462
+ * @returns void Session cleared successfully
2463
+ * @throws ApiError
2464
+ */
2465
+ public static nlpControllerClearSession(
2466
+ data: NlpControllerClearSessionData
2467
+ ): CancelablePromise<NlpControllerClearSessionResponse> {
2468
+ return __request(OpenAPI, {
2469
+ method: 'DELETE',
2470
+ url: '/api/v1/{region}/bean/nlp/session',
2471
+ path: {
2472
+ region: data.region
2473
+ },
2474
+ query: {
2475
+ sessionId: data.sessionId
2476
+ },
2477
+ errors: {
2478
+ 401: 'Unauthorized'
2479
+ }
2480
+ });
2481
+ }
2482
+
2483
+ /**
2484
+ * Get current session state
2485
+ * Get the current NLP dialogue session state. Useful for debugging and displaying session context in UI.
2486
+ * @param data The data for the request.
2487
+ * @param data.region Region code (cn, us, de)
2488
+ * @param data.sessionId Specific session ID to get (defaults to user session)
2489
+ * @returns unknown Current session state (or null if no active session)
2490
+ * @throws ApiError
2491
+ */
2492
+ public static nlpControllerGetSession(
2493
+ data: NlpControllerGetSessionData
2494
+ ): CancelablePromise<NlpControllerGetSessionResponse> {
2495
+ return __request(OpenAPI, {
2496
+ method: 'GET',
2497
+ url: '/api/v1/{region}/bean/nlp/session',
2498
+ path: {
2499
+ region: data.region
2500
+ },
2501
+ query: {
2502
+ sessionId: data.sessionId
2503
+ },
2504
+ errors: {
2505
+ 401: 'Unauthorized'
2506
+ }
2507
+ });
2508
+ }
2509
+ }
2510
+
2511
+ export class BeanPlatformsService {
2512
+ /**
2513
+ * Get all platforms with statistics
2514
+ * @param data The data for the request.
2515
+ * @param data.region Region code (cn, us, de)
2516
+ * @returns unknown List of platforms with binding and account counts
2517
+ * @throws ApiError
2518
+ */
2519
+ public static platformControllerFindAll(
2520
+ data: PlatformControllerFindAllData
2521
+ ): CancelablePromise<PlatformControllerFindAllResponse> {
2522
+ return __request(OpenAPI, {
2523
+ method: 'GET',
2524
+ url: '/api/v1/bean/platforms',
2525
+ path: {
2526
+ region: data.region
2527
+ }
2528
+ });
2529
+ }
2530
+
2531
+ /**
2532
+ * @param data The data for the request.
2533
+ * @param data.region Region code (cn, us, de)
2534
+ * @returns unknown
2535
+ * @throws ApiError
2536
+ */
2537
+ public static platformController(
2538
+ data: PlatformControllerData
2539
+ ): CancelablePromise<PlatformControllerResponse> {
2540
+ return __request(OpenAPI, {
2541
+ method: 'POST',
2542
+ url: '/api/v1/bean/platforms',
2543
+ path: {
2544
+ region: data.region
2545
+ }
2546
+ });
2547
+ }
2548
+
2549
+ /**
2550
+ * Get platform list for current user
2551
+ * @param data The data for the request.
2552
+ * @param data.region Region code (cn, us, de)
2553
+ * @returns unknown List of platforms with user binding status
2554
+ * @throws ApiError
2555
+ */
2556
+ public static platformControllerGetPlatformList(
2557
+ data: PlatformControllerGetPlatformListData
2558
+ ): CancelablePromise<PlatformControllerGetPlatformListResponse> {
2559
+ return __request(OpenAPI, {
2560
+ method: 'GET',
2561
+ url: '/api/v1/bean/platforms/list',
2562
+ path: {
2563
+ region: data.region
2564
+ }
2565
+ });
2566
+ }
2567
+
2568
+ /**
2569
+ * @param data The data for the request.
2570
+ * @param data.region Region code (cn, us, de)
2571
+ * @returns unknown
2572
+ * @throws ApiError
2573
+ */
2574
+ public static platformController1(
2575
+ data: PlatformController1Data
2576
+ ): CancelablePromise<PlatformController1Response> {
2577
+ return __request(OpenAPI, {
2578
+ method: 'PUT',
2579
+ url: '/api/v1/bean/platforms/{id}',
2580
+ path: {
2581
+ region: data.region
2582
+ }
2583
+ });
2584
+ }
2585
+
2586
+ /**
2587
+ * @param data The data for the request.
2588
+ * @param data.region Region code (cn, us, de)
2589
+ * @returns void
2590
+ * @throws ApiError
2591
+ */
2592
+ public static platformController2(
2593
+ data: PlatformController2Data
2594
+ ): CancelablePromise<PlatformController2Response> {
2595
+ return __request(OpenAPI, {
2596
+ method: 'DELETE',
2597
+ url: '/api/v1/bean/platforms/{id}',
2598
+ path: {
2599
+ region: data.region
2600
+ }
2601
+ });
2602
+ }
2603
+ }
2604
+
2605
+ export class SymbolsService {
2606
+ /**
2607
+ * Search for symbols
2608
+ * Search symbols by query with optional filters for asset class, area, and indices
2609
+ * @param data The data for the request.
2610
+ * @param data.region Region code (cn, us, de)
2611
+ * @param data.includeIndices Include index symbols in results
2612
+ * @param data.assetSubClass Asset sub-class filter
2613
+ * @param data.assetClass Asset class filter
2614
+ * @param data.area Geographic area filter (e.g., CN, US)
2615
+ * @param data.query Search query string
2616
+ * @returns unknown Symbols found successfully
2617
+ * @throws ApiError
2618
+ */
2619
+ public static symbolControllerLookupSymbol(
2620
+ data: SymbolControllerLookupSymbolData
2621
+ ): CancelablePromise<SymbolControllerLookupSymbolResponse> {
2622
+ return __request(OpenAPI, {
2623
+ method: 'GET',
2624
+ url: '/api/v1/market/symbols/lookup',
2625
+ path: {
2626
+ region: data.region
2627
+ },
2628
+ query: {
2629
+ includeIndices: data.includeIndices,
2630
+ assetSubClass: data.assetSubClass,
2631
+ assetClass: data.assetClass,
2632
+ area: data.area,
2633
+ query: data.query
2634
+ },
2635
+ errors: {
2636
+ 400: 'Invalid query parameters'
2637
+ }
2638
+ });
2639
+ }
2640
+
2641
+ /**
2642
+ * Get symbol data
2643
+ * Retrieve detailed symbol information including optional historical data
2644
+ * @param data The data for the request.
2645
+ * @param data.dataSource Data source provider
2646
+ * @param data.symbol Symbol identifier (e.g., ticker code)
2647
+ * @param data.region Region code (cn, us, de)
2648
+ * @param data.includeHistoricalData Include historical price data (0 or 1)
2649
+ * @returns unknown Symbol data retrieved successfully
2650
+ * @throws ApiError
2651
+ */
2652
+ public static symbolControllerGetSymbolData(
2653
+ data: SymbolControllerGetSymbolDataData
2654
+ ): CancelablePromise<SymbolControllerGetSymbolDataResponse> {
2655
+ return __request(OpenAPI, {
2656
+ method: 'GET',
2657
+ url: '/api/v1/market/symbols/{dataSource}/{symbol}',
2658
+ path: {
2659
+ dataSource: data.dataSource,
2660
+ symbol: data.symbol,
2661
+ region: data.region
2662
+ },
2663
+ query: {
2664
+ includeHistoricalData: data.includeHistoricalData
2665
+ },
2666
+ errors: {
2667
+ 400: 'Invalid data source',
2668
+ 404: 'Symbol not found'
2669
+ }
2670
+ });
2671
+ }
2672
+
2673
+ /**
2674
+ * Gather symbol data for specific date
2675
+ * Retrieve historical symbol data for a specific date
2676
+ * @param data The data for the request.
2677
+ * @param data.dataSource Data source provider
2678
+ * @param data.dateString Date in ISO 8601 format (YYYY-MM-DD)
2679
+ * @param data.symbol Symbol identifier (e.g., ticker code)
2680
+ * @param data.region Region code (cn, us, de)
2681
+ * @returns unknown Historical data retrieved successfully
2682
+ * @throws ApiError
2683
+ */
2684
+ public static symbolControllerGatherSymbolForDate(
2685
+ data: SymbolControllerGatherSymbolForDateData
2686
+ ): CancelablePromise<SymbolControllerGatherSymbolForDateResponse> {
2687
+ return __request(OpenAPI, {
2688
+ method: 'GET',
2689
+ url: '/api/v1/market/symbols/{dataSource}/{symbol}/{dateString}',
2690
+ path: {
2691
+ dataSource: data.dataSource,
2692
+ dateString: data.dateString,
2693
+ symbol: data.symbol,
2694
+ region: data.region
2695
+ },
2696
+ errors: {
2697
+ 400: 'Invalid date format',
2698
+ 404: 'Symbol data not found for specified date'
2699
+ }
2700
+ });
2701
+ }
2702
+
2703
+ /**
2704
+ * @param data The data for the request.
2705
+ * @param data.region Region code (cn, us, de)
2706
+ * @returns unknown
2707
+ * @throws ApiError
2708
+ */
2709
+ public static symbolController(
2710
+ data: SymbolControllerData
2711
+ ): CancelablePromise<SymbolControllerResponse> {
2712
+ return __request(OpenAPI, {
2713
+ method: 'PUT',
2714
+ url: '/api/v1/market/symbols/yahoo/batch-update',
2715
+ path: {
2716
+ region: data.region
2717
+ }
2718
+ });
2719
+ }
2720
+ }
2721
+
2722
+ export class DefaultService {
2723
+ /**
2724
+ * @param data The data for the request.
2725
+ * @param data.region Region code (cn, us, de)
2726
+ * @returns unknown
2727
+ * @throws ApiError
2728
+ */
2729
+ public static cacheControllerFlushCache(
2730
+ data: CacheControllerFlushCacheData
2731
+ ): CancelablePromise<CacheControllerFlushCacheResponse> {
2732
+ return __request(OpenAPI, {
2733
+ method: 'POST',
2734
+ url: '/api/v1/cache/flush',
2735
+ path: {
2736
+ region: data.region
2737
+ }
2738
+ });
2739
+ }
2740
+ }
2741
+
2742
+ export class DashboardService {
2743
+ /**
2744
+ * Get net worth overview
2745
+ * Returns total net worth with breakdown of assets and liabilities
2746
+ * @param data The data for the request.
2747
+ * @param data.region Region code (cn, us, de)
2748
+ * @param data.date Date for balance calculation (ISO 8601 format)
2749
+ * @returns NetWorthResponseDto Net worth retrieved successfully
2750
+ * @throws ApiError
2751
+ */
2752
+ public static dashboardControllerGetNetWorth(
2753
+ data: DashboardControllerGetNetWorthData
2754
+ ): CancelablePromise<DashboardControllerGetNetWorthResponse> {
2755
+ return __request(OpenAPI, {
2756
+ method: 'GET',
2757
+ url: '/api/v1/{region}/dashboard/net-worth',
2758
+ path: {
2759
+ region: data.region
2760
+ },
2761
+ query: {
2762
+ date: data.date
2763
+ },
2764
+ errors: {
2765
+ 401: 'User not authenticated'
2766
+ }
2767
+ });
2768
+ }
2769
+
2770
+ /**
2771
+ * Get accounts grouped by platform
2772
+ * Returns accounts with balances grouped by financial platform
2773
+ * @param data The data for the request.
2774
+ * @param data.region Region code (cn, us, de)
2775
+ * @param data.groupBy Grouping strategy
2776
+ * @param data.date Date for balance calculation (ISO 8601 format)
2777
+ * @returns unknown Accounts retrieved successfully. Response type depends on groupBy parameter.
2778
+ * @throws ApiError
2779
+ */
2780
+ public static dashboardControllerGetAccounts(
2781
+ data: DashboardControllerGetAccountsData
2782
+ ): CancelablePromise<DashboardControllerGetAccountsResponse> {
2783
+ return __request(OpenAPI, {
2784
+ method: 'GET',
2785
+ url: '/api/v1/{region}/dashboard/accounts',
2786
+ path: {
2787
+ region: data.region
2788
+ },
2789
+ query: {
2790
+ groupBy: data.groupBy,
2791
+ date: data.date
2792
+ },
2793
+ errors: {
2794
+ 401: 'User not authenticated'
2795
+ }
2796
+ });
2797
+ }
2798
+
2799
+ /**
2800
+ * Get cash flow summary
2801
+ * Returns income, expenses, and savings for a monthly period
2802
+ * @param data The data for the request.
2803
+ * @param data.period Period in YYYY-MM format
2804
+ * @param data.region Region code (cn, us, de)
2805
+ * @returns CashFlowResponseDto Cash flow retrieved successfully
2806
+ * @throws ApiError
2807
+ */
2808
+ public static dashboardControllerGetCashFlow(
2809
+ data: DashboardControllerGetCashFlowData
2810
+ ): CancelablePromise<DashboardControllerGetCashFlowResponse> {
2811
+ return __request(OpenAPI, {
2812
+ method: 'GET',
2813
+ url: '/api/v1/{region}/dashboard/cash-flow',
2814
+ path: {
2815
+ region: data.region
2816
+ },
2817
+ query: {
2818
+ period: data.period
2819
+ },
2820
+ errors: {
2821
+ 400: 'Invalid period format',
2822
+ 401: 'User not authenticated'
2823
+ }
2824
+ });
2825
+ }
2826
+ }
2827
+
2828
+ export class ReportingService {
2829
+ /**
2830
+ * Get portfolio value trends
2831
+ *
2832
+ * Returns time series data of portfolio net worth.
2833
+ *
2834
+ * **Multi-currency Support:**
2835
+ * - `series[].byCurrency` - Currency breakdown for each data point
2836
+ * - `byCurrency` - Separate time series grouped by currency
2837
+ * - `warnings` - Exchange rate warnings if conversion failed
2838
+ *
2839
+ * **Parameters:**
2840
+ * - `period`: Time period (1m, 3m, 6m, 1y)
2841
+ * - `granularity`: Data granularity (day, week, month)
2842
+ *
2843
+ * @param data The data for the request.
2844
+ * @param data.region Region code (cn, us, de)
2845
+ * @param data.period Time period
2846
+ * @param data.granularity Data granularity
2847
+ * @returns PortfolioTrendsResponseDto Trends retrieved successfully
2848
+ * @throws ApiError
2849
+ */
2850
+ public static reportingControllerGetPortfolioTrends(
2851
+ data: ReportingControllerGetPortfolioTrendsData
2852
+ ): CancelablePromise<ReportingControllerGetPortfolioTrendsResponse> {
2853
+ return __request(OpenAPI, {
2854
+ method: 'GET',
2855
+ url: '/api/v1/{region}/reporting/portfolio/trends',
2856
+ path: {
2857
+ region: data.region
2858
+ },
2859
+ query: {
2860
+ period: data.period,
2861
+ granularity: data.granularity
2862
+ },
2863
+ errors: {
2864
+ 401: 'User not authenticated'
2865
+ }
2866
+ });
2867
+ }
2868
+
2869
+ /**
2870
+ * Generate portfolio snapshot
2871
+ *
2872
+ * Manually generate a portfolio snapshot for a specific date.
2873
+ *
2874
+ * **Multi-currency Support:**
2875
+ * - Fetches balances grouped by currency
2876
+ * - Uses user's baseCurrency setting for conversion
2877
+ * - Stores exchange rates and warnings
2878
+ *
2879
+ * **Use Cases:**
2880
+ * - Testing snapshot generation
2881
+ * - Force regeneration after data correction
2882
+ * - Initial setup for new users
2883
+ *
2884
+ * @param data The data for the request.
2885
+ * @param data.region Region code (cn, us, de)
2886
+ * @param data.requestBody Optional date (defaults to today)
2887
+ * @returns GenerateSnapshotResponse Snapshot generated successfully
2888
+ * @throws ApiError
2889
+ */
2890
+ public static reportingControllerGenerateSnapshot(
2891
+ data: ReportingControllerGenerateSnapshotData
2892
+ ): CancelablePromise<ReportingControllerGenerateSnapshotResponse> {
2893
+ return __request(OpenAPI, {
2894
+ method: 'POST',
2895
+ url: '/api/v1/{region}/reporting/snapshots/generate',
2896
+ path: {
2897
+ region: data.region
2898
+ },
2899
+ body: data.requestBody,
2900
+ mediaType: 'application/json',
2901
+ errors: {
2902
+ 400: 'Invalid date format',
2903
+ 401: 'User not authenticated'
2904
+ }
2905
+ });
2906
+ }
2907
+
2908
+ /**
2909
+ * Backfill portfolio snapshots
2910
+ *
2911
+ * Generate snapshots for a date range (historical data backfill).
2912
+ *
2913
+ * **Multi-currency Support:**
2914
+ * - Each snapshot includes multi-currency data
2915
+ * - Uses exchange rates available at generation time
2916
+ * - Warnings stored for missing exchange rates
2917
+ *
2918
+ * **Best Practices:**
2919
+ * - Use for initial setup after account configuration
2920
+ * - Run during low-traffic periods for large date ranges
2921
+ * - Existing snapshots are skipped (not regenerated)
2922
+ *
2923
+ * @param data The data for the request.
2924
+ * @param data.region Region code (cn, us, de)
2925
+ * @param data.requestBody
2926
+ * @returns BackfillSnapshotsResponse Backfill completed successfully
2927
+ * @throws ApiError
2928
+ */
2929
+ public static reportingControllerBackfillSnapshots(
2930
+ data: ReportingControllerBackfillSnapshotsData
2931
+ ): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
2932
+ return __request(OpenAPI, {
2933
+ method: 'POST',
2934
+ url: '/api/v1/{region}/reporting/snapshots/backfill',
2935
+ path: {
2936
+ region: data.region
2937
+ },
2938
+ body: data.requestBody,
2939
+ mediaType: 'application/json',
2940
+ errors: {
2941
+ 400: 'Invalid date format or range',
2942
+ 401: 'User not authenticated',
2943
+ 409: 'Backfill already in progress for this user'
2944
+ }
2945
+ });
2946
+ }
2947
+ }
2948
+
2949
+ export class ApiKeysService {
2950
+ /**
2951
+ * @param data The data for the request.
2952
+ * @param data.region Region code (cn, us, de)
2953
+ * @returns unknown
2954
+ * @throws ApiError
2955
+ */
2956
+ public static apiKeysController(
2957
+ data: ApiKeysControllerData
2958
+ ): CancelablePromise<ApiKeysControllerResponse> {
2959
+ return __request(OpenAPI, {
2960
+ method: 'POST',
2961
+ url: '/api/v1/auth/api-keys',
2962
+ path: {
2963
+ region: data.region
2964
+ }
2965
+ });
2966
+ }
2967
+ }
2968
+
2969
+ export class AuthService {
2970
+ /**
2971
+ * Anonymous login with access token
2972
+ * @param data The data for the request.
2973
+ * @param data.region Region code (cn, us, de)
2974
+ * @param data.requestBody
2975
+ * @returns unknown Login successful
2976
+ * @throws ApiError
2977
+ */
2978
+ public static authControllerAccessTokenLogin(
2979
+ data: AuthControllerAccessTokenLoginData
2980
+ ): CancelablePromise<AuthControllerAccessTokenLoginResponse> {
2981
+ return __request(OpenAPI, {
2982
+ method: 'POST',
2983
+ url: '/api/v1/auth/sessions/anonymous',
2984
+ path: {
2985
+ region: data.region
2986
+ },
2987
+ body: data.requestBody,
2988
+ mediaType: 'application/json',
2989
+ errors: {
2990
+ 401: 'Invalid access token'
2991
+ }
2992
+ });
2993
+ }
2994
+ }
2995
+
2996
+ export class ExchangeRateService {
2997
+ /**
2998
+ * Get exchange rate for currency pair
2999
+ * Retrieves historical exchange rate for a specific date and currency pair
3000
+ * @param data The data for the request.
3001
+ * @param data.symbol Currency pair symbol (e.g., USDCNY, EURUSD)
3002
+ * @param data.dateString Date in ISO format (YYYY-MM-DD)
3003
+ * @param data.region Region code (cn, us, de)
3004
+ * @returns unknown Exchange rate retrieved successfully
3005
+ * @throws ApiError
3006
+ */
3007
+ public static exchangeRateControllerGetExchangeRate(
3008
+ data: ExchangeRateControllerGetExchangeRateData
3009
+ ): CancelablePromise<ExchangeRateControllerGetExchangeRateResponse> {
3010
+ return __request(OpenAPI, {
3011
+ method: 'GET',
3012
+ url: '/api/v1/market/exchange-rates/{symbol}/{dateString}',
3013
+ path: {
3014
+ symbol: data.symbol,
3015
+ dateString: data.dateString,
3016
+ region: data.region
3017
+ },
3018
+ errors: {
3019
+ 404: 'Exchange rate not found for the specified currency pair and date'
3020
+ }
3021
+ });
3022
+ }
3023
+ }
3024
+
3025
+ export class HealthService {
3026
+ /**
3027
+ * Basic health check for K8s/load balancer probes
3028
+ * @param data The data for the request.
3029
+ * @param data.region Region code (cn, us, de)
3030
+ * @returns unknown Service is healthy
3031
+ * @throws ApiError
3032
+ */
3033
+ public static healthControllerGetHealth(
3034
+ data: HealthControllerGetHealthData
3035
+ ): CancelablePromise<HealthControllerGetHealthResponse> {
3036
+ return __request(OpenAPI, {
3037
+ method: 'GET',
3038
+ url: '/api/v1/health',
3039
+ path: {
3040
+ region: data.region
3041
+ },
3042
+ errors: {
3043
+ 503: 'Service unavailable'
3044
+ }
3045
+ });
3046
+ }
3047
+
3048
+ /**
3049
+ * Check database connection health
3050
+ * @param data The data for the request.
3051
+ * @param data.region Region code (cn, us, de)
3052
+ * @returns unknown Database is healthy
3053
+ * @throws ApiError
3054
+ */
3055
+ public static healthControllerCheckDatabase(
3056
+ data: HealthControllerCheckDatabaseData
3057
+ ): CancelablePromise<HealthControllerCheckDatabaseResponse> {
3058
+ return __request(OpenAPI, {
3059
+ method: 'GET',
3060
+ url: '/api/v1/health/database',
3061
+ path: {
3062
+ region: data.region
3063
+ },
3064
+ errors: {
3065
+ 503: 'Database unavailable'
3066
+ }
3067
+ });
3068
+ }
3069
+
3070
+ /**
3071
+ * Check Redis connection health
3072
+ * @param data The data for the request.
3073
+ * @param data.region Region code (cn, us, de)
3074
+ * @returns unknown Redis is healthy
3075
+ * @throws ApiError
3076
+ */
3077
+ public static healthControllerCheckRedis(
3078
+ data: HealthControllerCheckRedisData
3079
+ ): CancelablePromise<HealthControllerCheckRedisResponse> {
3080
+ return __request(OpenAPI, {
3081
+ method: 'GET',
3082
+ url: '/api/v1/health/redis',
3083
+ path: {
3084
+ region: data.region
3085
+ },
3086
+ errors: {
3087
+ 503: 'Redis unavailable'
3088
+ }
3089
+ });
3090
+ }
3091
+
3092
+ /**
3093
+ * Get status of all circuit breakers
3094
+ * @param data The data for the request.
3095
+ * @param data.region Region code (cn, us, de)
3096
+ * @returns unknown Circuit breaker status
3097
+ * @throws ApiError
3098
+ */
3099
+ public static healthControllerGetCircuitBreakersHealth(
3100
+ data: HealthControllerGetCircuitBreakersHealthData
3101
+ ): CancelablePromise<HealthControllerGetCircuitBreakersHealthResponse> {
3102
+ return __request(OpenAPI, {
3103
+ method: 'GET',
3104
+ url: '/api/v1/health/circuit-breakers',
3105
+ path: {
3106
+ region: data.region
3107
+ },
3108
+ errors: {
3109
+ 401: 'Unauthorized',
3110
+ 500: 'Internal error'
3111
+ }
3112
+ });
3113
+ }
3114
+
3115
+ /**
3116
+ * Reset a circuit breaker to CLOSED state
3117
+ * @param data The data for the request.
3118
+ * @param data.name Circuit breaker name to reset
3119
+ * @param data.region Region code (cn, us, de)
3120
+ * @returns unknown Circuit breaker reset successfully
3121
+ * @throws ApiError
3122
+ */
3123
+ public static healthControllerResetCircuitBreaker(
3124
+ data: HealthControllerResetCircuitBreakerData
3125
+ ): CancelablePromise<HealthControllerResetCircuitBreakerResponse> {
3126
+ return __request(OpenAPI, {
3127
+ method: 'POST',
3128
+ url: '/api/v1/health/circuit-breakers/{name}/reset',
3129
+ path: {
3130
+ name: data.name,
3131
+ region: data.region
3132
+ },
3133
+ errors: {
3134
+ 401: 'Unauthorized',
3135
+ 404: 'Circuit breaker not found'
3136
+ }
3137
+ });
3138
+ }
3139
+
3140
+ /**
3141
+ * Get health check metrics and statistics
3142
+ * @param data The data for the request.
3143
+ * @param data.region Region code (cn, us, de)
3144
+ * @returns unknown Health metrics
3145
+ * @throws ApiError
3146
+ */
3147
+ public static healthControllerGetMetrics(
3148
+ data: HealthControllerGetMetricsData
3149
+ ): CancelablePromise<HealthControllerGetMetricsResponse> {
3150
+ return __request(OpenAPI, {
3151
+ method: 'GET',
3152
+ url: '/api/v1/health/metrics',
3153
+ path: {
3154
+ region: data.region
3155
+ },
3156
+ errors: {
3157
+ 401: 'Unauthorized'
3158
+ }
3159
+ });
3160
+ }
3161
+
3162
+ /**
3163
+ * Check health of a specific data enhancer
3164
+ * @param data The data for the request.
3165
+ * @param data.name Data enhancer name
3166
+ * @param data.region Region code (cn, us, de)
3167
+ * @returns unknown Data enhancer is healthy
3168
+ * @throws ApiError
3169
+ */
3170
+ public static healthControllerGetHealthOfDataEnhancer(
3171
+ data: HealthControllerGetHealthOfDataEnhancerData
3172
+ ): CancelablePromise<HealthControllerGetHealthOfDataEnhancerResponse> {
3173
+ return __request(OpenAPI, {
3174
+ method: 'GET',
3175
+ url: '/api/v1/health/data-enhancer/{name}',
3176
+ path: {
3177
+ name: data.name,
3178
+ region: data.region
3179
+ },
3180
+ errors: {
3181
+ 401: 'Unauthorized',
3182
+ 503: 'Data enhancer unavailable'
3183
+ }
3184
+ });
3185
+ }
3186
+
3187
+ /**
3188
+ * Check health of all data providers
3189
+ * @param data The data for the request.
3190
+ * @param data.region Region code (cn, us, de)
3191
+ * @returns unknown Data providers health status
3192
+ * @throws ApiError
3193
+ */
3194
+ public static healthControllerCheckDataProviders(
3195
+ data: HealthControllerCheckDataProvidersData
3196
+ ): CancelablePromise<HealthControllerCheckDataProvidersResponse> {
3197
+ return __request(OpenAPI, {
3198
+ method: 'GET',
3199
+ url: '/api/v1/health/data-providers',
3200
+ path: {
3201
+ region: data.region
3202
+ },
3203
+ errors: {
3204
+ 401: 'Unauthorized',
3205
+ 503: 'Data providers check failed'
3206
+ }
3207
+ });
3208
+ }
3209
+
3210
+ /**
3211
+ * Check health of a specific data provider
3212
+ * @param data The data for the request.
3213
+ * @param data.dataSource Data source identifier
3214
+ * @param data.region Region code (cn, us, de)
3215
+ * @returns unknown Data provider is healthy
3216
+ * @throws ApiError
3217
+ */
3218
+ public static healthControllerGetHealthOfDataProvider(
3219
+ data: HealthControllerGetHealthOfDataProviderData
3220
+ ): CancelablePromise<HealthControllerGetHealthOfDataProviderResponse> {
3221
+ return __request(OpenAPI, {
3222
+ method: 'GET',
3223
+ url: '/api/v1/health/data-provider/{dataSource}',
3224
+ path: {
3225
+ dataSource: data.dataSource,
3226
+ region: data.region
3227
+ },
3228
+ errors: {
3229
+ 400: 'Invalid data source',
3230
+ 401: 'Unauthorized',
3231
+ 503: 'Data provider unavailable'
3232
+ }
3233
+ });
3234
+ }
3235
+ }
3236
+
3237
+ export class InfoService {
3238
+ /**
3239
+ * Get system information
3240
+ * @param data The data for the request.
3241
+ * @param data.region Region code (cn, us, de)
3242
+ * @returns unknown System information retrieved successfully
3243
+ * @throws ApiError
3244
+ */
3245
+ public static infoControllerGetInfo(
3246
+ data: InfoControllerGetInfoData
3247
+ ): CancelablePromise<InfoControllerGetInfoResponse> {
3248
+ return __request(OpenAPI, {
3249
+ method: 'GET',
3250
+ url: '/api/v1/system/info',
3251
+ path: {
3252
+ region: data.region
3253
+ }
3254
+ });
3255
+ }
3256
+ }
3257
+
3258
+ export class LogosService {
3259
+ /**
3260
+ * Get asset logo by data source and symbol
3261
+ * @param data The data for the request.
3262
+ * @param data.dataSource Data source identifier (e.g., YAHOO, COINGECKO)
3263
+ * @param data.symbol Asset symbol (e.g., AAPL, BTC)
3264
+ * @param data.region Region code (cn, us, de)
3265
+ * @returns unknown Logo image stream (favicon)
3266
+ * @throws ApiError
3267
+ */
3268
+ public static logoControllerGetLogoByDataSourceAndSymbol(
3269
+ data: LogoControllerGetLogoByDataSourceAndSymbolData
3270
+ ): CancelablePromise<LogoControllerGetLogoByDataSourceAndSymbolResponse> {
3271
+ return __request(OpenAPI, {
3272
+ method: 'GET',
3273
+ url: '/api/v1/market/logos/{dataSource}/{symbol}',
3274
+ path: {
3275
+ dataSource: data.dataSource,
3276
+ symbol: data.symbol,
3277
+ region: data.region
3278
+ },
3279
+ errors: {
3280
+ 401: 'Unauthorized',
3281
+ 404: 'Logo not found for the specified asset',
3282
+ 503: 'Service unavailable'
3283
+ }
3284
+ });
3285
+ }
3286
+
3287
+ /**
3288
+ * Get website favicon by URL
3289
+ * @param data The data for the request.
3290
+ * @param data.url Website URL to fetch favicon from
3291
+ * @param data.region Region code (cn, us, de)
3292
+ * @returns unknown Logo image stream (favicon)
3293
+ * @throws ApiError
3294
+ */
3295
+ public static logoControllerGetLogoByUrl(
3296
+ data: LogoControllerGetLogoByUrlData
3297
+ ): CancelablePromise<LogoControllerGetLogoByUrlResponse> {
3298
+ return __request(OpenAPI, {
3299
+ method: 'GET',
3300
+ url: '/api/v1/market/logos',
3301
+ path: {
3302
+ region: data.region
3303
+ },
3304
+ query: {
3305
+ url: data.url
3306
+ },
3307
+ errors: {
3308
+ 401: 'Unauthorized',
3309
+ 503: 'Service unavailable'
3310
+ }
3311
+ });
3312
+ }
3313
+ }
3314
+
3315
+ export class MarketDataService {
3316
+ /**
3317
+ * Get market data by symbol
3318
+ * Retrieves market data and asset profile for a given symbol and data source
3319
+ * @param data The data for the request.
3320
+ * @param data.dataSource Data source provider
3321
+ * @param data.symbol Symbol code
3322
+ * @param data.region Region code (cn, us, de)
3323
+ * @returns unknown Market data retrieved successfully
3324
+ * @throws ApiError
3325
+ */
3326
+ public static marketDataControllerGetMarketDataBySymbol(
3327
+ data: MarketDataControllerGetMarketDataBySymbolData
3328
+ ): CancelablePromise<MarketDataControllerGetMarketDataBySymbolResponse> {
3329
+ return __request(OpenAPI, {
3330
+ method: 'GET',
3331
+ url: '/api/v1/market-data/{dataSource}/{symbol}',
3332
+ path: {
3333
+ dataSource: data.dataSource,
3334
+ symbol: data.symbol,
3335
+ region: data.region
3336
+ },
3337
+ errors: {
3338
+ 403: 'Insufficient permissions to read market data',
3339
+ 404: 'Market data not found'
3340
+ }
3341
+ });
3342
+ }
3343
+
3344
+ /**
3345
+ * @param data The data for the request.
3346
+ * @param data.region Region code (cn, us, de)
3347
+ * @returns unknown
3348
+ * @throws ApiError
3349
+ */
3350
+ public static marketDataController(
3351
+ data: MarketDataControllerData
3352
+ ): CancelablePromise<MarketDataControllerResponse> {
3353
+ return __request(OpenAPI, {
3354
+ method: 'POST',
3355
+ url: '/api/v1/market-data/{dataSource}/{symbol}',
3356
+ path: {
3357
+ region: data.region
3358
+ }
3359
+ });
3360
+ }
3361
+ }