@gofynd/fdk-client-javascript 1.1.6 → 1.3.0
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/README.md +52 -3
- package/index.js +0 -3
- package/package.json +1 -2
- package/sdk/application/ApplicationAPIClient.d.ts +15 -1
- package/sdk/application/ApplicationAPIClient.js +12 -3
- package/sdk/application/ApplicationClient.d.ts +36 -6
- package/sdk/application/ApplicationClient.js +30 -43
- package/sdk/application/ApplicationConfig.d.ts +92 -12
- package/sdk/application/ApplicationConfig.js +48 -14
- package/sdk/application/Cart/CartApplicationClient.d.ts +200 -357
- package/sdk/application/Cart/CartApplicationClient.js +711 -483
- package/sdk/application/Cart/CartApplicationModel.d.ts +2054 -96
- package/sdk/application/Cart/CartApplicationModel.js +1224 -93
- package/sdk/application/Cart/CartApplicationValidator.d.ts +508 -30
- package/sdk/application/Cart/CartApplicationValidator.js +270 -15
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +274 -422
- package/sdk/application/Catalog/CatalogApplicationClient.js +865 -630
- package/sdk/application/Catalog/CatalogApplicationModel.d.ts +2320 -117
- package/sdk/application/Catalog/CatalogApplicationModel.js +1566 -172
- package/sdk/application/Catalog/CatalogApplicationValidator.d.ts +798 -31
- package/sdk/application/Catalog/CatalogApplicationValidator.js +318 -3
- package/sdk/application/Common/CommonApplicationClient.d.ts +16 -21
- package/sdk/application/Common/CommonApplicationClient.js +52 -33
- package/sdk/application/Common/CommonApplicationModel.d.ts +368 -19
- package/sdk/application/Common/CommonApplicationModel.js +192 -40
- package/sdk/application/Common/CommonApplicationValidator.d.ts +42 -4
- package/sdk/application/Common/CommonApplicationValidator.js +21 -3
- package/sdk/application/Communication/CommunicationApplicationClient.d.ts +31 -18
- package/sdk/application/Communication/CommunicationApplicationClient.js +86 -47
- package/sdk/application/Communication/CommunicationApplicationModel.d.ts +157 -14
- package/sdk/application/Communication/CommunicationApplicationModel.js +104 -23
- package/sdk/application/Communication/CommunicationApplicationValidator.d.ts +27 -4
- package/sdk/application/Communication/CommunicationApplicationValidator.js +21 -5
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +149 -118
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +457 -260
- package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +2235 -110
- package/sdk/application/Configuration/ConfigurationApplicationModel.js +1113 -193
- package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +160 -8
- package/sdk/application/Configuration/ConfigurationApplicationValidator.js +88 -4
- package/sdk/application/Content/ContentApplicationClient.d.ts +149 -139
- package/sdk/application/Content/ContentApplicationClient.js +489 -278
- package/sdk/application/Content/ContentApplicationModel.d.ts +1010 -105
- package/sdk/application/Content/ContentApplicationModel.js +737 -396
- package/sdk/application/Content/ContentApplicationValidator.d.ts +214 -12
- package/sdk/application/Content/ContentApplicationValidator.js +113 -3
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +23 -29
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +74 -47
- package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +148 -20
- package/sdk/application/FileStorage/FileStorageApplicationModel.js +100 -87
- package/sdk/application/FileStorage/FileStorageApplicationValidator.d.ts +55 -5
- package/sdk/application/FileStorage/FileStorageApplicationValidator.js +33 -6
- package/sdk/application/Lead/LeadApplicationClient.d.ts +57 -53
- package/sdk/application/Lead/LeadApplicationClient.js +188 -103
- package/sdk/application/Lead/LeadApplicationModel.d.ts +686 -54
- package/sdk/application/Lead/LeadApplicationModel.js +330 -244
- package/sdk/application/Lead/LeadApplicationValidator.d.ts +91 -9
- package/sdk/application/Lead/LeadApplicationValidator.js +51 -6
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +40 -33
- package/sdk/application/Logistic/LogisticApplicationClient.js +131 -73
- package/sdk/application/Logistic/LogisticApplicationModel.d.ts +399 -28
- package/sdk/application/Logistic/LogisticApplicationModel.js +293 -24
- package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +48 -6
- package/sdk/application/Logistic/LogisticApplicationValidator.js +34 -6
- package/sdk/application/Order/OrderApplicationClient.d.ts +93 -133
- package/sdk/application/Order/OrderApplicationClient.js +329 -217
- package/sdk/application/Order/OrderApplicationModel.d.ts +1101 -66
- package/sdk/application/Order/OrderApplicationModel.js +776 -57
- package/sdk/application/Order/OrderApplicationValidator.d.ts +249 -14
- package/sdk/application/Order/OrderApplicationValidator.js +114 -5
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +400 -366
- package/sdk/application/Payment/PaymentApplicationClient.js +1176 -703
- package/sdk/application/Payment/PaymentApplicationModel.d.ts +3125 -99
- package/sdk/application/Payment/PaymentApplicationModel.js +1158 -62
- package/sdk/application/Payment/PaymentApplicationValidator.d.ts +494 -41
- package/sdk/application/Payment/PaymentApplicationValidator.js +297 -25
- package/sdk/application/PosCart/PosCartApplicationClient.d.ts +205 -350
- package/sdk/application/PosCart/PosCartApplicationClient.js +720 -491
- package/sdk/application/PosCart/PosCartApplicationModel.d.ts +1823 -89
- package/sdk/application/PosCart/PosCartApplicationModel.js +1117 -85
- package/sdk/application/PosCart/PosCartApplicationValidator.d.ts +480 -29
- package/sdk/application/PosCart/PosCartApplicationValidator.js +262 -15
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +58 -47
- package/sdk/application/Rewards/RewardsApplicationClient.js +187 -102
- package/sdk/application/Rewards/RewardsApplicationModel.d.ts +343 -22
- package/sdk/application/Rewards/RewardsApplicationModel.js +230 -15
- package/sdk/application/Rewards/RewardsApplicationValidator.d.ts +70 -7
- package/sdk/application/Rewards/RewardsApplicationValidator.js +45 -6
- package/sdk/application/Share/ShareApplicationClient.d.ts +52 -50
- package/sdk/application/Share/ShareApplicationClient.js +185 -97
- package/sdk/application/Share/ShareApplicationModel.d.ts +198 -15
- package/sdk/application/Share/ShareApplicationModel.js +131 -31
- package/sdk/application/Share/ShareApplicationValidator.d.ts +86 -8
- package/sdk/application/Share/ShareApplicationValidator.js +48 -4
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +30 -27
- package/sdk/application/Theme/ThemeApplicationClient.js +102 -56
- package/sdk/application/Theme/ThemeApplicationModel.d.ts +1291 -48
- package/sdk/application/Theme/ThemeApplicationModel.js +895 -134
- package/sdk/application/Theme/ThemeApplicationValidator.d.ts +49 -5
- package/sdk/application/Theme/ThemeApplicationValidator.js +26 -3
- package/sdk/application/User/UserApplicationClient.d.ts +260 -305
- package/sdk/application/User/UserApplicationClient.js +910 -522
- package/sdk/application/User/UserApplicationModel.d.ts +992 -101
- package/sdk/application/User/UserApplicationModel.js +699 -248
- package/sdk/application/User/UserApplicationValidator.d.ts +457 -33
- package/sdk/application/User/UserApplicationValidator.js +265 -31
- package/sdk/common/AxiosHelper.js +7 -2
- package/sdk/common/FDKError.d.ts +3 -0
- package/sdk/common/FDKError.js +8 -0
- package/sdk/common/Paginator.d.ts +27 -12
- package/sdk/common/Paginator.js +15 -0
- package/sdk/common/RequestSigner.js +0 -1
- package/sdk/common/utils.d.ts +3 -0
- package/sdk/common/utils.js +29 -0
- package/sdk/partner/PartnerAPIClient.d.ts +16 -1
- package/sdk/partner/PartnerAPIClient.js +12 -2
- package/sdk/partner/PartnerClient.d.ts +22 -3
- package/sdk/partner/PartnerClient.js +20 -0
- package/sdk/partner/PartnerConfig.d.ts +40 -14
- package/sdk/partner/PartnerConfig.js +31 -6
- package/sdk/partner/Theme/ThemePartnerClient.d.ts +299 -0
- package/sdk/partner/Theme/ThemePartnerClient.js +768 -0
- package/sdk/partner/Theme/ThemePartnerModel.d.ts +1706 -0
- package/sdk/partner/Theme/ThemePartnerModel.js +1409 -0
- package/sdk/partner/Theme/ThemePartnerValidator.d.ts +22 -0
- package/sdk/partner/Theme/ThemePartnerValidator.js +157 -0
- package/sdk/partner/index.d.ts +3 -1
- package/sdk/partner/index.js +3 -1
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +30 -25
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +104 -53
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +190 -17
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +132 -15
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +52 -5
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +30 -4
- package/sdk/platform/Billing/BillingPlatformClient.d.ts +133 -97
- package/sdk/platform/Billing/BillingPlatformClient.js +561 -191
- package/sdk/platform/Billing/BillingPlatformModel.d.ts +1071 -68
- package/sdk/platform/Billing/BillingPlatformModel.js +762 -151
- package/sdk/platform/Billing/BillingPlatformValidator.d.ts +175 -12
- package/sdk/platform/Billing/BillingPlatformValidator.js +118 -8
- package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +454 -635
- package/sdk/platform/Cart/CartPlatformApplicationClient.js +1646 -957
- package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +827 -57
- package/sdk/platform/Cart/CartPlatformApplicationValidator.js +492 -34
- package/sdk/platform/Cart/CartPlatformModel.d.ts +3839 -175
- package/sdk/platform/Cart/CartPlatformModel.js +2423 -217
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +528 -638
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +1600 -984
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +1081 -49
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +482 -23
- package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +652 -826
- package/sdk/platform/Catalog/CatalogPlatformClient.js +1979 -1264
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +6869 -326
- package/sdk/platform/Catalog/CatalogPlatformModel.js +4215 -351
- package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +1361 -71
- package/sdk/platform/Catalog/CatalogPlatformValidator.js +624 -30
- package/sdk/platform/Common/CommonPlatformClient.d.ts +16 -21
- package/sdk/platform/Common/CommonPlatformClient.js +50 -33
- package/sdk/platform/Common/CommonPlatformModel.d.ts +423 -19
- package/sdk/platform/Common/CommonPlatformModel.js +214 -40
- package/sdk/platform/Common/CommonPlatformValidator.d.ts +37 -4
- package/sdk/platform/Common/CommonPlatformValidator.js +20 -3
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +731 -303
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +3095 -785
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +699 -41
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +463 -27
- package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +19 -5
- package/sdk/platform/Communication/CommunicationPlatformClient.js +59 -19
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1708 -102
- package/sdk/platform/Communication/CommunicationPlatformModel.js +1360 -235
- package/sdk/platform/Communication/CommunicationPlatformValidator.d.ts +16 -3
- package/sdk/platform/Communication/CommunicationPlatformValidator.js +11 -3
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +127 -111
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +435 -225
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +882 -43
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +666 -78
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +184 -13
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +105 -10
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +327 -240
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +922 -438
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +297 -22
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +191 -17
- package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +184 -178
- package/sdk/platform/Configuration/ConfigurationPlatformClient.js +555 -311
- package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +4337 -188
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +2178 -248
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +332 -19
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +153 -10
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +605 -578
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +1996 -987
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +872 -62
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +487 -35
- package/sdk/platform/Content/ContentPlatformModel.d.ts +1472 -108
- package/sdk/platform/Content/ContentPlatformModel.js +1085 -204
- package/sdk/platform/Discount/DiscountPlatformClient.d.ts +85 -82
- package/sdk/platform/Discount/DiscountPlatformClient.js +333 -175
- package/sdk/platform/Discount/DiscountPlatformModel.d.ts +281 -15
- package/sdk/platform/Discount/DiscountPlatformModel.js +189 -10
- package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +185 -13
- package/sdk/platform/Discount/DiscountPlatformValidator.js +88 -8
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +109 -52
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +570 -105
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +141 -6
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +118 -7
- package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +43 -63
- package/sdk/platform/FileStorage/FileStoragePlatformClient.js +153 -135
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +426 -20
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +379 -40
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +106 -8
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +60 -8
- package/sdk/platform/Finance/FinancePlatformClient.d.ts +260 -129
- package/sdk/platform/Finance/FinancePlatformClient.js +1182 -194
- package/sdk/platform/Finance/FinancePlatformModel.d.ts +1267 -50
- package/sdk/platform/Finance/FinancePlatformModel.js +1252 -38
- package/sdk/platform/Finance/FinancePlatformValidator.d.ts +233 -15
- package/sdk/platform/Finance/FinancePlatformValidator.js +229 -16
- package/sdk/platform/Inventory/InventoryPlatformClient.d.ts +111 -97
- package/sdk/platform/Inventory/InventoryPlatformClient.js +330 -199
- package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +1354 -61
- package/sdk/platform/Inventory/InventoryPlatformModel.js +916 -83
- package/sdk/platform/Inventory/InventoryPlatformValidator.d.ts +168 -12
- package/sdk/platform/Inventory/InventoryPlatformValidator.js +82 -6
- package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +100 -106
- package/sdk/platform/Lead/LeadPlatformApplicationClient.js +372 -186
- package/sdk/platform/Lead/LeadPlatformApplicationValidator.d.ts +180 -14
- package/sdk/platform/Lead/LeadPlatformApplicationValidator.js +94 -9
- package/sdk/platform/Lead/LeadPlatformClient.d.ts +89 -104
- package/sdk/platform/Lead/LeadPlatformClient.js +305 -180
- package/sdk/platform/Lead/LeadPlatformModel.d.ts +1045 -54
- package/sdk/platform/Lead/LeadPlatformModel.js +504 -142
- package/sdk/platform/Lead/LeadPlatformValidator.d.ts +173 -12
- package/sdk/platform/Lead/LeadPlatformValidator.js +92 -15
- package/sdk/platform/OAuthClient.js +6 -2
- package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +20 -14
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +58 -29
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +26 -4
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +16 -3
- package/sdk/platform/Order/OrderPlatformClient.d.ts +437 -556
- package/sdk/platform/Order/OrderPlatformClient.js +1500 -760
- package/sdk/platform/Order/OrderPlatformModel.d.ts +5225 -247
- package/sdk/platform/Order/OrderPlatformModel.js +3473 -260
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +859 -37
- package/sdk/platform/Order/OrderPlatformValidator.js +435 -23
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +16 -42
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +52 -155
- package/sdk/platform/Partner/PartnerPlatformApplicationValidator.d.ts +37 -6
- package/sdk/platform/Partner/PartnerPlatformApplicationValidator.js +19 -17
- package/sdk/platform/Partner/PartnerPlatformModel.d.ts +78 -45
- package/sdk/platform/Partner/PartnerPlatformModel.js +43 -369
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +418 -288
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +1509 -505
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +438 -30
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +312 -19
- package/sdk/platform/Payment/PaymentPlatformClient.d.ts +83 -73
- package/sdk/platform/Payment/PaymentPlatformClient.js +259 -154
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +3200 -93
- package/sdk/platform/Payment/PaymentPlatformModel.js +1334 -36
- package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +111 -11
- package/sdk/platform/Payment/PaymentPlatformValidator.js +68 -7
- package/sdk/platform/PlatformAPIClient.d.ts +16 -1
- package/sdk/platform/PlatformAPIClient.js +9 -1
- package/sdk/platform/PlatformApplicationClient.d.ts +22 -1798
- package/sdk/platform/PlatformApplicationClient.js +17 -1899
- package/sdk/platform/PlatformClient.d.ts +31 -12581
- package/sdk/platform/PlatformClient.js +30 -15089
- package/sdk/platform/PlatformConfig.d.ts +37 -11
- package/sdk/platform/PlatformConfig.js +32 -6
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +96 -92
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +344 -177
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +149 -12
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +82 -8
- package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +360 -23
- package/sdk/platform/Rewards/RewardsPlatformModel.js +238 -22
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +159 -92
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +473 -208
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +138 -13
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +100 -14
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +166 -178
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +518 -329
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1408 -96
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +1034 -71
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +280 -18
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +134 -11
- package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +41 -66
- package/sdk/platform/Share/SharePlatformApplicationClient.js +149 -116
- package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +87 -7
- package/sdk/platform/Share/SharePlatformApplicationValidator.js +42 -5
- package/sdk/platform/Share/SharePlatformModel.d.ts +250 -16
- package/sdk/platform/Share/SharePlatformModel.js +167 -19
- package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +229 -193
- package/sdk/platform/Theme/ThemePlatformApplicationClient.js +976 -352
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +345 -24
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +206 -14
- package/sdk/platform/Theme/ThemePlatformClient.d.ts +37 -0
- package/sdk/platform/Theme/ThemePlatformClient.js +235 -0
- package/sdk/platform/Theme/ThemePlatformModel.d.ts +1527 -48
- package/sdk/platform/Theme/ThemePlatformModel.js +1099 -118
- package/sdk/platform/Theme/ThemePlatformValidator.d.ts +32 -0
- package/sdk/platform/Theme/ThemePlatformValidator.js +38 -0
- package/sdk/platform/User/UserPlatformApplicationClient.d.ts +138 -152
- package/sdk/platform/User/UserPlatformApplicationClient.js +470 -244
- package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +242 -18
- package/sdk/platform/User/UserPlatformApplicationValidator.js +129 -12
- package/sdk/platform/User/UserPlatformModel.d.ts +653 -101
- package/sdk/platform/User/UserPlatformModel.js +467 -424
- package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +153 -49
- package/sdk/platform/Webhook/WebhookPlatformClient.js +896 -88
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +632 -16
- package/sdk/platform/Webhook/WebhookPlatformModel.js +502 -54
- package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +170 -7
- package/sdk/platform/Webhook/WebhookPlatformValidator.js +157 -7
- package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +16 -21
- package/sdk/public/Configuration/ConfigurationPublicClient.js +48 -33
- package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +370 -19
- package/sdk/public/Configuration/ConfigurationPublicModel.js +191 -40
- package/sdk/public/Configuration/ConfigurationPublicValidator.d.ts +42 -4
- package/sdk/public/Configuration/ConfigurationPublicValidator.js +21 -3
- package/sdk/public/Inventory/InventoryPublicClient.d.ts +54 -48
- package/sdk/public/Inventory/InventoryPublicClient.js +161 -98
- package/sdk/public/Inventory/InventoryPublicModel.d.ts +392 -21
- package/sdk/public/Inventory/InventoryPublicModel.js +267 -27
- package/sdk/public/Inventory/InventoryPublicValidator.d.ts +90 -8
- package/sdk/public/Inventory/InventoryPublicValidator.js +44 -4
- package/sdk/public/Partner/PartnerPublicClient.d.ts +22 -0
- package/sdk/public/Partner/PartnerPublicClient.js +110 -0
- package/sdk/public/Partner/PartnerPublicModel.d.ts +240 -0
- package/sdk/public/Partner/PartnerPublicModel.js +280 -0
- package/sdk/public/Partner/PartnerPublicValidator.d.ts +18 -0
- package/sdk/public/Partner/PartnerPublicValidator.js +19 -0
- package/sdk/public/PublicAPIClient.d.ts +14 -1
- package/sdk/public/PublicAPIClient.js +7 -1
- package/sdk/public/PublicClient.d.ts +21 -3
- package/sdk/public/PublicClient.js +20 -0
- package/sdk/public/PublicConfig.d.ts +27 -6
- package/sdk/public/PublicConfig.js +17 -1
- package/sdk/public/Webhook/WebhookPublicClient.d.ts +16 -11
- package/sdk/public/Webhook/WebhookPublicClient.js +48 -27
- package/sdk/public/Webhook/WebhookPublicModel.d.ts +52 -16
- package/sdk/public/Webhook/WebhookPublicModel.js +33 -113
- package/sdk/public/Webhook/WebhookPublicValidator.d.ts +18 -3
- package/sdk/public/Webhook/WebhookPublicValidator.js +14 -4
- package/sdk/public/index.d.ts +1 -0
- package/sdk/public/index.js +2 -0
- package/sdk/application/ApplicationModels.d.ts +0 -3
- package/sdk/application/ApplicationModels.js +0 -20
- package/sdk/platform/Partner/PartnerPlatformClient.d.ts +0 -145
- package/sdk/platform/Partner/PartnerPlatformClient.js +0 -799
- package/sdk/platform/Partner/PartnerPlatformValidator.d.ts +0 -14
- package/sdk/platform/Partner/PartnerPlatformValidator.js +0 -87
|
@@ -1,12 +1,1004 @@
|
|
|
1
1
|
const Joi = require("joi");
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
/**
|
|
4
|
+
* @typedef AddBeneficiaryDetailsOTPRequest
|
|
5
|
+
* @property {BankDetailsForOTP} details
|
|
6
|
+
* @property {string} order_id
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @typedef AddressDetail
|
|
11
|
+
* @property {string} address - Address details
|
|
12
|
+
* @property {string} address_type - Address type e.g. home, office
|
|
13
|
+
* @property {string} area - Area details
|
|
14
|
+
* @property {string} area_code - Customer pin/zip code
|
|
15
|
+
* @property {string} area_code_slug - Area slug code, use pin/zip code if not available
|
|
16
|
+
* @property {string} city - City name
|
|
17
|
+
* @property {string} country - Country name
|
|
18
|
+
* @property {string} country_iso_code - Country's code name e.g. `IN`, `GB`
|
|
19
|
+
* @property {string} country_phone_code - Country's phone code
|
|
20
|
+
* @property {string} [email] - Customer email
|
|
21
|
+
* @property {string} [expire_at] - Address expiry timestamp
|
|
22
|
+
* @property {string} g_address_id - Unique address id generated by Fynd platform
|
|
23
|
+
* @property {Object} [geo_location] - Location latitude and logitude
|
|
24
|
+
* @property {Object} [google_map_point] - Google map point of location
|
|
25
|
+
* @property {string} [landmark] - Landmark
|
|
26
|
+
* @property {string} name - Customer name
|
|
27
|
+
* @property {string} phone - Phone number
|
|
28
|
+
* @property {string} state - State of the customer
|
|
29
|
+
* @property {Object[]} [tags] - Optional address tag
|
|
30
|
+
*/
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* @typedef BankDetailsForOTP
|
|
34
|
+
* @property {string} account_holder
|
|
35
|
+
* @property {string} account_no
|
|
36
|
+
* @property {string} bank_name
|
|
37
|
+
* @property {string} branch_name
|
|
38
|
+
* @property {string} ifsc_code
|
|
39
|
+
*/
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* @typedef CancelOrResendPaymentLinkRequest
|
|
43
|
+
* @property {string} payment_link_id - Unique id of payment link
|
|
44
|
+
*/
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* @typedef CancelPaymentLinkResponse
|
|
48
|
+
* @property {string} message - Message
|
|
49
|
+
* @property {number} status_code - HTTP status code
|
|
50
|
+
* @property {boolean} success - Successful or failure
|
|
51
|
+
*/
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* @typedef CODdata
|
|
55
|
+
* @property {boolean} is_active - COD option is active or not
|
|
56
|
+
* @property {number} limit - Total Limit of user
|
|
57
|
+
* @property {number} remaining_limit - Remaining Limit for COD of User
|
|
58
|
+
* @property {number} usages - Used COD limit from the user Limit
|
|
59
|
+
* @property {string} user_id - Payment mode name
|
|
60
|
+
*/
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* @typedef Code
|
|
64
|
+
* @property {string} code - Payment Method Code
|
|
65
|
+
* @property {string} merchant_code - Merchant Payment Code
|
|
66
|
+
* @property {string} name - Name of payment method
|
|
67
|
+
*/
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* @typedef CreatePaymentLinkMeta
|
|
71
|
+
* @property {string} amount
|
|
72
|
+
* @property {string} [assign_card_id]
|
|
73
|
+
* @property {string} cart_id
|
|
74
|
+
* @property {string} checkout_mode
|
|
75
|
+
* @property {string} pincode
|
|
76
|
+
*/
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* @typedef CreatePaymentLinkRequest
|
|
80
|
+
* @property {number} amount - Total value of order
|
|
81
|
+
* @property {string} [description] - Merchant order id
|
|
82
|
+
* @property {string} email - Email to which the payment link is to be sent
|
|
83
|
+
* @property {string} external_order_id - Merchant order id
|
|
84
|
+
* @property {CreatePaymentLinkMeta} meta - Meta
|
|
85
|
+
* @property {string} mobile_number - Mobile number to which the payment link is
|
|
86
|
+
* to be sent
|
|
87
|
+
*/
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* @typedef CreatePaymentLinkResponse
|
|
91
|
+
* @property {string} message - Message
|
|
92
|
+
* @property {string} [payment_link_id] - Unique id of payment link
|
|
93
|
+
* @property {string} [payment_link_url] - Url of payment link
|
|
94
|
+
* @property {number} [polling_timeout] - Polling request timeout
|
|
95
|
+
* @property {number} status_code - HTTP status code
|
|
96
|
+
* @property {boolean} success - Successful or failure
|
|
97
|
+
*/
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* @typedef DeletePayoutResponse
|
|
101
|
+
* @property {boolean} success - Response is successful or not
|
|
102
|
+
*/
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* @typedef DeleteSubscriptionPaymentMethodResponse
|
|
106
|
+
* @property {boolean} success - Success or failure.
|
|
107
|
+
*/
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* @typedef EdcAddRequest
|
|
111
|
+
* @property {number} aggregator_id - Aggregator which will accept payment
|
|
112
|
+
* @property {string} [device_tag] - Device tag of edc device to identify it
|
|
113
|
+
* @property {string} edc_device_serial_no - Serial number or imei of EDC device
|
|
114
|
+
* @property {string} edc_model - Model of the edc machine
|
|
115
|
+
* @property {number} store_id - Store at which devices is to used
|
|
116
|
+
* @property {string} terminal_serial_no - Device serial number of
|
|
117
|
+
* terminal(android tablet)
|
|
118
|
+
*/
|
|
119
|
+
|
|
120
|
+
/**
|
|
121
|
+
* @typedef EdcAggregatorAndModelListResponse
|
|
122
|
+
* @property {EdcModelData[]} data - List of aggregators and their edc models
|
|
123
|
+
* @property {boolean} success - Response is successful or not
|
|
124
|
+
*/
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* @typedef EdcDevice
|
|
128
|
+
* @property {number} aggregator_id - Aggregator which will accept payment
|
|
129
|
+
* @property {string} [aggregator_name] - Name of the corresponding aggregator
|
|
130
|
+
* @property {string} application_id - Application ID
|
|
131
|
+
* @property {string} device_tag - Device tag of edc device to identify it
|
|
132
|
+
* @property {string} edc_device_serial_no - Serial number of EDC device
|
|
133
|
+
* @property {string} [edc_model] - Name of the model
|
|
134
|
+
* @property {boolean} is_active - State whether device is active or inactive
|
|
135
|
+
* @property {string} [merchant_store_pos_code] - This is provided by pinelabs
|
|
136
|
+
* @property {number} store_id - Store at which devices is to used
|
|
137
|
+
* @property {string} terminal_serial_no - Device serial number of
|
|
138
|
+
* terminal(android tablet)
|
|
139
|
+
* @property {string} terminal_unique_identifier - Genearated unique value for edc device
|
|
140
|
+
*/
|
|
141
|
+
|
|
142
|
+
/**
|
|
143
|
+
* @typedef EdcDeviceAddResponse
|
|
144
|
+
* @property {EdcDevice} data - Details of the EDC Device that is added
|
|
145
|
+
* @property {boolean} success - Response is successful or not
|
|
146
|
+
*/
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* @typedef EdcDeviceDetailsResponse
|
|
150
|
+
* @property {EdcDevice} data - Details of one EDC Device
|
|
151
|
+
* @property {boolean} success - Response is successful or not
|
|
152
|
+
*/
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* @typedef EdcDeviceListResponse
|
|
156
|
+
* @property {EdcDevice[]} items - List of all edc mapped to the application
|
|
157
|
+
* options with their Details.
|
|
158
|
+
* @property {Page} page - Pagination Response
|
|
159
|
+
* @property {boolean} success - Response is successful or not
|
|
160
|
+
*/
|
|
161
|
+
|
|
162
|
+
/**
|
|
163
|
+
* @typedef EdcDeviceStatsResponse
|
|
164
|
+
* @property {StatisticsData} statistics - Message
|
|
165
|
+
* @property {boolean} success - Response is successful or not
|
|
166
|
+
*/
|
|
167
|
+
|
|
168
|
+
/**
|
|
169
|
+
* @typedef EdcDeviceUpdateResponse
|
|
170
|
+
* @property {boolean} success - Response is successful or not
|
|
171
|
+
*/
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* @typedef EdcModelData
|
|
175
|
+
* @property {string} aggregator - Name of aggregator
|
|
176
|
+
* @property {number} aggregator_id - ID of aggregator
|
|
177
|
+
* @property {string[]} models - List of string of edc models
|
|
178
|
+
*/
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* @typedef EdcUpdateRequest
|
|
182
|
+
* @property {number} [aggregator_id] - Aggregator which will accept payment
|
|
183
|
+
* @property {string} [device_tag] - Device tag of edc device to identify it
|
|
184
|
+
* @property {string} [edc_device_serial_no] - Serial number or imei of EDC device
|
|
185
|
+
* @property {string} [edc_model] - Model of the edc machine
|
|
186
|
+
* @property {boolean} [is_active] - State whether device is active or inactive
|
|
187
|
+
* @property {string} [merchant_store_pos_code] - This is provided by pinelabs
|
|
188
|
+
* @property {number} [store_id] - Store at which devices is to used
|
|
189
|
+
*/
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* @typedef ErrorCodeAndDescription
|
|
193
|
+
* @property {string} code - Error descrption code.
|
|
194
|
+
* @property {string} description - Error human understandable description.
|
|
195
|
+
*/
|
|
196
|
+
|
|
197
|
+
/**
|
|
198
|
+
* @typedef ErrorCodeDescription
|
|
199
|
+
* @property {string} code - Error descrption code.
|
|
200
|
+
* @property {string} description - Error human understandable description.
|
|
201
|
+
* @property {boolean} success - Response is successful or not
|
|
202
|
+
*/
|
|
203
|
+
|
|
204
|
+
/**
|
|
205
|
+
* @typedef ErrorDescription
|
|
206
|
+
* @property {number} [amount] - Amount paid
|
|
207
|
+
* @property {boolean} [cancelled] - Payment link is cancelled or not
|
|
208
|
+
* @property {boolean} [expired] - Payment link expired or not
|
|
209
|
+
* @property {boolean} [invalid_id] - Payment link id is valid or not
|
|
210
|
+
* @property {string} [merchant_name] - Name of merchant that created payment link
|
|
211
|
+
* @property {string} [merchant_order_id] - Order id
|
|
212
|
+
* @property {string} [msg] - Message
|
|
213
|
+
* @property {string} [payment_transaction_id] - Payment transaction id
|
|
214
|
+
*/
|
|
215
|
+
|
|
216
|
+
/**
|
|
217
|
+
* @typedef ErrorResponse
|
|
218
|
+
* @property {Object} [error]
|
|
219
|
+
* @property {string} message - Message
|
|
220
|
+
* @property {number} status_code - HTTP status code
|
|
221
|
+
* @property {boolean} success - Successful or failure
|
|
222
|
+
*/
|
|
223
|
+
|
|
224
|
+
/**
|
|
225
|
+
* @typedef GetOauthUrlResponse
|
|
226
|
+
* @property {boolean} success - Response is successful or not
|
|
227
|
+
* @property {string} url - The url to call for authenticating
|
|
228
|
+
*/
|
|
229
|
+
|
|
230
|
+
/**
|
|
231
|
+
* @typedef GetPaymentCode
|
|
232
|
+
* @property {PaymentCode} method_code - Payment method code
|
|
233
|
+
*/
|
|
234
|
+
|
|
235
|
+
/**
|
|
236
|
+
* @typedef GetPaymentCodeResponse
|
|
237
|
+
* @property {GetPaymentCode} data - Data about Payment Code.
|
|
238
|
+
* @property {boolean} success - Response is successful or not.
|
|
239
|
+
*/
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* @typedef GetPaymentLinkResponse
|
|
243
|
+
* @property {number} [amount] - Total value of order
|
|
244
|
+
* @property {string} [external_order_id] - Merchant order id
|
|
245
|
+
* @property {string} [merchant_name] - Merchant name
|
|
246
|
+
* @property {string} message - Message
|
|
247
|
+
* @property {string} [payment_link_current_status] - Status of payment link
|
|
248
|
+
* @property {string} [payment_link_url] - Url of payment link
|
|
249
|
+
* @property {number} [polling_timeout] - Polling request timeout
|
|
250
|
+
* @property {number} status_code - HTTP status code
|
|
251
|
+
* @property {boolean} success - Successful or failure
|
|
252
|
+
*/
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* @typedef GetUserCODLimitResponse
|
|
256
|
+
* @property {boolean} success - Response is successful or not
|
|
257
|
+
* @property {CODdata} user_cod_data - User COD Data
|
|
258
|
+
*/
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* @typedef HttpErrorCodeAndResponse
|
|
262
|
+
* @property {ErrorCodeAndDescription} error
|
|
263
|
+
* @property {boolean} success - Response is successful or not
|
|
264
|
+
*/
|
|
265
|
+
|
|
266
|
+
/**
|
|
267
|
+
* @typedef IfscCodeResponse
|
|
268
|
+
* @property {string} bank_name - Bank Name Of Account
|
|
269
|
+
* @property {string} branch_name - Branch Name Of Account
|
|
270
|
+
* @property {boolean} [success] - Response is successful or not
|
|
271
|
+
*/
|
|
272
|
+
|
|
273
|
+
/**
|
|
274
|
+
* @typedef IntentApp
|
|
275
|
+
* @property {string} [code] - Code
|
|
276
|
+
* @property {string} [display_name] - Display_name
|
|
277
|
+
* @property {Object} [logos] - Logos
|
|
278
|
+
* @property {string} [package_name] - Package_name
|
|
279
|
+
*/
|
|
280
|
+
|
|
281
|
+
/**
|
|
282
|
+
* @typedef IntentAppErrorList
|
|
283
|
+
* @property {string} [code] - Code
|
|
284
|
+
* @property {string} [package_name] - Package_name
|
|
285
|
+
*/
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* @typedef LinkStatus
|
|
289
|
+
* @property {string} message - Message
|
|
290
|
+
* @property {boolean} status - Link action status
|
|
291
|
+
*/
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* @typedef MerchantOnBoardingRequest
|
|
295
|
+
* @property {string} aggregator - Payment aggregator name
|
|
296
|
+
* @property {string} app_id - Application id
|
|
297
|
+
* @property {string} credit_line_id - Merchant ID at Ajiodhan's end
|
|
298
|
+
* @property {string} status - Status
|
|
299
|
+
* @property {string} user_id - Deadlock/Grimlock user id
|
|
300
|
+
*/
|
|
301
|
+
|
|
302
|
+
/**
|
|
303
|
+
* @typedef MerchantOnBoardingResponse
|
|
304
|
+
* @property {Object} data
|
|
305
|
+
* @property {boolean} success - Success/Failure of the transaction
|
|
306
|
+
*/
|
|
307
|
+
|
|
308
|
+
/**
|
|
309
|
+
* @typedef MerchnatPaymentModeRequest
|
|
310
|
+
* @property {Object} [offline] - Details to be updated for online payment configuration.
|
|
311
|
+
* @property {Object} [online] - Details to be updated for offline payment configuration.
|
|
312
|
+
*/
|
|
313
|
+
|
|
314
|
+
/**
|
|
315
|
+
* @typedef MerchnatPaymentModeResponse
|
|
316
|
+
* @property {Object[]} [items] - List of all aggregator and payment mode details.
|
|
317
|
+
* @property {string} [message] - Message
|
|
318
|
+
* @property {boolean} success - Response is successful or not.
|
|
319
|
+
*/
|
|
320
|
+
|
|
321
|
+
/**
|
|
322
|
+
* @typedef MultiTenderPaymentMeta
|
|
323
|
+
* @property {string} [current_status]
|
|
324
|
+
* @property {Object} [extra_meta]
|
|
325
|
+
* @property {string} [order_id]
|
|
326
|
+
* @property {string} [payment_gateway]
|
|
327
|
+
* @property {string} [payment_id]
|
|
328
|
+
*/
|
|
329
|
+
|
|
330
|
+
/**
|
|
331
|
+
* @typedef MultiTenderPaymentMethod
|
|
332
|
+
* @property {number} amount - Payment amount
|
|
333
|
+
* @property {MultiTenderPaymentMeta} [meta]
|
|
334
|
+
* @property {string} mode
|
|
335
|
+
* @property {string} [name] - Payment mode name
|
|
336
|
+
*/
|
|
337
|
+
|
|
338
|
+
/**
|
|
339
|
+
* @typedef NotFoundResourceError
|
|
340
|
+
* @property {string} code - Bad Request Data
|
|
341
|
+
* @property {string} description - Not Found
|
|
342
|
+
* @property {boolean} success - Response is successful or not
|
|
343
|
+
*/
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* @typedef OrderBeneficiaryDetails
|
|
347
|
+
* @property {string} account_holder - Account Holder Name
|
|
348
|
+
* @property {string} account_no - Account Number
|
|
349
|
+
* @property {string} address - Address of User
|
|
350
|
+
* @property {string} bank_name - Bank Name Of Account
|
|
351
|
+
* @property {string} beneficiary_id - Benenficiary Id
|
|
352
|
+
* @property {string} [branch_name] - Branch Name Of Account
|
|
353
|
+
* @property {string} [comment] - Remarks
|
|
354
|
+
* @property {string} created_on - Creation Date of Beneficiary
|
|
355
|
+
* @property {string} [delights_user_name] - User Id Who filled the Beneficiary
|
|
356
|
+
* @property {string} display_name - Display Name Of Account
|
|
357
|
+
* @property {string} email - EMail of User
|
|
358
|
+
* @property {number} id -
|
|
359
|
+
* @property {string} ifsc_code - Ifsc Code Of Account
|
|
360
|
+
* @property {boolean} is_active - Boolean Flag whether Beneficiary set or not
|
|
361
|
+
* @property {string} [mobile] - MObile no of User
|
|
362
|
+
* @property {string} modified_on - MOdification Date of Beneficiary
|
|
363
|
+
* @property {string} subtitle - SHort Title Of Account
|
|
364
|
+
* @property {string} title - Title Of Account
|
|
365
|
+
* @property {string} transfer_mode - Transfer Mode Of Account
|
|
366
|
+
*/
|
|
367
|
+
|
|
368
|
+
/**
|
|
369
|
+
* @typedef OrderBeneficiaryResponse
|
|
370
|
+
* @property {OrderBeneficiaryDetails[]} [beneficiaries] - All Beneficiaries Of An Order
|
|
371
|
+
* @property {boolean} [show_beneficiary_details] - Show beneficiary details or not.
|
|
372
|
+
*/
|
|
373
|
+
|
|
374
|
+
/**
|
|
375
|
+
* @typedef OrderDetail
|
|
376
|
+
* @property {string} aggregator - Name of the payment gateway aggregator.
|
|
377
|
+
* @property {Object} aggregator_order_details - Aggregator order details
|
|
378
|
+
* generated by the payment gateway.
|
|
379
|
+
* @property {number} amount - Amount paid.
|
|
380
|
+
* @property {string} currency - Currency of the payment.
|
|
381
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
382
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
383
|
+
* Fynd payments platform and is unique.
|
|
384
|
+
* @property {string} status - Order status created by payment gateway aggregator.
|
|
385
|
+
*/
|
|
386
|
+
|
|
387
|
+
/**
|
|
388
|
+
* @typedef Page
|
|
389
|
+
* @property {number} [current]
|
|
390
|
+
* @property {boolean} [has_next]
|
|
391
|
+
* @property {boolean} [has_previous]
|
|
392
|
+
* @property {number} [item_total]
|
|
393
|
+
* @property {string} [next_id]
|
|
394
|
+
* @property {number} [size]
|
|
395
|
+
* @property {string} type
|
|
396
|
+
*/
|
|
397
|
+
|
|
398
|
+
/**
|
|
399
|
+
* @typedef PaymentCode
|
|
400
|
+
* @property {Code} codes - List of dict that contains payment method data
|
|
401
|
+
* @property {string} name - Name of payment name
|
|
402
|
+
* @property {string} networks - Payment networks
|
|
403
|
+
* @property {string} types - Type of payment mode
|
|
404
|
+
*/
|
|
405
|
+
|
|
406
|
+
/**
|
|
407
|
+
* @typedef PaymentConfirmationRequest
|
|
408
|
+
* @property {string} order_id - Unique order id
|
|
409
|
+
* @property {MultiTenderPaymentMethod[]} payment_methods
|
|
410
|
+
*/
|
|
411
|
+
|
|
412
|
+
/**
|
|
413
|
+
* @typedef PaymentConfirmationResponse
|
|
414
|
+
* @property {string} message - Message
|
|
415
|
+
* @property {string} order_id - Unique order id
|
|
416
|
+
* @property {boolean} success - Payment confirmation updated or not.
|
|
417
|
+
*/
|
|
418
|
+
|
|
419
|
+
/**
|
|
420
|
+
* @typedef PaymentGatewayConfig
|
|
421
|
+
* @property {string} config_type - Config Type of the aggregator
|
|
422
|
+
* @property {boolean} [is_active] - Enable/ Disable Flag
|
|
423
|
+
* @property {string} key - Api key of the payment aggregator
|
|
424
|
+
* @property {string} merchant_salt - Merchant key of the payment aggregator
|
|
425
|
+
* @property {string} secret - Secret Key of the payment aggregator
|
|
426
|
+
*/
|
|
427
|
+
|
|
428
|
+
/**
|
|
429
|
+
* @typedef PaymentGatewayConfigRequest
|
|
430
|
+
* @property {PaymentGatewayConfig} [aggregator_name]
|
|
431
|
+
* @property {string} app_id - Application Id to which Payment config Mapped
|
|
432
|
+
* @property {boolean} [is_active] - Enable/ Disable Flag
|
|
433
|
+
*/
|
|
434
|
+
|
|
435
|
+
/**
|
|
436
|
+
* @typedef PaymentGatewayConfigResponse
|
|
437
|
+
* @property {Object[]} [aggregators] - List of all speceific Payment options
|
|
438
|
+
* with their Details.
|
|
439
|
+
* @property {string} app_id - Application Id to which Payment config Mapped
|
|
440
|
+
* @property {boolean} created - Response is created or not
|
|
441
|
+
* @property {string[]} display_fields - List of all included options with their Details.
|
|
442
|
+
* @property {string[]} excluded_fields - List of all excluded options with their Details.
|
|
443
|
+
* @property {boolean} success - Response is successful or not
|
|
444
|
+
*/
|
|
445
|
+
|
|
446
|
+
/**
|
|
447
|
+
* @typedef PaymentGatewayToBeReviewed
|
|
448
|
+
* @property {string[]} aggregator - List of added payment gateway
|
|
449
|
+
* @property {boolean} success - Response is successful or not
|
|
450
|
+
*/
|
|
451
|
+
|
|
452
|
+
/**
|
|
453
|
+
* @typedef PaymentInitializationRequest
|
|
454
|
+
* @property {string} aggregator - Payment gateway name
|
|
455
|
+
* @property {number} amount - Payable amount.
|
|
456
|
+
* @property {string} contact - Customer valid mobile number
|
|
457
|
+
* @property {string} currency - Currency code.
|
|
458
|
+
* @property {string} customer_id - Payment gateway customer id.
|
|
459
|
+
* @property {string} [device_id] - EDC machine Unique Identifier
|
|
460
|
+
* @property {string} email - Customer valid email
|
|
461
|
+
* @property {string} merchant_order_id - Unique fynd order id
|
|
462
|
+
* @property {string} method - Payment method
|
|
463
|
+
* @property {string} order_id - Payment gateway order id
|
|
464
|
+
* @property {string} [razorpay_payment_id] - Payment gateway payment id
|
|
465
|
+
* @property {number} [timeout] - Payment polling timeout if not recieved response
|
|
466
|
+
* @property {string} [vpa] - Customer vpa address
|
|
467
|
+
*/
|
|
468
|
+
|
|
469
|
+
/**
|
|
470
|
+
* @typedef PaymentInitializationResponse
|
|
471
|
+
* @property {string} aggregator - Payment gateway name
|
|
472
|
+
* @property {string} [aggregator_order_id] - Payment order id
|
|
473
|
+
* @property {number} [amount] - Payable amount.
|
|
474
|
+
* @property {string} [bqr_image] - Bharath qr image url.
|
|
475
|
+
* @property {string} [currency] - Currency code.
|
|
476
|
+
* @property {string} [customer_id] - Payment gateway customer id.
|
|
477
|
+
* @property {string} [device_id] - EDC machine Unique Identifier
|
|
478
|
+
* @property {string} merchant_order_id - Order id
|
|
479
|
+
* @property {string} method - Payment method
|
|
480
|
+
* @property {string} polling_url - Polling url.
|
|
481
|
+
* @property {string} [razorpay_payment_id] - Payment id.
|
|
482
|
+
* @property {string} [status] - Status of payment.
|
|
483
|
+
* @property {boolean} success - Response is successful or not.
|
|
484
|
+
* @property {number} [timeout] - Timeout.
|
|
485
|
+
* @property {string} [upi_poll_url] - UPI poll url.
|
|
486
|
+
* @property {string} [virtual_id] - Payment virtual address.
|
|
487
|
+
* @property {string} [vpa] - Customer vpa address
|
|
488
|
+
*/
|
|
489
|
+
|
|
490
|
+
/**
|
|
491
|
+
* @typedef PaymentModeList
|
|
492
|
+
* @property {string} aggregator_name - Aggregator_name
|
|
493
|
+
* @property {string} [card_brand] - Card_brand
|
|
494
|
+
* @property {string} [card_brand_image] - Card_brand_image
|
|
495
|
+
* @property {string} [card_fingerprint] - Card_fingerprint
|
|
496
|
+
* @property {string} [card_id] - Card_id
|
|
497
|
+
* @property {string} [card_isin] - Card_isin
|
|
498
|
+
* @property {string} [card_issuer] - Card_issuer
|
|
499
|
+
* @property {string} [card_name] - Card_name
|
|
500
|
+
* @property {string} [card_number] - Card_number
|
|
501
|
+
* @property {string} [card_reference] - Card_reference
|
|
502
|
+
* @property {string} [card_token] - Card_token
|
|
503
|
+
* @property {string} [card_type] - Card_type
|
|
504
|
+
* @property {number} [cod_limit] - Cod limit
|
|
505
|
+
* @property {number} [cod_limit_per_order] - Cod limit per order
|
|
506
|
+
* @property {string} [code] - Code
|
|
507
|
+
* @property {boolean} [compliant_with_tokenisation_guidelines] - If card is
|
|
508
|
+
* tokenised or not
|
|
509
|
+
* @property {string} [display_name] - Display name
|
|
510
|
+
* @property {number} [display_priority] - Dispaly Priority
|
|
511
|
+
* @property {number} [exp_month] - Exp_month
|
|
512
|
+
* @property {number} [exp_year] - Exp_year
|
|
513
|
+
* @property {boolean} [expired] - Expired
|
|
514
|
+
* @property {string} [fynd_vpa] - Fynd_vpa
|
|
515
|
+
* @property {IntentApp[]} [intent_app] - Intent_app
|
|
516
|
+
* @property {IntentAppErrorList[]} [intent_app_error_dict_list] -
|
|
517
|
+
* Intent_app_error_dict_list
|
|
518
|
+
* @property {string[]} [intent_app_error_list] - Intent_app_error_list
|
|
519
|
+
* @property {boolean} [intent_flow] - Intent_flow
|
|
520
|
+
* @property {Object} [logo_url] - Logo
|
|
521
|
+
* @property {string} [merchant_code] - Merchant code
|
|
522
|
+
* @property {string} [name] - Name
|
|
523
|
+
* @property {string} [nickname] - Nickname
|
|
524
|
+
* @property {number} [remaining_limit] - Remaining limit
|
|
525
|
+
* @property {number} [retry_count] - Retry_count
|
|
526
|
+
* @property {number} [timeout] - Timeout
|
|
527
|
+
*/
|
|
528
|
+
|
|
529
|
+
/**
|
|
530
|
+
* @typedef PaymentModeLogo
|
|
531
|
+
* @property {string} large - Large
|
|
532
|
+
* @property {string} small - Smalll
|
|
533
|
+
*/
|
|
534
|
+
|
|
535
|
+
/**
|
|
536
|
+
* @typedef PaymentObjectListSerializer
|
|
537
|
+
* @property {Object} [aggregator_payment_object]
|
|
538
|
+
* @property {string[]} all_status
|
|
539
|
+
* @property {string} amount_in_paisa
|
|
540
|
+
* @property {string} application_id
|
|
541
|
+
* @property {string} collected_by
|
|
542
|
+
* @property {string} company_id
|
|
543
|
+
* @property {string} created_on
|
|
544
|
+
* @property {string} currency
|
|
545
|
+
* @property {string} current_status
|
|
546
|
+
* @property {string} id
|
|
547
|
+
* @property {string} modified_on
|
|
548
|
+
* @property {string} payment_gateway
|
|
549
|
+
* @property {string} [payment_id]
|
|
550
|
+
* @property {string} payment_mode
|
|
551
|
+
* @property {string} payment_mode_identifier
|
|
552
|
+
* @property {Object} [refund_object]
|
|
553
|
+
* @property {string} refunded_by
|
|
554
|
+
* @property {Object} user_object
|
|
555
|
+
*/
|
|
556
|
+
|
|
557
|
+
/**
|
|
558
|
+
* @typedef PaymentOptions
|
|
559
|
+
* @property {RootPaymentMode[]} payment_option - Payment options
|
|
560
|
+
*/
|
|
561
|
+
|
|
562
|
+
/**
|
|
563
|
+
* @typedef PaymentOptionsResponse
|
|
564
|
+
* @property {PaymentOptions} payment_options - Payment options
|
|
565
|
+
* @property {boolean} success - Response is successful or not
|
|
566
|
+
*/
|
|
567
|
+
|
|
568
|
+
/**
|
|
569
|
+
* @typedef PaymentSessionDetail
|
|
570
|
+
* @property {string} [aggregator_customer_id] - Unique customer id generated by
|
|
571
|
+
* payment gateway, not required for standard checkout.
|
|
572
|
+
* @property {string} aggregator_order_id - Unique order id or payment request
|
|
573
|
+
* id generated by payment gateway
|
|
574
|
+
* @property {number} amount - Amount paid.
|
|
575
|
+
* @property {number} amount_captured - Amount which is captured or credited to
|
|
576
|
+
* merchant account
|
|
577
|
+
* @property {number} [amount_refunded]
|
|
578
|
+
* @property {AddressDetail} billing_address - Billing address
|
|
579
|
+
* @property {string} cancel_url - Cancel url sent by Fynd platform at the time
|
|
580
|
+
* of payment creation
|
|
581
|
+
* @property {boolean} [captured] - Whether the payment is captured (credited to
|
|
582
|
+
* merchant account) by payment gateway.
|
|
583
|
+
* @property {string} [created] - Timestamp in epoch
|
|
584
|
+
* @property {string} currency - Currency of the payment.
|
|
585
|
+
* @property {string} g_user_id - Global user identifier - unique user id
|
|
586
|
+
* generated by Fynd platform
|
|
587
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
588
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
589
|
+
* Fynd payments platform and is unique.
|
|
590
|
+
* @property {string} [kind] - Optional kind of purchase/payment - one time
|
|
591
|
+
* payment (sale) or subcription. defaults to sale.
|
|
592
|
+
* @property {string} [locale] - User's locale
|
|
593
|
+
* @property {string} [merchant_locale] - Merchant's locale
|
|
594
|
+
* @property {string} mode - Test or live, test mode uses test credentials so
|
|
595
|
+
* that actual payment is not created.
|
|
596
|
+
* @property {string} payment_id - Unique transaction id generated by payment gateway
|
|
597
|
+
* @property {Object[]} payment_methods - Method of payment
|
|
598
|
+
* @property {AddressDetail} shipping_address - Shipping address
|
|
599
|
+
* @property {string} status - Stautus of the payment
|
|
600
|
+
* @property {string} success_url - Success url sent by Fynd platform at the
|
|
601
|
+
* time of payment creation
|
|
602
|
+
*/
|
|
603
|
+
|
|
604
|
+
/**
|
|
605
|
+
* @typedef PaymentSessionRequestSerializer
|
|
606
|
+
* @property {string} currency - Currency of the payment.
|
|
607
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
608
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
609
|
+
* Fynd payments platform and is unique.
|
|
610
|
+
* @property {OrderDetail} order_details - The details of the order.
|
|
611
|
+
* @property {PaymentSessionDetail[]} payment_details - The payment details with
|
|
612
|
+
* the schema `PaymentSessionDetail`.
|
|
613
|
+
* @property {string} status - Status of the payment.
|
|
614
|
+
* @property {number} total_amount - Amount paid.
|
|
615
|
+
*/
|
|
616
|
+
|
|
617
|
+
/**
|
|
618
|
+
* @typedef PaymentSessionResponseSerializer
|
|
619
|
+
* @property {string} currency - Currency of the payment.
|
|
620
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
621
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
622
|
+
* Fynd payments platform and is unique.
|
|
623
|
+
* @property {Object[]} platform_transaction_details - Platform transaction details.
|
|
624
|
+
* @property {string} status - Status of the payment.
|
|
625
|
+
* @property {number} total_amount - Amount paid.
|
|
626
|
+
*/
|
|
627
|
+
|
|
628
|
+
/**
|
|
629
|
+
* @typedef PaymentStatusBulkHandlerRequest
|
|
630
|
+
* @property {string[]} merchant_order_id - List of order ids
|
|
631
|
+
*/
|
|
632
|
+
|
|
633
|
+
/**
|
|
634
|
+
* @typedef PaymentStatusBulkHandlerResponse
|
|
635
|
+
* @property {number} [count]
|
|
636
|
+
* @property {PaymentStatusObject[]} [data]
|
|
637
|
+
* @property {string} [error]
|
|
638
|
+
* @property {number} status
|
|
639
|
+
* @property {string} success
|
|
640
|
+
*/
|
|
641
|
+
|
|
642
|
+
/**
|
|
643
|
+
* @typedef PaymentStatusObject
|
|
644
|
+
* @property {string} merchant_order_id
|
|
645
|
+
* @property {PaymentObjectListSerializer[]} [payment_object_list]
|
|
646
|
+
*/
|
|
647
|
+
|
|
648
|
+
/**
|
|
649
|
+
* @typedef PaymentStatusUpdateRequest
|
|
650
|
+
* @property {string} aggregator - Payment gateway name
|
|
651
|
+
* @property {number} amount - Payable amount.
|
|
652
|
+
* @property {string} contact - Customer valid mobile number
|
|
653
|
+
* @property {string} currency - Currency code.
|
|
654
|
+
* @property {string} customer_id - Payment gateway customer id.
|
|
655
|
+
* @property {string} [device_id] - EDC machine Unique Identifier
|
|
656
|
+
* @property {string} email - Customer valid email
|
|
657
|
+
* @property {string} merchant_order_id - Unique fynd order id
|
|
658
|
+
* @property {string} merchant_transaction_id - Unique fynd transaction id
|
|
659
|
+
* @property {string} method - Payment method
|
|
660
|
+
* @property {string} order_id - Payment gateway order id
|
|
661
|
+
* @property {string} status - Status of payment.
|
|
662
|
+
* @property {string} [vpa] - Customer vpa address
|
|
663
|
+
*/
|
|
664
|
+
|
|
665
|
+
/**
|
|
666
|
+
* @typedef PaymentStatusUpdateResponse
|
|
667
|
+
* @property {string} aggregator_name - Payment gateway name
|
|
668
|
+
* @property {string} [redirect_url] - Redirect url
|
|
669
|
+
* @property {boolean} retry - Response is successful or not.
|
|
670
|
+
* @property {string} status - Payment status
|
|
671
|
+
* @property {boolean} [success] - Response is successful or not
|
|
672
|
+
*/
|
|
673
|
+
|
|
674
|
+
/**
|
|
675
|
+
* @typedef Payout
|
|
676
|
+
* @property {PayoutCustomer} customers - Customers details object
|
|
677
|
+
* @property {boolean} is_active - Enable/DIsable Flag Payout
|
|
678
|
+
* @property {boolean} is_default - Default or not
|
|
679
|
+
* @property {PayoutMoreAttributes} more_attributes - Bank details object
|
|
680
|
+
* @property {PayoutAggregator[]} [payouts_aggregators]
|
|
681
|
+
* @property {string} transfer_type - Transafer type
|
|
682
|
+
* @property {string} unique_transfer_no - Display priority of the payment mode
|
|
683
|
+
*/
|
|
684
|
+
|
|
685
|
+
/**
|
|
686
|
+
* @typedef PayoutAggregator
|
|
687
|
+
* @property {number} [aggregator_fund_id] - Aggregator_fund_id
|
|
688
|
+
* @property {number} [aggregator_id] - Aggregator_id
|
|
689
|
+
* @property {number} [payout_details_id] - Payout_details_id
|
|
690
|
+
*/
|
|
691
|
+
|
|
692
|
+
/**
|
|
693
|
+
* @typedef PayoutBankDetails
|
|
694
|
+
* @property {string} [account_holder]
|
|
695
|
+
* @property {string} [account_no]
|
|
696
|
+
* @property {string} account_type
|
|
697
|
+
* @property {string} [bank_name]
|
|
698
|
+
* @property {string} [branch_name]
|
|
699
|
+
* @property {string} [city]
|
|
700
|
+
* @property {string} [country]
|
|
701
|
+
* @property {string} ifsc_code
|
|
702
|
+
* @property {number} [pincode]
|
|
703
|
+
* @property {string} [state]
|
|
704
|
+
*/
|
|
705
|
+
|
|
706
|
+
/**
|
|
707
|
+
* @typedef PayoutCustomer
|
|
708
|
+
* @property {string} [email] - Customer Email
|
|
709
|
+
* @property {number} [id] - Customer ID
|
|
710
|
+
* @property {string} [mobile] - Customer Mobile No
|
|
711
|
+
* @property {string} [name] - Customer Name
|
|
712
|
+
* @property {string} [unique_external_id] - Unique_external_id
|
|
713
|
+
*/
|
|
714
|
+
|
|
715
|
+
/**
|
|
716
|
+
* @typedef PayoutMoreAttributes
|
|
717
|
+
* @property {string} [account_holder] - Account Holder Name
|
|
718
|
+
* @property {string} [account_no] - Account Number
|
|
719
|
+
* @property {string} [account_type] - Account Type Saving/Current
|
|
720
|
+
* @property {string} [bank_name] - Name of Bank
|
|
721
|
+
* @property {string} [branch_name] - Branch Name
|
|
722
|
+
* @property {string} [city] - City
|
|
723
|
+
* @property {string} [country] - Country
|
|
724
|
+
* @property {string} [ifsc_code] - IFSC Code
|
|
725
|
+
* @property {string} [state] - State
|
|
726
|
+
*/
|
|
727
|
+
|
|
728
|
+
/**
|
|
729
|
+
* @typedef PayoutRequest
|
|
730
|
+
* @property {string} aggregator - Aggregator Name
|
|
731
|
+
* @property {PayoutBankDetails} bank_details - Payout bank details object
|
|
732
|
+
* @property {boolean} is_active - Enable/Disable Flag Payout
|
|
733
|
+
* @property {string} transfer_type - Transafer type
|
|
734
|
+
* @property {string} unique_external_id - Unique Id of Payout
|
|
735
|
+
* @property {Object} users - Payout users object
|
|
736
|
+
*/
|
|
737
|
+
|
|
738
|
+
/**
|
|
739
|
+
* @typedef PayoutResponse
|
|
740
|
+
* @property {string} aggregator - Aggregator Name
|
|
741
|
+
* @property {Object} bank_details - Payout bank_details object
|
|
742
|
+
* @property {boolean} created - Created flag
|
|
743
|
+
* @property {boolean} is_active - Enable/DIsable Flag Payout
|
|
744
|
+
* @property {string} payment_status - Status of payment
|
|
745
|
+
* @property {Object} payouts - Payout object
|
|
746
|
+
* @property {boolean} success - Response is successful or not
|
|
747
|
+
* @property {string} transfer_type - Transfer type
|
|
748
|
+
* @property {string} unique_transfer_no - Unique transfer no
|
|
749
|
+
* @property {Object} users - Users details object
|
|
750
|
+
*/
|
|
751
|
+
|
|
752
|
+
/**
|
|
753
|
+
* @typedef PayoutsResponse
|
|
754
|
+
* @property {Payout[]} items - Contains list of PayoutSchema
|
|
755
|
+
* @property {boolean} success - Response is successful or not
|
|
756
|
+
*/
|
|
757
|
+
|
|
758
|
+
/**
|
|
759
|
+
* @typedef PollingPaymentLinkResponse
|
|
760
|
+
* @property {string} [aggregator_name] - Aggregator name
|
|
761
|
+
* @property {number} [amount] - Amount
|
|
762
|
+
* @property {number} [http_status] - HTTP status code
|
|
763
|
+
* @property {string} [message] - Message
|
|
764
|
+
* @property {string} [order_id] - Fynd order id
|
|
765
|
+
* @property {string} [payment_link_id] - Payment link id
|
|
766
|
+
* @property {string} [redirect_url] - Url to redirect to
|
|
767
|
+
* @property {string} [status] - Status of payment link
|
|
768
|
+
* @property {number} [status_code] - HTTP status code
|
|
769
|
+
* @property {boolean} [success] - Successful or failure
|
|
770
|
+
*/
|
|
771
|
+
|
|
772
|
+
/**
|
|
773
|
+
* @typedef RefundAccountResponse
|
|
774
|
+
* @property {Object} [data] - Refund account data.
|
|
775
|
+
* @property {boolean} [is_verified_flag]
|
|
776
|
+
* @property {string} message - Response message
|
|
777
|
+
* @property {boolean} success - Success or failure flag.
|
|
778
|
+
*/
|
|
779
|
+
|
|
780
|
+
/**
|
|
781
|
+
* @typedef RefundSessionDetail
|
|
782
|
+
* @property {number} amount - Amount refunded.
|
|
783
|
+
* @property {string} [balance_transaction] - Balance transaction.
|
|
784
|
+
* @property {string} created - Timestamp in epoch.
|
|
785
|
+
* @property {string} currency - Currency of the payment.
|
|
786
|
+
* @property {string} payment_id - Unique payment id generated by payment gateway.
|
|
787
|
+
* @property {string} [reason] - Reason for refund, optional
|
|
788
|
+
* @property {string} [receipt_number] - Unique receipt for refund, generated by
|
|
789
|
+
* payment gateway, if not available can be utr.
|
|
790
|
+
* @property {string} [refund_utr] - Unique refund utr generated by payment gateway.
|
|
791
|
+
* @property {string} request_id - Refund request id, unique id generated by Fynd platform
|
|
792
|
+
* @property {string} [source_transfer_reversal] - Description in case of
|
|
793
|
+
* reversal of payment.
|
|
794
|
+
* @property {string} status - Status of the refund.
|
|
795
|
+
* @property {string} [transfer_reversal] - Description in case of reversal of payment.
|
|
796
|
+
*/
|
|
797
|
+
|
|
798
|
+
/**
|
|
799
|
+
* @typedef RefundSessionRequestSerializer
|
|
800
|
+
* @property {string} currency - The currency of the payment.
|
|
801
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
802
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
803
|
+
* Fynd payments platform and is unique.
|
|
804
|
+
* @property {PaymentSessionDetail} payment_details - Details of the payment
|
|
805
|
+
* @property {RefundSessionDetail[]} [refund_details] - Details of the refund
|
|
806
|
+
* @property {string} status - The status of the refund.
|
|
807
|
+
* @property {number} total_amount - The total amount refunded.
|
|
808
|
+
*/
|
|
809
|
+
|
|
810
|
+
/**
|
|
811
|
+
* @typedef RefundSessionResponseSerializer
|
|
812
|
+
* @property {string} currency - The currency of the payment.
|
|
813
|
+
* @property {string} gid - Global identifier of the entity (e.g. order, cart
|
|
814
|
+
* etc.) against which payment_session was initiated. This is generated by
|
|
815
|
+
* Fynd payments platform and is unique.
|
|
816
|
+
* @property {Object[]} platform_refund_details - Details of the refund
|
|
817
|
+
* @property {string} status - The status of the refund.
|
|
818
|
+
* @property {number} total_refund_amount - The total amount refunded.
|
|
819
|
+
*/
|
|
820
|
+
|
|
821
|
+
/**
|
|
822
|
+
* @typedef RepaymentDetailsSerialiserPayAll
|
|
823
|
+
* @property {string} aggregator_order_id - Id of payment gateway
|
|
824
|
+
* @property {string} aggregator_transaction_id - Unique Id for the transaction
|
|
825
|
+
* @property {string} extension_order_id - Order id created in extension
|
|
826
|
+
* @property {RepaymentRequestDetails[]} [shipment_details]
|
|
827
|
+
* @property {number} total_amount - Total amount
|
|
828
|
+
*/
|
|
829
|
+
|
|
830
|
+
/**
|
|
831
|
+
* @typedef RepaymentRequestDetails
|
|
832
|
+
* @property {string} aggregator - Name of Payment Gateway
|
|
833
|
+
* @property {string} aggregator_order_id - Id of payment gateway
|
|
834
|
+
* @property {string} aggregator_transaction_id - Unique Id for the transaction
|
|
835
|
+
* @property {number} amount - Amount to paid back
|
|
836
|
+
* @property {string} current_status - Status
|
|
837
|
+
* @property {string} fwd_shipment_id - Purchase Shipment Id
|
|
838
|
+
* @property {string} merchant_order_id - Merchant's Order Id
|
|
839
|
+
* @property {number} outstanding_details_id - Outstanding details ID
|
|
840
|
+
* @property {string} payment_mode - Payment Mode
|
|
841
|
+
* @property {string} payment_mode_identifier - Payment Mode Id
|
|
842
|
+
*/
|
|
843
|
+
|
|
844
|
+
/**
|
|
845
|
+
* @typedef RepaymentResponse
|
|
846
|
+
* @property {Object} data
|
|
847
|
+
* @property {boolean} success - Success/Failure of the transaction
|
|
848
|
+
*/
|
|
849
|
+
|
|
850
|
+
/**
|
|
851
|
+
* @typedef ResendOrCancelPaymentRequest
|
|
852
|
+
* @property {string} [device_id] - EDC machine Unique Identifier
|
|
853
|
+
* @property {string} order_id - Unique order id
|
|
854
|
+
* @property {string} request_type - Either resend or cancel
|
|
855
|
+
*/
|
|
856
|
+
|
|
857
|
+
/**
|
|
858
|
+
* @typedef ResendOrCancelPaymentResponse
|
|
859
|
+
* @property {LinkStatus} data - Data about link action status.
|
|
860
|
+
* @property {boolean} success - Response is successful or not.
|
|
861
|
+
*/
|
|
862
|
+
|
|
863
|
+
/**
|
|
864
|
+
* @typedef ResendPaymentLinkResponse
|
|
865
|
+
* @property {string} message - Message
|
|
866
|
+
* @property {number} [polling_timeout] - Polling request timeout
|
|
867
|
+
* @property {number} status_code - HTTP status code
|
|
868
|
+
* @property {boolean} success - Successful or failure
|
|
869
|
+
*/
|
|
870
|
+
|
|
871
|
+
/**
|
|
872
|
+
* @typedef RevokeOAuthToken
|
|
873
|
+
* @property {string} message - The confirmation message of the token revoke.
|
|
874
|
+
* @property {boolean} success - Response is successful or not
|
|
875
|
+
*/
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* @typedef RootPaymentMode
|
|
879
|
+
* @property {boolean} [add_card_enabled] - Annonymous card flag
|
|
880
|
+
* @property {string} [aggregator_name] - Dispaly Priority
|
|
881
|
+
* @property {boolean} [anonymous_enable] - Annonymous card flag
|
|
882
|
+
* @property {string} display_name - Payment mode display name
|
|
883
|
+
* @property {number} display_priority - Dispaly Priority
|
|
884
|
+
* @property {boolean} [is_pay_by_card_pl] - This flag will be true in case of
|
|
885
|
+
* Payment link payment through card
|
|
886
|
+
* @property {PaymentModeList[]} [list] - Payment mode
|
|
887
|
+
* @property {string} name - Payment mode name
|
|
888
|
+
* @property {boolean} [save_card] - Card save or not
|
|
889
|
+
*/
|
|
890
|
+
|
|
891
|
+
/**
|
|
892
|
+
* @typedef SaveSubscriptionSetupIntentRequest
|
|
893
|
+
* @property {string} unique_external_id - Unique id i.e company:id
|
|
894
|
+
*/
|
|
895
|
+
|
|
896
|
+
/**
|
|
897
|
+
* @typedef SaveSubscriptionSetupIntentResponse
|
|
898
|
+
* @property {Object} data - Subscription Payment Method Object
|
|
899
|
+
* @property {boolean} success - Response is successful or not
|
|
900
|
+
*/
|
|
901
|
+
|
|
902
|
+
/**
|
|
903
|
+
* @typedef SetCODForUserRequest
|
|
904
|
+
* @property {boolean} is_active - Either true or false
|
|
905
|
+
* @property {string} merchant_user_id - Merchant User id
|
|
906
|
+
* @property {string} mobileno - Mobile No. of User
|
|
907
|
+
*/
|
|
908
|
+
|
|
909
|
+
/**
|
|
910
|
+
* @typedef SetCODOptionResponse
|
|
911
|
+
* @property {string} message - Message
|
|
912
|
+
* @property {boolean} success - Response is successful or not
|
|
913
|
+
*/
|
|
914
|
+
|
|
915
|
+
/**
|
|
916
|
+
* @typedef StatisticsData
|
|
917
|
+
* @property {number} active_device_count - No of active devices
|
|
918
|
+
* @property {number} inactive_device_count - No of inactive devices
|
|
919
|
+
*/
|
|
920
|
+
|
|
921
|
+
/**
|
|
922
|
+
* @typedef SubscriptionConfigResponse
|
|
923
|
+
* @property {string} aggregator - Aggregator Name
|
|
924
|
+
* @property {Object} config - Aggregator Config
|
|
925
|
+
* @property {boolean} success - Response is successful or not
|
|
926
|
+
*/
|
|
927
|
+
|
|
928
|
+
/**
|
|
929
|
+
* @typedef SubscriptionPaymentMethodResponse
|
|
930
|
+
* @property {Object[]} data - Subscription Payment Method Object
|
|
931
|
+
* @property {boolean} success - Response is successful or not
|
|
932
|
+
*/
|
|
933
|
+
|
|
934
|
+
/**
|
|
935
|
+
* @typedef UpdatePayoutRequest
|
|
936
|
+
* @property {boolean} is_active - Enable/Disable Flag Payout
|
|
937
|
+
* @property {boolean} is_default - Enable/Disable Default Payout
|
|
938
|
+
* @property {string} unique_external_id - Unique Id of Payout
|
|
939
|
+
*/
|
|
940
|
+
|
|
941
|
+
/**
|
|
942
|
+
* @typedef UpdatePayoutResponse
|
|
943
|
+
* @property {boolean} is_active - Enable/DIsable Flag Payout
|
|
944
|
+
* @property {boolean} is_default - Enable/Disable Default Payout
|
|
945
|
+
* @property {boolean} success - Response is successful or not
|
|
946
|
+
*/
|
|
947
|
+
|
|
948
|
+
/**
|
|
949
|
+
* @typedef ValidateCustomerRequest
|
|
950
|
+
* @property {string} aggregator - Payment gateway name in camel case i.e Simpl, Rupifi
|
|
951
|
+
* @property {Object} [billing_address] - Extra meta fields.
|
|
952
|
+
* @property {Object} [delivery_address] - Extra meta fields.
|
|
953
|
+
* @property {Object} [merchant_params] - Extra meta fields.
|
|
954
|
+
* @property {Object[]} [order_items] - Extra meta fields.
|
|
955
|
+
* @property {string} [payload] - Hashed payload string.
|
|
956
|
+
* @property {string} phone_number - User mobile number without country code.
|
|
957
|
+
* @property {number} transaction_amount_in_paise - Payable amount in paise
|
|
958
|
+
*/
|
|
959
|
+
|
|
960
|
+
/**
|
|
961
|
+
* @typedef ValidateCustomerResponse
|
|
962
|
+
* @property {Object} data - Payment gateway response data
|
|
963
|
+
* @property {string} message - Error or success message.
|
|
964
|
+
* @property {boolean} success - Response is successful or not
|
|
965
|
+
*/
|
|
966
|
+
|
|
967
|
+
class PaymentPlatformModel {
|
|
968
|
+
/** @returns {AddBeneficiaryDetailsOTPRequest} */
|
|
4
969
|
static AddBeneficiaryDetailsOTPRequest() {
|
|
5
970
|
return Joi.object({
|
|
6
|
-
details:
|
|
971
|
+
details: PaymentPlatformModel.BankDetailsForOTP().required(),
|
|
7
972
|
order_id: Joi.string().allow("").required(),
|
|
8
973
|
});
|
|
9
974
|
}
|
|
975
|
+
|
|
976
|
+
/** @returns {AddressDetail} */
|
|
977
|
+
static AddressDetail() {
|
|
978
|
+
return Joi.object({
|
|
979
|
+
address: Joi.string().allow("").required(),
|
|
980
|
+
address_type: Joi.string().allow("").required(),
|
|
981
|
+
area: Joi.string().allow("").required(),
|
|
982
|
+
area_code: Joi.string().allow("").required(),
|
|
983
|
+
area_code_slug: Joi.string().allow("").required(),
|
|
984
|
+
city: Joi.string().allow("").required(),
|
|
985
|
+
country: Joi.string().allow("").required(),
|
|
986
|
+
country_iso_code: Joi.string().allow("").required(),
|
|
987
|
+
country_phone_code: Joi.string().allow("").required(),
|
|
988
|
+
email: Joi.string().allow(""),
|
|
989
|
+
expire_at: Joi.string().allow(""),
|
|
990
|
+
g_address_id: Joi.string().allow("").required(),
|
|
991
|
+
geo_location: Joi.any(),
|
|
992
|
+
google_map_point: Joi.any(),
|
|
993
|
+
landmark: Joi.string().allow(""),
|
|
994
|
+
name: Joi.string().allow("").required(),
|
|
995
|
+
phone: Joi.string().allow("").required(),
|
|
996
|
+
state: Joi.string().allow("").required(),
|
|
997
|
+
tags: Joi.array().items(Joi.any()),
|
|
998
|
+
});
|
|
999
|
+
}
|
|
1000
|
+
|
|
1001
|
+
/** @returns {BankDetailsForOTP} */
|
|
10
1002
|
static BankDetailsForOTP() {
|
|
11
1003
|
return Joi.object({
|
|
12
1004
|
account_holder: Joi.string().allow("").required(),
|
|
@@ -16,11 +1008,15 @@ class PaymentModel {
|
|
|
16
1008
|
ifsc_code: Joi.string().allow("").required(),
|
|
17
1009
|
});
|
|
18
1010
|
}
|
|
1011
|
+
|
|
1012
|
+
/** @returns {CancelOrResendPaymentLinkRequest} */
|
|
19
1013
|
static CancelOrResendPaymentLinkRequest() {
|
|
20
1014
|
return Joi.object({
|
|
21
1015
|
payment_link_id: Joi.string().allow("").required(),
|
|
22
1016
|
});
|
|
23
1017
|
}
|
|
1018
|
+
|
|
1019
|
+
/** @returns {CancelPaymentLinkResponse} */
|
|
24
1020
|
static CancelPaymentLinkResponse() {
|
|
25
1021
|
return Joi.object({
|
|
26
1022
|
message: Joi.string().allow("").required(),
|
|
@@ -28,6 +1024,8 @@ class PaymentModel {
|
|
|
28
1024
|
success: Joi.boolean().required(),
|
|
29
1025
|
});
|
|
30
1026
|
}
|
|
1027
|
+
|
|
1028
|
+
/** @returns {CODdata} */
|
|
31
1029
|
static CODdata() {
|
|
32
1030
|
return Joi.object({
|
|
33
1031
|
is_active: Joi.boolean().required(),
|
|
@@ -37,6 +1035,8 @@ class PaymentModel {
|
|
|
37
1035
|
user_id: Joi.string().allow("").required(),
|
|
38
1036
|
});
|
|
39
1037
|
}
|
|
1038
|
+
|
|
1039
|
+
/** @returns {Code} */
|
|
40
1040
|
static Code() {
|
|
41
1041
|
return Joi.object({
|
|
42
1042
|
code: Joi.string().allow("").required(),
|
|
@@ -44,6 +1044,8 @@ class PaymentModel {
|
|
|
44
1044
|
name: Joi.string().allow("").required(),
|
|
45
1045
|
});
|
|
46
1046
|
}
|
|
1047
|
+
|
|
1048
|
+
/** @returns {CreatePaymentLinkMeta} */
|
|
47
1049
|
static CreatePaymentLinkMeta() {
|
|
48
1050
|
return Joi.object({
|
|
49
1051
|
amount: Joi.string().allow("").required(),
|
|
@@ -53,16 +1055,20 @@ class PaymentModel {
|
|
|
53
1055
|
pincode: Joi.string().allow("").required(),
|
|
54
1056
|
});
|
|
55
1057
|
}
|
|
1058
|
+
|
|
1059
|
+
/** @returns {CreatePaymentLinkRequest} */
|
|
56
1060
|
static CreatePaymentLinkRequest() {
|
|
57
1061
|
return Joi.object({
|
|
58
1062
|
amount: Joi.number().required(),
|
|
59
1063
|
description: Joi.string().allow("").allow(null),
|
|
60
1064
|
email: Joi.string().allow("").required(),
|
|
61
1065
|
external_order_id: Joi.string().allow("").required(),
|
|
62
|
-
meta:
|
|
1066
|
+
meta: PaymentPlatformModel.CreatePaymentLinkMeta().required(),
|
|
63
1067
|
mobile_number: Joi.string().allow("").required(),
|
|
64
1068
|
});
|
|
65
1069
|
}
|
|
1070
|
+
|
|
1071
|
+
/** @returns {CreatePaymentLinkResponse} */
|
|
66
1072
|
static CreatePaymentLinkResponse() {
|
|
67
1073
|
return Joi.object({
|
|
68
1074
|
message: Joi.string().allow("").required(),
|
|
@@ -73,16 +1079,22 @@ class PaymentModel {
|
|
|
73
1079
|
success: Joi.boolean().required(),
|
|
74
1080
|
});
|
|
75
1081
|
}
|
|
1082
|
+
|
|
1083
|
+
/** @returns {DeletePayoutResponse} */
|
|
76
1084
|
static DeletePayoutResponse() {
|
|
77
1085
|
return Joi.object({
|
|
78
1086
|
success: Joi.boolean().required(),
|
|
79
1087
|
});
|
|
80
1088
|
}
|
|
1089
|
+
|
|
1090
|
+
/** @returns {DeleteSubscriptionPaymentMethodResponse} */
|
|
81
1091
|
static DeleteSubscriptionPaymentMethodResponse() {
|
|
82
1092
|
return Joi.object({
|
|
83
1093
|
success: Joi.boolean().required(),
|
|
84
1094
|
});
|
|
85
1095
|
}
|
|
1096
|
+
|
|
1097
|
+
/** @returns {EdcAddRequest} */
|
|
86
1098
|
static EdcAddRequest() {
|
|
87
1099
|
return Joi.object({
|
|
88
1100
|
aggregator_id: Joi.number().required(),
|
|
@@ -93,12 +1105,16 @@ class PaymentModel {
|
|
|
93
1105
|
terminal_serial_no: Joi.string().allow("").required(),
|
|
94
1106
|
});
|
|
95
1107
|
}
|
|
1108
|
+
|
|
1109
|
+
/** @returns {EdcAggregatorAndModelListResponse} */
|
|
96
1110
|
static EdcAggregatorAndModelListResponse() {
|
|
97
1111
|
return Joi.object({
|
|
98
|
-
data: Joi.array().items(
|
|
1112
|
+
data: Joi.array().items(PaymentPlatformModel.EdcModelData()).required(),
|
|
99
1113
|
success: Joi.boolean().required(),
|
|
100
1114
|
});
|
|
101
1115
|
}
|
|
1116
|
+
|
|
1117
|
+
/** @returns {EdcDevice} */
|
|
102
1118
|
static EdcDevice() {
|
|
103
1119
|
return Joi.object({
|
|
104
1120
|
aggregator_id: Joi.number().required(),
|
|
@@ -114,36 +1130,48 @@ class PaymentModel {
|
|
|
114
1130
|
terminal_unique_identifier: Joi.string().allow("").required(),
|
|
115
1131
|
});
|
|
116
1132
|
}
|
|
1133
|
+
|
|
1134
|
+
/** @returns {EdcDeviceAddResponse} */
|
|
117
1135
|
static EdcDeviceAddResponse() {
|
|
118
1136
|
return Joi.object({
|
|
119
|
-
data:
|
|
1137
|
+
data: PaymentPlatformModel.EdcDevice().required(),
|
|
120
1138
|
success: Joi.boolean().required(),
|
|
121
1139
|
});
|
|
122
1140
|
}
|
|
1141
|
+
|
|
1142
|
+
/** @returns {EdcDeviceDetailsResponse} */
|
|
123
1143
|
static EdcDeviceDetailsResponse() {
|
|
124
1144
|
return Joi.object({
|
|
125
|
-
data:
|
|
1145
|
+
data: PaymentPlatformModel.EdcDevice().required(),
|
|
126
1146
|
success: Joi.boolean().required(),
|
|
127
1147
|
});
|
|
128
1148
|
}
|
|
1149
|
+
|
|
1150
|
+
/** @returns {EdcDeviceListResponse} */
|
|
129
1151
|
static EdcDeviceListResponse() {
|
|
130
1152
|
return Joi.object({
|
|
131
|
-
items: Joi.array().items(
|
|
132
|
-
page:
|
|
1153
|
+
items: Joi.array().items(PaymentPlatformModel.EdcDevice()).required(),
|
|
1154
|
+
page: PaymentPlatformModel.Page().required(),
|
|
133
1155
|
success: Joi.boolean().required(),
|
|
134
1156
|
});
|
|
135
1157
|
}
|
|
1158
|
+
|
|
1159
|
+
/** @returns {EdcDeviceStatsResponse} */
|
|
136
1160
|
static EdcDeviceStatsResponse() {
|
|
137
1161
|
return Joi.object({
|
|
138
|
-
statistics:
|
|
1162
|
+
statistics: PaymentPlatformModel.StatisticsData().required(),
|
|
139
1163
|
success: Joi.boolean().required(),
|
|
140
1164
|
});
|
|
141
1165
|
}
|
|
1166
|
+
|
|
1167
|
+
/** @returns {EdcDeviceUpdateResponse} */
|
|
142
1168
|
static EdcDeviceUpdateResponse() {
|
|
143
1169
|
return Joi.object({
|
|
144
1170
|
success: Joi.boolean().required(),
|
|
145
1171
|
});
|
|
146
1172
|
}
|
|
1173
|
+
|
|
1174
|
+
/** @returns {EdcModelData} */
|
|
147
1175
|
static EdcModelData() {
|
|
148
1176
|
return Joi.object({
|
|
149
1177
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -151,6 +1179,8 @@ class PaymentModel {
|
|
|
151
1179
|
models: Joi.array().items(Joi.string().allow("")).required(),
|
|
152
1180
|
});
|
|
153
1181
|
}
|
|
1182
|
+
|
|
1183
|
+
/** @returns {EdcUpdateRequest} */
|
|
154
1184
|
static EdcUpdateRequest() {
|
|
155
1185
|
return Joi.object({
|
|
156
1186
|
aggregator_id: Joi.number(),
|
|
@@ -162,12 +1192,16 @@ class PaymentModel {
|
|
|
162
1192
|
store_id: Joi.number(),
|
|
163
1193
|
});
|
|
164
1194
|
}
|
|
1195
|
+
|
|
1196
|
+
/** @returns {ErrorCodeAndDescription} */
|
|
165
1197
|
static ErrorCodeAndDescription() {
|
|
166
1198
|
return Joi.object({
|
|
167
1199
|
code: Joi.string().allow("").required(),
|
|
168
1200
|
description: Joi.string().allow("").required(),
|
|
169
1201
|
});
|
|
170
1202
|
}
|
|
1203
|
+
|
|
1204
|
+
/** @returns {ErrorCodeDescription} */
|
|
171
1205
|
static ErrorCodeDescription() {
|
|
172
1206
|
return Joi.object({
|
|
173
1207
|
code: Joi.string().allow("").required(),
|
|
@@ -175,6 +1209,8 @@ class PaymentModel {
|
|
|
175
1209
|
success: Joi.boolean().required(),
|
|
176
1210
|
});
|
|
177
1211
|
}
|
|
1212
|
+
|
|
1213
|
+
/** @returns {ErrorDescription} */
|
|
178
1214
|
static ErrorDescription() {
|
|
179
1215
|
return Joi.object({
|
|
180
1216
|
amount: Joi.number().allow(null),
|
|
@@ -187,31 +1223,41 @@ class PaymentModel {
|
|
|
187
1223
|
payment_transaction_id: Joi.string().allow("").allow(null),
|
|
188
1224
|
});
|
|
189
1225
|
}
|
|
1226
|
+
|
|
1227
|
+
/** @returns {ErrorResponse} */
|
|
190
1228
|
static ErrorResponse() {
|
|
191
1229
|
return Joi.object({
|
|
192
|
-
error:
|
|
1230
|
+
error: Joi.any().allow(null),
|
|
193
1231
|
message: Joi.string().allow("").required(),
|
|
194
1232
|
status_code: Joi.number().required(),
|
|
195
1233
|
success: Joi.boolean().required(),
|
|
196
1234
|
});
|
|
197
1235
|
}
|
|
1236
|
+
|
|
1237
|
+
/** @returns {GetOauthUrlResponse} */
|
|
198
1238
|
static GetOauthUrlResponse() {
|
|
199
1239
|
return Joi.object({
|
|
200
1240
|
success: Joi.boolean().required(),
|
|
201
1241
|
url: Joi.string().allow("").required(),
|
|
202
1242
|
});
|
|
203
1243
|
}
|
|
1244
|
+
|
|
1245
|
+
/** @returns {GetPaymentCode} */
|
|
204
1246
|
static GetPaymentCode() {
|
|
205
1247
|
return Joi.object({
|
|
206
|
-
method_code:
|
|
1248
|
+
method_code: PaymentPlatformModel.PaymentCode().required(),
|
|
207
1249
|
});
|
|
208
1250
|
}
|
|
1251
|
+
|
|
1252
|
+
/** @returns {GetPaymentCodeResponse} */
|
|
209
1253
|
static GetPaymentCodeResponse() {
|
|
210
1254
|
return Joi.object({
|
|
211
|
-
data:
|
|
1255
|
+
data: PaymentPlatformModel.GetPaymentCode().required(),
|
|
212
1256
|
success: Joi.boolean().required(),
|
|
213
1257
|
});
|
|
214
1258
|
}
|
|
1259
|
+
|
|
1260
|
+
/** @returns {GetPaymentLinkResponse} */
|
|
215
1261
|
static GetPaymentLinkResponse() {
|
|
216
1262
|
return Joi.object({
|
|
217
1263
|
amount: Joi.number().allow(null),
|
|
@@ -225,18 +1271,24 @@ class PaymentModel {
|
|
|
225
1271
|
success: Joi.boolean().required(),
|
|
226
1272
|
});
|
|
227
1273
|
}
|
|
1274
|
+
|
|
1275
|
+
/** @returns {GetUserCODLimitResponse} */
|
|
228
1276
|
static GetUserCODLimitResponse() {
|
|
229
1277
|
return Joi.object({
|
|
230
1278
|
success: Joi.boolean().required(),
|
|
231
|
-
user_cod_data:
|
|
1279
|
+
user_cod_data: PaymentPlatformModel.CODdata().required(),
|
|
232
1280
|
});
|
|
233
1281
|
}
|
|
1282
|
+
|
|
1283
|
+
/** @returns {HttpErrorCodeAndResponse} */
|
|
234
1284
|
static HttpErrorCodeAndResponse() {
|
|
235
1285
|
return Joi.object({
|
|
236
|
-
error:
|
|
1286
|
+
error: PaymentPlatformModel.ErrorCodeAndDescription().required(),
|
|
237
1287
|
success: Joi.boolean().required(),
|
|
238
1288
|
});
|
|
239
1289
|
}
|
|
1290
|
+
|
|
1291
|
+
/** @returns {IfscCodeResponse} */
|
|
240
1292
|
static IfscCodeResponse() {
|
|
241
1293
|
return Joi.object({
|
|
242
1294
|
bank_name: Joi.string().allow("").required(),
|
|
@@ -244,26 +1296,34 @@ class PaymentModel {
|
|
|
244
1296
|
success: Joi.boolean(),
|
|
245
1297
|
});
|
|
246
1298
|
}
|
|
1299
|
+
|
|
1300
|
+
/** @returns {IntentApp} */
|
|
247
1301
|
static IntentApp() {
|
|
248
1302
|
return Joi.object({
|
|
249
1303
|
code: Joi.string().allow("").allow(null),
|
|
250
1304
|
display_name: Joi.string().allow("").allow(null),
|
|
251
|
-
logos:
|
|
1305
|
+
logos: Joi.any().allow(null),
|
|
252
1306
|
package_name: Joi.string().allow("").allow(null),
|
|
253
1307
|
});
|
|
254
1308
|
}
|
|
1309
|
+
|
|
1310
|
+
/** @returns {IntentAppErrorList} */
|
|
255
1311
|
static IntentAppErrorList() {
|
|
256
1312
|
return Joi.object({
|
|
257
1313
|
code: Joi.string().allow("").allow(null),
|
|
258
1314
|
package_name: Joi.string().allow("").allow(null),
|
|
259
1315
|
});
|
|
260
1316
|
}
|
|
1317
|
+
|
|
1318
|
+
/** @returns {LinkStatus} */
|
|
261
1319
|
static LinkStatus() {
|
|
262
1320
|
return Joi.object({
|
|
263
1321
|
message: Joi.string().allow("").required(),
|
|
264
1322
|
status: Joi.boolean().required(),
|
|
265
1323
|
});
|
|
266
1324
|
}
|
|
1325
|
+
|
|
1326
|
+
/** @returns {MerchantOnBoardingRequest} */
|
|
267
1327
|
static MerchantOnBoardingRequest() {
|
|
268
1328
|
return Joi.object({
|
|
269
1329
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -273,12 +1333,33 @@ class PaymentModel {
|
|
|
273
1333
|
user_id: Joi.string().allow("").required(),
|
|
274
1334
|
});
|
|
275
1335
|
}
|
|
1336
|
+
|
|
1337
|
+
/** @returns {MerchantOnBoardingResponse} */
|
|
276
1338
|
static MerchantOnBoardingResponse() {
|
|
277
1339
|
return Joi.object({
|
|
278
1340
|
data: Joi.any().required(),
|
|
279
1341
|
success: Joi.boolean().required(),
|
|
280
1342
|
});
|
|
281
1343
|
}
|
|
1344
|
+
|
|
1345
|
+
/** @returns {MerchnatPaymentModeRequest} */
|
|
1346
|
+
static MerchnatPaymentModeRequest() {
|
|
1347
|
+
return Joi.object({
|
|
1348
|
+
offline: Joi.any().allow(null),
|
|
1349
|
+
online: Joi.any().allow(null),
|
|
1350
|
+
});
|
|
1351
|
+
}
|
|
1352
|
+
|
|
1353
|
+
/** @returns {MerchnatPaymentModeResponse} */
|
|
1354
|
+
static MerchnatPaymentModeResponse() {
|
|
1355
|
+
return Joi.object({
|
|
1356
|
+
items: Joi.array().items(Joi.any()),
|
|
1357
|
+
message: Joi.string().allow("").allow(null),
|
|
1358
|
+
success: Joi.boolean().required(),
|
|
1359
|
+
});
|
|
1360
|
+
}
|
|
1361
|
+
|
|
1362
|
+
/** @returns {MultiTenderPaymentMeta} */
|
|
282
1363
|
static MultiTenderPaymentMeta() {
|
|
283
1364
|
return Joi.object({
|
|
284
1365
|
current_status: Joi.string().allow(""),
|
|
@@ -288,14 +1369,18 @@ class PaymentModel {
|
|
|
288
1369
|
payment_id: Joi.string().allow(""),
|
|
289
1370
|
});
|
|
290
1371
|
}
|
|
1372
|
+
|
|
1373
|
+
/** @returns {MultiTenderPaymentMethod} */
|
|
291
1374
|
static MultiTenderPaymentMethod() {
|
|
292
1375
|
return Joi.object({
|
|
293
1376
|
amount: Joi.number().required(),
|
|
294
|
-
meta:
|
|
1377
|
+
meta: PaymentPlatformModel.MultiTenderPaymentMeta(),
|
|
295
1378
|
mode: Joi.string().allow("").required(),
|
|
296
1379
|
name: Joi.string().allow(""),
|
|
297
1380
|
});
|
|
298
1381
|
}
|
|
1382
|
+
|
|
1383
|
+
/** @returns {NotFoundResourceError} */
|
|
299
1384
|
static NotFoundResourceError() {
|
|
300
1385
|
return Joi.object({
|
|
301
1386
|
code: Joi.string().allow("").required(),
|
|
@@ -303,6 +1388,8 @@ class PaymentModel {
|
|
|
303
1388
|
success: Joi.boolean().required(),
|
|
304
1389
|
});
|
|
305
1390
|
}
|
|
1391
|
+
|
|
1392
|
+
/** @returns {OrderBeneficiaryDetails} */
|
|
306
1393
|
static OrderBeneficiaryDetails() {
|
|
307
1394
|
return Joi.object({
|
|
308
1395
|
account_holder: Joi.string().allow("").required(),
|
|
@@ -326,12 +1413,30 @@ class PaymentModel {
|
|
|
326
1413
|
transfer_mode: Joi.string().allow("").required(),
|
|
327
1414
|
});
|
|
328
1415
|
}
|
|
1416
|
+
|
|
1417
|
+
/** @returns {OrderBeneficiaryResponse} */
|
|
329
1418
|
static OrderBeneficiaryResponse() {
|
|
330
1419
|
return Joi.object({
|
|
331
|
-
beneficiaries: Joi.array().items(
|
|
1420
|
+
beneficiaries: Joi.array().items(
|
|
1421
|
+
PaymentPlatformModel.OrderBeneficiaryDetails()
|
|
1422
|
+
),
|
|
332
1423
|
show_beneficiary_details: Joi.boolean(),
|
|
333
1424
|
});
|
|
334
1425
|
}
|
|
1426
|
+
|
|
1427
|
+
/** @returns {OrderDetail} */
|
|
1428
|
+
static OrderDetail() {
|
|
1429
|
+
return Joi.object({
|
|
1430
|
+
aggregator: Joi.string().allow("").required(),
|
|
1431
|
+
aggregator_order_details: Joi.any().required(),
|
|
1432
|
+
amount: Joi.number().required(),
|
|
1433
|
+
currency: Joi.string().allow("").required(),
|
|
1434
|
+
gid: Joi.string().allow("").required(),
|
|
1435
|
+
status: Joi.string().allow("").required(),
|
|
1436
|
+
});
|
|
1437
|
+
}
|
|
1438
|
+
|
|
1439
|
+
/** @returns {Page} */
|
|
335
1440
|
static Page() {
|
|
336
1441
|
return Joi.object({
|
|
337
1442
|
current: Joi.number(),
|
|
@@ -343,22 +1448,28 @@ class PaymentModel {
|
|
|
343
1448
|
type: Joi.string().allow("").required(),
|
|
344
1449
|
});
|
|
345
1450
|
}
|
|
1451
|
+
|
|
1452
|
+
/** @returns {PaymentCode} */
|
|
346
1453
|
static PaymentCode() {
|
|
347
1454
|
return Joi.object({
|
|
348
|
-
codes:
|
|
1455
|
+
codes: PaymentPlatformModel.Code().required(),
|
|
349
1456
|
name: Joi.string().allow("").required(),
|
|
350
1457
|
networks: Joi.string().allow("").required(),
|
|
351
1458
|
types: Joi.string().allow("").required(),
|
|
352
1459
|
});
|
|
353
1460
|
}
|
|
1461
|
+
|
|
1462
|
+
/** @returns {PaymentConfirmationRequest} */
|
|
354
1463
|
static PaymentConfirmationRequest() {
|
|
355
1464
|
return Joi.object({
|
|
356
1465
|
order_id: Joi.string().allow("").required(),
|
|
357
1466
|
payment_methods: Joi.array()
|
|
358
|
-
.items(
|
|
1467
|
+
.items(PaymentPlatformModel.MultiTenderPaymentMethod())
|
|
359
1468
|
.required(),
|
|
360
1469
|
});
|
|
361
1470
|
}
|
|
1471
|
+
|
|
1472
|
+
/** @returns {PaymentConfirmationResponse} */
|
|
362
1473
|
static PaymentConfirmationResponse() {
|
|
363
1474
|
return Joi.object({
|
|
364
1475
|
message: Joi.string().allow("").required(),
|
|
@@ -366,6 +1477,8 @@ class PaymentModel {
|
|
|
366
1477
|
success: Joi.boolean().required(),
|
|
367
1478
|
});
|
|
368
1479
|
}
|
|
1480
|
+
|
|
1481
|
+
/** @returns {PaymentGatewayConfig} */
|
|
369
1482
|
static PaymentGatewayConfig() {
|
|
370
1483
|
return Joi.object({
|
|
371
1484
|
config_type: Joi.string().allow("").required(),
|
|
@@ -375,13 +1488,17 @@ class PaymentModel {
|
|
|
375
1488
|
secret: Joi.string().allow("").required(),
|
|
376
1489
|
});
|
|
377
1490
|
}
|
|
1491
|
+
|
|
1492
|
+
/** @returns {PaymentGatewayConfigRequest} */
|
|
378
1493
|
static PaymentGatewayConfigRequest() {
|
|
379
1494
|
return Joi.object({
|
|
380
|
-
aggregator_name:
|
|
1495
|
+
aggregator_name: PaymentPlatformModel.PaymentGatewayConfig(),
|
|
381
1496
|
app_id: Joi.string().allow("").required(),
|
|
382
1497
|
is_active: Joi.boolean().allow(null),
|
|
383
1498
|
});
|
|
384
1499
|
}
|
|
1500
|
+
|
|
1501
|
+
/** @returns {PaymentGatewayConfigResponse} */
|
|
385
1502
|
static PaymentGatewayConfigResponse() {
|
|
386
1503
|
return Joi.object({
|
|
387
1504
|
aggregators: Joi.array().items(Joi.any()),
|
|
@@ -392,12 +1509,16 @@ class PaymentModel {
|
|
|
392
1509
|
success: Joi.boolean().required(),
|
|
393
1510
|
});
|
|
394
1511
|
}
|
|
1512
|
+
|
|
1513
|
+
/** @returns {PaymentGatewayToBeReviewed} */
|
|
395
1514
|
static PaymentGatewayToBeReviewed() {
|
|
396
1515
|
return Joi.object({
|
|
397
1516
|
aggregator: Joi.array().items(Joi.string().allow("")).required(),
|
|
398
1517
|
success: Joi.boolean().required(),
|
|
399
1518
|
});
|
|
400
1519
|
}
|
|
1520
|
+
|
|
1521
|
+
/** @returns {PaymentInitializationRequest} */
|
|
401
1522
|
static PaymentInitializationRequest() {
|
|
402
1523
|
return Joi.object({
|
|
403
1524
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -415,6 +1536,8 @@ class PaymentModel {
|
|
|
415
1536
|
vpa: Joi.string().allow("").allow(null),
|
|
416
1537
|
});
|
|
417
1538
|
}
|
|
1539
|
+
|
|
1540
|
+
/** @returns {PaymentInitializationResponse} */
|
|
418
1541
|
static PaymentInitializationResponse() {
|
|
419
1542
|
return Joi.object({
|
|
420
1543
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -436,6 +1559,8 @@ class PaymentModel {
|
|
|
436
1559
|
vpa: Joi.string().allow("").allow(null),
|
|
437
1560
|
});
|
|
438
1561
|
}
|
|
1562
|
+
|
|
1563
|
+
/** @returns {PaymentModeList} */
|
|
439
1564
|
static PaymentModeList() {
|
|
440
1565
|
return Joi.object({
|
|
441
1566
|
aggregator_name: Joi.string().allow("").required(),
|
|
@@ -460,13 +1585,13 @@ class PaymentModel {
|
|
|
460
1585
|
exp_year: Joi.number().allow(null),
|
|
461
1586
|
expired: Joi.boolean().allow(null),
|
|
462
1587
|
fynd_vpa: Joi.string().allow("").allow(null),
|
|
463
|
-
intent_app: Joi.array().items(
|
|
1588
|
+
intent_app: Joi.array().items(PaymentPlatformModel.IntentApp()),
|
|
464
1589
|
intent_app_error_dict_list: Joi.array().items(
|
|
465
|
-
|
|
1590
|
+
PaymentPlatformModel.IntentAppErrorList()
|
|
466
1591
|
),
|
|
467
1592
|
intent_app_error_list: Joi.array().items(Joi.string().allow("")),
|
|
468
1593
|
intent_flow: Joi.boolean().allow(null),
|
|
469
|
-
logo_url:
|
|
1594
|
+
logo_url: Joi.any().allow(null),
|
|
470
1595
|
merchant_code: Joi.string().allow("").allow(null),
|
|
471
1596
|
name: Joi.string().allow("").allow(null),
|
|
472
1597
|
nickname: Joi.string().allow("").allow(null),
|
|
@@ -475,12 +1600,16 @@ class PaymentModel {
|
|
|
475
1600
|
timeout: Joi.number().allow(null),
|
|
476
1601
|
});
|
|
477
1602
|
}
|
|
1603
|
+
|
|
1604
|
+
/** @returns {PaymentModeLogo} */
|
|
478
1605
|
static PaymentModeLogo() {
|
|
479
1606
|
return Joi.object({
|
|
480
1607
|
large: Joi.string().allow("").required(),
|
|
481
1608
|
small: Joi.string().allow("").required(),
|
|
482
1609
|
});
|
|
483
1610
|
}
|
|
1611
|
+
|
|
1612
|
+
/** @returns {PaymentObjectListSerializer} */
|
|
484
1613
|
static PaymentObjectListSerializer() {
|
|
485
1614
|
return Joi.object({
|
|
486
1615
|
aggregator_payment_object: Joi.any().allow(null),
|
|
@@ -503,41 +1632,105 @@ class PaymentModel {
|
|
|
503
1632
|
user_object: Joi.any().required(),
|
|
504
1633
|
});
|
|
505
1634
|
}
|
|
1635
|
+
|
|
1636
|
+
/** @returns {PaymentOptions} */
|
|
506
1637
|
static PaymentOptions() {
|
|
507
1638
|
return Joi.object({
|
|
508
1639
|
payment_option: Joi.array()
|
|
509
|
-
.items(
|
|
1640
|
+
.items(PaymentPlatformModel.RootPaymentMode())
|
|
510
1641
|
.required(),
|
|
511
1642
|
});
|
|
512
1643
|
}
|
|
1644
|
+
|
|
1645
|
+
/** @returns {PaymentOptionsResponse} */
|
|
513
1646
|
static PaymentOptionsResponse() {
|
|
514
1647
|
return Joi.object({
|
|
515
|
-
payment_options:
|
|
1648
|
+
payment_options: PaymentPlatformModel.PaymentOptions().required(),
|
|
516
1649
|
success: Joi.boolean().required(),
|
|
517
1650
|
});
|
|
518
1651
|
}
|
|
1652
|
+
|
|
1653
|
+
/** @returns {PaymentSessionDetail} */
|
|
1654
|
+
static PaymentSessionDetail() {
|
|
1655
|
+
return Joi.object({
|
|
1656
|
+
aggregator_customer_id: Joi.string().allow(""),
|
|
1657
|
+
aggregator_order_id: Joi.string().allow("").required(),
|
|
1658
|
+
amount: Joi.number().required(),
|
|
1659
|
+
amount_captured: Joi.number().required(),
|
|
1660
|
+
amount_refunded: Joi.number(),
|
|
1661
|
+
billing_address: PaymentPlatformModel.AddressDetail().required(),
|
|
1662
|
+
cancel_url: Joi.string().allow("").required(),
|
|
1663
|
+
captured: Joi.boolean(),
|
|
1664
|
+
created: Joi.string().allow(""),
|
|
1665
|
+
currency: Joi.string().allow("").required(),
|
|
1666
|
+
g_user_id: Joi.string().allow("").required(),
|
|
1667
|
+
gid: Joi.string().allow("").required(),
|
|
1668
|
+
kind: Joi.string().allow(""),
|
|
1669
|
+
locale: Joi.string().allow(""),
|
|
1670
|
+
merchant_locale: Joi.string().allow(""),
|
|
1671
|
+
mode: Joi.string().allow("").required(),
|
|
1672
|
+
payment_id: Joi.string().allow("").required(),
|
|
1673
|
+
payment_methods: Joi.array().items(Joi.any()).required(),
|
|
1674
|
+
shipping_address: PaymentPlatformModel.AddressDetail().required(),
|
|
1675
|
+
status: Joi.string().allow("").required(),
|
|
1676
|
+
success_url: Joi.string().allow("").required(),
|
|
1677
|
+
});
|
|
1678
|
+
}
|
|
1679
|
+
|
|
1680
|
+
/** @returns {PaymentSessionRequestSerializer} */
|
|
1681
|
+
static PaymentSessionRequestSerializer() {
|
|
1682
|
+
return Joi.object({
|
|
1683
|
+
currency: Joi.string().allow("").required(),
|
|
1684
|
+
gid: Joi.string().allow("").required(),
|
|
1685
|
+
order_details: PaymentPlatformModel.OrderDetail().required(),
|
|
1686
|
+
payment_details: Joi.array()
|
|
1687
|
+
.items(PaymentPlatformModel.PaymentSessionDetail())
|
|
1688
|
+
.required(),
|
|
1689
|
+
status: Joi.string().allow("").required(),
|
|
1690
|
+
total_amount: Joi.number().required(),
|
|
1691
|
+
});
|
|
1692
|
+
}
|
|
1693
|
+
|
|
1694
|
+
/** @returns {PaymentSessionResponseSerializer} */
|
|
1695
|
+
static PaymentSessionResponseSerializer() {
|
|
1696
|
+
return Joi.object({
|
|
1697
|
+
currency: Joi.string().allow("").required(),
|
|
1698
|
+
gid: Joi.string().allow("").required(),
|
|
1699
|
+
platform_transaction_details: Joi.array().items(Joi.any()).required(),
|
|
1700
|
+
status: Joi.string().allow("").required(),
|
|
1701
|
+
total_amount: Joi.number().required(),
|
|
1702
|
+
});
|
|
1703
|
+
}
|
|
1704
|
+
|
|
1705
|
+
/** @returns {PaymentStatusBulkHandlerRequest} */
|
|
519
1706
|
static PaymentStatusBulkHandlerRequest() {
|
|
520
1707
|
return Joi.object({
|
|
521
1708
|
merchant_order_id: Joi.array().items(Joi.string().allow("")).required(),
|
|
522
1709
|
});
|
|
523
1710
|
}
|
|
1711
|
+
|
|
1712
|
+
/** @returns {PaymentStatusBulkHandlerResponse} */
|
|
524
1713
|
static PaymentStatusBulkHandlerResponse() {
|
|
525
1714
|
return Joi.object({
|
|
526
1715
|
count: Joi.number(),
|
|
527
|
-
data: Joi.array().items(
|
|
1716
|
+
data: Joi.array().items(PaymentPlatformModel.PaymentStatusObject()),
|
|
528
1717
|
error: Joi.string().allow(""),
|
|
529
1718
|
status: Joi.number().required(),
|
|
530
1719
|
success: Joi.string().allow("").required(),
|
|
531
1720
|
});
|
|
532
1721
|
}
|
|
1722
|
+
|
|
1723
|
+
/** @returns {PaymentStatusObject} */
|
|
533
1724
|
static PaymentStatusObject() {
|
|
534
1725
|
return Joi.object({
|
|
535
1726
|
merchant_order_id: Joi.string().allow("").required(),
|
|
536
1727
|
payment_object_list: Joi.array().items(
|
|
537
|
-
|
|
1728
|
+
PaymentPlatformModel.PaymentObjectListSerializer()
|
|
538
1729
|
),
|
|
539
1730
|
});
|
|
540
1731
|
}
|
|
1732
|
+
|
|
1733
|
+
/** @returns {PaymentStatusUpdateRequest} */
|
|
541
1734
|
static PaymentStatusUpdateRequest() {
|
|
542
1735
|
return Joi.object({
|
|
543
1736
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -555,6 +1748,8 @@ class PaymentModel {
|
|
|
555
1748
|
vpa: Joi.string().allow(""),
|
|
556
1749
|
});
|
|
557
1750
|
}
|
|
1751
|
+
|
|
1752
|
+
/** @returns {PaymentStatusUpdateResponse} */
|
|
558
1753
|
static PaymentStatusUpdateResponse() {
|
|
559
1754
|
return Joi.object({
|
|
560
1755
|
aggregator_name: Joi.string().allow("").required(),
|
|
@@ -564,17 +1759,23 @@ class PaymentModel {
|
|
|
564
1759
|
success: Joi.boolean().allow(null),
|
|
565
1760
|
});
|
|
566
1761
|
}
|
|
1762
|
+
|
|
1763
|
+
/** @returns {Payout} */
|
|
567
1764
|
static Payout() {
|
|
568
1765
|
return Joi.object({
|
|
569
|
-
customers:
|
|
1766
|
+
customers: PaymentPlatformModel.PayoutCustomer().required(),
|
|
570
1767
|
is_active: Joi.boolean().required(),
|
|
571
1768
|
is_default: Joi.boolean().required(),
|
|
572
|
-
more_attributes:
|
|
573
|
-
payouts_aggregators: Joi.array().items(
|
|
1769
|
+
more_attributes: PaymentPlatformModel.PayoutMoreAttributes().required(),
|
|
1770
|
+
payouts_aggregators: Joi.array().items(
|
|
1771
|
+
PaymentPlatformModel.PayoutAggregator()
|
|
1772
|
+
),
|
|
574
1773
|
transfer_type: Joi.string().allow("").required(),
|
|
575
1774
|
unique_transfer_no: Joi.string().allow("").required(),
|
|
576
1775
|
});
|
|
577
1776
|
}
|
|
1777
|
+
|
|
1778
|
+
/** @returns {PayoutAggregator} */
|
|
578
1779
|
static PayoutAggregator() {
|
|
579
1780
|
return Joi.object({
|
|
580
1781
|
aggregator_fund_id: Joi.number().allow(null),
|
|
@@ -582,6 +1783,8 @@ class PaymentModel {
|
|
|
582
1783
|
payout_details_id: Joi.number().allow(null),
|
|
583
1784
|
});
|
|
584
1785
|
}
|
|
1786
|
+
|
|
1787
|
+
/** @returns {PayoutBankDetails} */
|
|
585
1788
|
static PayoutBankDetails() {
|
|
586
1789
|
return Joi.object({
|
|
587
1790
|
account_holder: Joi.string().allow(""),
|
|
@@ -596,6 +1799,8 @@ class PaymentModel {
|
|
|
596
1799
|
state: Joi.string().allow(""),
|
|
597
1800
|
});
|
|
598
1801
|
}
|
|
1802
|
+
|
|
1803
|
+
/** @returns {PayoutCustomer} */
|
|
599
1804
|
static PayoutCustomer() {
|
|
600
1805
|
return Joi.object({
|
|
601
1806
|
email: Joi.string().allow("").allow(null),
|
|
@@ -605,6 +1810,8 @@ class PaymentModel {
|
|
|
605
1810
|
unique_external_id: Joi.string().allow("").allow(null),
|
|
606
1811
|
});
|
|
607
1812
|
}
|
|
1813
|
+
|
|
1814
|
+
/** @returns {PayoutMoreAttributes} */
|
|
608
1815
|
static PayoutMoreAttributes() {
|
|
609
1816
|
return Joi.object({
|
|
610
1817
|
account_holder: Joi.string().allow("").allow(null),
|
|
@@ -618,16 +1825,20 @@ class PaymentModel {
|
|
|
618
1825
|
state: Joi.string().allow("").allow(null),
|
|
619
1826
|
});
|
|
620
1827
|
}
|
|
1828
|
+
|
|
1829
|
+
/** @returns {PayoutRequest} */
|
|
621
1830
|
static PayoutRequest() {
|
|
622
1831
|
return Joi.object({
|
|
623
1832
|
aggregator: Joi.string().allow("").required(),
|
|
624
|
-
bank_details:
|
|
1833
|
+
bank_details: PaymentPlatformModel.PayoutBankDetails().required(),
|
|
625
1834
|
is_active: Joi.boolean().required(),
|
|
626
1835
|
transfer_type: Joi.string().allow("").required(),
|
|
627
1836
|
unique_external_id: Joi.string().allow("").required(),
|
|
628
1837
|
users: Joi.any().required(),
|
|
629
1838
|
});
|
|
630
1839
|
}
|
|
1840
|
+
|
|
1841
|
+
/** @returns {PayoutResponse} */
|
|
631
1842
|
static PayoutResponse() {
|
|
632
1843
|
return Joi.object({
|
|
633
1844
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -642,12 +1853,16 @@ class PaymentModel {
|
|
|
642
1853
|
users: Joi.any().required(),
|
|
643
1854
|
});
|
|
644
1855
|
}
|
|
1856
|
+
|
|
1857
|
+
/** @returns {PayoutsResponse} */
|
|
645
1858
|
static PayoutsResponse() {
|
|
646
1859
|
return Joi.object({
|
|
647
|
-
items: Joi.array().items(
|
|
1860
|
+
items: Joi.array().items(PaymentPlatformModel.Payout()).required(),
|
|
648
1861
|
success: Joi.boolean().required(),
|
|
649
1862
|
});
|
|
650
1863
|
}
|
|
1864
|
+
|
|
1865
|
+
/** @returns {PollingPaymentLinkResponse} */
|
|
651
1866
|
static PollingPaymentLinkResponse() {
|
|
652
1867
|
return Joi.object({
|
|
653
1868
|
aggregator_name: Joi.string().allow("").allow(null),
|
|
@@ -662,6 +1877,8 @@ class PaymentModel {
|
|
|
662
1877
|
success: Joi.boolean().allow(null),
|
|
663
1878
|
});
|
|
664
1879
|
}
|
|
1880
|
+
|
|
1881
|
+
/** @returns {RefundAccountResponse} */
|
|
665
1882
|
static RefundAccountResponse() {
|
|
666
1883
|
return Joi.object({
|
|
667
1884
|
data: Joi.any(),
|
|
@@ -670,17 +1887,64 @@ class PaymentModel {
|
|
|
670
1887
|
success: Joi.boolean().required(),
|
|
671
1888
|
});
|
|
672
1889
|
}
|
|
1890
|
+
|
|
1891
|
+
/** @returns {RefundSessionDetail} */
|
|
1892
|
+
static RefundSessionDetail() {
|
|
1893
|
+
return Joi.object({
|
|
1894
|
+
amount: Joi.number().required(),
|
|
1895
|
+
balance_transaction: Joi.string().allow(""),
|
|
1896
|
+
created: Joi.string().allow("").required(),
|
|
1897
|
+
currency: Joi.string().allow("").required(),
|
|
1898
|
+
payment_id: Joi.string().allow("").required(),
|
|
1899
|
+
reason: Joi.string().allow(""),
|
|
1900
|
+
receipt_number: Joi.string().allow(""),
|
|
1901
|
+
refund_utr: Joi.string().allow(""),
|
|
1902
|
+
request_id: Joi.string().allow("").required(),
|
|
1903
|
+
source_transfer_reversal: Joi.string().allow(""),
|
|
1904
|
+
status: Joi.string().allow("").required(),
|
|
1905
|
+
transfer_reversal: Joi.string().allow(""),
|
|
1906
|
+
});
|
|
1907
|
+
}
|
|
1908
|
+
|
|
1909
|
+
/** @returns {RefundSessionRequestSerializer} */
|
|
1910
|
+
static RefundSessionRequestSerializer() {
|
|
1911
|
+
return Joi.object({
|
|
1912
|
+
currency: Joi.string().allow("").required(),
|
|
1913
|
+
gid: Joi.string().allow("").required(),
|
|
1914
|
+
payment_details: PaymentPlatformModel.PaymentSessionDetail().required(),
|
|
1915
|
+
refund_details: Joi.array().items(
|
|
1916
|
+
PaymentPlatformModel.RefundSessionDetail()
|
|
1917
|
+
),
|
|
1918
|
+
status: Joi.string().allow("").required(),
|
|
1919
|
+
total_amount: Joi.number().required(),
|
|
1920
|
+
});
|
|
1921
|
+
}
|
|
1922
|
+
|
|
1923
|
+
/** @returns {RefundSessionResponseSerializer} */
|
|
1924
|
+
static RefundSessionResponseSerializer() {
|
|
1925
|
+
return Joi.object({
|
|
1926
|
+
currency: Joi.string().allow("").required(),
|
|
1927
|
+
gid: Joi.string().allow("").required(),
|
|
1928
|
+
platform_refund_details: Joi.array().items(Joi.any()).required(),
|
|
1929
|
+
status: Joi.string().allow("").required(),
|
|
1930
|
+
total_refund_amount: Joi.number().required(),
|
|
1931
|
+
});
|
|
1932
|
+
}
|
|
1933
|
+
|
|
1934
|
+
/** @returns {RepaymentDetailsSerialiserPayAll} */
|
|
673
1935
|
static RepaymentDetailsSerialiserPayAll() {
|
|
674
1936
|
return Joi.object({
|
|
675
1937
|
aggregator_order_id: Joi.string().allow("").required(),
|
|
676
1938
|
aggregator_transaction_id: Joi.string().allow("").required(),
|
|
677
1939
|
extension_order_id: Joi.string().allow("").allow(null).required(),
|
|
678
1940
|
shipment_details: Joi.array().items(
|
|
679
|
-
|
|
1941
|
+
PaymentPlatformModel.RepaymentRequestDetails()
|
|
680
1942
|
),
|
|
681
1943
|
total_amount: Joi.number().required(),
|
|
682
1944
|
});
|
|
683
1945
|
}
|
|
1946
|
+
|
|
1947
|
+
/** @returns {RepaymentRequestDetails} */
|
|
684
1948
|
static RepaymentRequestDetails() {
|
|
685
1949
|
return Joi.object({
|
|
686
1950
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -695,12 +1959,16 @@ class PaymentModel {
|
|
|
695
1959
|
payment_mode_identifier: Joi.string().allow("").required(),
|
|
696
1960
|
});
|
|
697
1961
|
}
|
|
1962
|
+
|
|
1963
|
+
/** @returns {RepaymentResponse} */
|
|
698
1964
|
static RepaymentResponse() {
|
|
699
1965
|
return Joi.object({
|
|
700
1966
|
data: Joi.any().required(),
|
|
701
1967
|
success: Joi.boolean().required(),
|
|
702
1968
|
});
|
|
703
1969
|
}
|
|
1970
|
+
|
|
1971
|
+
/** @returns {ResendOrCancelPaymentRequest} */
|
|
704
1972
|
static ResendOrCancelPaymentRequest() {
|
|
705
1973
|
return Joi.object({
|
|
706
1974
|
device_id: Joi.string().allow("").allow(null),
|
|
@@ -708,12 +1976,16 @@ class PaymentModel {
|
|
|
708
1976
|
request_type: Joi.string().allow("").required(),
|
|
709
1977
|
});
|
|
710
1978
|
}
|
|
1979
|
+
|
|
1980
|
+
/** @returns {ResendOrCancelPaymentResponse} */
|
|
711
1981
|
static ResendOrCancelPaymentResponse() {
|
|
712
1982
|
return Joi.object({
|
|
713
|
-
data:
|
|
1983
|
+
data: PaymentPlatformModel.LinkStatus().required(),
|
|
714
1984
|
success: Joi.boolean().required(),
|
|
715
1985
|
});
|
|
716
1986
|
}
|
|
1987
|
+
|
|
1988
|
+
/** @returns {ResendPaymentLinkResponse} */
|
|
717
1989
|
static ResendPaymentLinkResponse() {
|
|
718
1990
|
return Joi.object({
|
|
719
1991
|
message: Joi.string().allow("").required(),
|
|
@@ -722,12 +1994,16 @@ class PaymentModel {
|
|
|
722
1994
|
success: Joi.boolean().required(),
|
|
723
1995
|
});
|
|
724
1996
|
}
|
|
1997
|
+
|
|
1998
|
+
/** @returns {RevokeOAuthToken} */
|
|
725
1999
|
static RevokeOAuthToken() {
|
|
726
2000
|
return Joi.object({
|
|
727
2001
|
message: Joi.string().allow("").required(),
|
|
728
2002
|
success: Joi.boolean().required(),
|
|
729
2003
|
});
|
|
730
2004
|
}
|
|
2005
|
+
|
|
2006
|
+
/** @returns {RootPaymentMode} */
|
|
731
2007
|
static RootPaymentMode() {
|
|
732
2008
|
return Joi.object({
|
|
733
2009
|
add_card_enabled: Joi.boolean().allow(null),
|
|
@@ -736,22 +2012,28 @@ class PaymentModel {
|
|
|
736
2012
|
display_name: Joi.string().allow("").required(),
|
|
737
2013
|
display_priority: Joi.number().required(),
|
|
738
2014
|
is_pay_by_card_pl: Joi.boolean().allow(null),
|
|
739
|
-
list: Joi.array().items(
|
|
2015
|
+
list: Joi.array().items(PaymentPlatformModel.PaymentModeList()),
|
|
740
2016
|
name: Joi.string().allow("").required(),
|
|
741
2017
|
save_card: Joi.boolean().allow(null),
|
|
742
2018
|
});
|
|
743
2019
|
}
|
|
2020
|
+
|
|
2021
|
+
/** @returns {SaveSubscriptionSetupIntentRequest} */
|
|
744
2022
|
static SaveSubscriptionSetupIntentRequest() {
|
|
745
2023
|
return Joi.object({
|
|
746
2024
|
unique_external_id: Joi.string().allow("").required(),
|
|
747
2025
|
});
|
|
748
2026
|
}
|
|
2027
|
+
|
|
2028
|
+
/** @returns {SaveSubscriptionSetupIntentResponse} */
|
|
749
2029
|
static SaveSubscriptionSetupIntentResponse() {
|
|
750
2030
|
return Joi.object({
|
|
751
2031
|
data: Joi.any().required(),
|
|
752
2032
|
success: Joi.boolean().required(),
|
|
753
2033
|
});
|
|
754
2034
|
}
|
|
2035
|
+
|
|
2036
|
+
/** @returns {SetCODForUserRequest} */
|
|
755
2037
|
static SetCODForUserRequest() {
|
|
756
2038
|
return Joi.object({
|
|
757
2039
|
is_active: Joi.boolean().required(),
|
|
@@ -759,18 +2041,24 @@ class PaymentModel {
|
|
|
759
2041
|
mobileno: Joi.string().allow("").required(),
|
|
760
2042
|
});
|
|
761
2043
|
}
|
|
2044
|
+
|
|
2045
|
+
/** @returns {SetCODOptionResponse} */
|
|
762
2046
|
static SetCODOptionResponse() {
|
|
763
2047
|
return Joi.object({
|
|
764
2048
|
message: Joi.string().allow("").required(),
|
|
765
2049
|
success: Joi.boolean().required(),
|
|
766
2050
|
});
|
|
767
2051
|
}
|
|
2052
|
+
|
|
2053
|
+
/** @returns {StatisticsData} */
|
|
768
2054
|
static StatisticsData() {
|
|
769
2055
|
return Joi.object({
|
|
770
2056
|
active_device_count: Joi.number().required(),
|
|
771
2057
|
inactive_device_count: Joi.number().required(),
|
|
772
2058
|
});
|
|
773
2059
|
}
|
|
2060
|
+
|
|
2061
|
+
/** @returns {SubscriptionConfigResponse} */
|
|
774
2062
|
static SubscriptionConfigResponse() {
|
|
775
2063
|
return Joi.object({
|
|
776
2064
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -778,12 +2066,16 @@ class PaymentModel {
|
|
|
778
2066
|
success: Joi.boolean().required(),
|
|
779
2067
|
});
|
|
780
2068
|
}
|
|
2069
|
+
|
|
2070
|
+
/** @returns {SubscriptionPaymentMethodResponse} */
|
|
781
2071
|
static SubscriptionPaymentMethodResponse() {
|
|
782
2072
|
return Joi.object({
|
|
783
2073
|
data: Joi.array().items(Joi.any()).required(),
|
|
784
2074
|
success: Joi.boolean().required(),
|
|
785
2075
|
});
|
|
786
2076
|
}
|
|
2077
|
+
|
|
2078
|
+
/** @returns {UpdatePayoutRequest} */
|
|
787
2079
|
static UpdatePayoutRequest() {
|
|
788
2080
|
return Joi.object({
|
|
789
2081
|
is_active: Joi.boolean().required(),
|
|
@@ -791,6 +2083,8 @@ class PaymentModel {
|
|
|
791
2083
|
unique_external_id: Joi.string().allow("").required(),
|
|
792
2084
|
});
|
|
793
2085
|
}
|
|
2086
|
+
|
|
2087
|
+
/** @returns {UpdatePayoutResponse} */
|
|
794
2088
|
static UpdatePayoutResponse() {
|
|
795
2089
|
return Joi.object({
|
|
796
2090
|
is_active: Joi.boolean().required(),
|
|
@@ -798,6 +2092,8 @@ class PaymentModel {
|
|
|
798
2092
|
success: Joi.boolean().required(),
|
|
799
2093
|
});
|
|
800
2094
|
}
|
|
2095
|
+
|
|
2096
|
+
/** @returns {ValidateCustomerRequest} */
|
|
801
2097
|
static ValidateCustomerRequest() {
|
|
802
2098
|
return Joi.object({
|
|
803
2099
|
aggregator: Joi.string().allow("").required(),
|
|
@@ -810,6 +2106,8 @@ class PaymentModel {
|
|
|
810
2106
|
transaction_amount_in_paise: Joi.number().required(),
|
|
811
2107
|
});
|
|
812
2108
|
}
|
|
2109
|
+
|
|
2110
|
+
/** @returns {ValidateCustomerResponse} */
|
|
813
2111
|
static ValidateCustomerResponse() {
|
|
814
2112
|
return Joi.object({
|
|
815
2113
|
data: Joi.any().required(),
|
|
@@ -818,4 +2116,4 @@ class PaymentModel {
|
|
|
818
2116
|
});
|
|
819
2117
|
}
|
|
820
2118
|
}
|
|
821
|
-
module.exports =
|
|
2119
|
+
module.exports = PaymentPlatformModel;
|