@firela/api-types 0.0.0-canary.3cce6a41 → 0.0.0-canary.3e45eeb0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +170 -20
- package/dist/index.d.ts +170 -20
- package/package.json +1 -1
- package/src/generated/schemas.gen.ts +215 -12
- package/src/generated/services.gen.ts +31 -1
- package/src/generated/types.gen.ts +233 -21
|
@@ -193,6 +193,8 @@ import type {
|
|
|
193
193
|
TransactionRuleControllerDeleteResponse,
|
|
194
194
|
TransactionRuleControllerTestData,
|
|
195
195
|
TransactionRuleControllerTestResponse,
|
|
196
|
+
CategoryCatalogControllerListData,
|
|
197
|
+
CategoryCatalogControllerListResponse,
|
|
196
198
|
EventControllerCreateData,
|
|
197
199
|
EventControllerCreateResponse,
|
|
198
200
|
EventControllerFindAllData,
|
|
@@ -2349,7 +2351,7 @@ export class UsersService {
|
|
|
2349
2351
|
* Get current authenticated user
|
|
2350
2352
|
* @param data The data for the request.
|
|
2351
2353
|
* @param data.acceptLanguage
|
|
2352
|
-
* @returns
|
|
2354
|
+
* @returns UserResponseDto User retrieved successfully
|
|
2353
2355
|
* @throws ApiError
|
|
2354
2356
|
*/
|
|
2355
2357
|
public static userControllerGetUser(
|
|
@@ -2856,6 +2858,34 @@ export class BeanTransactionRulesService {
|
|
|
2856
2858
|
}
|
|
2857
2859
|
}
|
|
2858
2860
|
|
|
2861
|
+
export class BeanCategoryCatalogService {
|
|
2862
|
+
/**
|
|
2863
|
+
* List category catalog for a region
|
|
2864
|
+
* Returns the region-scoped category slugs (expense/income/investment/banking/transfer/payment) for the NLP result picker. CN-exclusive payment instruments (huabei/baitiao) appear only under /cn.
|
|
2865
|
+
* @param data The data for the request.
|
|
2866
|
+
* @param data.region Region code for tenant context
|
|
2867
|
+
* @param data.scenario Filter by scenario
|
|
2868
|
+
* @param data.routeBearing Filter by routeBearing (entity-router route() consumes it)
|
|
2869
|
+
* @returns CategoryCatalogListResponseDto Category catalog retrieved successfully
|
|
2870
|
+
* @throws ApiError
|
|
2871
|
+
*/
|
|
2872
|
+
public static categoryCatalogControllerList(
|
|
2873
|
+
data: CategoryCatalogControllerListData
|
|
2874
|
+
): CancelablePromise<CategoryCatalogControllerListResponse> {
|
|
2875
|
+
return __request(OpenAPI, {
|
|
2876
|
+
method: 'GET',
|
|
2877
|
+
url: '/api/v1/{region}/bean/categories',
|
|
2878
|
+
path: {
|
|
2879
|
+
region: data.region
|
|
2880
|
+
},
|
|
2881
|
+
query: {
|
|
2882
|
+
scenario: data.scenario,
|
|
2883
|
+
routeBearing: data.routeBearing
|
|
2884
|
+
}
|
|
2885
|
+
});
|
|
2886
|
+
}
|
|
2887
|
+
}
|
|
2888
|
+
|
|
2859
2889
|
export class LifeEventsService {
|
|
2860
2890
|
/**
|
|
2861
2891
|
* Create a new life event
|
|
@@ -3016,6 +3016,32 @@ export type DeleteOwnUserDto = {
|
|
|
3016
3016
|
accessToken: string;
|
|
3017
3017
|
};
|
|
3018
3018
|
|
|
3019
|
+
export type UserSettingsResponseDto = {
|
|
3020
|
+
/**
|
|
3021
|
+
* Base currency (ISO 4217) for net-worth/report aggregation. Independent of region (ADR-0006).
|
|
3022
|
+
*/
|
|
3023
|
+
baseCurrency: string | null;
|
|
3024
|
+
};
|
|
3025
|
+
|
|
3026
|
+
export type UserResponseDto = {
|
|
3027
|
+
/**
|
|
3028
|
+
* User ID
|
|
3029
|
+
*/
|
|
3030
|
+
id: string;
|
|
3031
|
+
/**
|
|
3032
|
+
* Assigned user role
|
|
3033
|
+
*/
|
|
3034
|
+
role: string;
|
|
3035
|
+
/**
|
|
3036
|
+
* Permission strings
|
|
3037
|
+
*/
|
|
3038
|
+
permissions: Array<string>;
|
|
3039
|
+
/**
|
|
3040
|
+
* User settings
|
|
3041
|
+
*/
|
|
3042
|
+
settings: UserSettingsResponseDto;
|
|
3043
|
+
};
|
|
3044
|
+
|
|
3019
3045
|
export type SignupDto = {
|
|
3020
3046
|
/**
|
|
3021
3047
|
* Cloudflare Turnstile verification token (optional when Turnstile disabled)
|
|
@@ -3502,6 +3528,57 @@ export type TestRuleResponseDto = {
|
|
|
3502
3528
|
};
|
|
3503
3529
|
};
|
|
3504
3530
|
|
|
3531
|
+
export type CategoryCatalogEntryDto = {
|
|
3532
|
+
/**
|
|
3533
|
+
* Category slug (single source-of-truth)
|
|
3534
|
+
*/
|
|
3535
|
+
slug: string;
|
|
3536
|
+
/**
|
|
3537
|
+
* Display scenario group (maps to frontend picker _scenario)
|
|
3538
|
+
*/
|
|
3539
|
+
scenario:
|
|
3540
|
+
| 'expense'
|
|
3541
|
+
| 'income'
|
|
3542
|
+
| 'investment'
|
|
3543
|
+
| 'banking'
|
|
3544
|
+
| 'transfer'
|
|
3545
|
+
| 'payment';
|
|
3546
|
+
/**
|
|
3547
|
+
* Lucide icon name
|
|
3548
|
+
*/
|
|
3549
|
+
icon: string;
|
|
3550
|
+
/**
|
|
3551
|
+
* Applicable regions ('*' = all, 'cn' = CN-only)
|
|
3552
|
+
*/
|
|
3553
|
+
regions: Array<string>;
|
|
3554
|
+
};
|
|
3555
|
+
|
|
3556
|
+
/**
|
|
3557
|
+
* Display scenario group (maps to frontend picker _scenario)
|
|
3558
|
+
*/
|
|
3559
|
+
export type scenario =
|
|
3560
|
+
| 'expense'
|
|
3561
|
+
| 'income'
|
|
3562
|
+
| 'investment'
|
|
3563
|
+
| 'banking'
|
|
3564
|
+
| 'transfer'
|
|
3565
|
+
| 'payment';
|
|
3566
|
+
|
|
3567
|
+
export type CategoryCatalogListResponseDto = {
|
|
3568
|
+
/**
|
|
3569
|
+
* Category entries (region-scoped, query-filtered)
|
|
3570
|
+
*/
|
|
3571
|
+
items: Array<CategoryCatalogEntryDto>;
|
|
3572
|
+
/**
|
|
3573
|
+
* Total category entries for the region (before query filtering)
|
|
3574
|
+
*/
|
|
3575
|
+
total: number;
|
|
3576
|
+
/**
|
|
3577
|
+
* Region code
|
|
3578
|
+
*/
|
|
3579
|
+
region: string;
|
|
3580
|
+
};
|
|
3581
|
+
|
|
3505
3582
|
export type CreateBeanEventDto = {
|
|
3506
3583
|
/**
|
|
3507
3584
|
* Life event date (ISO 8601)
|
|
@@ -4183,11 +4260,88 @@ export type ParserTelemetryReportDto = unknown;
|
|
|
4183
4260
|
|
|
4184
4261
|
export type UncoveredFormatMissDto = unknown;
|
|
4185
4262
|
|
|
4263
|
+
export type ClientParsedDataDto = {
|
|
4264
|
+
/**
|
|
4265
|
+
* Transaction amount
|
|
4266
|
+
*/
|
|
4267
|
+
amount?: number;
|
|
4268
|
+
/**
|
|
4269
|
+
* Currency code
|
|
4270
|
+
*/
|
|
4271
|
+
currency?: string;
|
|
4272
|
+
/**
|
|
4273
|
+
* Transaction date (ISO 8601)
|
|
4274
|
+
*/
|
|
4275
|
+
date?: string;
|
|
4276
|
+
/**
|
|
4277
|
+
* Payee/merchant name
|
|
4278
|
+
*/
|
|
4279
|
+
payee?: string;
|
|
4280
|
+
/**
|
|
4281
|
+
* Transaction narration
|
|
4282
|
+
*/
|
|
4283
|
+
narration?: string;
|
|
4284
|
+
/**
|
|
4285
|
+
* Category slug
|
|
4286
|
+
*/
|
|
4287
|
+
category?: string;
|
|
4288
|
+
/**
|
|
4289
|
+
* Income type
|
|
4290
|
+
*/
|
|
4291
|
+
incomeType?: string;
|
|
4292
|
+
/**
|
|
4293
|
+
* Income source
|
|
4294
|
+
*/
|
|
4295
|
+
incomeSource?: string;
|
|
4296
|
+
/**
|
|
4297
|
+
* Security symbol code (e.g., 600519, AAPL)
|
|
4298
|
+
*/
|
|
4299
|
+
symbol?: string;
|
|
4300
|
+
/**
|
|
4301
|
+
* Quantity of shares/units
|
|
4302
|
+
*/
|
|
4303
|
+
quantity?: number;
|
|
4304
|
+
/**
|
|
4305
|
+
* Unit price per share/unit
|
|
4306
|
+
*/
|
|
4307
|
+
price?: number;
|
|
4308
|
+
/**
|
|
4309
|
+
* Investment action
|
|
4310
|
+
*/
|
|
4311
|
+
investmentAction?: 'buy' | 'sell';
|
|
4312
|
+
/**
|
|
4313
|
+
* Payment source: asset (default) or liability (credit card)
|
|
4314
|
+
*/
|
|
4315
|
+
paymentSource?: 'asset' | 'liability';
|
|
4316
|
+
/**
|
|
4317
|
+
* Liability account hint (CreditCard/Huabei/Baitiao)
|
|
4318
|
+
*/
|
|
4319
|
+
liabilityHint?: string;
|
|
4320
|
+
/**
|
|
4321
|
+
* Display-only warning from the prior response; accepted but ignored.
|
|
4322
|
+
*/
|
|
4323
|
+
warning?: string;
|
|
4324
|
+
};
|
|
4325
|
+
|
|
4326
|
+
/**
|
|
4327
|
+
* Investment action
|
|
4328
|
+
*/
|
|
4329
|
+
export type investmentAction = 'buy' | 'sell';
|
|
4330
|
+
|
|
4331
|
+
/**
|
|
4332
|
+
* Payment source: asset (default) or liability (credit card)
|
|
4333
|
+
*/
|
|
4334
|
+
export type paymentSource = 'asset' | 'liability';
|
|
4335
|
+
|
|
4186
4336
|
export type ProcessNlpDto = {
|
|
4187
4337
|
/**
|
|
4188
|
-
* Natural language text describing a transaction (
|
|
4338
|
+
* Natural language text describing a transaction. Optional when `confirm` is true (structured confirm); otherwise required.
|
|
4339
|
+
*/
|
|
4340
|
+
message?: string;
|
|
4341
|
+
/**
|
|
4342
|
+
* Structured confirm signal — bypasses NL confirm-word matching when true. Send parsedData field edits alongside. The NL word-list path is the fallback.
|
|
4189
4343
|
*/
|
|
4190
|
-
|
|
4344
|
+
confirm?: boolean;
|
|
4191
4345
|
/**
|
|
4192
4346
|
* Session ID for multi-turn conversation (auto-generated if not provided)
|
|
4193
4347
|
*/
|
|
@@ -4195,9 +4349,7 @@ export type ProcessNlpDto = {
|
|
|
4195
4349
|
/**
|
|
4196
4350
|
* Parsed data from previous NLP response for session recovery. Send back the parsedData received in confirm_payee/confirm responses.
|
|
4197
4351
|
*/
|
|
4198
|
-
parsedData?:
|
|
4199
|
-
[key: string]: unknown;
|
|
4200
|
-
};
|
|
4352
|
+
parsedData?: ClientParsedDataDto;
|
|
4201
4353
|
/**
|
|
4202
4354
|
* confirm_rule echo-back: rule id selected from the prior confirm_rule response (matchedRule.id or alternatives[i].ruleId). Applied directly when the session is confirming_rule — no NL re-parse.
|
|
4203
4355
|
*/
|
|
@@ -4302,16 +4454,6 @@ export type NlpParsedDataDto = {
|
|
|
4302
4454
|
warning?: string;
|
|
4303
4455
|
};
|
|
4304
4456
|
|
|
4305
|
-
/**
|
|
4306
|
-
* Investment action
|
|
4307
|
-
*/
|
|
4308
|
-
export type investmentAction = 'buy' | 'sell';
|
|
4309
|
-
|
|
4310
|
-
/**
|
|
4311
|
-
* Payment source: asset (default) or liability (credit card)
|
|
4312
|
-
*/
|
|
4313
|
-
export type paymentSource = 'asset' | 'liability';
|
|
4314
|
-
|
|
4315
4457
|
export type NlpSourceTransactionDto = {
|
|
4316
4458
|
/**
|
|
4317
4459
|
* Transaction date (ISO format)
|
|
@@ -4639,7 +4781,12 @@ export type NlpResponseDto = {
|
|
|
4639
4781
|
/**
|
|
4640
4782
|
* Asset sub-type (only present when intent is "asset"). Determines which asset-related form to render.
|
|
4641
4783
|
*/
|
|
4642
|
-
assetSubType?:
|
|
4784
|
+
assetSubType?:
|
|
4785
|
+
| 'transfer'
|
|
4786
|
+
| 'banking'
|
|
4787
|
+
| 'investment'
|
|
4788
|
+
| 'lend'
|
|
4789
|
+
| 'lend_collect';
|
|
4643
4790
|
/**
|
|
4644
4791
|
* Liability sub-type (only present when intent is "liability"). borrow: borrowing money (Liabilities → Assets), repay: repaying debt (Assets → Liabilities).
|
|
4645
4792
|
*/
|
|
@@ -4756,7 +4903,12 @@ export type intent = 'expense' | 'asset' | 'income' | 'liability' | 'equity';
|
|
|
4756
4903
|
/**
|
|
4757
4904
|
* Asset sub-type (only present when intent is "asset"). Determines which asset-related form to render.
|
|
4758
4905
|
*/
|
|
4759
|
-
export type assetSubType =
|
|
4906
|
+
export type assetSubType =
|
|
4907
|
+
| 'transfer'
|
|
4908
|
+
| 'banking'
|
|
4909
|
+
| 'investment'
|
|
4910
|
+
| 'lend'
|
|
4911
|
+
| 'lend_collect';
|
|
4760
4912
|
|
|
4761
4913
|
/**
|
|
4762
4914
|
* Liability sub-type (only present when intent is "liability"). borrow: borrowing money (Liabilities → Assets), repay: repaying debt (Assets → Liabilities).
|
|
@@ -4797,7 +4949,7 @@ export type PlatformListItemDto = {
|
|
|
4797
4949
|
*/
|
|
4798
4950
|
canonical: string;
|
|
4799
4951
|
/**
|
|
4800
|
-
* Suggested path segment — canonical
|
|
4952
|
+
* Suggested path segment — canonical PascalCased per hyphen-part, hyphens preserved (e.g. "Apple-Pay")
|
|
4801
4953
|
*/
|
|
4802
4954
|
suggestedSegment: string;
|
|
4803
4955
|
/**
|
|
@@ -4855,7 +5007,7 @@ export type PlatformMatchResultDto = {
|
|
|
4855
5007
|
| 'INSURANCE'
|
|
4856
5008
|
| 'OTHER';
|
|
4857
5009
|
/**
|
|
4858
|
-
* Suggested path segment — canonical,
|
|
5010
|
+
* Suggested path segment — canonical PascalCased per hyphen-part, hyphens preserved (e.g. "Apple-Pay")
|
|
4859
5011
|
*/
|
|
4860
5012
|
suggestedSegment: string;
|
|
4861
5013
|
/**
|
|
@@ -8437,7 +8589,7 @@ export type UserControllerGetUserData = {
|
|
|
8437
8589
|
acceptLanguage: string;
|
|
8438
8590
|
};
|
|
8439
8591
|
|
|
8440
|
-
export type UserControllerGetUserResponse =
|
|
8592
|
+
export type UserControllerGetUserResponse = UserResponseDto;
|
|
8441
8593
|
|
|
8442
8594
|
export type UserControllerSignupUserData = {
|
|
8443
8595
|
requestBody: SignupDto;
|
|
@@ -8909,6 +9061,55 @@ export type TransactionRuleControllerTestData = {
|
|
|
8909
9061
|
|
|
8910
9062
|
export type TransactionRuleControllerTestResponse = TestRuleResponseDto;
|
|
8911
9063
|
|
|
9064
|
+
export type CategoryCatalogControllerListData = {
|
|
9065
|
+
/**
|
|
9066
|
+
* Region code for tenant context
|
|
9067
|
+
*/
|
|
9068
|
+
region:
|
|
9069
|
+
| 'ad'
|
|
9070
|
+
| 'ae'
|
|
9071
|
+
| 'af'
|
|
9072
|
+
| 'ag'
|
|
9073
|
+
| 'al'
|
|
9074
|
+
| 'am'
|
|
9075
|
+
| 'ao'
|
|
9076
|
+
| 'au'
|
|
9077
|
+
| 'br'
|
|
9078
|
+
| 'ca'
|
|
9079
|
+
| 'cn'
|
|
9080
|
+
| 'de'
|
|
9081
|
+
| 'dz'
|
|
9082
|
+
| 'es'
|
|
9083
|
+
| 'fr'
|
|
9084
|
+
| 'gb'
|
|
9085
|
+
| 'hk'
|
|
9086
|
+
| 'in'
|
|
9087
|
+
| 'it'
|
|
9088
|
+
| 'jp'
|
|
9089
|
+
| 'kr'
|
|
9090
|
+
| 'nl'
|
|
9091
|
+
| 'sg'
|
|
9092
|
+
| 'tw'
|
|
9093
|
+
| 'us';
|
|
9094
|
+
/**
|
|
9095
|
+
* Filter by routeBearing (entity-router route() consumes it)
|
|
9096
|
+
*/
|
|
9097
|
+
routeBearing?: boolean;
|
|
9098
|
+
/**
|
|
9099
|
+
* Filter by scenario
|
|
9100
|
+
*/
|
|
9101
|
+
scenario?:
|
|
9102
|
+
| 'expense'
|
|
9103
|
+
| 'income'
|
|
9104
|
+
| 'investment'
|
|
9105
|
+
| 'banking'
|
|
9106
|
+
| 'transfer'
|
|
9107
|
+
| 'payment';
|
|
9108
|
+
};
|
|
9109
|
+
|
|
9110
|
+
export type CategoryCatalogControllerListResponse =
|
|
9111
|
+
CategoryCatalogListResponseDto;
|
|
9112
|
+
|
|
8912
9113
|
export type EventControllerCreateData = {
|
|
8913
9114
|
/**
|
|
8914
9115
|
* Region code for tenant context (decorative for life events)
|
|
@@ -11570,7 +11771,7 @@ export type $OpenApiTs = {
|
|
|
11570
11771
|
/**
|
|
11571
11772
|
* User retrieved successfully
|
|
11572
11773
|
*/
|
|
11573
|
-
200:
|
|
11774
|
+
200: UserResponseDto;
|
|
11574
11775
|
};
|
|
11575
11776
|
};
|
|
11576
11777
|
post: {
|
|
@@ -11944,6 +12145,17 @@ export type $OpenApiTs = {
|
|
|
11944
12145
|
};
|
|
11945
12146
|
};
|
|
11946
12147
|
};
|
|
12148
|
+
'/api/v1/{region}/bean/categories': {
|
|
12149
|
+
get: {
|
|
12150
|
+
req: CategoryCatalogControllerListData;
|
|
12151
|
+
res: {
|
|
12152
|
+
/**
|
|
12153
|
+
* Category catalog retrieved successfully
|
|
12154
|
+
*/
|
|
12155
|
+
200: CategoryCatalogListResponseDto;
|
|
12156
|
+
};
|
|
12157
|
+
};
|
|
12158
|
+
};
|
|
11947
12159
|
'/api/v1/{region}/bean/events': {
|
|
11948
12160
|
post: {
|
|
11949
12161
|
req: EventControllerCreateData;
|