@firela/api-types 0.0.0-canary.a3c2cb48 → 0.0.0-canary.a4e21680
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 +3732 -972
- package/dist/index.d.ts +3732 -972
- package/dist/index.js +160 -75
- package/dist/index.mjs +160 -75
- package/package.json +2 -3
- package/src/generated/schemas.gen.ts +3333 -505
- package/src/generated/services.gen.ts +1644 -617
- package/src/generated/types.gen.ts +5368 -2359
package/dist/index.js
CHANGED
|
@@ -670,6 +670,7 @@ var BeanTransactionsService = class {
|
|
|
670
670
|
* @param data.status Filter by transaction status
|
|
671
671
|
* @param data.search Search in narration and payee fields (max 200 chars)
|
|
672
672
|
* @param data.accountId Filter by account ID (transactions with postings to this account)
|
|
673
|
+
* @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
|
|
673
674
|
* @returns TransactionListResponseDto Transaction list
|
|
674
675
|
* @throws ApiError
|
|
675
676
|
*/
|
|
@@ -687,25 +688,93 @@ var BeanTransactionsService = class {
|
|
|
687
688
|
dateTo: data.dateTo,
|
|
688
689
|
status: data.status,
|
|
689
690
|
search: data.search,
|
|
690
|
-
accountId: data.accountId
|
|
691
|
+
accountId: data.accountId,
|
|
692
|
+
category: data.category
|
|
691
693
|
},
|
|
692
694
|
errors: {
|
|
695
|
+
400: "Validation failed",
|
|
693
696
|
401: "Authentication required"
|
|
694
697
|
}
|
|
695
698
|
});
|
|
696
699
|
}
|
|
697
700
|
/**
|
|
701
|
+
* @deprecated
|
|
702
|
+
* Batch create transactions (DEPRECATED)
|
|
703
|
+
* DEPRECATED: Use POST /:region/bean/import/provider/:name/sync instead. This endpoint skips dedup, rule matching, and review branching.
|
|
698
704
|
* @param data The data for the request.
|
|
699
705
|
* @param data.region Region code for tenant context
|
|
700
|
-
* @
|
|
706
|
+
* @param data.requestBody
|
|
707
|
+
* @returns BatchTransactionResponseDto Transactions processed
|
|
701
708
|
* @throws ApiError
|
|
702
709
|
*/
|
|
703
|
-
static
|
|
710
|
+
static transactionControllerCreateBatch(data) {
|
|
704
711
|
return request(OpenAPI, {
|
|
705
712
|
method: "POST",
|
|
706
713
|
url: "/api/v1/{region}/bean/transactions/batch",
|
|
707
714
|
path: {
|
|
708
715
|
region: data.region
|
|
716
|
+
},
|
|
717
|
+
body: data.requestBody,
|
|
718
|
+
mediaType: "application/json",
|
|
719
|
+
errors: {
|
|
720
|
+
400: "Invalid input",
|
|
721
|
+
401: "Authentication required"
|
|
722
|
+
}
|
|
723
|
+
});
|
|
724
|
+
}
|
|
725
|
+
/**
|
|
726
|
+
* Correct (supersede) a transaction
|
|
727
|
+
* Atomically voids the original (SUPERSEDED) and creates a replacement through the full validation pipeline.
|
|
728
|
+
* @param data The data for the request.
|
|
729
|
+
* @param data.id Original transaction ID to correct
|
|
730
|
+
* @param data.region Region code for tenant context
|
|
731
|
+
* @param data.requestBody
|
|
732
|
+
* @returns TransactionDetailDto Corrected transaction created
|
|
733
|
+
* @throws ApiError
|
|
734
|
+
*/
|
|
735
|
+
static transactionControllerCorrect(data) {
|
|
736
|
+
return request(OpenAPI, {
|
|
737
|
+
method: "POST",
|
|
738
|
+
url: "/api/v1/{region}/bean/transactions/{id}/correct",
|
|
739
|
+
path: {
|
|
740
|
+
id: data.id,
|
|
741
|
+
region: data.region
|
|
742
|
+
},
|
|
743
|
+
body: data.requestBody,
|
|
744
|
+
mediaType: "application/json",
|
|
745
|
+
errors: {
|
|
746
|
+
404: "Original transaction not found",
|
|
747
|
+
409: "Original no longer ACTIVE (concurrent modification)",
|
|
748
|
+
422: "Pipeline validation failed (does not balance, invalid accounts)"
|
|
749
|
+
}
|
|
750
|
+
});
|
|
751
|
+
}
|
|
752
|
+
/**
|
|
753
|
+
* Suggest transaction tags
|
|
754
|
+
* Returns distinct tags from the user ACTIVE transactions, sorted by usage, for autocomplete. Optional q performs a case-insensitive prefix match.
|
|
755
|
+
* @param data The data for the request.
|
|
756
|
+
* @param data.region Region code for tenant context
|
|
757
|
+
* @param data.q Prefix match, case-insensitive (max 50 chars)
|
|
758
|
+
* @param data.sort usage (default) or name
|
|
759
|
+
* @param data.limit Max suggestions (1-100, default 10)
|
|
760
|
+
* @returns TagSuggestionsResponseDto Tag suggestions
|
|
761
|
+
* @throws ApiError
|
|
762
|
+
*/
|
|
763
|
+
static transactionControllerSuggestTags(data) {
|
|
764
|
+
return request(OpenAPI, {
|
|
765
|
+
method: "GET",
|
|
766
|
+
url: "/api/v1/{region}/bean/transactions/tags",
|
|
767
|
+
path: {
|
|
768
|
+
region: data.region
|
|
769
|
+
},
|
|
770
|
+
query: {
|
|
771
|
+
q: data.q,
|
|
772
|
+
sort: data.sort,
|
|
773
|
+
limit: data.limit
|
|
774
|
+
},
|
|
775
|
+
errors: {
|
|
776
|
+
400: "Validation failed",
|
|
777
|
+
401: "Authentication required"
|
|
709
778
|
}
|
|
710
779
|
});
|
|
711
780
|
}
|
|
@@ -760,17 +829,26 @@ var BeanTransactionsService = class {
|
|
|
760
829
|
});
|
|
761
830
|
}
|
|
762
831
|
/**
|
|
832
|
+
* Void transaction
|
|
833
|
+
* Soft-deletes a transaction by marking it as VOIDED
|
|
763
834
|
* @param data The data for the request.
|
|
835
|
+
* @param data.id Transaction ID
|
|
764
836
|
* @param data.region Region code for tenant context
|
|
765
|
-
* @returns void
|
|
837
|
+
* @returns void Transaction voided successfully
|
|
766
838
|
* @throws ApiError
|
|
767
839
|
*/
|
|
768
|
-
static
|
|
840
|
+
static transactionControllerDelete(data) {
|
|
769
841
|
return request(OpenAPI, {
|
|
770
842
|
method: "DELETE",
|
|
771
843
|
url: "/api/v1/{region}/bean/transactions/{id}",
|
|
772
844
|
path: {
|
|
845
|
+
id: data.id,
|
|
773
846
|
region: data.region
|
|
847
|
+
},
|
|
848
|
+
errors: {
|
|
849
|
+
400: "Transaction already voided",
|
|
850
|
+
401: "Authentication required",
|
|
851
|
+
404: "Transaction not found"
|
|
774
852
|
}
|
|
775
853
|
});
|
|
776
854
|
}
|
|
@@ -781,6 +859,7 @@ var BeanBalancesService = class {
|
|
|
781
859
|
* Calculate account balance at a specific date for a single currency
|
|
782
860
|
* @param data The data for the request.
|
|
783
861
|
* @param data.account Account name (e.g., "Assets:Bank:Checking")
|
|
862
|
+
* @param data.region Region code for tenant context
|
|
784
863
|
* @param data.date Date to calculate balance at (ISO 8601 format)
|
|
785
864
|
* @param data.currency Currency to query (e.g., "USD", "CNY")
|
|
786
865
|
* @returns BalanceResponseDto Balance calculated successfully
|
|
@@ -790,6 +869,9 @@ var BeanBalancesService = class {
|
|
|
790
869
|
return request(OpenAPI, {
|
|
791
870
|
method: "GET",
|
|
792
871
|
url: "/api/v1/{region}/bean/balances",
|
|
872
|
+
path: {
|
|
873
|
+
region: data.region
|
|
874
|
+
},
|
|
793
875
|
query: {
|
|
794
876
|
account: data.account,
|
|
795
877
|
date: data.date,
|
|
@@ -804,13 +886,18 @@ var BeanBalancesService = class {
|
|
|
804
886
|
/**
|
|
805
887
|
* Query multi-currency account balance
|
|
806
888
|
* Calculate account balances for all currencies at a specific date
|
|
889
|
+
* @param data The data for the request.
|
|
890
|
+
* @param data.region Region code for tenant context
|
|
807
891
|
* @returns MultiCurrencyBalanceResponseDto Balances calculated successfully
|
|
808
892
|
* @throws ApiError
|
|
809
893
|
*/
|
|
810
|
-
static balanceControllerGetMultiCurrencyBalance() {
|
|
894
|
+
static balanceControllerGetMultiCurrencyBalance(data) {
|
|
811
895
|
return request(OpenAPI, {
|
|
812
896
|
method: "GET",
|
|
813
897
|
url: "/api/v1/{region}/bean/balances/multi-currency",
|
|
898
|
+
path: {
|
|
899
|
+
region: data.region
|
|
900
|
+
},
|
|
814
901
|
errors: {
|
|
815
902
|
400: "Invalid query parameters",
|
|
816
903
|
401: "User not authenticated"
|
|
@@ -820,17 +907,26 @@ var BeanBalancesService = class {
|
|
|
820
907
|
};
|
|
821
908
|
var BeanCommoditiesService = class {
|
|
822
909
|
/**
|
|
910
|
+
* Create a new commodity
|
|
911
|
+
* Creates a new commodity definition for the authenticated user
|
|
823
912
|
* @param data The data for the request.
|
|
824
913
|
* @param data.region Region code for tenant context
|
|
825
|
-
* @
|
|
914
|
+
* @param data.requestBody
|
|
915
|
+
* @returns CommodityResponseDto Commodity created successfully
|
|
826
916
|
* @throws ApiError
|
|
827
917
|
*/
|
|
828
|
-
static
|
|
918
|
+
static commodityControllerCreate(data) {
|
|
829
919
|
return request(OpenAPI, {
|
|
830
920
|
method: "POST",
|
|
831
921
|
url: "/api/v1/{region}/bean/commodities",
|
|
832
922
|
path: {
|
|
833
923
|
region: data.region
|
|
924
|
+
},
|
|
925
|
+
body: data.requestBody,
|
|
926
|
+
mediaType: "application/json",
|
|
927
|
+
errors: {
|
|
928
|
+
400: "Invalid input data",
|
|
929
|
+
409: "Commodity already exists"
|
|
834
930
|
}
|
|
835
931
|
});
|
|
836
932
|
}
|
|
@@ -880,57 +976,81 @@ var BeanCommoditiesService = class {
|
|
|
880
976
|
});
|
|
881
977
|
}
|
|
882
978
|
/**
|
|
979
|
+
* Update commodity
|
|
980
|
+
* Updates an existing commodity definition. Symbol cannot be changed.
|
|
883
981
|
* @param data The data for the request.
|
|
982
|
+
* @param data.symbol Commodity symbol
|
|
884
983
|
* @param data.region Region code for tenant context
|
|
885
|
-
* @
|
|
984
|
+
* @param data.requestBody
|
|
985
|
+
* @returns CommodityResponseDto Commodity updated successfully
|
|
886
986
|
* @throws ApiError
|
|
887
987
|
*/
|
|
888
|
-
static
|
|
988
|
+
static commodityControllerUpdate(data) {
|
|
889
989
|
return request(OpenAPI, {
|
|
890
990
|
method: "PUT",
|
|
891
991
|
url: "/api/v1/{region}/bean/commodities/{symbol}",
|
|
892
992
|
path: {
|
|
993
|
+
symbol: data.symbol,
|
|
893
994
|
region: data.region
|
|
995
|
+
},
|
|
996
|
+
body: data.requestBody,
|
|
997
|
+
mediaType: "application/json",
|
|
998
|
+
errors: {
|
|
999
|
+
400: "Invalid input data",
|
|
1000
|
+
404: "Commodity not found"
|
|
894
1001
|
}
|
|
895
1002
|
});
|
|
896
1003
|
}
|
|
897
1004
|
/**
|
|
1005
|
+
* Delete commodity
|
|
1006
|
+
* Deletes a commodity definition
|
|
898
1007
|
* @param data The data for the request.
|
|
1008
|
+
* @param data.symbol Commodity symbol
|
|
899
1009
|
* @param data.region Region code for tenant context
|
|
900
|
-
* @returns void
|
|
1010
|
+
* @returns void Commodity deleted successfully
|
|
901
1011
|
* @throws ApiError
|
|
902
1012
|
*/
|
|
903
|
-
static
|
|
1013
|
+
static commodityControllerDelete(data) {
|
|
904
1014
|
return request(OpenAPI, {
|
|
905
1015
|
method: "DELETE",
|
|
906
1016
|
url: "/api/v1/{region}/bean/commodities/{symbol}",
|
|
907
1017
|
path: {
|
|
1018
|
+
symbol: data.symbol,
|
|
908
1019
|
region: data.region
|
|
1020
|
+
},
|
|
1021
|
+
errors: {
|
|
1022
|
+
404: "Commodity not found"
|
|
909
1023
|
}
|
|
910
1024
|
});
|
|
911
1025
|
}
|
|
912
1026
|
/**
|
|
1027
|
+
* Ensure commodity exists
|
|
1028
|
+
* Gets existing commodity or creates it with automatic initialization from OpenBB
|
|
913
1029
|
* @param data The data for the request.
|
|
1030
|
+
* @param data.symbol Commodity symbol
|
|
914
1031
|
* @param data.region Region code for tenant context
|
|
915
|
-
* @returns
|
|
1032
|
+
* @returns CommodityResponseDto Commodity retrieved or created
|
|
916
1033
|
* @throws ApiError
|
|
917
1034
|
*/
|
|
918
|
-
static
|
|
1035
|
+
static commodityControllerGetOrCreate(data) {
|
|
919
1036
|
return request(OpenAPI, {
|
|
920
1037
|
method: "POST",
|
|
921
1038
|
url: "/api/v1/{region}/bean/commodities/{symbol}/ensure",
|
|
922
1039
|
path: {
|
|
1040
|
+
symbol: data.symbol,
|
|
923
1041
|
region: data.region
|
|
924
1042
|
}
|
|
925
1043
|
});
|
|
926
1044
|
}
|
|
927
1045
|
/**
|
|
1046
|
+
* Bulk create commodities
|
|
1047
|
+
* Creates multiple commodities from a list of symbols, useful for initialization
|
|
928
1048
|
* @param data The data for the request.
|
|
929
1049
|
* @param data.region Region code for tenant context
|
|
930
|
-
* @returns
|
|
1050
|
+
* @returns CommodityResponseDto Commodities created successfully
|
|
931
1051
|
* @throws ApiError
|
|
932
1052
|
*/
|
|
933
|
-
static
|
|
1053
|
+
static commodityControllerBulkCreate(data) {
|
|
934
1054
|
return request(OpenAPI, {
|
|
935
1055
|
method: "POST",
|
|
936
1056
|
url: "/api/v1/{region}/bean/commodities/bulk",
|
|
@@ -966,7 +1086,7 @@ var ProviderSyncService = class {
|
|
|
966
1086
|
*
|
|
967
1087
|
* @param data The data for the request.
|
|
968
1088
|
* @param data.providerName Provider name
|
|
969
|
-
* @param data.region Region code
|
|
1089
|
+
* @param data.region Region code for tenant context
|
|
970
1090
|
* @param data.requestBody
|
|
971
1091
|
* @returns ProviderSyncResponseDto Sync completed successfully
|
|
972
1092
|
* @throws ApiError
|
|
@@ -991,13 +1111,18 @@ var ProviderSyncService = class {
|
|
|
991
1111
|
/**
|
|
992
1112
|
* Get supported providers
|
|
993
1113
|
* Returns a list of all providers supported by the sync endpoint.
|
|
1114
|
+
* @param data The data for the request.
|
|
1115
|
+
* @param data.region Region code for tenant context
|
|
994
1116
|
* @returns SupportedProvidersResponseDto List of supported providers
|
|
995
1117
|
* @throws ApiError
|
|
996
1118
|
*/
|
|
997
|
-
static providerSyncControllerGetSupportedProviders() {
|
|
1119
|
+
static providerSyncControllerGetSupportedProviders(data) {
|
|
998
1120
|
return request(OpenAPI, {
|
|
999
1121
|
method: "GET",
|
|
1000
1122
|
url: "/api/v1/{region}/bean/import/provider/supported",
|
|
1123
|
+
path: {
|
|
1124
|
+
region: data.region
|
|
1125
|
+
},
|
|
1001
1126
|
errors: {
|
|
1002
1127
|
401: "Missing or invalid authentication"
|
|
1003
1128
|
}
|
|
@@ -1008,6 +1133,7 @@ var ProviderSyncService = class {
|
|
|
1008
1133
|
* Returns whether a specific provider is supported.
|
|
1009
1134
|
* @param data The data for the request.
|
|
1010
1135
|
* @param data.providerName Provider name to check
|
|
1136
|
+
* @param data.region Region code for tenant context
|
|
1011
1137
|
* @returns unknown Provider support status
|
|
1012
1138
|
* @throws ApiError
|
|
1013
1139
|
*/
|
|
@@ -1016,7 +1142,8 @@ var ProviderSyncService = class {
|
|
|
1016
1142
|
method: "GET",
|
|
1017
1143
|
url: "/api/v1/{region}/bean/import/provider/{providerName}/supported",
|
|
1018
1144
|
path: {
|
|
1019
|
-
providerName: data.providerName
|
|
1145
|
+
providerName: data.providerName,
|
|
1146
|
+
region: data.region
|
|
1020
1147
|
},
|
|
1021
1148
|
errors: {
|
|
1022
1149
|
401: "Missing or invalid authentication"
|
|
@@ -1053,6 +1180,20 @@ var HealthService = class {
|
|
|
1053
1180
|
}
|
|
1054
1181
|
});
|
|
1055
1182
|
}
|
|
1183
|
+
/**
|
|
1184
|
+
* Check OpenBB schema status
|
|
1185
|
+
* @returns unknown OpenBB status
|
|
1186
|
+
* @throws ApiError
|
|
1187
|
+
*/
|
|
1188
|
+
static healthControllerCheckOpenBb() {
|
|
1189
|
+
return request(OpenAPI, {
|
|
1190
|
+
method: "GET",
|
|
1191
|
+
url: "/api/v1/health/openbb",
|
|
1192
|
+
errors: {
|
|
1193
|
+
503: "OpenBB unavailable"
|
|
1194
|
+
}
|
|
1195
|
+
});
|
|
1196
|
+
}
|
|
1056
1197
|
/**
|
|
1057
1198
|
* Check Redis connection health
|
|
1058
1199
|
* @returns unknown Redis is healthy
|
|
@@ -1116,62 +1257,6 @@ var HealthService = class {
|
|
|
1116
1257
|
}
|
|
1117
1258
|
});
|
|
1118
1259
|
}
|
|
1119
|
-
/**
|
|
1120
|
-
* Check health of a specific data enhancer
|
|
1121
|
-
* @param data The data for the request.
|
|
1122
|
-
* @param data.name Data enhancer name
|
|
1123
|
-
* @returns unknown Data enhancer is healthy
|
|
1124
|
-
* @throws ApiError
|
|
1125
|
-
*/
|
|
1126
|
-
static healthControllerGetHealthOfDataEnhancer(data) {
|
|
1127
|
-
return request(OpenAPI, {
|
|
1128
|
-
method: "GET",
|
|
1129
|
-
url: "/api/v1/health/data-enhancer/{name}",
|
|
1130
|
-
path: {
|
|
1131
|
-
name: data.name
|
|
1132
|
-
},
|
|
1133
|
-
errors: {
|
|
1134
|
-
401: "Unauthorized",
|
|
1135
|
-
503: "Data enhancer unavailable"
|
|
1136
|
-
}
|
|
1137
|
-
});
|
|
1138
|
-
}
|
|
1139
|
-
/**
|
|
1140
|
-
* Check health of all data providers
|
|
1141
|
-
* @returns unknown Data providers health status
|
|
1142
|
-
* @throws ApiError
|
|
1143
|
-
*/
|
|
1144
|
-
static healthControllerCheckDataProviders() {
|
|
1145
|
-
return request(OpenAPI, {
|
|
1146
|
-
method: "GET",
|
|
1147
|
-
url: "/api/v1/health/data-providers",
|
|
1148
|
-
errors: {
|
|
1149
|
-
401: "Unauthorized",
|
|
1150
|
-
503: "Data providers check failed"
|
|
1151
|
-
}
|
|
1152
|
-
});
|
|
1153
|
-
}
|
|
1154
|
-
/**
|
|
1155
|
-
* Check health of a specific data provider
|
|
1156
|
-
* @param data The data for the request.
|
|
1157
|
-
* @param data.dataSource Data source identifier
|
|
1158
|
-
* @returns unknown Data provider is healthy
|
|
1159
|
-
* @throws ApiError
|
|
1160
|
-
*/
|
|
1161
|
-
static healthControllerGetHealthOfDataProvider(data) {
|
|
1162
|
-
return request(OpenAPI, {
|
|
1163
|
-
method: "GET",
|
|
1164
|
-
url: "/api/v1/health/data-provider/{dataSource}",
|
|
1165
|
-
path: {
|
|
1166
|
-
dataSource: data.dataSource
|
|
1167
|
-
},
|
|
1168
|
-
errors: {
|
|
1169
|
-
400: "Invalid data source",
|
|
1170
|
-
401: "Unauthorized",
|
|
1171
|
-
503: "Data provider unavailable"
|
|
1172
|
-
}
|
|
1173
|
-
});
|
|
1174
|
-
}
|
|
1175
1260
|
};
|
|
1176
1261
|
// Annotate the CommonJS export names for ESM import in node:
|
|
1177
1262
|
0 && (module.exports = {
|