@firela/api-types 0.0.0-canary.a90ce0e4 → 0.0.0-canary.a9a40e6

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.
@@ -31,6 +31,8 @@ import type {
31
31
  TransactionControllerListResponse,
32
32
  TransactionControllerCreateBatchData,
33
33
  TransactionControllerCreateBatchResponse,
34
+ TransactionControllerBatchVoidData,
35
+ TransactionControllerBatchVoidResponse,
34
36
  TransactionControllerCorrectData,
35
37
  TransactionControllerCorrectResponse,
36
38
  TransactionControllerSuggestTagsData,
@@ -57,6 +59,48 @@ import type {
57
59
  ReviewControllerUndoResponse,
58
60
  ReviewControllerBatchResolveData,
59
61
  ReviewControllerBatchResolveResponse,
62
+ TransactionRuleControllerCreateData,
63
+ TransactionRuleControllerCreateResponse,
64
+ TransactionRuleControllerListData,
65
+ TransactionRuleControllerListResponse,
66
+ TransactionRuleControllerValidateData,
67
+ TransactionRuleControllerValidateResponse,
68
+ TransactionRuleControllerBulkCreateData,
69
+ TransactionRuleControllerBulkCreateResponse,
70
+ TransactionRuleControllerExportData,
71
+ TransactionRuleControllerExportResponse,
72
+ TransactionRuleControllerGetStatisticsData,
73
+ TransactionRuleControllerGetStatisticsResponse,
74
+ TransactionRuleControllerGetDetailData,
75
+ TransactionRuleControllerGetDetailResponse,
76
+ TransactionRuleControllerUpdateData,
77
+ TransactionRuleControllerUpdateResponse,
78
+ TransactionRuleControllerDeleteData,
79
+ TransactionRuleControllerDeleteResponse,
80
+ TransactionRuleControllerTestData,
81
+ TransactionRuleControllerTestResponse,
82
+ UserControllerDeleteOwnUserData,
83
+ UserControllerDeleteOwnUserResponse,
84
+ UserControllerGetUserData,
85
+ UserControllerGetUserResponse,
86
+ UserControllerSignupUserData,
87
+ UserControllerSignupUserResponse,
88
+ UserControllerDeleteUserData,
89
+ UserControllerDeleteUserResponse,
90
+ UserControllerGetUserInfoData,
91
+ UserControllerGetUserInfoResponse,
92
+ UserControllerUpdateUserSettingData,
93
+ UserControllerUpdateUserSettingResponse,
94
+ UserControllerGetAllUserSettingsByPageData,
95
+ UserControllerGetAllUserSettingsByPageResponse,
96
+ UserControllerGetAssetLiabilitySummaryResponse,
97
+ PropertyControllerGetAllResponse,
98
+ PropertyControllerGetByKeyData,
99
+ PropertyControllerGetByKeyResponse,
100
+ PropertyControllerUpdateData,
101
+ PropertyControllerUpdateResponse,
102
+ PropertyControllerDeleteData,
103
+ PropertyControllerDeleteResponse,
60
104
  PayeeControllerCreateData,
61
105
  PayeeControllerCreateResponse,
62
106
  PayeeControllerFindAllData,
@@ -85,6 +129,7 @@ import type {
85
129
  PayeeProfileAdminControllerVerifyResponse,
86
130
  PayeeProfileAdminControllerUnverifyData,
87
131
  PayeeProfileAdminControllerUnverifyResponse,
132
+ PayeeProfileControllerListActiveResponse,
88
133
  CommodityControllerCreateData,
89
134
  CommodityControllerCreateResponse,
90
135
  CommodityControllerFindAllData,
@@ -99,6 +144,14 @@ import type {
99
144
  CommodityControllerGetOrCreateResponse,
100
145
  CommodityControllerBulkCreateData,
101
146
  CommodityControllerBulkCreateResponse,
147
+ ReportingControllerGetPortfolioTrendsData,
148
+ ReportingControllerGetPortfolioTrendsResponse,
149
+ ReportingControllerGetCashFlowTrendsData,
150
+ ReportingControllerGetCashFlowTrendsResponse,
151
+ ReportingControllerGenerateSnapshotData,
152
+ ReportingControllerGenerateSnapshotResponse,
153
+ ReportingControllerBackfillSnapshotsData,
154
+ ReportingControllerBackfillSnapshotsResponse,
102
155
  PriceControllerCreateData,
103
156
  PriceControllerCreateResponse,
104
157
  PriceControllerFindAllData,
@@ -143,48 +196,8 @@ import type {
143
196
  ExpectedTransactionControllerEnterNowResponse,
144
197
  ForecastControllerGetForecastData,
145
198
  ForecastControllerGetForecastResponse,
146
- TransactionRuleControllerCreateData,
147
- TransactionRuleControllerCreateResponse,
148
- TransactionRuleControllerListData,
149
- TransactionRuleControllerListResponse,
150
- TransactionRuleControllerValidateData,
151
- TransactionRuleControllerValidateResponse,
152
- TransactionRuleControllerBulkCreateData,
153
- TransactionRuleControllerBulkCreateResponse,
154
- TransactionRuleControllerExportData,
155
- TransactionRuleControllerExportResponse,
156
- TransactionRuleControllerGetStatisticsData,
157
- TransactionRuleControllerGetStatisticsResponse,
158
- TransactionRuleControllerGetDetailData,
159
- TransactionRuleControllerGetDetailResponse,
160
- TransactionRuleControllerUpdateData,
161
- TransactionRuleControllerUpdateResponse,
162
- TransactionRuleControllerDeleteData,
163
- TransactionRuleControllerDeleteResponse,
164
- TransactionRuleControllerTestData,
165
- TransactionRuleControllerTestResponse,
166
- UserControllerDeleteOwnUserData,
167
- UserControllerDeleteOwnUserResponse,
168
- UserControllerGetUserData,
169
- UserControllerGetUserResponse,
170
- UserControllerSignupUserData,
171
- UserControllerSignupUserResponse,
172
- UserControllerDeleteUserData,
173
- UserControllerDeleteUserResponse,
174
- UserControllerGetUserInfoData,
175
- UserControllerGetUserInfoResponse,
176
- UserControllerUpdateUserSettingData,
177
- UserControllerUpdateUserSettingResponse,
178
- UserControllerGetAllUserSettingsByPageData,
179
- UserControllerGetAllUserSettingsByPageResponse,
180
- UserControllerGetAssetLiabilitySummaryResponse,
181
- PropertyControllerGetAllResponse,
182
- PropertyControllerGetByKeyData,
183
- PropertyControllerGetByKeyResponse,
184
- PropertyControllerUpdateData,
185
- PropertyControllerUpdateResponse,
186
- PropertyControllerDeleteData,
187
- PropertyControllerDeleteResponse,
199
+ CategoryCatalogControllerListData,
200
+ CategoryCatalogControllerListResponse,
188
201
  EventControllerCreateData,
189
202
  EventControllerCreateResponse,
190
203
  EventControllerFindAllData,
@@ -207,6 +220,7 @@ import type {
207
220
  ReconciliationControllerPadResponse,
208
221
  ReconciliationControllerHistoryData,
209
222
  ReconciliationControllerHistoryResponse,
223
+ ExportControllerExportBeancountData,
210
224
  ExportControllerExportBeancountResponse,
211
225
  FileImportControllerImportFileData,
212
226
  FileImportControllerImportFileResponse,
@@ -249,9 +263,12 @@ import type {
249
263
  PlatformControllerFindAllResponse,
250
264
  PlatformControllerCreateData,
251
265
  PlatformControllerCreateResponse,
266
+ PlatformControllerGetPlatformListData,
252
267
  PlatformControllerGetPlatformListResponse,
253
268
  PlatformControllerMatchPlatformsData,
254
269
  PlatformControllerMatchPlatformsResponse,
270
+ PlatformControllerGetPlatformStandardsData,
271
+ PlatformControllerGetPlatformStandardsResponse,
255
272
  PlatformControllerUpdateData,
256
273
  PlatformControllerUpdateResponse,
257
274
  PlatformControllerDeleteData,
@@ -264,19 +281,17 @@ import type {
264
281
  DashboardControllerGetCashFlowResponse,
265
282
  DashboardControllerGetExpensesData,
266
283
  DashboardControllerGetExpensesResponse,
284
+ DashboardControllerGetAdvisorContextData,
285
+ DashboardControllerGetAdvisorContextResponse,
267
286
  HoldingPnlControllerGetHoldingPnlData,
268
287
  HoldingPnlControllerGetHoldingPnlResponse,
269
- ReportingControllerGetPortfolioTrendsData,
270
- ReportingControllerGetPortfolioTrendsResponse,
271
- ReportingControllerGetCashFlowTrendsData,
272
- ReportingControllerGetCashFlowTrendsResponse,
273
- ReportingControllerGenerateSnapshotData,
274
- ReportingControllerGenerateSnapshotResponse,
275
- ReportingControllerBackfillSnapshotsData,
276
- ReportingControllerBackfillSnapshotsResponse,
277
288
  ApiKeysControllerCreateApiKeyResponse,
278
289
  AuthControllerAccessTokenLoginData,
279
290
  AuthControllerAccessTokenLoginResponse,
291
+ AuthControllerAdvisorTokenLoginData,
292
+ AuthControllerAdvisorTokenLoginResponse,
293
+ ParserContributionControllerCreateData,
294
+ ParserContributionControllerCreateResponse,
280
295
  CacheControllerFlushCacheResponse,
281
296
  ExchangeRateControllerGetExchangeRateData,
282
297
  ExchangeRateControllerGetExchangeRateResponse,
@@ -288,7 +303,11 @@ import type {
288
303
  HealthControllerResetCircuitBreakerData,
289
304
  HealthControllerResetCircuitBreakerResponse,
290
305
  HealthControllerGetMetricsResponse,
291
- InfoControllerGetInfoResponse
306
+ InfoControllerGetInfoResponse,
307
+ SymbolControllerSearchData,
308
+ SymbolControllerSearchResponse,
309
+ SymbolControllerGetQuoteData,
310
+ SymbolControllerGetQuoteResponse
292
311
  } from './types.gen';
293
312
 
294
313
  export class BeanAccountsService {
@@ -326,7 +345,7 @@ export class BeanAccountsService {
326
345
  * @param data.type Filter by account type
327
346
  * @param data.status Filter by status
328
347
  * @param data.isCustom Filter by custom (user-created) accounts only
329
- * @param data.search Search term for account path
348
+ * @param data.search Search term matched against account path and user-set display name (case-insensitive)
330
349
  * @param data.limit Maximum number of results
331
350
  * @param data.offset Number of results to skip
332
351
  * @returns AccountListResponseDto Accounts retrieved successfully
@@ -407,7 +426,7 @@ export class BeanAccountsService {
407
426
 
408
427
  /**
409
428
  * Delete account
410
- * Deletes an account (only if no transactions)
429
+ * Deletes an account (only if no active transactions; voided/superseded residual postings are cleaned up)
411
430
  * @param data The data for the request.
412
431
  * @param data.id Account UUID
413
432
  * @param data.region Region code for tenant context
@@ -426,7 +445,7 @@ export class BeanAccountsService {
426
445
  },
427
446
  errors: {
428
447
  404: 'Account not found',
429
- 409: 'Account has transactions and cannot be deleted'
448
+ 409: 'Account has active transactions and cannot be deleted'
430
449
  }
431
450
  });
432
451
  }
@@ -522,11 +541,11 @@ export class BeanAccountsService {
522
541
  export class BeanAccountStandardsService {
523
542
  /**
524
543
  * Get account templates
525
- * Returns predefined account templates for a region. Supports filtering by account type and search term.
544
+ * Returns predefined account templates for a region. Supports filtering by account type and search term. Not-yet-open region codes return the universal-only catalog (#759).
526
545
  * @param data The data for the request.
527
- * @param data.region Region code (cn, us, de)
546
+ * @param data.region Region code (any ISO alpha-2; not-yet-open codes return the universal-only catalog)
528
547
  * @param data.type Filter by account type
529
- * @param data.search Search term for path or description
548
+ * @param data.search Search term for path, description, aliases, or localized display name
530
549
  * @returns AccountStandardListResponseDto Account templates retrieved successfully
531
550
  * @throws ApiError
532
551
  */
@@ -550,7 +569,7 @@ export class BeanAccountStandardsService {
550
569
  * Get template metadata for an account path
551
570
  * Returns root type for a template path.
552
571
  * @param data The data for the request.
553
- * @param data.region Region code for tenant context
572
+ * @param data.region Region code for tenant context. Not-yet-open codes degrade to the universal-only catalog (#759)
554
573
  * @param data.path Account path to check
555
574
  * @returns TemplateMetadataResponseDto Template metadata retrieved successfully
556
575
  * @throws ApiError
@@ -572,9 +591,9 @@ export class BeanAccountStandardsService {
572
591
 
573
592
  /**
574
593
  * Get available regions with hierarchy
575
- * Returns supported regions with inheritance metadata
594
+ * Returns the full region catalog (every ISO 3166-1 entry) with an 'open' flag and inheritance metadata (#759)
576
595
  * @param data The data for the request.
577
- * @param data.region Region code for tenant context
596
+ * @param data.region Region code for tenant context. Not-yet-open codes degrade to the universal-only catalog (#759)
578
597
  * @returns RegionsMetadataResponseDto Regions metadata retrieved successfully
579
598
  * @throws ApiError
580
599
  */
@@ -631,10 +650,11 @@ export class BeanTransactionsService {
631
650
  * @param data.offset Number of items to skip (default: 0)
632
651
  * @param data.dateFrom Filter by start date (inclusive), format: YYYY-MM-DD
633
652
  * @param data.dateTo Filter by end date (inclusive), format: YYYY-MM-DD
634
- * @param data.status Filter by transaction status
653
+ * @param data.status Filter by transaction status: single value, comma-separated multi-value (e.g. VOIDED,SUPERSEDED), or ALL to include audit rows. Defaults to ACTIVE-only (ADR-0128; previously unfiltered — breaking change).
635
654
  * @param data.search Search in narration and payee fields (max 200 chars)
636
655
  * @param data.accountId Filter by account ID (transactions with postings to this account)
637
- * @param data.category Filter by ADR-0075 functional category (Group segment); matches any posting to an Expenses/Income account whose derived Group segment equals this value
656
+ * @param data.category Filter by ADR-0075 functional category (Group segment); matches any posting to an account whose derived Group segment equals this value. Must be accompanied by flow (ADR-0126).
657
+ * @param data.flow Required when category is present (400 otherwise) and vice versa (ADR-0126). Restricts the category account set to the flow root (income → Income:, expense → Expenses:) and drives the per-leg sign normalization of row viewpointAmount and the summary. OpenAPI cannot express conditional requiredness — the pairing is enforced at runtime.
638
658
  * @returns TransactionListResponseDto Transaction list
639
659
  * @throws ApiError
640
660
  */
@@ -655,7 +675,8 @@ export class BeanTransactionsService {
655
675
  status: data.status,
656
676
  search: data.search,
657
677
  accountId: data.accountId,
658
- category: data.category
678
+ category: data.category,
679
+ flow: data.flow
659
680
  },
660
681
  errors: {
661
682
  400: 'Validation failed',
@@ -692,6 +713,34 @@ export class BeanTransactionsService {
692
713
  });
693
714
  }
694
715
 
716
+ /**
717
+ * Batch void transactions
718
+ * Soft-deletes (VOIDED) a batch of the caller's ACTIVE transactions in one DB transaction. Voiding releases each row's importId dedup slot, so re-importing the same file after an undo batch-void imports every row again instead of skipping them as duplicates.
719
+ * @param data The data for the request.
720
+ * @param data.region Region code for tenant context
721
+ * @param data.requestBody Batch void request (1-500 unique transaction IDs)
722
+ * @returns BatchVoidResultDto Batch void result: count of rows voided plus ids not found / no longer ACTIVE
723
+ * @throws ApiError
724
+ */
725
+ public static transactionControllerBatchVoid(
726
+ data: TransactionControllerBatchVoidData
727
+ ): CancelablePromise<TransactionControllerBatchVoidResponse> {
728
+ return __request(OpenAPI, {
729
+ method: 'POST',
730
+ url: '/api/v1/{region}/bean/transactions/batch-void',
731
+ path: {
732
+ region: data.region
733
+ },
734
+ body: data.requestBody,
735
+ mediaType: 'application/json',
736
+ errors: {
737
+ 400: 'Validation failed (empty, over 500, duplicate or non-string ids)',
738
+ 401: 'Authentication required',
739
+ 403: 'Batch contains ids owned by another user — whole request rejected, nothing committed'
740
+ }
741
+ });
742
+ }
743
+
695
744
  /**
696
745
  * Correct (supersede) a transaction
697
746
  * Atomically voids the original (SUPERSEDED) and creates a replacement through the full validation pipeline.
@@ -1036,1659 +1085,1862 @@ export class BeanReviewsService {
1036
1085
  }
1037
1086
  }
1038
1087
 
1039
- export class BeanPayeesService {
1088
+ export class BeanTransactionRulesService {
1040
1089
  /**
1041
- * Create a new payee
1042
- * Creates a new payee mapping for the authenticated user. The payee name must be unique within the user's account.
1090
+ * Create a new transaction rule (or upsert if upsertByPayee=true)
1091
+ * Creates a new rule. If upsertByPayee=true, updates existing rule matching payeeKeywords[0] instead of creating duplicate.
1043
1092
  * @param data The data for the request.
1093
+ * @param data.region Region code for tenant context
1044
1094
  * @param data.requestBody
1045
- * @returns PayeeResponseDto Payee created successfully
1095
+ * @returns TransactionRuleResponseDto Rule updated successfully (upsert mode)
1046
1096
  * @throws ApiError
1047
1097
  */
1048
- public static payeeControllerCreate(
1049
- data: PayeeControllerCreateData
1050
- ): CancelablePromise<PayeeControllerCreateResponse> {
1098
+ public static transactionRuleControllerCreate(
1099
+ data: TransactionRuleControllerCreateData
1100
+ ): CancelablePromise<TransactionRuleControllerCreateResponse> {
1051
1101
  return __request(OpenAPI, {
1052
1102
  method: 'POST',
1053
- url: '/api/v1/bean/payees',
1103
+ url: '/api/v1/{region}/bean/transaction-rules',
1104
+ path: {
1105
+ region: data.region
1106
+ },
1054
1107
  body: data.requestBody,
1055
1108
  mediaType: 'application/json',
1056
1109
  errors: {
1057
- 400: 'Invalid input data',
1058
- 409: 'Payee already exists'
1110
+ 400: 'Validation failed',
1111
+ 401: 'Unauthorized',
1112
+ 409: 'Resource conflict - another process is updating this rule'
1059
1113
  }
1060
1114
  });
1061
1115
  }
1062
1116
 
1063
1117
  /**
1064
- * List user payees
1065
- * Returns all payee mappings for the authenticated user with optional filtering
1118
+ * Get all transaction rules for user
1066
1119
  * @param data The data for the request.
1067
- * @param data.search Search term for payee name (partial match, case-insensitive). Useful for autocomplete.
1068
- * @param data.payee Filter by exact payee name match
1069
- * @param data.category Filter by custom category
1070
- * @param data.tag Filter by custom tag (returns payees that have this tag)
1071
- * @param data.isActive Filter by active status. Defaults to true (show only active payees).
1072
- * @returns PayeeListResponseDto Payees retrieved successfully
1120
+ * @param data.region Region code for tenant context
1121
+ * @param data.limit Max results per page (default: 20, max: 100)
1122
+ * @param data.offset Pagination offset (default: 0)
1123
+ * @param data.enabled Filter by enabled status
1124
+ * @param data.learningSource Filter by learning source. Omit this parameter or pass empty string to get manually created rules (learningSource is null in database).
1125
+ * @param data.autoApplyEnabled Filter by auto-apply status
1126
+ * @returns TransactionRuleListResponseDto List of rules
1073
1127
  * @throws ApiError
1074
1128
  */
1075
- public static payeeControllerFindAll(
1076
- data: PayeeControllerFindAllData = {}
1077
- ): CancelablePromise<PayeeControllerFindAllResponse> {
1129
+ public static transactionRuleControllerList(
1130
+ data: TransactionRuleControllerListData
1131
+ ): CancelablePromise<TransactionRuleControllerListResponse> {
1078
1132
  return __request(OpenAPI, {
1079
1133
  method: 'GET',
1080
- url: '/api/v1/bean/payees',
1134
+ url: '/api/v1/{region}/bean/transaction-rules',
1135
+ path: {
1136
+ region: data.region
1137
+ },
1081
1138
  query: {
1082
- search: data.search,
1083
- payee: data.payee,
1084
- category: data.category,
1085
- tag: data.tag,
1086
- isActive: data.isActive
1139
+ limit: data.limit,
1140
+ offset: data.offset,
1141
+ enabled: data.enabled,
1142
+ learningSource: data.learningSource,
1143
+ autoApplyEnabled: data.autoApplyEnabled
1144
+ },
1145
+ errors: {
1146
+ 401: 'Unauthorized'
1087
1147
  }
1088
1148
  });
1089
1149
  }
1090
1150
 
1091
1151
  /**
1092
- * Get payee autocomplete suggestions
1093
- * Returns active payee names matching the query, sorted by recent usage. Used for transaction input autocomplete.
1152
+ * Validate transaction rule configuration
1094
1153
  * @param data The data for the request.
1095
- * @param data.q Search query for payee name (partial match, case-insensitive)
1096
- * @param data.limit Maximum number of suggestions
1097
- * @returns PayeeAutocompleteResponseDto Autocomplete suggestions retrieved successfully
1154
+ * @param data.region Region code for tenant context
1155
+ * @param data.requestBody
1156
+ * @returns ValidateRuleResponseDto Validation result
1098
1157
  * @throws ApiError
1099
1158
  */
1100
- public static payeeControllerAutocomplete(
1101
- data: PayeeControllerAutocompleteData
1102
- ): CancelablePromise<PayeeControllerAutocompleteResponse> {
1159
+ public static transactionRuleControllerValidate(
1160
+ data: TransactionRuleControllerValidateData
1161
+ ): CancelablePromise<TransactionRuleControllerValidateResponse> {
1103
1162
  return __request(OpenAPI, {
1104
- method: 'GET',
1105
- url: '/api/v1/bean/payees/autocomplete',
1106
- query: {
1107
- q: data.q,
1108
- limit: data.limit
1163
+ method: 'POST',
1164
+ url: '/api/v1/{region}/bean/transaction-rules/validate',
1165
+ path: {
1166
+ region: data.region
1167
+ },
1168
+ body: data.requestBody,
1169
+ mediaType: 'application/json',
1170
+ errors: {
1171
+ 400: 'Validation failed',
1172
+ 401: 'Unauthorized'
1109
1173
  }
1110
1174
  });
1111
1175
  }
1112
1176
 
1113
1177
  /**
1114
- * Get top payees by usage
1115
- * Returns the most frequently used payees, sorted by use count. Used for statistics and analytics.
1178
+ * Bulk create transaction rules
1116
1179
  * @param data The data for the request.
1117
- * @param data.limit Maximum number of results
1118
- * @returns PayeeStatsResponseDto Top payees retrieved successfully
1180
+ * @param data.region Region code for tenant context
1181
+ * @param data.requestBody
1182
+ * @returns BulkCreateRulesResponseDto Bulk create completed
1119
1183
  * @throws ApiError
1120
1184
  */
1121
- public static payeeControllerGetTopPayees(
1122
- data: PayeeControllerGetTopPayeesData = {}
1123
- ): CancelablePromise<PayeeControllerGetTopPayeesResponse> {
1185
+ public static transactionRuleControllerBulkCreate(
1186
+ data: TransactionRuleControllerBulkCreateData
1187
+ ): CancelablePromise<TransactionRuleControllerBulkCreateResponse> {
1124
1188
  return __request(OpenAPI, {
1125
- method: 'GET',
1126
- url: '/api/v1/bean/payees/top',
1127
- query: {
1128
- limit: data.limit
1189
+ method: 'POST',
1190
+ url: '/api/v1/{region}/bean/transaction-rules/bulk',
1191
+ path: {
1192
+ region: data.region
1193
+ },
1194
+ body: data.requestBody,
1195
+ mediaType: 'application/json',
1196
+ errors: {
1197
+ 400: 'Invalid bulk create data',
1198
+ 401: 'Unauthorized'
1129
1199
  }
1130
1200
  });
1131
1201
  }
1132
1202
 
1133
1203
  /**
1134
- * Get payee by ID
1135
- * Returns a specific payee mapping by its UUID
1204
+ * Export transaction rules
1136
1205
  * @param data The data for the request.
1137
- * @param data.id Payee UUID
1138
- * @returns PayeeResponseDto Payee retrieved successfully
1206
+ * @param data.format Export format (currently only JSON supported)
1207
+ * @param data.region Region code for tenant context
1208
+ * @returns ExportRulesResponseDto Exported rules
1139
1209
  * @throws ApiError
1140
1210
  */
1141
- public static payeeControllerFindOne(
1142
- data: PayeeControllerFindOneData
1143
- ): CancelablePromise<PayeeControllerFindOneResponse> {
1211
+ public static transactionRuleControllerExport(
1212
+ data: TransactionRuleControllerExportData
1213
+ ): CancelablePromise<TransactionRuleControllerExportResponse> {
1144
1214
  return __request(OpenAPI, {
1145
1215
  method: 'GET',
1146
- url: '/api/v1/bean/payees/{id}',
1216
+ url: '/api/v1/{region}/bean/transaction-rules/export/{format}',
1147
1217
  path: {
1148
- id: data.id
1218
+ format: data.format,
1219
+ region: data.region
1149
1220
  },
1150
1221
  errors: {
1151
- 403: 'Payee belongs to another user',
1152
- 404: 'Payee not found'
1222
+ 400: 'Unsupported format',
1223
+ 401: 'Unauthorized'
1153
1224
  }
1154
1225
  });
1155
1226
  }
1156
1227
 
1157
1228
  /**
1158
- * Update payee
1159
- * Updates a payee mapping. The payee name cannot be changed after creation.
1229
+ * Get transaction rule statistics
1160
1230
  * @param data The data for the request.
1161
- * @param data.id Payee UUID
1162
- * @param data.requestBody
1163
- * @returns PayeeResponseDto Payee updated successfully
1231
+ * @param data.period Statistics time period
1232
+ * @param data.region Region code for tenant context
1233
+ * @returns RuleStatisticsResponseDto Rule statistics
1164
1234
  * @throws ApiError
1165
1235
  */
1166
- public static payeeControllerUpdate(
1167
- data: PayeeControllerUpdateData
1168
- ): CancelablePromise<PayeeControllerUpdateResponse> {
1236
+ public static transactionRuleControllerGetStatistics(
1237
+ data: TransactionRuleControllerGetStatisticsData
1238
+ ): CancelablePromise<TransactionRuleControllerGetStatisticsResponse> {
1169
1239
  return __request(OpenAPI, {
1170
- method: 'PUT',
1171
- url: '/api/v1/bean/payees/{id}',
1240
+ method: 'GET',
1241
+ url: '/api/v1/{region}/bean/transaction-rules/statistics/{period}',
1172
1242
  path: {
1173
- id: data.id
1243
+ period: data.period,
1244
+ region: data.region
1174
1245
  },
1175
- body: data.requestBody,
1176
- mediaType: 'application/json',
1177
1246
  errors: {
1178
- 400: 'Invalid input data',
1179
- 404: 'Payee not found'
1247
+ 401: 'Unauthorized'
1180
1248
  }
1181
1249
  });
1182
1250
  }
1183
1251
 
1184
1252
  /**
1185
- * Delete payee
1186
- * Soft deletes a payee by marking it as inactive. Inactive payees will not appear in autocomplete suggestions.
1253
+ * Get transaction rule detail
1187
1254
  * @param data The data for the request.
1188
- * @param data.id Payee UUID
1189
- * @returns void Payee deleted successfully
1255
+ * @param data.ruleId Rule ID
1256
+ * @param data.region Region code for tenant context
1257
+ * @returns TransactionRuleResponseDto Rule details
1190
1258
  * @throws ApiError
1191
1259
  */
1192
- public static payeeControllerDelete(
1193
- data: PayeeControllerDeleteData
1194
- ): CancelablePromise<PayeeControllerDeleteResponse> {
1260
+ public static transactionRuleControllerGetDetail(
1261
+ data: TransactionRuleControllerGetDetailData
1262
+ ): CancelablePromise<TransactionRuleControllerGetDetailResponse> {
1195
1263
  return __request(OpenAPI, {
1196
- method: 'DELETE',
1197
- url: '/api/v1/bean/payees/{id}',
1264
+ method: 'GET',
1265
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1198
1266
  path: {
1199
- id: data.id
1267
+ ruleId: data.ruleId,
1268
+ region: data.region
1200
1269
  },
1201
1270
  errors: {
1202
- 404: 'Payee not found'
1271
+ 401: 'Unauthorized',
1272
+ 403: 'Forbidden - not owner of rule',
1273
+ 404: 'Rule not found'
1203
1274
  }
1204
1275
  });
1205
1276
  }
1206
- }
1207
1277
 
1208
- export class AdminPayeeProfilesService {
1209
1278
  /**
1210
- * Create payee profile (Admin only)
1211
- * Creates a new global payee profile. The canonical name must be unique (case-insensitive).
1279
+ * Update a transaction rule
1212
1280
  * @param data The data for the request.
1281
+ * @param data.ruleId Rule ID to update
1282
+ * @param data.region Region code for tenant context
1213
1283
  * @param data.requestBody
1214
- * @returns PayeeProfileResponseDto Payee profile created successfully
1284
+ * @returns TransactionRuleResponseDto Rule updated successfully
1215
1285
  * @throws ApiError
1216
1286
  */
1217
- public static payeeProfileAdminControllerCreate(
1218
- data: PayeeProfileAdminControllerCreateData
1219
- ): CancelablePromise<PayeeProfileAdminControllerCreateResponse> {
1287
+ public static transactionRuleControllerUpdate(
1288
+ data: TransactionRuleControllerUpdateData
1289
+ ): CancelablePromise<TransactionRuleControllerUpdateResponse> {
1220
1290
  return __request(OpenAPI, {
1221
- method: 'POST',
1222
- url: '/api/v1/admin/payee-profiles',
1291
+ method: 'PUT',
1292
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1293
+ path: {
1294
+ ruleId: data.ruleId,
1295
+ region: data.region
1296
+ },
1223
1297
  body: data.requestBody,
1224
1298
  mediaType: 'application/json',
1225
1299
  errors: {
1226
1300
  400: 'Validation failed',
1227
- 403: 'Admin access required',
1228
- 409: 'Payee profile already exists'
1301
+ 401: 'Unauthorized',
1302
+ 403: 'Forbidden - not owner of rule',
1303
+ 404: 'Rule not found',
1304
+ 409: 'Resource conflict - rule is being modified by another process'
1229
1305
  }
1230
1306
  });
1231
1307
  }
1232
1308
 
1233
1309
  /**
1234
- * List payee profiles (Admin only)
1235
- * Returns all payee profiles with optional filtering by category, country, verification status, etc.
1310
+ * Delete a transaction rule
1236
1311
  * @param data The data for the request.
1237
- * @param data.search Search term for canonical name and aliases (case-insensitive)
1238
- * @param data.category Filter by category
1239
- * @param data.country Filter by country (ISO 3166-1 alpha-2)
1240
- * @param data.isActive Filter by active status (default: true - show only active)
1241
- * @param data.verified Filter by verification status. true = verified only, false = unverified only
1242
- * @param data.dataSource Filter by data source
1243
- * @returns PayeeProfileListResponseDto Payee profiles retrieved successfully
1312
+ * @param data.ruleId Rule ID to delete
1313
+ * @param data.region Region code for tenant context
1314
+ * @returns void Rule deleted successfully
1244
1315
  * @throws ApiError
1245
1316
  */
1246
- public static payeeProfileAdminControllerFindAll(
1247
- data: PayeeProfileAdminControllerFindAllData = {}
1248
- ): CancelablePromise<PayeeProfileAdminControllerFindAllResponse> {
1317
+ public static transactionRuleControllerDelete(
1318
+ data: TransactionRuleControllerDeleteData
1319
+ ): CancelablePromise<TransactionRuleControllerDeleteResponse> {
1249
1320
  return __request(OpenAPI, {
1250
- method: 'GET',
1251
- url: '/api/v1/admin/payee-profiles',
1252
- query: {
1253
- search: data.search,
1254
- category: data.category,
1255
- country: data.country,
1256
- isActive: data.isActive,
1257
- verified: data.verified,
1258
- dataSource: data.dataSource
1321
+ method: 'DELETE',
1322
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
1323
+ path: {
1324
+ ruleId: data.ruleId,
1325
+ region: data.region
1259
1326
  },
1260
1327
  errors: {
1261
- 403: 'Admin access required'
1328
+ 401: 'Unauthorized',
1329
+ 403: 'Forbidden - not owner of rule',
1330
+ 404: 'Rule not found',
1331
+ 409: 'Resource conflict - rule is being modified by another process'
1262
1332
  }
1263
1333
  });
1264
1334
  }
1265
1335
 
1266
1336
  /**
1267
- * Get payee profile by ID (Admin only)
1268
- * Returns a single payee profile by its ID.
1337
+ * Test rule matching
1269
1338
  * @param data The data for the request.
1270
- * @param data.id Payee profile ID (UUID)
1271
- * @returns PayeeProfileResponseDto Payee profile retrieved successfully
1339
+ * @param data.ruleId Rule ID to test
1340
+ * @param data.region Region code for tenant context
1341
+ * @param data.requestBody
1342
+ * @returns TestRuleResponseDto Test result
1272
1343
  * @throws ApiError
1273
1344
  */
1274
- public static payeeProfileAdminControllerFindOne(
1275
- data: PayeeProfileAdminControllerFindOneData
1276
- ): CancelablePromise<PayeeProfileAdminControllerFindOneResponse> {
1345
+ public static transactionRuleControllerTest(
1346
+ data: TransactionRuleControllerTestData
1347
+ ): CancelablePromise<TransactionRuleControllerTestResponse> {
1277
1348
  return __request(OpenAPI, {
1278
- method: 'GET',
1279
- url: '/api/v1/admin/payee-profiles/{id}',
1349
+ method: 'POST',
1350
+ url: '/api/v1/{region}/bean/transaction-rules/{ruleId}/test',
1280
1351
  path: {
1281
- id: data.id
1352
+ ruleId: data.ruleId,
1353
+ region: data.region
1282
1354
  },
1355
+ body: data.requestBody,
1356
+ mediaType: 'application/json',
1283
1357
  errors: {
1284
- 403: 'Admin access required',
1285
- 404: 'Payee profile not found'
1358
+ 401: 'Unauthorized',
1359
+ 403: 'Forbidden - not owner of rule',
1360
+ 404: 'Rule not found'
1286
1361
  }
1287
1362
  });
1288
1363
  }
1364
+ }
1289
1365
 
1366
+ export class UsersService {
1290
1367
  /**
1291
- * Update payee profile (Admin only)
1292
- * Updates an existing payee profile. The canonical name cannot be changed.
1368
+ * Delete own user account
1293
1369
  * @param data The data for the request.
1294
- * @param data.id Payee profile ID (UUID)
1295
1370
  * @param data.requestBody
1296
- * @returns PayeeProfileResponseDto Payee profile updated successfully
1371
+ * @returns void User deleted successfully
1297
1372
  * @throws ApiError
1298
1373
  */
1299
- public static payeeProfileAdminControllerUpdate(
1300
- data: PayeeProfileAdminControllerUpdateData
1301
- ): CancelablePromise<PayeeProfileAdminControllerUpdateResponse> {
1374
+ public static userControllerDeleteOwnUser(
1375
+ data: UserControllerDeleteOwnUserData
1376
+ ): CancelablePromise<UserControllerDeleteOwnUserResponse> {
1302
1377
  return __request(OpenAPI, {
1303
- method: 'PUT',
1304
- url: '/api/v1/admin/payee-profiles/{id}',
1305
- path: {
1306
- id: data.id
1307
- },
1378
+ method: 'DELETE',
1379
+ url: '/api/v1/users',
1308
1380
  body: data.requestBody,
1309
1381
  mediaType: 'application/json',
1310
1382
  errors: {
1311
- 403: 'Admin access required',
1312
- 404: 'Payee profile not found'
1383
+ 403: 'Invalid access token'
1313
1384
  }
1314
1385
  });
1315
1386
  }
1316
1387
 
1317
1388
  /**
1318
- * Soft delete payee profile (Admin only)
1319
- * Marks a payee profile as inactive (soft delete). The profile cannot be deleted if it is referenced by user payees.
1389
+ * Get current authenticated user
1320
1390
  * @param data The data for the request.
1321
- * @param data.id Payee profile ID (UUID)
1322
- * @returns void Payee profile deleted successfully
1391
+ * @param data.acceptLanguage
1392
+ * @returns UserResponseDto User retrieved successfully
1323
1393
  * @throws ApiError
1324
1394
  */
1325
- public static payeeProfileAdminControllerDelete(
1326
- data: PayeeProfileAdminControllerDeleteData
1327
- ): CancelablePromise<PayeeProfileAdminControllerDeleteResponse> {
1395
+ public static userControllerGetUser(
1396
+ data: UserControllerGetUserData
1397
+ ): CancelablePromise<UserControllerGetUserResponse> {
1328
1398
  return __request(OpenAPI, {
1329
- method: 'DELETE',
1330
- url: '/api/v1/admin/payee-profiles/{id}',
1331
- path: {
1332
- id: data.id
1333
- },
1334
- errors: {
1335
- 403: 'Admin access required',
1336
- 404: 'Payee profile not found',
1337
- 409: 'Payee profile is in use and cannot be deleted'
1399
+ method: 'GET',
1400
+ url: '/api/v1/users',
1401
+ headers: {
1402
+ 'accept-language': data.acceptLanguage
1338
1403
  }
1339
1404
  });
1340
1405
  }
1341
1406
 
1342
1407
  /**
1343
- * Verify payee profile (Admin only)
1344
- * Marks a payee profile as verified by setting verifiedAt to current timestamp.
1408
+ * Sign up new user
1409
+ * Create a new account with auto-generated access token. Protected by Cloudflare Turnstile to prevent automated signup (when enabled).
1345
1410
  * @param data The data for the request.
1346
- * @param data.id Payee profile ID (UUID)
1347
- * @returns PayeeProfileResponseDto Payee profile verified successfully
1411
+ * @param data.requestBody
1412
+ * @returns SignupResponseDto User created successfully
1348
1413
  * @throws ApiError
1349
1414
  */
1350
- public static payeeProfileAdminControllerVerify(
1351
- data: PayeeProfileAdminControllerVerifyData
1352
- ): CancelablePromise<PayeeProfileAdminControllerVerifyResponse> {
1415
+ public static userControllerSignupUser(
1416
+ data: UserControllerSignupUserData
1417
+ ): CancelablePromise<UserControllerSignupUserResponse> {
1353
1418
  return __request(OpenAPI, {
1354
1419
  method: 'POST',
1355
- url: '/api/v1/admin/payee-profiles/{id}/verify',
1356
- path: {
1357
- id: data.id
1358
- },
1420
+ url: '/api/v1/users',
1421
+ body: data.requestBody,
1422
+ mediaType: 'application/json',
1359
1423
  errors: {
1360
- 403: 'Admin access required',
1361
- 404: 'Payee profile not found'
1424
+ 400: 'Invalid Turnstile token (when Turnstile is enabled)',
1425
+ 403: 'User signup is disabled'
1362
1426
  }
1363
1427
  });
1364
1428
  }
1365
1429
 
1366
1430
  /**
1367
- * Unverify payee profile (Admin only)
1368
- * Removes verification status by setting verifiedAt to null.
1431
+ * Delete user by ID (admin only)
1369
1432
  * @param data The data for the request.
1370
- * @param data.id Payee profile ID (UUID)
1371
- * @returns PayeeProfileResponseDto Payee profile unverified successfully
1433
+ * @param data.id User ID to delete
1434
+ * @returns void User deleted successfully
1372
1435
  * @throws ApiError
1373
1436
  */
1374
- public static payeeProfileAdminControllerUnverify(
1375
- data: PayeeProfileAdminControllerUnverifyData
1376
- ): CancelablePromise<PayeeProfileAdminControllerUnverifyResponse> {
1437
+ public static userControllerDeleteUser(
1438
+ data: UserControllerDeleteUserData
1439
+ ): CancelablePromise<UserControllerDeleteUserResponse> {
1377
1440
  return __request(OpenAPI, {
1378
1441
  method: 'DELETE',
1379
- url: '/api/v1/admin/payee-profiles/{id}/verify',
1442
+ url: '/api/v1/users/{id}',
1380
1443
  path: {
1381
1444
  id: data.id
1382
1445
  },
1383
1446
  errors: {
1384
- 403: 'Admin access required',
1385
- 404: 'Payee profile not found'
1447
+ 403: 'Cannot delete own account or insufficient permissions'
1386
1448
  }
1387
1449
  });
1388
1450
  }
1389
- }
1390
1451
 
1391
- export class BeanCommoditiesService {
1392
1452
  /**
1393
- * Create a new commodity
1394
- * Creates a new commodity definition for the authenticated user
1453
+ * Get user info by user ID
1395
1454
  * @param data The data for the request.
1396
- * @param data.region Region code for tenant context
1397
- * @param data.requestBody
1398
- * @returns CommodityResponseDto Commodity created successfully
1455
+ * @param data.id User ID
1456
+ * @returns unknown User info retrieved successfully
1399
1457
  * @throws ApiError
1400
1458
  */
1401
- public static commodityControllerCreate(
1402
- data: CommodityControllerCreateData
1403
- ): CancelablePromise<CommodityControllerCreateResponse> {
1459
+ public static userControllerGetUserInfo(
1460
+ data: UserControllerGetUserInfoData
1461
+ ): CancelablePromise<UserControllerGetUserInfoResponse> {
1404
1462
  return __request(OpenAPI, {
1405
- method: 'POST',
1406
- url: '/api/v1/{region}/bean/commodities',
1463
+ method: 'GET',
1464
+ url: '/api/v1/users/{id}/info',
1407
1465
  path: {
1408
- region: data.region
1466
+ id: data.id
1409
1467
  },
1468
+ errors: {
1469
+ 403: 'Cannot access other user info without admin permission'
1470
+ }
1471
+ });
1472
+ }
1473
+
1474
+ /**
1475
+ * Update user settings
1476
+ * @param data The data for the request.
1477
+ * @param data.requestBody
1478
+ * @returns unknown Settings updated successfully
1479
+ * @throws ApiError
1480
+ */
1481
+ public static userControllerUpdateUserSetting(
1482
+ data: UserControllerUpdateUserSettingData
1483
+ ): CancelablePromise<UserControllerUpdateUserSettingResponse> {
1484
+ return __request(OpenAPI, {
1485
+ method: 'PUT',
1486
+ url: '/api/v1/users/setting',
1410
1487
  body: data.requestBody,
1411
1488
  mediaType: 'application/json',
1412
1489
  errors: {
1413
- 400: 'Invalid input data',
1414
- 409: 'Commodity already exists'
1490
+ 403: 'Insufficient permissions'
1415
1491
  }
1416
1492
  });
1417
1493
  }
1418
1494
 
1419
1495
  /**
1420
- * List user commodities
1421
- * Returns all commodity definitions for the authenticated user with optional filtering
1496
+ * Get all user settings paginated (admin only)
1422
1497
  * @param data The data for the request.
1423
- * @param data.region Region code for tenant context
1424
- * @param data.search Search term for symbol or metadata fields (partial match). Searches symbol and metadata.name.
1425
- * @param data.symbol Filter by exact symbol match
1426
- * @returns CommodityListResponseDto Commodities retrieved successfully
1498
+ * @param data.pageNo Page number
1499
+ * @param data.pageSize Page size
1500
+ * @returns unknown Settings list retrieved successfully
1427
1501
  * @throws ApiError
1428
1502
  */
1429
- public static commodityControllerFindAll(
1430
- data: CommodityControllerFindAllData
1431
- ): CancelablePromise<CommodityControllerFindAllResponse> {
1503
+ public static userControllerGetAllUserSettingsByPage(
1504
+ data: UserControllerGetAllUserSettingsByPageData
1505
+ ): CancelablePromise<UserControllerGetAllUserSettingsByPageResponse> {
1432
1506
  return __request(OpenAPI, {
1433
1507
  method: 'GET',
1434
- url: '/api/v1/{region}/bean/commodities',
1435
- path: {
1436
- region: data.region
1437
- },
1508
+ url: '/api/v1/users/settings-by-page',
1438
1509
  query: {
1439
- search: data.search,
1440
- symbol: data.symbol
1510
+ pageNo: data.pageNo,
1511
+ pageSize: data.pageSize
1441
1512
  }
1442
1513
  });
1443
1514
  }
1444
1515
 
1445
1516
  /**
1446
- * Get commodity by symbol
1447
- * Returns a specific commodity definition by its symbol
1448
- * @param data The data for the request.
1449
- * @param data.symbol Commodity symbol
1450
- * @param data.region Region code for tenant context
1451
- * @returns CommodityResponseDto Commodity retrieved successfully
1517
+ * Get asset and liability summary for current user
1518
+ * @returns unknown Summary retrieved successfully
1452
1519
  * @throws ApiError
1453
1520
  */
1454
- public static commodityControllerFindOne(
1455
- data: CommodityControllerFindOneData
1456
- ): CancelablePromise<CommodityControllerFindOneResponse> {
1521
+ public static userControllerGetAssetLiabilitySummary(): CancelablePromise<UserControllerGetAssetLiabilitySummaryResponse> {
1457
1522
  return __request(OpenAPI, {
1458
1523
  method: 'GET',
1459
- url: '/api/v1/{region}/bean/commodities/{symbol}',
1460
- path: {
1461
- symbol: data.symbol,
1462
- region: data.region
1463
- },
1464
- errors: {
1465
- 404: 'Commodity not found'
1466
- }
1524
+ url: '/api/v1/users/asset-liability-summary'
1467
1525
  });
1468
1526
  }
1527
+ }
1469
1528
 
1529
+ export class PropertiesService {
1470
1530
  /**
1471
- * Update commodity
1472
- * Updates an existing commodity definition. Symbol cannot be changed.
1473
- * @param data The data for the request.
1474
- * @param data.symbol Commodity symbol
1475
- * @param data.region Region code for tenant context
1476
- * @param data.requestBody
1477
- * @returns CommodityResponseDto Commodity updated successfully
1531
+ * Get all system properties
1532
+ * @returns unknown Properties retrieved successfully
1478
1533
  * @throws ApiError
1479
1534
  */
1480
- public static commodityControllerUpdate(
1481
- data: CommodityControllerUpdateData
1482
- ): CancelablePromise<CommodityControllerUpdateResponse> {
1535
+ public static propertyControllerGetAll(): CancelablePromise<PropertyControllerGetAllResponse> {
1483
1536
  return __request(OpenAPI, {
1484
- method: 'PUT',
1485
- url: '/api/v1/{region}/bean/commodities/{symbol}',
1486
- path: {
1487
- symbol: data.symbol,
1488
- region: data.region
1489
- },
1490
- body: data.requestBody,
1491
- mediaType: 'application/json',
1537
+ method: 'GET',
1538
+ url: '/api/v1/admin/properties',
1492
1539
  errors: {
1493
- 400: 'Invalid input data',
1494
- 404: 'Commodity not found'
1540
+ 401: 'Unauthorized',
1541
+ 403: 'Forbidden - insufficient permissions'
1495
1542
  }
1496
1543
  });
1497
1544
  }
1498
1545
 
1499
1546
  /**
1500
- * Delete commodity
1501
- * Deletes a commodity definition
1547
+ * Get property by key
1502
1548
  * @param data The data for the request.
1503
- * @param data.symbol Commodity symbol
1504
- * @param data.region Region code for tenant context
1505
- * @returns void Commodity deleted successfully
1549
+ * @param data.key Property key
1550
+ * @returns unknown Property retrieved successfully
1506
1551
  * @throws ApiError
1507
1552
  */
1508
- public static commodityControllerDelete(
1509
- data: CommodityControllerDeleteData
1510
- ): CancelablePromise<CommodityControllerDeleteResponse> {
1553
+ public static propertyControllerGetByKey(
1554
+ data: PropertyControllerGetByKeyData
1555
+ ): CancelablePromise<PropertyControllerGetByKeyResponse> {
1511
1556
  return __request(OpenAPI, {
1512
- method: 'DELETE',
1513
- url: '/api/v1/{region}/bean/commodities/{symbol}',
1557
+ method: 'GET',
1558
+ url: '/api/v1/admin/properties/{key}',
1514
1559
  path: {
1515
- symbol: data.symbol,
1516
- region: data.region
1560
+ key: data.key
1517
1561
  },
1518
1562
  errors: {
1519
- 404: 'Commodity not found'
1563
+ 401: 'Unauthorized',
1564
+ 403: 'Forbidden - insufficient permissions',
1565
+ 404: 'Property not found'
1520
1566
  }
1521
1567
  });
1522
1568
  }
1523
1569
 
1524
1570
  /**
1525
- * Ensure commodity exists
1526
- * Gets existing commodity or creates it with automatic initialization from OpenBB
1571
+ * Update a system property
1527
1572
  * @param data The data for the request.
1528
- * @param data.symbol Commodity symbol
1529
- * @param data.region Region code for tenant context
1530
- * @returns CommodityResponseDto Commodity retrieved or created
1573
+ * @param data.key Property key
1574
+ * @param data.requestBody
1575
+ * @returns unknown Property updated successfully
1531
1576
  * @throws ApiError
1532
1577
  */
1533
- public static commodityControllerGetOrCreate(
1534
- data: CommodityControllerGetOrCreateData
1535
- ): CancelablePromise<CommodityControllerGetOrCreateResponse> {
1578
+ public static propertyControllerUpdate(
1579
+ data: PropertyControllerUpdateData
1580
+ ): CancelablePromise<PropertyControllerUpdateResponse> {
1536
1581
  return __request(OpenAPI, {
1537
- method: 'POST',
1538
- url: '/api/v1/{region}/bean/commodities/{symbol}/ensure',
1582
+ method: 'PUT',
1583
+ url: '/api/v1/admin/properties/{key}',
1539
1584
  path: {
1540
- symbol: data.symbol,
1541
- region: data.region
1585
+ key: data.key
1586
+ },
1587
+ body: data.requestBody,
1588
+ mediaType: 'application/json',
1589
+ errors: {
1590
+ 401: 'Unauthorized',
1591
+ 403: 'Forbidden - insufficient permissions'
1542
1592
  }
1543
1593
  });
1544
1594
  }
1545
1595
 
1546
1596
  /**
1547
- * Bulk create commodities
1548
- * Creates multiple commodities from a list of symbols, useful for initialization
1597
+ * Delete a system property
1549
1598
  * @param data The data for the request.
1550
- * @param data.region Region code for tenant context
1551
- * @returns CommodityResponseDto Commodities created successfully
1599
+ * @param data.key Property key
1600
+ * @returns void Property deleted successfully
1552
1601
  * @throws ApiError
1553
1602
  */
1554
- public static commodityControllerBulkCreate(
1555
- data: CommodityControllerBulkCreateData
1556
- ): CancelablePromise<CommodityControllerBulkCreateResponse> {
1603
+ public static propertyControllerDelete(
1604
+ data: PropertyControllerDeleteData
1605
+ ): CancelablePromise<PropertyControllerDeleteResponse> {
1557
1606
  return __request(OpenAPI, {
1558
- method: 'POST',
1559
- url: '/api/v1/{region}/bean/commodities/bulk',
1607
+ method: 'DELETE',
1608
+ url: '/api/v1/admin/properties/{key}',
1560
1609
  path: {
1561
- region: data.region
1610
+ key: data.key
1611
+ },
1612
+ errors: {
1613
+ 401: 'Unauthorized',
1614
+ 403: 'Forbidden - insufficient permissions',
1615
+ 404: 'Property not found'
1562
1616
  }
1563
1617
  });
1564
1618
  }
1565
1619
  }
1566
1620
 
1567
- export class BeanPricesService {
1621
+ export class BeanPayeesService {
1568
1622
  /**
1569
- * Create a new price
1570
- * Creates a new price entry for the authenticated user
1623
+ * Create a new payee
1624
+ * Creates a new payee mapping for the authenticated user. The payee name must be unique within the user's account.
1571
1625
  * @param data The data for the request.
1572
- * @param data.region Region code for tenant context
1573
1626
  * @param data.requestBody
1574
- * @returns PriceResponseDto Price created successfully
1627
+ * @returns PayeeResponseDto Payee created successfully
1575
1628
  * @throws ApiError
1576
1629
  */
1577
- public static priceControllerCreate(
1578
- data: PriceControllerCreateData
1579
- ): CancelablePromise<PriceControllerCreateResponse> {
1630
+ public static payeeControllerCreate(
1631
+ data: PayeeControllerCreateData
1632
+ ): CancelablePromise<PayeeControllerCreateResponse> {
1580
1633
  return __request(OpenAPI, {
1581
1634
  method: 'POST',
1582
- url: '/api/v1/{region}/bean/prices',
1583
- path: {
1584
- region: data.region
1585
- },
1635
+ url: '/api/v1/bean/payees',
1586
1636
  body: data.requestBody,
1587
1637
  mediaType: 'application/json',
1588
1638
  errors: {
1589
- 404: 'Currency or quoteCurrency commodity not found',
1590
- 409: 'Price already exists for this currency pair and date'
1639
+ 400: 'Invalid input data',
1640
+ 409: 'Payee already exists'
1591
1641
  }
1592
1642
  });
1593
1643
  }
1594
1644
 
1595
1645
  /**
1596
- * List user prices
1597
- * Returns all price entries for the authenticated user with optional filtering
1646
+ * List user payees
1647
+ * Returns all payee mappings for the authenticated user with optional filtering
1598
1648
  * @param data The data for the request.
1599
- * @param data.region Region code for tenant context
1600
- * @param data.currency Filter by currency (e.g., BTC, AAPL, USD)
1601
- * @param data.quoteCurrency Filter by quote currency (pricing currency, e.g., USD, CNY)
1602
- * @param data.dateFrom Filter prices from this date (ISO 8601 format)
1603
- * @param data.dateTo Filter prices to this date (ISO 8601 format)
1604
- * @param data.search Search term for currency or quoteCurrency (case-insensitive partial match)
1605
- * @param data.page Page number for pagination (default: 1)
1606
- * @param data.limit Number of items per page (default: 20, max: 100)
1607
- * @returns PriceListResponseDto Prices retrieved successfully
1649
+ * @param data.search Search term for payee name (partial match, case-insensitive). Useful for autocomplete.
1650
+ * @param data.payee Filter by exact payee name match
1651
+ * @param data.category Filter by custom category
1652
+ * @param data.tag Filter by custom tag (returns payees that have this tag)
1653
+ * @param data.isActive Filter by active status. Defaults to true (show only active payees).
1654
+ * @returns PayeeListResponseDto Payees retrieved successfully
1608
1655
  * @throws ApiError
1609
1656
  */
1610
- public static priceControllerFindAll(
1611
- data: PriceControllerFindAllData
1612
- ): CancelablePromise<PriceControllerFindAllResponse> {
1657
+ public static payeeControllerFindAll(
1658
+ data: PayeeControllerFindAllData = {}
1659
+ ): CancelablePromise<PayeeControllerFindAllResponse> {
1613
1660
  return __request(OpenAPI, {
1614
1661
  method: 'GET',
1615
- url: '/api/v1/{region}/bean/prices',
1616
- path: {
1617
- region: data.region
1618
- },
1662
+ url: '/api/v1/bean/payees',
1619
1663
  query: {
1620
- currency: data.currency,
1621
- quoteCurrency: data.quoteCurrency,
1622
- dateFrom: data.dateFrom,
1623
- dateTo: data.dateTo,
1624
1664
  search: data.search,
1625
- page: data.page,
1626
- limit: data.limit
1665
+ payee: data.payee,
1666
+ category: data.category,
1667
+ tag: data.tag,
1668
+ isActive: data.isActive
1627
1669
  }
1628
1670
  });
1629
1671
  }
1630
1672
 
1631
1673
  /**
1632
- * Get price by ID
1633
- * Returns a single price entry by its ID
1674
+ * Get payee autocomplete suggestions
1675
+ * Returns active payee names matching the query, sorted by recent usage. Used for transaction input autocomplete.
1634
1676
  * @param data The data for the request.
1635
- * @param data.id Price ID
1636
- * @param data.region Region code for tenant context
1637
- * @returns PriceResponseDto Price retrieved successfully
1677
+ * @param data.q Search query for payee name (partial match, case-insensitive)
1678
+ * @param data.limit Maximum number of suggestions
1679
+ * @returns PayeeAutocompleteResponseDto Autocomplete suggestions retrieved successfully
1638
1680
  * @throws ApiError
1639
1681
  */
1640
- public static priceControllerFindOne(
1641
- data: PriceControllerFindOneData
1642
- ): CancelablePromise<PriceControllerFindOneResponse> {
1682
+ public static payeeControllerAutocomplete(
1683
+ data: PayeeControllerAutocompleteData
1684
+ ): CancelablePromise<PayeeControllerAutocompleteResponse> {
1643
1685
  return __request(OpenAPI, {
1644
1686
  method: 'GET',
1645
- url: '/api/v1/{region}/bean/prices/{id}',
1687
+ url: '/api/v1/bean/payees/autocomplete',
1688
+ query: {
1689
+ q: data.q,
1690
+ limit: data.limit
1691
+ }
1692
+ });
1693
+ }
1694
+
1695
+ /**
1696
+ * Get top payees by usage
1697
+ * Returns the most frequently used payees, sorted by use count. Used for statistics and analytics.
1698
+ * @param data The data for the request.
1699
+ * @param data.limit Maximum number of results
1700
+ * @returns PayeeStatsResponseDto Top payees retrieved successfully
1701
+ * @throws ApiError
1702
+ */
1703
+ public static payeeControllerGetTopPayees(
1704
+ data: PayeeControllerGetTopPayeesData = {}
1705
+ ): CancelablePromise<PayeeControllerGetTopPayeesResponse> {
1706
+ return __request(OpenAPI, {
1707
+ method: 'GET',
1708
+ url: '/api/v1/bean/payees/top',
1709
+ query: {
1710
+ limit: data.limit
1711
+ }
1712
+ });
1713
+ }
1714
+
1715
+ /**
1716
+ * Get payee by ID
1717
+ * Returns a specific payee mapping by its UUID
1718
+ * @param data The data for the request.
1719
+ * @param data.id Payee UUID
1720
+ * @returns PayeeResponseDto Payee retrieved successfully
1721
+ * @throws ApiError
1722
+ */
1723
+ public static payeeControllerFindOne(
1724
+ data: PayeeControllerFindOneData
1725
+ ): CancelablePromise<PayeeControllerFindOneResponse> {
1726
+ return __request(OpenAPI, {
1727
+ method: 'GET',
1728
+ url: '/api/v1/bean/payees/{id}',
1646
1729
  path: {
1647
- id: data.id,
1648
- region: data.region
1730
+ id: data.id
1649
1731
  },
1650
1732
  errors: {
1651
- 404: 'Price not found'
1733
+ 403: 'Payee belongs to another user',
1734
+ 404: 'Payee not found'
1652
1735
  }
1653
1736
  });
1654
1737
  }
1655
1738
 
1656
1739
  /**
1657
- * Update a price
1658
- * Updates an existing price entry
1740
+ * Update payee
1741
+ * Updates a payee mapping. The payee name cannot be changed after creation.
1659
1742
  * @param data The data for the request.
1660
- * @param data.id Price ID
1661
- * @param data.region Region code for tenant context
1743
+ * @param data.id Payee UUID
1662
1744
  * @param data.requestBody
1663
- * @returns PriceResponseDto Price updated successfully
1745
+ * @returns PayeeResponseDto Payee updated successfully
1664
1746
  * @throws ApiError
1665
1747
  */
1666
- public static priceControllerUpdate(
1667
- data: PriceControllerUpdateData
1668
- ): CancelablePromise<PriceControllerUpdateResponse> {
1748
+ public static payeeControllerUpdate(
1749
+ data: PayeeControllerUpdateData
1750
+ ): CancelablePromise<PayeeControllerUpdateResponse> {
1669
1751
  return __request(OpenAPI, {
1670
1752
  method: 'PUT',
1671
- url: '/api/v1/{region}/bean/prices/{id}',
1753
+ url: '/api/v1/bean/payees/{id}',
1672
1754
  path: {
1673
- id: data.id,
1674
- region: data.region
1755
+ id: data.id
1675
1756
  },
1676
1757
  body: data.requestBody,
1677
1758
  mediaType: 'application/json',
1678
1759
  errors: {
1679
- 404: 'Price not found',
1680
- 409: 'Updated price conflicts with existing price'
1760
+ 400: 'Invalid input data',
1761
+ 404: 'Payee not found'
1681
1762
  }
1682
1763
  });
1683
1764
  }
1684
1765
 
1685
1766
  /**
1686
- * Delete a price
1687
- * Deletes a price entry (hard delete)
1767
+ * Delete payee
1768
+ * Soft deletes a payee by marking it as inactive. Inactive payees will not appear in autocomplete suggestions.
1688
1769
  * @param data The data for the request.
1689
- * @param data.id Price ID
1690
- * @param data.region Region code for tenant context
1691
- * @returns void Price deleted successfully
1770
+ * @param data.id Payee UUID
1771
+ * @returns void Payee deleted successfully
1692
1772
  * @throws ApiError
1693
1773
  */
1694
- public static priceControllerDelete(
1695
- data: PriceControllerDeleteData
1696
- ): CancelablePromise<PriceControllerDeleteResponse> {
1774
+ public static payeeControllerDelete(
1775
+ data: PayeeControllerDeleteData
1776
+ ): CancelablePromise<PayeeControllerDeleteResponse> {
1697
1777
  return __request(OpenAPI, {
1698
1778
  method: 'DELETE',
1699
- url: '/api/v1/{region}/bean/prices/{id}',
1779
+ url: '/api/v1/bean/payees/{id}',
1700
1780
  path: {
1701
- id: data.id,
1702
- region: data.region
1781
+ id: data.id
1703
1782
  },
1704
1783
  errors: {
1705
- 404: 'Price not found'
1784
+ 404: 'Payee not found'
1706
1785
  }
1707
1786
  });
1708
1787
  }
1788
+ }
1709
1789
 
1790
+ export class AdminPayeeProfilesService {
1710
1791
  /**
1711
- * Bulk create prices
1712
- * Creates multiple price entries at once (skips duplicates)
1792
+ * Create payee profile (Admin only)
1793
+ * Creates a new global payee profile. The canonical name must be unique (case-insensitive).
1713
1794
  * @param data The data for the request.
1714
- * @param data.region Region code for tenant context
1715
1795
  * @param data.requestBody
1716
- * @returns PriceResponseDto Prices created successfully
1796
+ * @returns PayeeProfileResponseDto Payee profile created successfully
1717
1797
  * @throws ApiError
1718
1798
  */
1719
- public static priceControllerBulkCreate(
1720
- data: PriceControllerBulkCreateData
1721
- ): CancelablePromise<PriceControllerBulkCreateResponse> {
1799
+ public static payeeProfileAdminControllerCreate(
1800
+ data: PayeeProfileAdminControllerCreateData
1801
+ ): CancelablePromise<PayeeProfileAdminControllerCreateResponse> {
1722
1802
  return __request(OpenAPI, {
1723
1803
  method: 'POST',
1724
- url: '/api/v1/{region}/bean/prices/bulk',
1725
- path: {
1726
- region: data.region
1727
- },
1804
+ url: '/api/v1/admin/payee-profiles',
1728
1805
  body: data.requestBody,
1729
- mediaType: 'application/json'
1806
+ mediaType: 'application/json',
1807
+ errors: {
1808
+ 400: 'Validation failed',
1809
+ 403: 'Admin access required',
1810
+ 409: 'Payee profile already exists'
1811
+ }
1730
1812
  });
1731
1813
  }
1732
- }
1733
1814
 
1734
- export class RecurringRulesService {
1735
1815
  /**
1736
- * Create a new recurring rule
1737
- * Creates a new recurring transaction rule for the authenticated user
1816
+ * List payee profiles (Admin only)
1817
+ * Returns all payee profiles with optional filtering by category, country, verification status, etc.
1738
1818
  * @param data The data for the request.
1739
- * @param data.region Region code for tenant context
1740
- * @param data.requestBody
1741
- * @returns RecurringRuleResponseDto Rule created successfully
1819
+ * @param data.search Search term for canonical name and aliases (case-insensitive)
1820
+ * @param data.category Filter by category
1821
+ * @param data.country Filter by country (ISO 3166-1 alpha-2)
1822
+ * @param data.isActive Filter by active status (default: true - show only active)
1823
+ * @param data.verified Filter by verification status. true = verified only, false = unverified only
1824
+ * @param data.dataSource Filter by data source
1825
+ * @returns PayeeProfileListResponseDto Payee profiles retrieved successfully
1742
1826
  * @throws ApiError
1743
1827
  */
1744
- public static recurringRuleControllerCreate(
1745
- data: RecurringRuleControllerCreateData
1746
- ): CancelablePromise<RecurringRuleControllerCreateResponse> {
1828
+ public static payeeProfileAdminControllerFindAll(
1829
+ data: PayeeProfileAdminControllerFindAllData = {}
1830
+ ): CancelablePromise<PayeeProfileAdminControllerFindAllResponse> {
1747
1831
  return __request(OpenAPI, {
1748
- method: 'POST',
1749
- url: '/api/v1/{region}/bean/recurring-rules',
1750
- path: {
1751
- region: data.region
1832
+ method: 'GET',
1833
+ url: '/api/v1/admin/payee-profiles',
1834
+ query: {
1835
+ search: data.search,
1836
+ category: data.category,
1837
+ country: data.country,
1838
+ isActive: data.isActive,
1839
+ verified: data.verified,
1840
+ dataSource: data.dataSource
1752
1841
  },
1753
- body: data.requestBody,
1754
- mediaType: 'application/json',
1755
1842
  errors: {
1756
- 400: 'Invalid input data (e.g., autoCreate without accounts)',
1757
- 409: 'Rule with same name already exists'
1843
+ 403: 'Admin access required'
1758
1844
  }
1759
1845
  });
1760
1846
  }
1761
1847
 
1762
1848
  /**
1763
- * List recurring rules
1764
- * Returns all recurring rules for the authenticated user with optional filtering
1849
+ * Get payee profile by ID (Admin only)
1850
+ * Returns a single payee profile by its ID.
1765
1851
  * @param data The data for the request.
1766
- * @param data.region Region code for tenant context
1767
- * @param data.isActive Filter by active status
1768
- * @param data.frequency Filter by frequency (WEEKLY, MONTHLY, etc.)
1769
- * @param data.hasAutoCreate Filter by autoCreate enabled
1770
- * @returns RecurringRuleResponseDto Rules retrieved successfully
1852
+ * @param data.id Payee profile ID (UUID)
1853
+ * @returns PayeeProfileResponseDto Payee profile retrieved successfully
1771
1854
  * @throws ApiError
1772
1855
  */
1773
- public static recurringRuleControllerFindAll(
1774
- data: RecurringRuleControllerFindAllData
1775
- ): CancelablePromise<RecurringRuleControllerFindAllResponse> {
1856
+ public static payeeProfileAdminControllerFindOne(
1857
+ data: PayeeProfileAdminControllerFindOneData
1858
+ ): CancelablePromise<PayeeProfileAdminControllerFindOneResponse> {
1776
1859
  return __request(OpenAPI, {
1777
1860
  method: 'GET',
1778
- url: '/api/v1/{region}/bean/recurring-rules',
1861
+ url: '/api/v1/admin/payee-profiles/{id}',
1779
1862
  path: {
1780
- region: data.region
1863
+ id: data.id
1781
1864
  },
1782
- query: {
1783
- isActive: data.isActive,
1784
- frequency: data.frequency,
1785
- hasAutoCreate: data.hasAutoCreate
1865
+ errors: {
1866
+ 403: 'Admin access required',
1867
+ 404: 'Payee profile not found'
1786
1868
  }
1787
1869
  });
1788
1870
  }
1789
1871
 
1790
1872
  /**
1791
- * Create recurring rule from transaction
1792
- * Auto-creates a recurring rule using transaction data. User only confirms frequency.
1873
+ * Update payee profile (Admin only)
1874
+ * Updates an existing payee profile. The canonical name cannot be changed.
1793
1875
  * @param data The data for the request.
1794
- * @param data.transactionId Source transaction ID
1795
- * @param data.region Region code for tenant context
1876
+ * @param data.id Payee profile ID (UUID)
1796
1877
  * @param data.requestBody
1797
- * @returns RecurringRuleResponseDto Rule created successfully
1878
+ * @returns PayeeProfileResponseDto Payee profile updated successfully
1798
1879
  * @throws ApiError
1799
1880
  */
1800
- public static recurringRuleControllerCreateFromTransaction(
1801
- data: RecurringRuleControllerCreateFromTransactionData
1802
- ): CancelablePromise<RecurringRuleControllerCreateFromTransactionResponse> {
1881
+ public static payeeProfileAdminControllerUpdate(
1882
+ data: PayeeProfileAdminControllerUpdateData
1883
+ ): CancelablePromise<PayeeProfileAdminControllerUpdateResponse> {
1803
1884
  return __request(OpenAPI, {
1804
- method: 'POST',
1805
- url: '/api/v1/{region}/bean/recurring-rules/from-transaction/{transactionId}',
1885
+ method: 'PUT',
1886
+ url: '/api/v1/admin/payee-profiles/{id}',
1806
1887
  path: {
1807
- transactionId: data.transactionId,
1808
- region: data.region
1888
+ id: data.id
1809
1889
  },
1810
1890
  body: data.requestBody,
1811
1891
  mediaType: 'application/json',
1812
1892
  errors: {
1813
- 404: 'Transaction not found',
1814
- 409: 'Rule with same name already exists or transaction already linked'
1893
+ 403: 'Admin access required',
1894
+ 404: 'Payee profile not found'
1815
1895
  }
1816
1896
  });
1817
1897
  }
1818
1898
 
1819
1899
  /**
1820
- * Get recurring rule by ID
1821
- * Returns a specific recurring rule with its details
1900
+ * Soft delete payee profile (Admin only)
1901
+ * Marks a payee profile as inactive (soft delete). The profile cannot be deleted if it is referenced by user payees.
1822
1902
  * @param data The data for the request.
1823
- * @param data.id Rule ID
1824
- * @param data.region Region code for tenant context
1825
- * @returns RecurringRuleResponseDto Rule retrieved successfully
1903
+ * @param data.id Payee profile ID (UUID)
1904
+ * @returns void Payee profile deleted successfully
1826
1905
  * @throws ApiError
1827
1906
  */
1828
- public static recurringRuleControllerFindOne(
1829
- data: RecurringRuleControllerFindOneData
1830
- ): CancelablePromise<RecurringRuleControllerFindOneResponse> {
1907
+ public static payeeProfileAdminControllerDelete(
1908
+ data: PayeeProfileAdminControllerDeleteData
1909
+ ): CancelablePromise<PayeeProfileAdminControllerDeleteResponse> {
1831
1910
  return __request(OpenAPI, {
1832
- method: 'GET',
1833
- url: '/api/v1/{region}/bean/recurring-rules/{id}',
1911
+ method: 'DELETE',
1912
+ url: '/api/v1/admin/payee-profiles/{id}',
1834
1913
  path: {
1835
- id: data.id,
1836
- region: data.region
1914
+ id: data.id
1837
1915
  },
1838
1916
  errors: {
1839
- 404: 'Rule not found'
1917
+ 403: 'Admin access required',
1918
+ 404: 'Payee profile not found',
1919
+ 409: 'Payee profile is in use and cannot be deleted'
1840
1920
  }
1841
1921
  });
1842
1922
  }
1843
1923
 
1844
1924
  /**
1845
- * Update recurring rule
1846
- * Updates an existing recurring rule
1925
+ * Verify payee profile (Admin only)
1926
+ * Marks a payee profile as verified by setting verifiedAt to current timestamp.
1847
1927
  * @param data The data for the request.
1848
- * @param data.id Rule ID
1849
- * @param data.region Region code for tenant context
1850
- * @param data.requestBody
1851
- * @returns RecurringRuleResponseDto Rule updated successfully
1928
+ * @param data.id Payee profile ID (UUID)
1929
+ * @returns PayeeProfileResponseDto Payee profile verified successfully
1852
1930
  * @throws ApiError
1853
1931
  */
1854
- public static recurringRuleControllerUpdate(
1855
- data: RecurringRuleControllerUpdateData
1856
- ): CancelablePromise<RecurringRuleControllerUpdateResponse> {
1932
+ public static payeeProfileAdminControllerVerify(
1933
+ data: PayeeProfileAdminControllerVerifyData
1934
+ ): CancelablePromise<PayeeProfileAdminControllerVerifyResponse> {
1857
1935
  return __request(OpenAPI, {
1858
- method: 'PATCH',
1859
- url: '/api/v1/{region}/bean/recurring-rules/{id}',
1936
+ method: 'POST',
1937
+ url: '/api/v1/admin/payee-profiles/{id}/verify',
1860
1938
  path: {
1861
- id: data.id,
1862
- region: data.region
1939
+ id: data.id
1863
1940
  },
1864
- body: data.requestBody,
1865
- mediaType: 'application/json',
1866
1941
  errors: {
1867
- 400: 'Invalid input data',
1868
- 404: 'Rule not found'
1942
+ 403: 'Admin access required',
1943
+ 404: 'Payee profile not found'
1869
1944
  }
1870
1945
  });
1871
1946
  }
1872
1947
 
1873
1948
  /**
1874
- * Delete recurring rule
1875
- * Soft deletes a recurring rule (sets isActive to false)
1949
+ * Unverify payee profile (Admin only)
1950
+ * Removes verification status by setting verifiedAt to null.
1876
1951
  * @param data The data for the request.
1877
- * @param data.id Rule ID
1878
- * @param data.region Region code for tenant context
1879
- * @returns void Rule deleted successfully
1952
+ * @param data.id Payee profile ID (UUID)
1953
+ * @returns void Payee profile unverified successfully
1880
1954
  * @throws ApiError
1881
1955
  */
1882
- public static recurringRuleControllerDelete(
1883
- data: RecurringRuleControllerDeleteData
1884
- ): CancelablePromise<RecurringRuleControllerDeleteResponse> {
1956
+ public static payeeProfileAdminControllerUnverify(
1957
+ data: PayeeProfileAdminControllerUnverifyData
1958
+ ): CancelablePromise<PayeeProfileAdminControllerUnverifyResponse> {
1885
1959
  return __request(OpenAPI, {
1886
1960
  method: 'DELETE',
1887
- url: '/api/v1/{region}/bean/recurring-rules/{id}',
1961
+ url: '/api/v1/admin/payee-profiles/{id}/verify',
1888
1962
  path: {
1889
- id: data.id,
1890
- region: data.region
1963
+ id: data.id
1891
1964
  },
1892
1965
  errors: {
1893
- 404: 'Rule not found'
1966
+ 403: 'Admin access required',
1967
+ 404: 'Payee profile not found'
1894
1968
  }
1895
1969
  });
1896
1970
  }
1971
+ }
1897
1972
 
1973
+ export class PayeeProfilesService {
1898
1974
  /**
1899
- * Get rule with statistics
1900
- * Returns a rule with pending/overdue counts and next expected date
1901
- * @param data The data for the request.
1902
- * @param data.id Rule ID
1903
- * @param data.region Region code for tenant context
1904
- * @returns RecurringRuleWithStatsResponseDto Rule with stats retrieved successfully
1975
+ * List active payee profiles (directory dump)
1976
+ * Returns the full active PayeeProfile set as a trimmed projection for client-side dictionary caching. Aliases are verbatim as stored; clients normalize on their side.
1977
+ * @returns PayeeProfileDirectoryResponseDto Active payee profiles
1905
1978
  * @throws ApiError
1906
1979
  */
1907
- public static recurringRuleControllerGetWithStats(
1908
- data: RecurringRuleControllerGetWithStatsData
1909
- ): CancelablePromise<RecurringRuleControllerGetWithStatsResponse> {
1980
+ public static payeeProfileControllerListActive(): CancelablePromise<PayeeProfileControllerListActiveResponse> {
1910
1981
  return __request(OpenAPI, {
1911
1982
  method: 'GET',
1912
- url: '/api/v1/{region}/bean/recurring-rules/{id}/stats',
1913
- path: {
1914
- id: data.id,
1915
- region: data.region
1916
- },
1983
+ url: '/api/v1/bean/payee-profiles',
1917
1984
  errors: {
1918
- 404: 'Rule not found'
1985
+ 401: 'Missing or invalid token'
1919
1986
  }
1920
1987
  });
1921
1988
  }
1922
1989
  }
1923
1990
 
1924
- export class ExpectedTransactionsService {
1991
+ export class BeanCommoditiesService {
1925
1992
  /**
1926
- * List expected transactions
1927
- * Returns expected transactions for the authenticated user with optional filtering
1993
+ * Create a new commodity
1994
+ * Creates a new commodity definition for the authenticated user
1928
1995
  * @param data The data for the request.
1929
1996
  * @param data.region Region code for tenant context
1930
- * @param data.ruleId Filter by recurring rule ID
1931
- * @param data.status Filter by status (PENDING, COMPLETED, SKIPPED)
1932
- * @param data.fromDate Filter by date range start (YYYY-MM-DD)
1933
- * @param data.toDate Filter by date range end (YYYY-MM-DD)
1934
- * @returns ExpectedTransactionListResponseDto Expected transactions retrieved successfully
1997
+ * @param data.requestBody
1998
+ * @returns CommodityResponseDto Commodity created successfully
1935
1999
  * @throws ApiError
1936
2000
  */
1937
- public static expectedTransactionControllerFindAll(
1938
- data: ExpectedTransactionControllerFindAllData
1939
- ): CancelablePromise<ExpectedTransactionControllerFindAllResponse> {
2001
+ public static commodityControllerCreate(
2002
+ data: CommodityControllerCreateData
2003
+ ): CancelablePromise<CommodityControllerCreateResponse> {
1940
2004
  return __request(OpenAPI, {
1941
- method: 'GET',
1942
- url: '/api/v1/{region}/bean/expected-transactions',
2005
+ method: 'POST',
2006
+ url: '/api/v1/{region}/bean/commodities',
1943
2007
  path: {
1944
2008
  region: data.region
1945
2009
  },
1946
- query: {
1947
- ruleId: data.ruleId,
1948
- status: data.status,
1949
- fromDate: data.fromDate,
1950
- toDate: data.toDate
2010
+ body: data.requestBody,
2011
+ mediaType: 'application/json',
2012
+ errors: {
2013
+ 400: 'Invalid input data',
2014
+ 409: 'Commodity already exists'
1951
2015
  }
1952
2016
  });
1953
2017
  }
1954
2018
 
1955
2019
  /**
1956
- * List overdue expected transactions
1957
- * Returns all overdue expected transactions (PENDING past tolerance)
2020
+ * List user commodities
2021
+ * Returns all commodity definitions for the authenticated user with optional filtering
1958
2022
  * @param data The data for the request.
1959
2023
  * @param data.region Region code for tenant context
1960
- * @returns ExpectedTransactionListResponseDto Overdue transactions retrieved successfully
2024
+ * @param data.search Search term for symbol or metadata fields (partial match). Searches symbol and metadata.name.
2025
+ * @param data.symbol Filter by exact symbol match
2026
+ * @returns CommodityListResponseDto Commodities retrieved successfully
1961
2027
  * @throws ApiError
1962
2028
  */
1963
- public static expectedTransactionControllerFindOverdue(
1964
- data: ExpectedTransactionControllerFindOverdueData
1965
- ): CancelablePromise<ExpectedTransactionControllerFindOverdueResponse> {
2029
+ public static commodityControllerFindAll(
2030
+ data: CommodityControllerFindAllData
2031
+ ): CancelablePromise<CommodityControllerFindAllResponse> {
1966
2032
  return __request(OpenAPI, {
1967
2033
  method: 'GET',
1968
- url: '/api/v1/{region}/bean/expected-transactions/overdue',
2034
+ url: '/api/v1/{region}/bean/commodities',
1969
2035
  path: {
1970
2036
  region: data.region
2037
+ },
2038
+ query: {
2039
+ search: data.search,
2040
+ symbol: data.symbol
1971
2041
  }
1972
2042
  });
1973
2043
  }
1974
2044
 
1975
2045
  /**
1976
- * Get expected transaction by ID
1977
- * Returns a specific expected transaction with rule details
2046
+ * Get commodity by symbol
2047
+ * Returns a specific commodity definition by its symbol
1978
2048
  * @param data The data for the request.
1979
- * @param data.id Expected transaction ID
2049
+ * @param data.symbol Commodity symbol
1980
2050
  * @param data.region Region code for tenant context
1981
- * @returns ExpectedTransactionResponseDto Expected transaction retrieved successfully
2051
+ * @returns CommodityResponseDto Commodity retrieved successfully
1982
2052
  * @throws ApiError
1983
2053
  */
1984
- public static expectedTransactionControllerFindOne(
1985
- data: ExpectedTransactionControllerFindOneData
1986
- ): CancelablePromise<ExpectedTransactionControllerFindOneResponse> {
2054
+ public static commodityControllerFindOne(
2055
+ data: CommodityControllerFindOneData
2056
+ ): CancelablePromise<CommodityControllerFindOneResponse> {
1987
2057
  return __request(OpenAPI, {
1988
2058
  method: 'GET',
1989
- url: '/api/v1/{region}/bean/expected-transactions/{id}',
2059
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
1990
2060
  path: {
1991
- id: data.id,
2061
+ symbol: data.symbol,
1992
2062
  region: data.region
1993
2063
  },
1994
2064
  errors: {
1995
- 404: 'Expected transaction not found'
2065
+ 404: 'Commodity not found'
1996
2066
  }
1997
2067
  });
1998
2068
  }
1999
2069
 
2000
2070
  /**
2001
- * Skip expected transaction
2002
- * Marks an expected transaction as skipped (PENDING -> SKIPPED)
2071
+ * Update commodity
2072
+ * Updates an existing commodity definition. Symbol cannot be changed.
2003
2073
  * @param data The data for the request.
2004
- * @param data.id Expected transaction ID
2074
+ * @param data.symbol Commodity symbol
2005
2075
  * @param data.region Region code for tenant context
2006
- * @returns ExpectedTransactionResponseDto Expected transaction skipped successfully
2076
+ * @param data.requestBody
2077
+ * @returns CommodityResponseDto Commodity updated successfully
2007
2078
  * @throws ApiError
2008
2079
  */
2009
- public static expectedTransactionControllerSkip(
2010
- data: ExpectedTransactionControllerSkipData
2011
- ): CancelablePromise<ExpectedTransactionControllerSkipResponse> {
2080
+ public static commodityControllerUpdate(
2081
+ data: CommodityControllerUpdateData
2082
+ ): CancelablePromise<CommodityControllerUpdateResponse> {
2012
2083
  return __request(OpenAPI, {
2013
- method: 'POST',
2014
- url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
2084
+ method: 'PUT',
2085
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
2015
2086
  path: {
2016
- id: data.id,
2087
+ symbol: data.symbol,
2017
2088
  region: data.region
2018
2089
  },
2090
+ body: data.requestBody,
2091
+ mediaType: 'application/json',
2019
2092
  errors: {
2020
- 400: 'Cannot skip - not in PENDING status',
2021
- 404: 'Expected transaction not found'
2093
+ 400: 'Invalid input data',
2094
+ 404: 'Commodity not found'
2022
2095
  }
2023
2096
  });
2024
2097
  }
2025
2098
 
2026
2099
  /**
2027
- * Undo skip
2028
- * Reverses a skip operation (SKIPPED -> PENDING)
2100
+ * Delete commodity
2101
+ * Deletes a commodity definition
2029
2102
  * @param data The data for the request.
2030
- * @param data.id Expected transaction ID
2103
+ * @param data.symbol Commodity symbol
2031
2104
  * @param data.region Region code for tenant context
2032
- * @returns ExpectedTransactionResponseDto Skip undone successfully
2105
+ * @returns void Commodity deleted successfully
2033
2106
  * @throws ApiError
2034
2107
  */
2035
- public static expectedTransactionControllerUndoSkip(
2036
- data: ExpectedTransactionControllerUndoSkipData
2037
- ): CancelablePromise<ExpectedTransactionControllerUndoSkipResponse> {
2108
+ public static commodityControllerDelete(
2109
+ data: CommodityControllerDeleteData
2110
+ ): CancelablePromise<CommodityControllerDeleteResponse> {
2038
2111
  return __request(OpenAPI, {
2039
2112
  method: 'DELETE',
2040
- url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
2113
+ url: '/api/v1/{region}/bean/commodities/{symbol}',
2041
2114
  path: {
2042
- id: data.id,
2115
+ symbol: data.symbol,
2043
2116
  region: data.region
2044
2117
  },
2045
2118
  errors: {
2046
- 400: 'Cannot undo - not in SKIPPED status',
2047
- 404: 'Expected transaction not found'
2119
+ 404: 'Commodity not found'
2048
2120
  }
2049
2121
  });
2050
2122
  }
2051
2123
 
2052
2124
  /**
2053
- * Confirm transaction match
2054
- * Manually matches an expected transaction with an actual transaction
2125
+ * Ensure commodity exists
2126
+ * Gets existing commodity or creates it with automatic initialization from OpenBB
2055
2127
  * @param data The data for the request.
2056
- * @param data.id Expected transaction ID
2128
+ * @param data.symbol Commodity symbol
2057
2129
  * @param data.region Region code for tenant context
2058
- * @param data.requestBody
2059
- * @returns unknown Match confirmed successfully
2130
+ * @returns CommodityResponseDto Commodity retrieved or created
2060
2131
  * @throws ApiError
2061
2132
  */
2062
- public static expectedTransactionControllerConfirmMatch(
2063
- data: ExpectedTransactionControllerConfirmMatchData
2064
- ): CancelablePromise<ExpectedTransactionControllerConfirmMatchResponse> {
2133
+ public static commodityControllerGetOrCreate(
2134
+ data: CommodityControllerGetOrCreateData
2135
+ ): CancelablePromise<CommodityControllerGetOrCreateResponse> {
2065
2136
  return __request(OpenAPI, {
2066
2137
  method: 'POST',
2067
- url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
2138
+ url: '/api/v1/{region}/bean/commodities/{symbol}/ensure',
2068
2139
  path: {
2069
- id: data.id,
2140
+ symbol: data.symbol,
2070
2141
  region: data.region
2071
- },
2072
- body: data.requestBody,
2073
- mediaType: 'application/json',
2074
- errors: {
2075
- 400: 'Cannot match - not in PENDING status',
2076
- 404: 'Expected or actual transaction not found',
2077
- 409: 'Actual transaction already matched to another rule'
2078
2142
  }
2079
2143
  });
2080
2144
  }
2081
2145
 
2082
2146
  /**
2083
- * Unmatch transaction
2084
- * Removes the match between expected and actual transaction (COMPLETED -> PENDING)
2147
+ * Bulk create commodities
2148
+ * Creates multiple commodities from a list of symbols, useful for initialization
2085
2149
  * @param data The data for the request.
2086
- * @param data.id Expected transaction ID
2087
2150
  * @param data.region Region code for tenant context
2088
- * @returns unknown Match removed successfully
2151
+ * @returns CommodityResponseDto Commodities created successfully
2089
2152
  * @throws ApiError
2090
2153
  */
2091
- public static expectedTransactionControllerUnmatch(
2092
- data: ExpectedTransactionControllerUnmatchData
2093
- ): CancelablePromise<ExpectedTransactionControllerUnmatchResponse> {
2154
+ public static commodityControllerBulkCreate(
2155
+ data: CommodityControllerBulkCreateData
2156
+ ): CancelablePromise<CommodityControllerBulkCreateResponse> {
2094
2157
  return __request(OpenAPI, {
2095
- method: 'DELETE',
2096
- url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
2158
+ method: 'POST',
2159
+ url: '/api/v1/{region}/bean/commodities/bulk',
2097
2160
  path: {
2098
- id: data.id,
2099
2161
  region: data.region
2100
- },
2101
- errors: {
2102
- 400: 'Cannot unmatch - not in COMPLETED status',
2103
- 404: 'Expected transaction not found'
2104
2162
  }
2105
2163
  });
2106
2164
  }
2165
+ }
2107
2166
 
2167
+ export class ReportingService {
2108
2168
  /**
2109
- * Enter Now
2110
- * Creates an actual transaction for an expected transaction (YNAB-style Enter Now)
2169
+ * Get portfolio value trends
2170
+ *
2171
+ * Returns time series data of portfolio net worth.
2172
+ *
2173
+ * **Multi-currency Support:**
2174
+ * - `series[].byCurrency` - Currency breakdown for each data point
2175
+ * - `byCurrency` - Separate time series grouped by currency
2176
+ * - `warnings` - Exchange rate warnings if conversion failed
2177
+ *
2178
+ * **Parameters:**
2179
+ * - `period`: Time period (1m, 3m, 6m, 1y)
2180
+ * - `granularity`: Data granularity (day, week, month)
2181
+ *
2111
2182
  * @param data The data for the request.
2112
- * @param data.id Expected transaction ID
2113
2183
  * @param data.region Region code for tenant context
2114
- * @param data.requestBody
2115
- * @returns unknown Transaction created successfully
2116
- * @throws ApiError
2117
- */
2118
- public static expectedTransactionControllerEnterNow(
2119
- data: ExpectedTransactionControllerEnterNowData
2120
- ): CancelablePromise<ExpectedTransactionControllerEnterNowResponse> {
2184
+ * @param data.period Time period
2185
+ * @param data.granularity Data granularity
2186
+ * @returns PortfolioTrendsResponseDto Trends retrieved successfully
2187
+ * @throws ApiError
2188
+ */
2189
+ public static reportingControllerGetPortfolioTrends(
2190
+ data: ReportingControllerGetPortfolioTrendsData
2191
+ ): CancelablePromise<ReportingControllerGetPortfolioTrendsResponse> {
2121
2192
  return __request(OpenAPI, {
2122
- method: 'POST',
2123
- url: '/api/v1/{region}/bean/expected-transactions/{id}/enter',
2193
+ method: 'GET',
2194
+ url: '/api/v1/{region}/reporting/portfolio/trends',
2124
2195
  path: {
2125
- id: data.id,
2126
2196
  region: data.region
2127
2197
  },
2128
- body: data.requestBody,
2129
- mediaType: 'application/json',
2198
+ query: {
2199
+ period: data.period,
2200
+ granularity: data.granularity
2201
+ },
2130
2202
  errors: {
2131
- 400: 'Cannot enter - not in PENDING status or missing accounts',
2132
- 404: 'Expected transaction or accounts not found'
2203
+ 401: 'User not authenticated'
2133
2204
  }
2134
2205
  });
2135
2206
  }
2136
- }
2137
2207
 
2138
- export class RecurringForecastService {
2139
2208
  /**
2140
- * Get cash flow forecast
2141
- * Returns predicted outflows for the next N months based on active recurring rules
2209
+ * Get cash-flow trends
2210
+ *
2211
+ * Monthly income / expense / netSavings over a fixed N-month window
2212
+ * (current month + N−1 prior). Missing months are zero-filled (flow metric).
2213
+ *
2214
+ * **Parameters:**
2215
+ * - `period`: 1m | 3m | 6m | 1y (default 6m)
2216
+ * - `granularity`: accepted for API symmetry; v1 returns month buckets
2217
+ *
2142
2218
  * @param data The data for the request.
2143
2219
  * @param data.region Region code for tenant context
2144
- * @param data.months Number of months to forecast (1-12, default 3)
2145
- * @returns ForecastResponseDto Forecast retrieved successfully
2220
+ * @param data.period Time period
2221
+ * @param data.granularity Data granularity (accepted for API symmetry; v1 returns month buckets)
2222
+ * @returns CashFlowTrendsResponseDto Cash-flow trends retrieved successfully
2146
2223
  * @throws ApiError
2147
2224
  */
2148
- public static forecastControllerGetForecast(
2149
- data: ForecastControllerGetForecastData
2150
- ): CancelablePromise<ForecastControllerGetForecastResponse> {
2225
+ public static reportingControllerGetCashFlowTrends(
2226
+ data: ReportingControllerGetCashFlowTrendsData
2227
+ ): CancelablePromise<ReportingControllerGetCashFlowTrendsResponse> {
2151
2228
  return __request(OpenAPI, {
2152
2229
  method: 'GET',
2153
- url: '/api/v1/{region}/bean/recurring/forecast',
2230
+ url: '/api/v1/{region}/reporting/cash-flow/trends',
2154
2231
  path: {
2155
2232
  region: data.region
2156
2233
  },
2157
2234
  query: {
2158
- months: data.months
2235
+ period: data.period,
2236
+ granularity: data.granularity
2237
+ },
2238
+ errors: {
2239
+ 401: 'User not authenticated'
2159
2240
  }
2160
2241
  });
2161
2242
  }
2162
- }
2163
2243
 
2164
- export class BeanTransactionRulesService {
2165
2244
  /**
2166
- * Create a new transaction rule (or upsert if upsertByPayee=true)
2167
- * Creates a new rule. If upsertByPayee=true, updates existing rule matching payeeKeywords[0] instead of creating duplicate.
2245
+ * Generate portfolio snapshot
2246
+ *
2247
+ * Manually generate a portfolio snapshot for a specific date.
2248
+ *
2249
+ * **Multi-currency Support:**
2250
+ * - Fetches balances grouped by currency
2251
+ * - Uses user's baseCurrency setting for conversion
2252
+ * - Stores exchange rates and warnings
2253
+ *
2254
+ * **Use Cases:**
2255
+ * - Testing snapshot generation
2256
+ * - Force regeneration after data correction
2257
+ * - Initial setup for new users
2258
+ *
2168
2259
  * @param data The data for the request.
2169
2260
  * @param data.region Region code for tenant context
2170
- * @param data.requestBody
2171
- * @returns TransactionRuleResponseDto Rule updated successfully (upsert mode)
2261
+ * @param data.requestBody Optional date (defaults to today)
2262
+ * @returns GenerateSnapshotResponse Snapshot generated successfully
2172
2263
  * @throws ApiError
2173
2264
  */
2174
- public static transactionRuleControllerCreate(
2175
- data: TransactionRuleControllerCreateData
2176
- ): CancelablePromise<TransactionRuleControllerCreateResponse> {
2265
+ public static reportingControllerGenerateSnapshot(
2266
+ data: ReportingControllerGenerateSnapshotData
2267
+ ): CancelablePromise<ReportingControllerGenerateSnapshotResponse> {
2177
2268
  return __request(OpenAPI, {
2178
2269
  method: 'POST',
2179
- url: '/api/v1/{region}/bean/transaction-rules',
2270
+ url: '/api/v1/{region}/reporting/snapshots/generate',
2180
2271
  path: {
2181
2272
  region: data.region
2182
2273
  },
2183
2274
  body: data.requestBody,
2184
2275
  mediaType: 'application/json',
2185
2276
  errors: {
2186
- 400: 'Validation failed',
2187
- 401: 'Unauthorized',
2188
- 409: 'Resource conflict - another process is updating this rule'
2277
+ 400: 'Invalid date format',
2278
+ 401: 'User not authenticated'
2189
2279
  }
2190
2280
  });
2191
2281
  }
2192
2282
 
2193
2283
  /**
2194
- * Get all transaction rules for user
2284
+ * Backfill portfolio snapshots
2285
+ *
2286
+ * Generate snapshots for a date range (historical data backfill).
2287
+ *
2288
+ * **Multi-currency Support:**
2289
+ * - Each snapshot includes multi-currency data
2290
+ * - Uses exchange rates available at generation time
2291
+ * - Warnings stored for missing exchange rates
2292
+ *
2293
+ * **Best Practices:**
2294
+ * - Use for initial setup after account configuration
2295
+ * - Run during low-traffic periods for large date ranges
2296
+ * - Existing snapshots are skipped (not regenerated)
2297
+ *
2195
2298
  * @param data The data for the request.
2196
2299
  * @param data.region Region code for tenant context
2197
- * @param data.limit Max results per page (default: 20, max: 100)
2198
- * @param data.offset Pagination offset (default: 0)
2199
- * @param data.enabled Filter by enabled status
2200
- * @param data.learningSource Filter by learning source. Omit this parameter or pass empty string to get manually created rules (learningSource is null in database).
2201
- * @param data.autoApplyEnabled Filter by auto-apply status
2202
- * @returns TransactionRuleListResponseDto List of rules
2300
+ * @param data.requestBody
2301
+ * @returns BackfillSnapshotsResponse Backfill completed successfully
2203
2302
  * @throws ApiError
2204
2303
  */
2205
- public static transactionRuleControllerList(
2206
- data: TransactionRuleControllerListData
2207
- ): CancelablePromise<TransactionRuleControllerListResponse> {
2304
+ public static reportingControllerBackfillSnapshots(
2305
+ data: ReportingControllerBackfillSnapshotsData
2306
+ ): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
2208
2307
  return __request(OpenAPI, {
2209
- method: 'GET',
2210
- url: '/api/v1/{region}/bean/transaction-rules',
2308
+ method: 'POST',
2309
+ url: '/api/v1/{region}/reporting/snapshots/backfill',
2211
2310
  path: {
2212
2311
  region: data.region
2213
2312
  },
2214
- query: {
2215
- limit: data.limit,
2216
- offset: data.offset,
2217
- enabled: data.enabled,
2218
- learningSource: data.learningSource,
2219
- autoApplyEnabled: data.autoApplyEnabled
2220
- },
2313
+ body: data.requestBody,
2314
+ mediaType: 'application/json',
2221
2315
  errors: {
2222
- 401: 'Unauthorized'
2316
+ 400: 'Invalid date format or range',
2317
+ 401: 'User not authenticated',
2318
+ 409: 'Backfill already in progress for this user'
2223
2319
  }
2224
2320
  });
2225
2321
  }
2322
+ }
2226
2323
 
2324
+ export class BeanPricesService {
2227
2325
  /**
2228
- * Validate transaction rule configuration
2326
+ * Create a new price
2327
+ * Creates a new price entry for the authenticated user
2229
2328
  * @param data The data for the request.
2230
2329
  * @param data.region Region code for tenant context
2231
2330
  * @param data.requestBody
2232
- * @returns ValidateRuleResponseDto Validation result
2331
+ * @returns PriceResponseDto Price created successfully
2233
2332
  * @throws ApiError
2234
2333
  */
2235
- public static transactionRuleControllerValidate(
2236
- data: TransactionRuleControllerValidateData
2237
- ): CancelablePromise<TransactionRuleControllerValidateResponse> {
2334
+ public static priceControllerCreate(
2335
+ data: PriceControllerCreateData
2336
+ ): CancelablePromise<PriceControllerCreateResponse> {
2238
2337
  return __request(OpenAPI, {
2239
2338
  method: 'POST',
2240
- url: '/api/v1/{region}/bean/transaction-rules/validate',
2339
+ url: '/api/v1/{region}/bean/prices',
2241
2340
  path: {
2242
2341
  region: data.region
2243
2342
  },
2244
2343
  body: data.requestBody,
2245
2344
  mediaType: 'application/json',
2246
2345
  errors: {
2247
- 400: 'Validation failed',
2248
- 401: 'Unauthorized'
2346
+ 404: 'Currency or quoteCurrency commodity not found',
2347
+ 409: 'Price already exists for this currency pair and date'
2249
2348
  }
2250
2349
  });
2251
2350
  }
2252
2351
 
2253
2352
  /**
2254
- * Bulk create transaction rules
2353
+ * List user prices
2354
+ * Returns all price entries for the authenticated user with optional filtering
2255
2355
  * @param data The data for the request.
2256
2356
  * @param data.region Region code for tenant context
2257
- * @param data.requestBody
2258
- * @returns BulkCreateRulesResponseDto Bulk create completed
2357
+ * @param data.currency Filter by currency (e.g., BTC, AAPL, USD)
2358
+ * @param data.quoteCurrency Filter by quote currency (pricing currency, e.g., USD, CNY)
2359
+ * @param data.dateFrom Filter prices from this date (ISO 8601 format)
2360
+ * @param data.dateTo Filter prices to this date (ISO 8601 format)
2361
+ * @param data.search Search term for currency or quoteCurrency (case-insensitive partial match)
2362
+ * @param data.page Page number for pagination (default: 1)
2363
+ * @param data.limit Number of items per page (default: 20, max: 100)
2364
+ * @returns PriceListResponseDto Prices retrieved successfully
2259
2365
  * @throws ApiError
2260
2366
  */
2261
- public static transactionRuleControllerBulkCreate(
2262
- data: TransactionRuleControllerBulkCreateData
2263
- ): CancelablePromise<TransactionRuleControllerBulkCreateResponse> {
2367
+ public static priceControllerFindAll(
2368
+ data: PriceControllerFindAllData
2369
+ ): CancelablePromise<PriceControllerFindAllResponse> {
2264
2370
  return __request(OpenAPI, {
2265
- method: 'POST',
2266
- url: '/api/v1/{region}/bean/transaction-rules/bulk',
2371
+ method: 'GET',
2372
+ url: '/api/v1/{region}/bean/prices',
2267
2373
  path: {
2268
2374
  region: data.region
2269
2375
  },
2270
- body: data.requestBody,
2271
- mediaType: 'application/json',
2272
- errors: {
2273
- 400: 'Invalid bulk create data',
2274
- 401: 'Unauthorized'
2376
+ query: {
2377
+ currency: data.currency,
2378
+ quoteCurrency: data.quoteCurrency,
2379
+ dateFrom: data.dateFrom,
2380
+ dateTo: data.dateTo,
2381
+ search: data.search,
2382
+ page: data.page,
2383
+ limit: data.limit
2275
2384
  }
2276
2385
  });
2277
2386
  }
2278
2387
 
2279
2388
  /**
2280
- * Export transaction rules
2389
+ * Get price by ID
2390
+ * Returns a single price entry by its ID
2281
2391
  * @param data The data for the request.
2282
- * @param data.format Export format (currently only JSON supported)
2392
+ * @param data.id Price ID
2283
2393
  * @param data.region Region code for tenant context
2284
- * @returns ExportRulesResponseDto Exported rules
2394
+ * @returns PriceResponseDto Price retrieved successfully
2285
2395
  * @throws ApiError
2286
2396
  */
2287
- public static transactionRuleControllerExport(
2288
- data: TransactionRuleControllerExportData
2289
- ): CancelablePromise<TransactionRuleControllerExportResponse> {
2397
+ public static priceControllerFindOne(
2398
+ data: PriceControllerFindOneData
2399
+ ): CancelablePromise<PriceControllerFindOneResponse> {
2290
2400
  return __request(OpenAPI, {
2291
2401
  method: 'GET',
2292
- url: '/api/v1/{region}/bean/transaction-rules/export/{format}',
2402
+ url: '/api/v1/{region}/bean/prices/{id}',
2293
2403
  path: {
2294
- format: data.format,
2404
+ id: data.id,
2295
2405
  region: data.region
2296
2406
  },
2297
2407
  errors: {
2298
- 400: 'Unsupported format',
2299
- 401: 'Unauthorized'
2408
+ 404: 'Price not found'
2300
2409
  }
2301
2410
  });
2302
2411
  }
2303
2412
 
2304
2413
  /**
2305
- * Get transaction rule statistics
2414
+ * Update a price
2415
+ * Updates an existing price entry
2306
2416
  * @param data The data for the request.
2307
- * @param data.period Statistics time period
2417
+ * @param data.id Price ID
2308
2418
  * @param data.region Region code for tenant context
2309
- * @returns RuleStatisticsResponseDto Rule statistics
2419
+ * @param data.requestBody
2420
+ * @returns PriceResponseDto Price updated successfully
2310
2421
  * @throws ApiError
2311
2422
  */
2312
- public static transactionRuleControllerGetStatistics(
2313
- data: TransactionRuleControllerGetStatisticsData
2314
- ): CancelablePromise<TransactionRuleControllerGetStatisticsResponse> {
2423
+ public static priceControllerUpdate(
2424
+ data: PriceControllerUpdateData
2425
+ ): CancelablePromise<PriceControllerUpdateResponse> {
2315
2426
  return __request(OpenAPI, {
2316
- method: 'GET',
2317
- url: '/api/v1/{region}/bean/transaction-rules/statistics/{period}',
2427
+ method: 'PUT',
2428
+ url: '/api/v1/{region}/bean/prices/{id}',
2318
2429
  path: {
2319
- period: data.period,
2430
+ id: data.id,
2320
2431
  region: data.region
2321
2432
  },
2433
+ body: data.requestBody,
2434
+ mediaType: 'application/json',
2322
2435
  errors: {
2323
- 401: 'Unauthorized'
2436
+ 404: 'Price not found',
2437
+ 409: 'Updated price conflicts with existing price'
2324
2438
  }
2325
2439
  });
2326
2440
  }
2327
2441
 
2328
2442
  /**
2329
- * Get transaction rule detail
2443
+ * Delete a price
2444
+ * Deletes a price entry (hard delete)
2330
2445
  * @param data The data for the request.
2331
- * @param data.ruleId Rule ID
2446
+ * @param data.id Price ID
2332
2447
  * @param data.region Region code for tenant context
2333
- * @returns TransactionRuleResponseDto Rule details
2448
+ * @returns void Price deleted successfully
2334
2449
  * @throws ApiError
2335
2450
  */
2336
- public static transactionRuleControllerGetDetail(
2337
- data: TransactionRuleControllerGetDetailData
2338
- ): CancelablePromise<TransactionRuleControllerGetDetailResponse> {
2451
+ public static priceControllerDelete(
2452
+ data: PriceControllerDeleteData
2453
+ ): CancelablePromise<PriceControllerDeleteResponse> {
2339
2454
  return __request(OpenAPI, {
2340
- method: 'GET',
2341
- url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
2455
+ method: 'DELETE',
2456
+ url: '/api/v1/{region}/bean/prices/{id}',
2342
2457
  path: {
2343
- ruleId: data.ruleId,
2458
+ id: data.id,
2344
2459
  region: data.region
2345
2460
  },
2346
2461
  errors: {
2347
- 401: 'Unauthorized',
2348
- 403: 'Forbidden - not owner of rule',
2349
- 404: 'Rule not found'
2462
+ 404: 'Price not found'
2350
2463
  }
2351
2464
  });
2352
2465
  }
2353
2466
 
2354
2467
  /**
2355
- * Update a transaction rule
2468
+ * Bulk create prices
2469
+ * Creates multiple price entries at once (skips duplicates)
2356
2470
  * @param data The data for the request.
2357
- * @param data.ruleId Rule ID to update
2358
2471
  * @param data.region Region code for tenant context
2359
2472
  * @param data.requestBody
2360
- * @returns TransactionRuleResponseDto Rule updated successfully
2473
+ * @returns PriceResponseDto Prices created successfully
2361
2474
  * @throws ApiError
2362
2475
  */
2363
- public static transactionRuleControllerUpdate(
2364
- data: TransactionRuleControllerUpdateData
2365
- ): CancelablePromise<TransactionRuleControllerUpdateResponse> {
2476
+ public static priceControllerBulkCreate(
2477
+ data: PriceControllerBulkCreateData
2478
+ ): CancelablePromise<PriceControllerBulkCreateResponse> {
2366
2479
  return __request(OpenAPI, {
2367
- method: 'PUT',
2368
- url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
2480
+ method: 'POST',
2481
+ url: '/api/v1/{region}/bean/prices/bulk',
2369
2482
  path: {
2370
- ruleId: data.ruleId,
2371
2483
  region: data.region
2372
2484
  },
2373
2485
  body: data.requestBody,
2374
- mediaType: 'application/json',
2375
- errors: {
2376
- 400: 'Validation failed',
2377
- 401: 'Unauthorized',
2378
- 403: 'Forbidden - not owner of rule',
2379
- 404: 'Rule not found',
2380
- 409: 'Resource conflict - rule is being modified by another process'
2381
- }
2486
+ mediaType: 'application/json'
2382
2487
  });
2383
2488
  }
2489
+ }
2384
2490
 
2491
+ export class RecurringRulesService {
2385
2492
  /**
2386
- * Delete a transaction rule
2493
+ * Create a new recurring rule
2494
+ * Creates a new recurring transaction rule for the authenticated user
2387
2495
  * @param data The data for the request.
2388
- * @param data.ruleId Rule ID to delete
2389
2496
  * @param data.region Region code for tenant context
2390
- * @returns void Rule deleted successfully
2497
+ * @param data.requestBody
2498
+ * @returns RecurringRuleResponseDto Rule created successfully
2391
2499
  * @throws ApiError
2392
2500
  */
2393
- public static transactionRuleControllerDelete(
2394
- data: TransactionRuleControllerDeleteData
2395
- ): CancelablePromise<TransactionRuleControllerDeleteResponse> {
2501
+ public static recurringRuleControllerCreate(
2502
+ data: RecurringRuleControllerCreateData
2503
+ ): CancelablePromise<RecurringRuleControllerCreateResponse> {
2396
2504
  return __request(OpenAPI, {
2397
- method: 'DELETE',
2398
- url: '/api/v1/{region}/bean/transaction-rules/{ruleId}',
2505
+ method: 'POST',
2506
+ url: '/api/v1/{region}/bean/recurring-rules',
2399
2507
  path: {
2400
- ruleId: data.ruleId,
2401
2508
  region: data.region
2402
2509
  },
2510
+ body: data.requestBody,
2511
+ mediaType: 'application/json',
2403
2512
  errors: {
2404
- 401: 'Unauthorized',
2405
- 403: 'Forbidden - not owner of rule',
2406
- 404: 'Rule not found',
2407
- 409: 'Resource conflict - rule is being modified by another process'
2513
+ 400: 'Invalid input data (e.g., autoCreate without accounts)',
2514
+ 409: 'Rule with same name already exists'
2408
2515
  }
2409
2516
  });
2410
2517
  }
2411
2518
 
2412
2519
  /**
2413
- * Test rule matching
2520
+ * List recurring rules
2521
+ * Returns all recurring rules for the authenticated user with optional filtering
2414
2522
  * @param data The data for the request.
2415
- * @param data.ruleId Rule ID to test
2416
2523
  * @param data.region Region code for tenant context
2417
- * @param data.requestBody
2418
- * @returns TestRuleResponseDto Test result
2524
+ * @param data.isActive Filter by active status
2525
+ * @param data.frequency Filter by frequency (WEEKLY, MONTHLY, etc.)
2526
+ * @param data.hasAutoCreate Filter by autoCreate enabled
2527
+ * @returns RecurringRuleResponseDto Rules retrieved successfully
2419
2528
  * @throws ApiError
2420
2529
  */
2421
- public static transactionRuleControllerTest(
2422
- data: TransactionRuleControllerTestData
2423
- ): CancelablePromise<TransactionRuleControllerTestResponse> {
2530
+ public static recurringRuleControllerFindAll(
2531
+ data: RecurringRuleControllerFindAllData
2532
+ ): CancelablePromise<RecurringRuleControllerFindAllResponse> {
2424
2533
  return __request(OpenAPI, {
2425
- method: 'POST',
2426
- url: '/api/v1/{region}/bean/transaction-rules/{ruleId}/test',
2534
+ method: 'GET',
2535
+ url: '/api/v1/{region}/bean/recurring-rules',
2427
2536
  path: {
2428
- ruleId: data.ruleId,
2429
2537
  region: data.region
2430
2538
  },
2431
- body: data.requestBody,
2432
- mediaType: 'application/json',
2433
- errors: {
2434
- 401: 'Unauthorized',
2435
- 403: 'Forbidden - not owner of rule',
2436
- 404: 'Rule not found'
2539
+ query: {
2540
+ isActive: data.isActive,
2541
+ frequency: data.frequency,
2542
+ hasAutoCreate: data.hasAutoCreate
2437
2543
  }
2438
2544
  });
2439
2545
  }
2440
- }
2441
2546
 
2442
- export class UsersService {
2443
2547
  /**
2444
- * Delete own user account
2548
+ * Create recurring rule from transaction
2549
+ * Auto-creates a recurring rule using transaction data. User only confirms frequency.
2445
2550
  * @param data The data for the request.
2551
+ * @param data.transactionId Source transaction ID
2552
+ * @param data.region Region code for tenant context
2446
2553
  * @param data.requestBody
2447
- * @returns void User deleted successfully
2554
+ * @returns RecurringRuleResponseDto Rule created successfully
2448
2555
  * @throws ApiError
2449
2556
  */
2450
- public static userControllerDeleteOwnUser(
2451
- data: UserControllerDeleteOwnUserData
2452
- ): CancelablePromise<UserControllerDeleteOwnUserResponse> {
2557
+ public static recurringRuleControllerCreateFromTransaction(
2558
+ data: RecurringRuleControllerCreateFromTransactionData
2559
+ ): CancelablePromise<RecurringRuleControllerCreateFromTransactionResponse> {
2453
2560
  return __request(OpenAPI, {
2454
- method: 'DELETE',
2455
- url: '/api/v1/users',
2561
+ method: 'POST',
2562
+ url: '/api/v1/{region}/bean/recurring-rules/from-transaction/{transactionId}',
2563
+ path: {
2564
+ transactionId: data.transactionId,
2565
+ region: data.region
2566
+ },
2456
2567
  body: data.requestBody,
2457
2568
  mediaType: 'application/json',
2458
2569
  errors: {
2459
- 403: 'Invalid access token'
2570
+ 404: 'Transaction not found',
2571
+ 409: 'Rule with same name already exists or transaction already linked'
2460
2572
  }
2461
2573
  });
2462
2574
  }
2463
2575
 
2464
2576
  /**
2465
- * Get current authenticated user
2577
+ * Get recurring rule by ID
2578
+ * Returns a specific recurring rule with its details
2466
2579
  * @param data The data for the request.
2467
- * @param data.acceptLanguage
2468
- * @returns unknown User retrieved successfully
2580
+ * @param data.id Rule ID
2581
+ * @param data.region Region code for tenant context
2582
+ * @returns RecurringRuleResponseDto Rule retrieved successfully
2469
2583
  * @throws ApiError
2470
2584
  */
2471
- public static userControllerGetUser(
2472
- data: UserControllerGetUserData
2473
- ): CancelablePromise<UserControllerGetUserResponse> {
2585
+ public static recurringRuleControllerFindOne(
2586
+ data: RecurringRuleControllerFindOneData
2587
+ ): CancelablePromise<RecurringRuleControllerFindOneResponse> {
2474
2588
  return __request(OpenAPI, {
2475
2589
  method: 'GET',
2476
- url: '/api/v1/users',
2477
- headers: {
2478
- 'accept-language': data.acceptLanguage
2590
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
2591
+ path: {
2592
+ id: data.id,
2593
+ region: data.region
2594
+ },
2595
+ errors: {
2596
+ 404: 'Rule not found'
2479
2597
  }
2480
2598
  });
2481
2599
  }
2482
2600
 
2483
2601
  /**
2484
- * Sign up new user
2485
- * Create a new account with auto-generated access token. Protected by Cloudflare Turnstile to prevent automated signup (when enabled).
2602
+ * Update recurring rule
2603
+ * Updates an existing recurring rule
2486
2604
  * @param data The data for the request.
2605
+ * @param data.id Rule ID
2606
+ * @param data.region Region code for tenant context
2487
2607
  * @param data.requestBody
2488
- * @returns unknown User created successfully
2608
+ * @returns RecurringRuleResponseDto Rule updated successfully
2489
2609
  * @throws ApiError
2490
2610
  */
2491
- public static userControllerSignupUser(
2492
- data: UserControllerSignupUserData
2493
- ): CancelablePromise<UserControllerSignupUserResponse> {
2611
+ public static recurringRuleControllerUpdate(
2612
+ data: RecurringRuleControllerUpdateData
2613
+ ): CancelablePromise<RecurringRuleControllerUpdateResponse> {
2494
2614
  return __request(OpenAPI, {
2495
- method: 'POST',
2496
- url: '/api/v1/users',
2615
+ method: 'PATCH',
2616
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
2617
+ path: {
2618
+ id: data.id,
2619
+ region: data.region
2620
+ },
2497
2621
  body: data.requestBody,
2498
2622
  mediaType: 'application/json',
2499
2623
  errors: {
2500
- 400: 'Invalid Turnstile token (when Turnstile is enabled)',
2501
- 403: 'User signup is disabled'
2624
+ 400: 'Invalid input data',
2625
+ 404: 'Rule not found'
2502
2626
  }
2503
2627
  });
2504
2628
  }
2505
2629
 
2506
2630
  /**
2507
- * Delete user by ID (admin only)
2631
+ * Delete recurring rule
2632
+ * Soft deletes a recurring rule (sets isActive to false)
2508
2633
  * @param data The data for the request.
2509
- * @param data.id User ID to delete
2510
- * @returns void User deleted successfully
2634
+ * @param data.id Rule ID
2635
+ * @param data.region Region code for tenant context
2636
+ * @returns void Rule deleted successfully
2511
2637
  * @throws ApiError
2512
2638
  */
2513
- public static userControllerDeleteUser(
2514
- data: UserControllerDeleteUserData
2515
- ): CancelablePromise<UserControllerDeleteUserResponse> {
2639
+ public static recurringRuleControllerDelete(
2640
+ data: RecurringRuleControllerDeleteData
2641
+ ): CancelablePromise<RecurringRuleControllerDeleteResponse> {
2516
2642
  return __request(OpenAPI, {
2517
2643
  method: 'DELETE',
2518
- url: '/api/v1/users/{id}',
2644
+ url: '/api/v1/{region}/bean/recurring-rules/{id}',
2519
2645
  path: {
2520
- id: data.id
2646
+ id: data.id,
2647
+ region: data.region
2521
2648
  },
2522
2649
  errors: {
2523
- 403: 'Cannot delete own account or insufficient permissions'
2650
+ 404: 'Rule not found'
2524
2651
  }
2525
2652
  });
2526
2653
  }
2527
2654
 
2528
2655
  /**
2529
- * Get user info by user ID
2656
+ * Get rule with statistics
2657
+ * Returns a rule with pending/overdue counts and next expected date
2530
2658
  * @param data The data for the request.
2531
- * @param data.id User ID
2532
- * @returns unknown User info retrieved successfully
2659
+ * @param data.id Rule ID
2660
+ * @param data.region Region code for tenant context
2661
+ * @returns RecurringRuleWithStatsResponseDto Rule with stats retrieved successfully
2533
2662
  * @throws ApiError
2534
2663
  */
2535
- public static userControllerGetUserInfo(
2536
- data: UserControllerGetUserInfoData
2537
- ): CancelablePromise<UserControllerGetUserInfoResponse> {
2664
+ public static recurringRuleControllerGetWithStats(
2665
+ data: RecurringRuleControllerGetWithStatsData
2666
+ ): CancelablePromise<RecurringRuleControllerGetWithStatsResponse> {
2538
2667
  return __request(OpenAPI, {
2539
2668
  method: 'GET',
2540
- url: '/api/v1/users/{id}/info',
2669
+ url: '/api/v1/{region}/bean/recurring-rules/{id}/stats',
2541
2670
  path: {
2542
- id: data.id
2671
+ id: data.id,
2672
+ region: data.region
2543
2673
  },
2544
2674
  errors: {
2545
- 403: 'Cannot access other user info without admin permission'
2675
+ 404: 'Rule not found'
2546
2676
  }
2547
2677
  });
2548
2678
  }
2679
+ }
2549
2680
 
2681
+ export class ExpectedTransactionsService {
2550
2682
  /**
2551
- * Update user settings
2683
+ * List expected transactions
2684
+ * Returns expected transactions for the authenticated user with optional filtering
2552
2685
  * @param data The data for the request.
2553
- * @param data.requestBody
2554
- * @returns unknown Settings updated successfully
2686
+ * @param data.region Region code for tenant context
2687
+ * @param data.ruleId Filter by recurring rule ID
2688
+ * @param data.status Filter by status (PENDING, COMPLETED, SKIPPED)
2689
+ * @param data.fromDate Filter by date range start (YYYY-MM-DD)
2690
+ * @param data.toDate Filter by date range end (YYYY-MM-DD)
2691
+ * @returns ExpectedTransactionListResponseDto Expected transactions retrieved successfully
2555
2692
  * @throws ApiError
2556
2693
  */
2557
- public static userControllerUpdateUserSetting(
2558
- data: UserControllerUpdateUserSettingData
2559
- ): CancelablePromise<UserControllerUpdateUserSettingResponse> {
2694
+ public static expectedTransactionControllerFindAll(
2695
+ data: ExpectedTransactionControllerFindAllData
2696
+ ): CancelablePromise<ExpectedTransactionControllerFindAllResponse> {
2560
2697
  return __request(OpenAPI, {
2561
- method: 'PUT',
2562
- url: '/api/v1/users/setting',
2563
- body: data.requestBody,
2564
- mediaType: 'application/json',
2565
- errors: {
2566
- 403: 'Insufficient permissions'
2698
+ method: 'GET',
2699
+ url: '/api/v1/{region}/bean/expected-transactions',
2700
+ path: {
2701
+ region: data.region
2702
+ },
2703
+ query: {
2704
+ ruleId: data.ruleId,
2705
+ status: data.status,
2706
+ fromDate: data.fromDate,
2707
+ toDate: data.toDate
2567
2708
  }
2568
2709
  });
2569
2710
  }
2570
2711
 
2571
2712
  /**
2572
- * Get all user settings paginated (admin only)
2713
+ * List overdue expected transactions
2714
+ * Returns all overdue expected transactions (PENDING past tolerance)
2573
2715
  * @param data The data for the request.
2574
- * @param data.pageNo Page number
2575
- * @param data.pageSize Page size
2576
- * @returns unknown Settings list retrieved successfully
2716
+ * @param data.region Region code for tenant context
2717
+ * @returns ExpectedTransactionListResponseDto Overdue transactions retrieved successfully
2577
2718
  * @throws ApiError
2578
2719
  */
2579
- public static userControllerGetAllUserSettingsByPage(
2580
- data: UserControllerGetAllUserSettingsByPageData
2581
- ): CancelablePromise<UserControllerGetAllUserSettingsByPageResponse> {
2720
+ public static expectedTransactionControllerFindOverdue(
2721
+ data: ExpectedTransactionControllerFindOverdueData
2722
+ ): CancelablePromise<ExpectedTransactionControllerFindOverdueResponse> {
2582
2723
  return __request(OpenAPI, {
2583
2724
  method: 'GET',
2584
- url: '/api/v1/users/settings-by-page',
2585
- query: {
2586
- pageNo: data.pageNo,
2587
- pageSize: data.pageSize
2725
+ url: '/api/v1/{region}/bean/expected-transactions/overdue',
2726
+ path: {
2727
+ region: data.region
2588
2728
  }
2589
2729
  });
2590
2730
  }
2591
2731
 
2592
2732
  /**
2593
- * Get asset and liability summary for current user
2594
- * @returns unknown Summary retrieved successfully
2733
+ * Get expected transaction by ID
2734
+ * Returns a specific expected transaction with rule details
2735
+ * @param data The data for the request.
2736
+ * @param data.id Expected transaction ID
2737
+ * @param data.region Region code for tenant context
2738
+ * @returns ExpectedTransactionResponseDto Expected transaction retrieved successfully
2595
2739
  * @throws ApiError
2596
2740
  */
2597
- public static userControllerGetAssetLiabilitySummary(): CancelablePromise<UserControllerGetAssetLiabilitySummaryResponse> {
2741
+ public static expectedTransactionControllerFindOne(
2742
+ data: ExpectedTransactionControllerFindOneData
2743
+ ): CancelablePromise<ExpectedTransactionControllerFindOneResponse> {
2598
2744
  return __request(OpenAPI, {
2599
2745
  method: 'GET',
2600
- url: '/api/v1/users/asset-liability-summary'
2746
+ url: '/api/v1/{region}/bean/expected-transactions/{id}',
2747
+ path: {
2748
+ id: data.id,
2749
+ region: data.region
2750
+ },
2751
+ errors: {
2752
+ 404: 'Expected transaction not found'
2753
+ }
2601
2754
  });
2602
2755
  }
2603
- }
2604
2756
 
2605
- export class PropertiesService {
2606
2757
  /**
2607
- * Get all system properties
2608
- * @returns unknown Properties retrieved successfully
2758
+ * Skip expected transaction
2759
+ * Marks an expected transaction as skipped (PENDING -> SKIPPED)
2760
+ * @param data The data for the request.
2761
+ * @param data.id Expected transaction ID
2762
+ * @param data.region Region code for tenant context
2763
+ * @returns ExpectedTransactionResponseDto Expected transaction skipped successfully
2609
2764
  * @throws ApiError
2610
2765
  */
2611
- public static propertyControllerGetAll(): CancelablePromise<PropertyControllerGetAllResponse> {
2766
+ public static expectedTransactionControllerSkip(
2767
+ data: ExpectedTransactionControllerSkipData
2768
+ ): CancelablePromise<ExpectedTransactionControllerSkipResponse> {
2612
2769
  return __request(OpenAPI, {
2613
- method: 'GET',
2614
- url: '/api/v1/admin/properties',
2770
+ method: 'POST',
2771
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
2772
+ path: {
2773
+ id: data.id,
2774
+ region: data.region
2775
+ },
2615
2776
  errors: {
2616
- 401: 'Unauthorized',
2617
- 403: 'Forbidden - insufficient permissions'
2777
+ 400: 'Cannot skip - not in PENDING status',
2778
+ 404: 'Expected transaction not found'
2618
2779
  }
2619
2780
  });
2620
2781
  }
2621
2782
 
2622
2783
  /**
2623
- * Get property by key
2784
+ * Undo skip
2785
+ * Reverses a skip operation (SKIPPED -> PENDING)
2624
2786
  * @param data The data for the request.
2625
- * @param data.key Property key
2626
- * @returns unknown Property retrieved successfully
2787
+ * @param data.id Expected transaction ID
2788
+ * @param data.region Region code for tenant context
2789
+ * @returns void Skip undone successfully
2627
2790
  * @throws ApiError
2628
2791
  */
2629
- public static propertyControllerGetByKey(
2630
- data: PropertyControllerGetByKeyData
2631
- ): CancelablePromise<PropertyControllerGetByKeyResponse> {
2792
+ public static expectedTransactionControllerUndoSkip(
2793
+ data: ExpectedTransactionControllerUndoSkipData
2794
+ ): CancelablePromise<ExpectedTransactionControllerUndoSkipResponse> {
2632
2795
  return __request(OpenAPI, {
2633
- method: 'GET',
2634
- url: '/api/v1/admin/properties/{key}',
2796
+ method: 'DELETE',
2797
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/skip',
2635
2798
  path: {
2636
- key: data.key
2799
+ id: data.id,
2800
+ region: data.region
2637
2801
  },
2638
2802
  errors: {
2639
- 401: 'Unauthorized',
2640
- 403: 'Forbidden - insufficient permissions',
2641
- 404: 'Property not found'
2803
+ 400: 'Cannot undo - not in SKIPPED status',
2804
+ 404: 'Expected transaction not found'
2642
2805
  }
2643
2806
  });
2644
2807
  }
2645
2808
 
2646
2809
  /**
2647
- * Update a system property
2810
+ * Confirm transaction match
2811
+ * Manually matches an expected transaction with an actual transaction
2648
2812
  * @param data The data for the request.
2649
- * @param data.key Property key
2813
+ * @param data.id Expected transaction ID
2814
+ * @param data.region Region code for tenant context
2650
2815
  * @param data.requestBody
2651
- * @returns unknown Property updated successfully
2816
+ * @returns unknown Match confirmed successfully
2652
2817
  * @throws ApiError
2653
2818
  */
2654
- public static propertyControllerUpdate(
2655
- data: PropertyControllerUpdateData
2656
- ): CancelablePromise<PropertyControllerUpdateResponse> {
2819
+ public static expectedTransactionControllerConfirmMatch(
2820
+ data: ExpectedTransactionControllerConfirmMatchData
2821
+ ): CancelablePromise<ExpectedTransactionControllerConfirmMatchResponse> {
2657
2822
  return __request(OpenAPI, {
2658
- method: 'PUT',
2659
- url: '/api/v1/admin/properties/{key}',
2823
+ method: 'POST',
2824
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
2660
2825
  path: {
2661
- key: data.key
2826
+ id: data.id,
2827
+ region: data.region
2662
2828
  },
2663
2829
  body: data.requestBody,
2664
2830
  mediaType: 'application/json',
2665
2831
  errors: {
2666
- 401: 'Unauthorized',
2667
- 403: 'Forbidden - insufficient permissions'
2832
+ 400: 'Cannot match - not in PENDING status',
2833
+ 404: 'Expected or actual transaction not found',
2834
+ 409: 'Actual transaction already matched to another rule'
2835
+ }
2836
+ });
2837
+ }
2838
+
2839
+ /**
2840
+ * Unmatch transaction
2841
+ * Removes the match between expected and actual transaction (COMPLETED -> PENDING)
2842
+ * @param data The data for the request.
2843
+ * @param data.id Expected transaction ID
2844
+ * @param data.region Region code for tenant context
2845
+ * @returns void Match removed successfully
2846
+ * @throws ApiError
2847
+ */
2848
+ public static expectedTransactionControllerUnmatch(
2849
+ data: ExpectedTransactionControllerUnmatchData
2850
+ ): CancelablePromise<ExpectedTransactionControllerUnmatchResponse> {
2851
+ return __request(OpenAPI, {
2852
+ method: 'DELETE',
2853
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/match',
2854
+ path: {
2855
+ id: data.id,
2856
+ region: data.region
2857
+ },
2858
+ errors: {
2859
+ 400: 'Cannot unmatch - not in COMPLETED status',
2860
+ 404: 'Expected transaction not found'
2861
+ }
2862
+ });
2863
+ }
2864
+
2865
+ /**
2866
+ * Enter Now
2867
+ * Creates an actual transaction for an expected transaction (YNAB-style Enter Now)
2868
+ * @param data The data for the request.
2869
+ * @param data.id Expected transaction ID
2870
+ * @param data.region Region code for tenant context
2871
+ * @param data.requestBody
2872
+ * @returns unknown Transaction created successfully
2873
+ * @throws ApiError
2874
+ */
2875
+ public static expectedTransactionControllerEnterNow(
2876
+ data: ExpectedTransactionControllerEnterNowData
2877
+ ): CancelablePromise<ExpectedTransactionControllerEnterNowResponse> {
2878
+ return __request(OpenAPI, {
2879
+ method: 'POST',
2880
+ url: '/api/v1/{region}/bean/expected-transactions/{id}/enter',
2881
+ path: {
2882
+ id: data.id,
2883
+ region: data.region
2884
+ },
2885
+ body: data.requestBody,
2886
+ mediaType: 'application/json',
2887
+ errors: {
2888
+ 400: 'Cannot enter - not in PENDING status or missing accounts',
2889
+ 404: 'Expected transaction or accounts not found'
2668
2890
  }
2669
2891
  });
2670
2892
  }
2893
+ }
2894
+
2895
+ export class RecurringForecastService {
2896
+ /**
2897
+ * Get cash flow forecast
2898
+ * Returns predicted outflows for the next N months based on active recurring rules
2899
+ * @param data The data for the request.
2900
+ * @param data.region Region code for tenant context
2901
+ * @param data.months Number of months to forecast (1-12, default 3)
2902
+ * @returns ForecastResponseDto Forecast retrieved successfully
2903
+ * @throws ApiError
2904
+ */
2905
+ public static forecastControllerGetForecast(
2906
+ data: ForecastControllerGetForecastData
2907
+ ): CancelablePromise<ForecastControllerGetForecastResponse> {
2908
+ return __request(OpenAPI, {
2909
+ method: 'GET',
2910
+ url: '/api/v1/{region}/bean/recurring/forecast',
2911
+ path: {
2912
+ region: data.region
2913
+ },
2914
+ query: {
2915
+ months: data.months
2916
+ }
2917
+ });
2918
+ }
2919
+ }
2671
2920
 
2921
+ export class BeanCategoryCatalogService {
2672
2922
  /**
2673
- * Delete a system property
2923
+ * List category catalog for a region
2924
+ * Returns the region-scoped category slugs (expense/income/investment/banking/transfer/payment) for the NLP result picker, each with the categoryAccount paths the region-enabled system rules map it to (#816). CN-exclusive payment instruments (huabei/baitiao) appear only under /cn.
2674
2925
  * @param data The data for the request.
2675
- * @param data.key Property key
2676
- * @returns void Property deleted successfully
2926
+ * @param data.region Region code for tenant context
2927
+ * @param data.scenario Filter by scenario
2928
+ * @param data.routeBearing Filter by routeBearing (entity-router route() consumes it)
2929
+ * @returns CategoryCatalogListResponseDto Category catalog retrieved successfully
2677
2930
  * @throws ApiError
2678
2931
  */
2679
- public static propertyControllerDelete(
2680
- data: PropertyControllerDeleteData
2681
- ): CancelablePromise<PropertyControllerDeleteResponse> {
2932
+ public static categoryCatalogControllerList(
2933
+ data: CategoryCatalogControllerListData
2934
+ ): CancelablePromise<CategoryCatalogControllerListResponse> {
2682
2935
  return __request(OpenAPI, {
2683
- method: 'DELETE',
2684
- url: '/api/v1/admin/properties/{key}',
2936
+ method: 'GET',
2937
+ url: '/api/v1/{region}/bean/categories',
2685
2938
  path: {
2686
- key: data.key
2939
+ region: data.region
2687
2940
  },
2688
- errors: {
2689
- 401: 'Unauthorized',
2690
- 403: 'Forbidden - insufficient permissions',
2691
- 404: 'Property not found'
2941
+ query: {
2942
+ scenario: data.scenario,
2943
+ routeBearing: data.routeBearing
2692
2944
  }
2693
2945
  });
2694
2946
  }
@@ -2873,7 +3125,7 @@ export class OnboardingService {
2873
3125
  /**
2874
3126
  * Bootstrap core accounts + register asset accounts with opening balances (ADR-0113)
2875
3127
  * @param data The data for the request.
2876
- * @param data.region Region code for tenant context
3128
+ * @param data.region Region code for tenant context. Not-yet-open codes are accepted: the universal catalog backs onboarding regardless of region (#759)
2877
3129
  * @param data.requestBody
2878
3130
  * @returns unknown Onboarding bootstrap result.
2879
3131
  * @throws ApiError
@@ -3006,13 +3258,20 @@ export class BeanExportService {
3006
3258
  /**
3007
3259
  * Export Beancount ledger as ZIP
3008
3260
  * Export all user Beancount data as a ZIP file containing ledger.beancount and yearly files in community format.
3009
- * @returns unknown
3261
+ * @param data The data for the request.
3262
+ * @param data.region Region code for tenant context
3263
+ * @returns binary ZIP archive (application/zip) streamed as an attachment
3010
3264
  * @throws ApiError
3011
3265
  */
3012
- public static exportControllerExportBeancount(): CancelablePromise<ExportControllerExportBeancountResponse> {
3266
+ public static exportControllerExportBeancount(
3267
+ data: ExportControllerExportBeancountData
3268
+ ): CancelablePromise<ExportControllerExportBeancountResponse> {
3013
3269
  return __request(OpenAPI, {
3014
3270
  method: 'GET',
3015
- url: '/api/v1/{region}/bean/export/beancount'
3271
+ url: '/api/v1/{region}/bean/export/beancount',
3272
+ path: {
3273
+ region: data.region
3274
+ }
3016
3275
  });
3017
3276
  }
3018
3277
  }
@@ -3049,7 +3308,7 @@ export class BeanImportService {
3049
3308
 
3050
3309
  /**
3051
3310
  * Identify file type
3052
- * 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.
3311
+ * Server-side importer identification has been removed (ADR-0101); file matching is handled client-side via the community parser pipeline. Always returns identified=false with an explanatory message; kept for backward compatibility. Does not perform actual import.
3053
3312
  * @param data The data for the request.
3054
3313
  * @param data.region Region code for tenant context
3055
3314
  * @param data.formData File to identify
@@ -3569,13 +3828,20 @@ export class BeanPlatformsService {
3569
3828
 
3570
3829
  /**
3571
3830
  * Get platform list for current user
3572
- * @returns unknown List of platforms with user binding status
3831
+ * @param data The data for the request.
3832
+ * @param data.region Region code (ISO 3166-1 alpha-2) that biases within-type-bucket ordering (local-region platforms first). Case-insensitive — stored/compared UPPERCASE ("cn" == "CN").
3833
+ * @returns PlatformListItemDto List of platforms with user binding status
3573
3834
  * @throws ApiError
3574
3835
  */
3575
- public static platformControllerGetPlatformList(): CancelablePromise<PlatformControllerGetPlatformListResponse> {
3836
+ public static platformControllerGetPlatformList(
3837
+ data: PlatformControllerGetPlatformListData = {}
3838
+ ): CancelablePromise<PlatformControllerGetPlatformListResponse> {
3576
3839
  return __request(OpenAPI, {
3577
3840
  method: 'GET',
3578
- url: '/api/v1/bean/platforms/list'
3841
+ url: '/api/v1/bean/platforms/list',
3842
+ query: {
3843
+ region: data.region
3844
+ }
3579
3845
  });
3580
3846
  }
3581
3847
 
@@ -3583,8 +3849,8 @@ export class BeanPlatformsService {
3583
3849
  * Match platforms by name or alias
3584
3850
  * @param data The data for the request.
3585
3851
  * @param data.q Search query — Chinese name, English name, or abbreviation
3586
- * @param data.region Region code for category override lookup
3587
- * @returns unknown List of matching platforms with suggested segment names
3852
+ * @param data.region Region code (ISO 3166-1 alpha-2) that biases within-tier ordering (local-region platforms first); also the intended categoryOverrides key. Case-insensitive — stored/compared UPPERCASE ("cn" == "CN").
3853
+ * @returns PlatformMatchResponseDto Matching platforms with overall match type and truncation flag
3588
3854
  * @throws ApiError
3589
3855
  */
3590
3856
  public static platformControllerMatchPlatforms(
@@ -3600,6 +3866,31 @@ export class BeanPlatformsService {
3600
3866
  });
3601
3867
  }
3602
3868
 
3869
+ /**
3870
+ * Get the region and candidate account standards for a platform
3871
+ * @param data The data for the request.
3872
+ * @param data.id Platform ID (from a match result)
3873
+ * @param data.region Region code (ISO 3166-1 alpha-2, case-insensitive). Required for global platforms (countryCode null) — resolved as their template region; ignored when the platform has its own countryCode.
3874
+ * @param data.type Filter templates by account type (path first segment)
3875
+ * @returns PlatformStandardsResponseDto Resolved region plus the merged account-standard catalog of that region (groupable by productCategory client-side)
3876
+ * @throws ApiError
3877
+ */
3878
+ public static platformControllerGetPlatformStandards(
3879
+ data: PlatformControllerGetPlatformStandardsData
3880
+ ): CancelablePromise<PlatformControllerGetPlatformStandardsResponse> {
3881
+ return __request(OpenAPI, {
3882
+ method: 'GET',
3883
+ url: '/api/v1/bean/platforms/{id}/standards',
3884
+ path: {
3885
+ id: data.id
3886
+ },
3887
+ query: {
3888
+ region: data.region,
3889
+ type: data.type
3890
+ }
3891
+ });
3892
+ }
3893
+
3603
3894
  /**
3604
3895
  * Update a platform
3605
3896
  * @param data The data for the request.
@@ -3766,249 +4057,178 @@ export class DashboardService {
3766
4057
  }
3767
4058
  });
3768
4059
  }
3769
- }
3770
4060
 
3771
- export class InvestmentService {
3772
4061
  /**
3773
- * Get per-holding unrealized + realized P&L
3774
- * Average-cost unrealized P&L per account × commodity, plus cumulative realized P&L on sold lots (method = FIFO | average, default average).
4062
+ * Get the composite P8 advisor context
4063
+ * Assembles the P8 data context in one call: net worth (verbatim GET /dashboard/net-worth shape, user base currency semantics per ADR-0070), trailing-12m flow totals over the 12 calendar months including the as-of month, and top-3 expense categories by account-path leaf key — both flow blocks priced in CNY per the P8 contract. The P8 snake_case field spellings (as_of, net_worth, trailing_12m) are mapped by the consumer; the wire keeps the family camelCase
3775
4064
  * @param data The data for the request.
3776
4065
  * @param data.region Region code for tenant context
3777
- * @param data.asOf As-of date (ISO 8601), defaults to today
3778
- * @param data.accountId Scope to a single account
3779
- * @param data.method Realized-P&L lot-matching method (default average). Does not affect the average-cost unrealized basis.
3780
- * @returns HoldingPnlResponseDto Holding P&L retrieved successfully
4066
+ * @param data.date As-of date for the snapshot and the trailing-12m window anchor (ISO 8601 format)
4067
+ * @returns AdvisorContextResponseDto Advisor context retrieved successfully
3781
4068
  * @throws ApiError
3782
4069
  */
3783
- public static holdingPnlControllerGetHoldingPnl(
3784
- data: HoldingPnlControllerGetHoldingPnlData
3785
- ): CancelablePromise<HoldingPnlControllerGetHoldingPnlResponse> {
4070
+ public static dashboardControllerGetAdvisorContext(
4071
+ data: DashboardControllerGetAdvisorContextData
4072
+ ): CancelablePromise<DashboardControllerGetAdvisorContextResponse> {
3786
4073
  return __request(OpenAPI, {
3787
4074
  method: 'GET',
3788
- url: '/api/v1/{region}/investment/holdings/pnl',
4075
+ url: '/api/v1/{region}/dashboard/advisor-context',
3789
4076
  path: {
3790
4077
  region: data.region
3791
4078
  },
3792
4079
  query: {
3793
- asOf: data.asOf,
3794
- accountId: data.accountId,
3795
- method: data.method
4080
+ date: data.date
3796
4081
  },
3797
4082
  errors: {
3798
- 400: 'Invalid asOf format/value/future date, invalid accountId format, or unsupported method',
3799
- 401: 'User not authenticated'
4083
+ 400: 'Invalid date format',
4084
+ 401: 'User not authenticated, or the token is not advisor-scoped (exchange via POST /auth/sessions/advisor, #1512)'
3800
4085
  }
3801
4086
  });
3802
4087
  }
3803
4088
  }
3804
4089
 
3805
- export class ReportingService {
4090
+ export class InvestmentService {
3806
4091
  /**
3807
- * Get portfolio value trends
3808
- *
3809
- * Returns time series data of portfolio net worth.
3810
- *
3811
- * **Multi-currency Support:**
3812
- * - `series[].byCurrency` - Currency breakdown for each data point
3813
- * - `byCurrency` - Separate time series grouped by currency
3814
- * - `warnings` - Exchange rate warnings if conversion failed
3815
- *
3816
- * **Parameters:**
3817
- * - `period`: Time period (1m, 3m, 6m, 1y)
3818
- * - `granularity`: Data granularity (day, week, month)
3819
- *
4092
+ * Get per-holding unrealized + realized P&L
4093
+ * Average-cost unrealized P&L per account × commodity, plus cumulative realized P&L on sold lots (method = FIFO | average, default average).
3820
4094
  * @param data The data for the request.
3821
4095
  * @param data.region Region code for tenant context
3822
- * @param data.period Time period
3823
- * @param data.granularity Data granularity
3824
- * @returns PortfolioTrendsResponseDto Trends retrieved successfully
4096
+ * @param data.asOf As-of date (ISO 8601), defaults to today
4097
+ * @param data.accountId Scope to a single account
4098
+ * @param data.method Realized-P&L lot-matching method (default average). Does not affect the average-cost unrealized basis.
4099
+ * @returns HoldingPnlResponseDto Holding P&L retrieved successfully
3825
4100
  * @throws ApiError
3826
4101
  */
3827
- public static reportingControllerGetPortfolioTrends(
3828
- data: ReportingControllerGetPortfolioTrendsData
3829
- ): CancelablePromise<ReportingControllerGetPortfolioTrendsResponse> {
4102
+ public static holdingPnlControllerGetHoldingPnl(
4103
+ data: HoldingPnlControllerGetHoldingPnlData
4104
+ ): CancelablePromise<HoldingPnlControllerGetHoldingPnlResponse> {
3830
4105
  return __request(OpenAPI, {
3831
4106
  method: 'GET',
3832
- url: '/api/v1/{region}/reporting/portfolio/trends',
4107
+ url: '/api/v1/{region}/investment/holdings/pnl',
3833
4108
  path: {
3834
4109
  region: data.region
3835
4110
  },
3836
4111
  query: {
3837
- period: data.period,
3838
- granularity: data.granularity
4112
+ asOf: data.asOf,
4113
+ accountId: data.accountId,
4114
+ method: data.method
3839
4115
  },
3840
4116
  errors: {
4117
+ 400: 'Invalid asOf format/value/future date, invalid accountId format, or unsupported method',
3841
4118
  401: 'User not authenticated'
3842
4119
  }
3843
4120
  });
3844
4121
  }
4122
+ }
3845
4123
 
4124
+ export class ApiKeysService {
3846
4125
  /**
3847
- * Get cash-flow trends
3848
- *
3849
- * Monthly income / expense / netSavings over a fixed N-month window
3850
- * (current month + N−1 prior). Missing months are zero-filled (flow metric).
3851
- *
3852
- * **Parameters:**
3853
- * - `period`: 1m | 3m | 6m | 1y (default 6m)
3854
- * - `granularity`: accepted for API symmetry; v1 returns month buckets
3855
- *
3856
- * @param data The data for the request.
3857
- * @param data.region Region code for tenant context
3858
- * @param data.period Time period
3859
- * @param data.granularity Data granularity (accepted for API symmetry; v1 returns month buckets)
3860
- * @returns CashFlowTrendsResponseDto Cash-flow trends retrieved successfully
4126
+ * Create API key
4127
+ * Generates a new API key for the authenticated user
4128
+ * @returns unknown API key created successfully
3861
4129
  * @throws ApiError
3862
4130
  */
3863
- public static reportingControllerGetCashFlowTrends(
3864
- data: ReportingControllerGetCashFlowTrendsData
3865
- ): CancelablePromise<ReportingControllerGetCashFlowTrendsResponse> {
4131
+ public static apiKeysControllerCreateApiKey(): CancelablePromise<ApiKeysControllerCreateApiKeyResponse> {
3866
4132
  return __request(OpenAPI, {
3867
- method: 'GET',
3868
- url: '/api/v1/{region}/reporting/cash-flow/trends',
3869
- path: {
3870
- region: data.region
3871
- },
3872
- query: {
3873
- period: data.period,
3874
- granularity: data.granularity
3875
- },
4133
+ method: 'POST',
4134
+ url: '/api/v1/auth/api-keys',
3876
4135
  errors: {
3877
- 401: 'User not authenticated'
4136
+ 403: 'Insufficient permissions to create API key'
3878
4137
  }
3879
4138
  });
3880
4139
  }
4140
+ }
3881
4141
 
4142
+ export class AuthService {
3882
4143
  /**
3883
- * Generate portfolio snapshot
3884
- *
3885
- * Manually generate a portfolio snapshot for a specific date.
3886
- *
3887
- * **Multi-currency Support:**
3888
- * - Fetches balances grouped by currency
3889
- * - Uses user's baseCurrency setting for conversion
3890
- * - Stores exchange rates and warnings
3891
- *
3892
- * **Use Cases:**
3893
- * - Testing snapshot generation
3894
- * - Force regeneration after data correction
3895
- * - Initial setup for new users
3896
- *
4144
+ * Anonymous login with access token
3897
4145
  * @param data The data for the request.
3898
- * @param data.region Region code for tenant context
3899
- * @param data.requestBody Optional date (defaults to today)
3900
- * @returns GenerateSnapshotResponse Snapshot generated successfully
4146
+ * @param data.requestBody
4147
+ * @returns AnonymousLoginResponseDto Login successful
3901
4148
  * @throws ApiError
3902
4149
  */
3903
- public static reportingControllerGenerateSnapshot(
3904
- data: ReportingControllerGenerateSnapshotData
3905
- ): CancelablePromise<ReportingControllerGenerateSnapshotResponse> {
4150
+ public static authControllerAccessTokenLogin(
4151
+ data: AuthControllerAccessTokenLoginData
4152
+ ): CancelablePromise<AuthControllerAccessTokenLoginResponse> {
3906
4153
  return __request(OpenAPI, {
3907
4154
  method: 'POST',
3908
- url: '/api/v1/{region}/reporting/snapshots/generate',
3909
- path: {
3910
- region: data.region
3911
- },
4155
+ url: '/api/v1/auth/sessions/anonymous',
3912
4156
  body: data.requestBody,
3913
4157
  mediaType: 'application/json',
3914
4158
  errors: {
3915
- 400: 'Invalid date format',
3916
- 401: 'User not authenticated'
4159
+ 401: 'Invalid access token'
3917
4160
  }
3918
4161
  });
3919
4162
  }
3920
4163
 
3921
4164
  /**
3922
- * Backfill portfolio snapshots
3923
- *
3924
- * Generate snapshots for a date range (historical data backfill).
3925
- *
3926
- * **Multi-currency Support:**
3927
- * - Each snapshot includes multi-currency data
3928
- * - Uses exchange rates available at generation time
3929
- * - Warnings stored for missing exchange rates
3930
- *
3931
- * **Best Practices:**
3932
- * - Use for initial setup after account configuration
3933
- * - Run during low-traffic periods for large date ranges
3934
- * - Existing snapshots are skipped (not regenerated)
3935
- *
4165
+ * Exchange an access token for an advisor-scoped, short-TTL JWT (#1512)
3936
4166
  * @param data The data for the request.
3937
- * @param data.region Region code for tenant context
3938
4167
  * @param data.requestBody
3939
- * @returns BackfillSnapshotsResponse Backfill completed successfully
4168
+ * @returns AdvisorLoginResponseDto Advisor-scope login successful — the token is valid only on advisor tool-face endpoints (e.g. GET /:region/dashboard/advisor-context)
3940
4169
  * @throws ApiError
3941
4170
  */
3942
- public static reportingControllerBackfillSnapshots(
3943
- data: ReportingControllerBackfillSnapshotsData
3944
- ): CancelablePromise<ReportingControllerBackfillSnapshotsResponse> {
4171
+ public static authControllerAdvisorTokenLogin(
4172
+ data: AuthControllerAdvisorTokenLoginData
4173
+ ): CancelablePromise<AuthControllerAdvisorTokenLoginResponse> {
3945
4174
  return __request(OpenAPI, {
3946
4175
  method: 'POST',
3947
- url: '/api/v1/{region}/reporting/snapshots/backfill',
3948
- path: {
3949
- region: data.region
3950
- },
4176
+ url: '/api/v1/auth/sessions/advisor',
3951
4177
  body: data.requestBody,
3952
4178
  mediaType: 'application/json',
3953
4179
  errors: {
3954
- 400: 'Invalid date format or range',
3955
- 401: 'User not authenticated',
3956
- 409: 'Backfill already in progress for this user'
3957
- }
3958
- });
3959
- }
3960
- }
3961
-
3962
- export class ApiKeysService {
3963
- /**
3964
- * Create API key
3965
- * Generates a new API key for the authenticated user
3966
- * @returns unknown API key created successfully
3967
- * @throws ApiError
3968
- */
3969
- public static apiKeysControllerCreateApiKey(): CancelablePromise<ApiKeysControllerCreateApiKeyResponse> {
3970
- return __request(OpenAPI, {
3971
- method: 'POST',
3972
- url: '/api/v1/auth/api-keys',
3973
- errors: {
3974
- 403: 'Insufficient permissions to create API key'
4180
+ 401: 'Invalid access token'
3975
4181
  }
3976
4182
  });
3977
4183
  }
3978
4184
  }
3979
4185
 
3980
- export class AuthService {
4186
+ export class CommunityService {
3981
4187
  /**
3982
- * Anonymous login with access token
4188
+ * Relay a sanitized parser-contribution payload
4189
+ * A server-side bot re-sanitizes the payload and opens an issue on the target repository; the issue URL is returned. The payload is never persisted or logged (forward-and-drop).
3983
4190
  * @param data The data for the request.
4191
+ * @param data.region Region code for tenant context (routing only; the institution region rides in the payload meta)
3984
4192
  * @param data.requestBody
3985
- * @returns unknown Login successful
4193
+ * @returns ParserContributionRelayResponseDto Issue created by the bot
3986
4194
  * @throws ApiError
3987
4195
  */
3988
- public static authControllerAccessTokenLogin(
3989
- data: AuthControllerAccessTokenLoginData
3990
- ): CancelablePromise<AuthControllerAccessTokenLoginResponse> {
4196
+ public static parserContributionControllerCreate(
4197
+ data: ParserContributionControllerCreateData
4198
+ ): CancelablePromise<ParserContributionControllerCreateResponse> {
3991
4199
  return __request(OpenAPI, {
3992
4200
  method: 'POST',
3993
- url: '/api/v1/auth/sessions/anonymous',
4201
+ url: '/api/v1/{region}/community/parser-contributions',
4202
+ path: {
4203
+ region: data.region
4204
+ },
3994
4205
  body: data.requestBody,
3995
4206
  mediaType: 'application/json',
3996
4207
  errors: {
3997
- 401: 'Invalid access token'
4208
+ 401: 'Unauthorized',
4209
+ 422: 'Validation failed (institution slug, empty samples, row/cell size limits)',
4210
+ 429: 'Rate limited (5 submissions per user per hour)',
4211
+ 501: 'Relay not configured on this deployment — clients fall back to the clipboard flow',
4212
+ 502: 'GitHub bot failure (upstream), safe to retry'
3998
4213
  }
3999
4214
  });
4000
4215
  }
4001
4216
  }
4002
4217
 
4003
- export class DefaultService {
4218
+ export class AdminCacheService {
4004
4219
  /**
4005
- * @returns unknown
4220
+ * Flush entire cache (L1 + L2)
4221
+ * Clears ALL cache entries across ALL namespaces and users. Use only for emergency cache corruption recovery, maintenance-window refresh, or development resets.
4222
+ * @returns unknown Cache flushed successfully
4006
4223
  * @throws ApiError
4007
4224
  */
4008
4225
  public static cacheControllerFlushCache(): CancelablePromise<CacheControllerFlushCacheResponse> {
4009
4226
  return __request(OpenAPI, {
4010
4227
  method: 'POST',
4011
- url: '/api/v1/cache/flush'
4228
+ url: '/api/v1/cache/flush',
4229
+ errors: {
4230
+ 403: 'Admin access required'
4231
+ }
4012
4232
  });
4013
4233
  }
4014
4234
  }
@@ -4169,3 +4389,53 @@ export class InfoService {
4169
4389
  });
4170
4390
  }
4171
4391
  }
4392
+
4393
+ export class MarketDataService {
4394
+ /**
4395
+ * Search market symbols by name or code
4396
+ * Ranked search over the openbb catalog. Empty `q` returns [].
4397
+ * @param data The data for the request.
4398
+ * @param data.q Search term — matched against symbol and instrument name. Empty string returns [].
4399
+ * @param data.limit Maximum number of results (clamped 1..50)
4400
+ * @param data.exchange Filter by exchange code (e.g. US, HK, SS, SZ). A-share codes also match symbol notations and venue-code aliases (exchange=SS matches SH/SHH column values and bare 6-digit Shanghai symbols; SZ likewise)
4401
+ * @param data.assetType Filter by OpenBB asset_type (e.g. stock, etf)
4402
+ * @returns SymbolSearchResultDto Ranked search results
4403
+ * @throws ApiError
4404
+ */
4405
+ public static symbolControllerSearch(
4406
+ data: SymbolControllerSearchData
4407
+ ): CancelablePromise<SymbolControllerSearchResponse> {
4408
+ return __request(OpenAPI, {
4409
+ method: 'GET',
4410
+ url: '/api/v1/market/symbols/search',
4411
+ query: {
4412
+ q: data.q,
4413
+ limit: data.limit,
4414
+ exchange: data.exchange,
4415
+ assetType: data.assetType
4416
+ }
4417
+ });
4418
+ }
4419
+
4420
+ /**
4421
+ * Get a market symbol quote
4422
+ * @param data The data for the request.
4423
+ * @param data.symbol
4424
+ * @returns SymbolQuoteDto Symbol quote
4425
+ * @throws ApiError
4426
+ */
4427
+ public static symbolControllerGetQuote(
4428
+ data: SymbolControllerGetQuoteData
4429
+ ): CancelablePromise<SymbolControllerGetQuoteResponse> {
4430
+ return __request(OpenAPI, {
4431
+ method: 'GET',
4432
+ url: '/api/v1/market/symbols/{symbol}/quote',
4433
+ path: {
4434
+ symbol: data.symbol
4435
+ },
4436
+ errors: {
4437
+ 404: 'Symbol not found in the openbb catalog'
4438
+ }
4439
+ });
4440
+ }
4441
+ }