b2b-platform-utils 1.1.72 → 1.1.74
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/errorsMap.js +132 -0
- package/package.json +1 -1
package/errorsMap.js
CHANGED
|
@@ -1140,6 +1140,138 @@ const STATIC_ERRORS = [
|
|
|
1140
1140
|
httpCode: 422,
|
|
1141
1141
|
description: "Required payment client context is missing or invalid.",
|
|
1142
1142
|
},
|
|
1143
|
+
{
|
|
1144
|
+
errorCode: 1187,
|
|
1145
|
+
errorKey: "missingCardNumber",
|
|
1146
|
+
httpCode: 422,
|
|
1147
|
+
description: "Card number is required for this payment method.",
|
|
1148
|
+
},
|
|
1149
|
+
{
|
|
1150
|
+
errorCode: 1188,
|
|
1151
|
+
errorKey: "missingCardHolder",
|
|
1152
|
+
httpCode: 422,
|
|
1153
|
+
description: "Card holder is required for this payment method.",
|
|
1154
|
+
},
|
|
1155
|
+
{
|
|
1156
|
+
errorCode: 1189,
|
|
1157
|
+
errorKey: "missingCardExpireMonth",
|
|
1158
|
+
httpCode: 422,
|
|
1159
|
+
description: "Card expiration month is required for this payment method.",
|
|
1160
|
+
},
|
|
1161
|
+
{
|
|
1162
|
+
errorCode: 1190,
|
|
1163
|
+
errorKey: "missingCardExpireYear",
|
|
1164
|
+
httpCode: 422,
|
|
1165
|
+
description: "Card expiration year is required for this payment method.",
|
|
1166
|
+
},
|
|
1167
|
+
{
|
|
1168
|
+
errorCode: 1191,
|
|
1169
|
+
errorKey: "missingBankName",
|
|
1170
|
+
httpCode: 422,
|
|
1171
|
+
description: "Bank name is required for this payment method.",
|
|
1172
|
+
},
|
|
1173
|
+
{
|
|
1174
|
+
errorCode: 1192,
|
|
1175
|
+
errorKey: "missingBankAccount",
|
|
1176
|
+
httpCode: 422,
|
|
1177
|
+
description: "Bank account is required for this payment method.",
|
|
1178
|
+
},
|
|
1179
|
+
{
|
|
1180
|
+
errorCode: 1193,
|
|
1181
|
+
errorKey: "missingIban",
|
|
1182
|
+
httpCode: 422,
|
|
1183
|
+
description: "IBAN is required for this payment method.",
|
|
1184
|
+
},
|
|
1185
|
+
{
|
|
1186
|
+
errorCode: 1194,
|
|
1187
|
+
errorKey: "missingBankCode",
|
|
1188
|
+
httpCode: 422,
|
|
1189
|
+
description: "Bank code is required for this payment method.",
|
|
1190
|
+
},
|
|
1191
|
+
{
|
|
1192
|
+
errorCode: 1195,
|
|
1193
|
+
errorKey: "missingBankBranch",
|
|
1194
|
+
httpCode: 422,
|
|
1195
|
+
description: "Bank branch is required for this payment method.",
|
|
1196
|
+
},
|
|
1197
|
+
{
|
|
1198
|
+
errorCode: 1196,
|
|
1199
|
+
errorKey: "missingIfsc",
|
|
1200
|
+
httpCode: 422,
|
|
1201
|
+
description: "IFSC is required for this payment method.",
|
|
1202
|
+
},
|
|
1203
|
+
{
|
|
1204
|
+
errorCode: 1197,
|
|
1205
|
+
errorKey: "missingBeneficiaryName",
|
|
1206
|
+
httpCode: 422,
|
|
1207
|
+
description: "Beneficiary name is required for this payment method.",
|
|
1208
|
+
},
|
|
1209
|
+
{
|
|
1210
|
+
errorCode: 1198,
|
|
1211
|
+
errorKey: "missingDocumentId",
|
|
1212
|
+
httpCode: 422,
|
|
1213
|
+
description: "Document identifier is required for this payment method.",
|
|
1214
|
+
},
|
|
1215
|
+
{
|
|
1216
|
+
errorCode: 1199,
|
|
1217
|
+
errorKey: "missingNationality",
|
|
1218
|
+
httpCode: 422,
|
|
1219
|
+
description: "Nationality is required for this payment method.",
|
|
1220
|
+
},
|
|
1221
|
+
{
|
|
1222
|
+
errorCode: 1200,
|
|
1223
|
+
errorKey: "missingState",
|
|
1224
|
+
httpCode: 422,
|
|
1225
|
+
description: "State or region is required for this payment method.",
|
|
1226
|
+
},
|
|
1227
|
+
{
|
|
1228
|
+
errorCode: 1201,
|
|
1229
|
+
errorKey: "missingCountryCode",
|
|
1230
|
+
httpCode: 422,
|
|
1231
|
+
description: "Country code is required for this payment method.",
|
|
1232
|
+
},
|
|
1233
|
+
{
|
|
1234
|
+
errorCode: 1202,
|
|
1235
|
+
errorKey: "missingCryptoWallet",
|
|
1236
|
+
httpCode: 422,
|
|
1237
|
+
description: "Crypto wallet is required for this payment method.",
|
|
1238
|
+
},
|
|
1239
|
+
{
|
|
1240
|
+
errorCode: 1203,
|
|
1241
|
+
errorKey: "missingRequestCurrency",
|
|
1242
|
+
httpCode: 422,
|
|
1243
|
+
description: "Request currency is required for this payment method.",
|
|
1244
|
+
},
|
|
1245
|
+
{
|
|
1246
|
+
errorCode: 1204,
|
|
1247
|
+
errorKey: "invalidWagerMultiplier",
|
|
1248
|
+
httpCode: 422,
|
|
1249
|
+
description: "Wager multiplier is missing or invalid.",
|
|
1250
|
+
},
|
|
1251
|
+
{
|
|
1252
|
+
errorCode: 1205,
|
|
1253
|
+
errorKey: "financialOperationReasonRequired",
|
|
1254
|
+
httpCode: 422,
|
|
1255
|
+
description: "Financial operation reason is required.",
|
|
1256
|
+
},
|
|
1257
|
+
{
|
|
1258
|
+
errorCode: 1206,
|
|
1259
|
+
errorKey: "financialOperationIdempotencyRequired",
|
|
1260
|
+
httpCode: 422,
|
|
1261
|
+
description: "Financial operation idempotency identifier is required.",
|
|
1262
|
+
},
|
|
1263
|
+
{
|
|
1264
|
+
errorCode: 1207,
|
|
1265
|
+
errorKey: "financialOperationNotFound",
|
|
1266
|
+
httpCode: 404,
|
|
1267
|
+
description: "Financial operation was not found.",
|
|
1268
|
+
},
|
|
1269
|
+
{
|
|
1270
|
+
errorCode: 1208,
|
|
1271
|
+
errorKey: "financialOperationInvalidState",
|
|
1272
|
+
httpCode: 422,
|
|
1273
|
+
description: "Financial operation is not allowed in its current state.",
|
|
1274
|
+
},
|
|
1143
1275
|
];
|
|
1144
1276
|
|
|
1145
1277
|
const STATIC_BY_KEY = Object.fromEntries(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "b2b-platform-utils",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.74",
|
|
4
4
|
"description": "Shared utilities for Node.js microservices: errors map, local cache, logger, numbers, dates, filesystem, media optimization, paginator, slugger, crypto wrapper, sanitize HTML, sorting.",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"license": "KingSizer",
|