@gofynd/fdk-client-javascript 1.1.2 → 1.1.3

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.
Files changed (117) hide show
  1. package/README.md +1 -2
  2. package/index.d.ts +4 -7
  3. package/index.js +5 -12
  4. package/package.json +1 -1
  5. package/sdk/application/ApplicationClient.d.ts +20 -20
  6. package/sdk/application/ApplicationClient.js +26 -26
  7. package/sdk/application/Cart/CartApplicationClient.d.ts +36 -6
  8. package/sdk/application/Cart/CartApplicationClient.js +105 -10
  9. package/sdk/application/Cart/CartApplicationModel.d.ts +9 -0
  10. package/sdk/application/Cart/CartApplicationModel.js +105 -1
  11. package/sdk/application/Cart/CartApplicationValidator.d.ts +1 -0
  12. package/sdk/application/Cart/CartApplicationValidator.js +15 -1
  13. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +1 -0
  14. package/sdk/application/Catalog/CatalogApplicationModel.js +13 -0
  15. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +14 -10
  16. package/sdk/application/Configuration/ConfigurationApplicationClient.js +16 -10
  17. package/sdk/application/Configuration/ConfigurationApplicationModel.js +1 -0
  18. package/sdk/application/Configuration/ConfigurationApplicationValidator.js +1 -0
  19. package/sdk/application/Content/ContentApplicationModel.js +3 -1
  20. package/sdk/application/Logistic/LogisticApplicationModel.js +3 -2
  21. package/sdk/application/Order/OrderApplicationClient.d.ts +2 -2
  22. package/sdk/application/Order/OrderApplicationClient.js +2 -2
  23. package/sdk/application/Order/OrderApplicationModel.js +18 -8
  24. package/sdk/application/Payment/PaymentApplicationClient.d.ts +35 -0
  25. package/sdk/application/Payment/PaymentApplicationClient.js +200 -0
  26. package/sdk/application/Payment/PaymentApplicationModel.d.ts +4 -0
  27. package/sdk/application/Payment/PaymentApplicationModel.js +58 -7
  28. package/sdk/application/Payment/PaymentApplicationValidator.d.ts +3 -0
  29. package/sdk/application/Payment/PaymentApplicationValidator.js +19 -0
  30. package/sdk/application/PosCart/PosCartApplicationClient.d.ts +16 -3
  31. package/sdk/application/PosCart/PosCartApplicationClient.js +39 -6
  32. package/sdk/application/PosCart/PosCartApplicationModel.d.ts +6 -0
  33. package/sdk/application/PosCart/PosCartApplicationModel.js +63 -1
  34. package/sdk/application/PosCart/PosCartApplicationValidator.js +6 -0
  35. package/sdk/application/index.d.ts +10 -10
  36. package/sdk/application/index.js +13 -13
  37. package/sdk/common/Constant.d.ts +5 -0
  38. package/sdk/common/Constant.js +5 -0
  39. package/sdk/platform/Billing/BillingPlatformModel.js +6 -1
  40. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +459 -2
  41. package/sdk/platform/Cart/CartPlatformApplicationClient.js +2480 -340
  42. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +29 -0
  43. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +250 -0
  44. package/sdk/platform/Cart/CartPlatformModel.d.ts +52 -0
  45. package/sdk/platform/Cart/CartPlatformModel.js +580 -2
  46. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +8 -2
  47. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +10 -0
  48. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +1 -0
  49. package/sdk/platform/Catalog/CatalogPlatformClient.js +2 -2
  50. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1 -0
  51. package/sdk/platform/Catalog/CatalogPlatformModel.js +41 -29
  52. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1 -0
  53. package/sdk/platform/Communication/CommunicationPlatformModel.js +9 -0
  54. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +2 -2
  55. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +2 -2
  56. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +5 -4
  57. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +99 -78
  58. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +99 -78
  59. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +87 -71
  60. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +87 -71
  61. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +2 -0
  62. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +26 -0
  63. package/sdk/platform/Content/ContentPlatformModel.js +3 -1
  64. package/sdk/platform/Finance/FinancePlatformClient.d.ts +135 -0
  65. package/sdk/platform/Finance/FinancePlatformClient.js +853 -0
  66. package/sdk/platform/Finance/FinancePlatformModel.d.ts +51 -0
  67. package/sdk/platform/Finance/FinancePlatformModel.js +342 -0
  68. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +16 -0
  69. package/sdk/platform/Finance/FinancePlatformValidator.js +84 -0
  70. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +11 -1
  71. package/sdk/platform/Order/OrderPlatformApplicationClient.js +66 -2
  72. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +1 -0
  73. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +6 -0
  74. package/sdk/platform/Order/OrderPlatformClient.d.ts +159 -79
  75. package/sdk/platform/Order/OrderPlatformClient.js +541 -114
  76. package/sdk/platform/Order/OrderPlatformModel.d.ts +42 -6
  77. package/sdk/platform/Order/OrderPlatformModel.js +569 -159
  78. package/sdk/platform/Order/OrderPlatformValidator.d.ts +6 -0
  79. package/sdk/platform/Order/OrderPlatformValidator.js +51 -9
  80. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +22 -0
  81. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +127 -0
  82. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.d.ts +2 -0
  83. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.js +13 -0
  84. package/sdk/platform/Partner/PartnerPlatformClient.d.ts +145 -0
  85. package/sdk/platform/Partner/PartnerPlatformClient.js +799 -0
  86. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +39 -0
  87. package/sdk/platform/Partner/PartnerPlatformModel.js +367 -0
  88. package/sdk/platform/Partner/PartnerPlatformValidator.d.ts +14 -0
  89. package/sdk/platform/Partner/PartnerPlatformValidator.js +87 -0
  90. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +221 -0
  91. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +1476 -190
  92. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +20 -0
  93. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +126 -0
  94. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +44 -0
  95. package/sdk/platform/Payment/PaymentPlatformModel.js +410 -0
  96. package/sdk/platform/PlatformApplicationClient.d.ts +1149 -938
  97. package/sdk/platform/PlatformApplicationClient.js +1259 -1035
  98. package/sdk/platform/PlatformClient.d.ts +9888 -8286
  99. package/sdk/platform/PlatformClient.js +10960 -9038
  100. package/sdk/platform/index.d.ts +15 -14
  101. package/sdk/platform/index.js +20 -18
  102. package/sdk/public/PublicClient.d.ts +2 -2
  103. package/sdk/public/PublicClient.js +4 -4
  104. package/sdk/public/index.d.ts +1 -1
  105. package/sdk/public/index.js +2 -2
  106. package/partner.d.ts +0 -4
  107. package/partner.js +0 -7
  108. package/sdk/partner/OAuthClient.d.ts +0 -14
  109. package/sdk/partner/OAuthClient.js +0 -112
  110. package/sdk/partner/PartnerAPIClient.d.ts +0 -12
  111. package/sdk/partner/PartnerAPIClient.js +0 -42
  112. package/sdk/partner/PartnerClient.d.ts +0 -6
  113. package/sdk/partner/PartnerClient.js +0 -17
  114. package/sdk/partner/PartnerConfig.d.ts +0 -30
  115. package/sdk/partner/PartnerConfig.js +0 -39
  116. package/sdk/partner/index.d.ts +0 -3
  117. package/sdk/partner/index.js +0 -5
@@ -3,6 +3,18 @@ declare class Payment {
3
3
  constructor(config: any, applicationId: any);
4
4
  config: any;
5
5
  applicationId: any;
6
+ /**
7
+ * @param {Object} arg - Arg object.
8
+ * @param {string} arg.terminalUniqueIdentifier - Terminal unique identifier
9
+ * @param {EdcUpdateRequest} arg.body
10
+ * @returns {Promise<EdcDeviceUpdateResponse>} - Success response
11
+ * @summary: Update store id and device tag of edc device
12
+ * @description: Use this API to Update store id and device tag of edc device
13
+ */
14
+ addEdcDevice({ terminalUniqueIdentifier, body }?: {
15
+ terminalUniqueIdentifier: string;
16
+ body: EdcUpdateRequest;
17
+ }): Promise<EdcDeviceUpdateResponse>;
6
18
  /**
7
19
  * @param {Object} arg - Arg object.
8
20
  * @param {AddBeneficiaryDetailsOTPRequest} arg.body
@@ -13,6 +25,26 @@ declare class Payment {
13
25
  addRefundBankAccountUsingOTP({ body }?: {
14
26
  body: AddBeneficiaryDetailsOTPRequest;
15
27
  }): Promise<RefundAccountResponse>;
28
+ /**
29
+ * @param {Object} arg - Arg object.
30
+ * @param {CancelOrResendPaymentLinkRequest} arg.body
31
+ * @returns {Promise<CancelPaymentLinkResponse>} - Success response
32
+ * @summary: Cancel payment link
33
+ * @description: Use this API to cancel a payment link for the customer
34
+ */
35
+ cancelPaymentLink({ body }?: {
36
+ body: CancelOrResendPaymentLinkRequest;
37
+ }): Promise<CancelPaymentLinkResponse>;
38
+ /**
39
+ * @param {Object} arg - Arg object.
40
+ * @param {PaymentStatusUpdateRequest} arg.body
41
+ * @returns {Promise<PaymentStatusUpdateResponse>} - Success response
42
+ * @summary: Performs continuous polling to check status of payment on the server
43
+ * @description: Use this API to perform continuous polling at intervals to check the status of payment until timeout.
44
+ */
45
+ checkAndUpdatePaymentStatus({ body }?: {
46
+ body: PaymentStatusUpdateRequest;
47
+ }): Promise<PaymentStatusUpdateResponse>;
16
48
  /**
17
49
  * @param {Object} arg - Arg object.
18
50
  * @param {PaymentConfirmationRequest} arg.body
@@ -23,6 +55,48 @@ declare class Payment {
23
55
  confirmPayment({ body }?: {
24
56
  body: PaymentConfirmationRequest;
25
57
  }): Promise<PaymentConfirmationResponse>;
58
+ /**
59
+ * @param {Object} arg - Arg object.
60
+ * @param {CreatePaymentLinkRequest} arg.body
61
+ * @returns {Promise<CreatePaymentLinkResponse>} - Success response
62
+ * @summary: Create payment link
63
+ * @description: Use this API to create a payment link for the customer
64
+ */
65
+ createPaymentLink({ body }?: {
66
+ body: CreatePaymentLinkRequest;
67
+ }): Promise<CreatePaymentLinkResponse>;
68
+ /**
69
+ * @param {Object} arg - Arg object.
70
+ * @returns {Promise<EdcAggregatorAndModelListResponse>} - Success response
71
+ * @summary: get some information about the store and edc device
72
+ * @description: Use this API to get info of devices linked to a particular app.
73
+ */
74
+ edcAggregatorsAndModelList({}?: any): Promise<EdcAggregatorAndModelListResponse>;
75
+ /**
76
+ * @param {Object} arg - Arg object.
77
+ * @param {number} [arg.pageNo] -
78
+ * @param {number} [arg.pageSize] -
79
+ * @param {boolean} [arg.isActive] -
80
+ * @param {number} [arg.storeId] -
81
+ * @param {string} [arg.deviceTag] -
82
+ * @returns {Promise<EdcDeviceListResponse>} - Success response
83
+ * @summary: get all the device list of an app
84
+ * @description: Use this API to get all devices linked to a particular app.
85
+ */
86
+ edcDeviceList({ pageNo, pageSize, isActive, storeId, deviceTag }?: {
87
+ pageNo?: number;
88
+ pageSize?: number;
89
+ isActive?: boolean;
90
+ storeId?: number;
91
+ deviceTag?: string;
92
+ }): Promise<EdcDeviceListResponse>;
93
+ /**
94
+ * @param {Object} arg - Arg object.
95
+ * @returns {Promise<EdcDeviceStatsResponse>} - Success response
96
+ * @summary: get some information about the store and edc device
97
+ * @description: Use this API to get info of devices linked to a particular app.
98
+ */
99
+ edcDeviceStats({}?: any): Promise<EdcDeviceStatsResponse>;
26
100
  /**
27
101
  * @param {Object} arg - Arg object.
28
102
  * @param {string} arg.orderId -
@@ -42,6 +116,33 @@ declare class Payment {
42
116
  * @description: Get All Brand Payment Gateway Config Secret
43
117
  */
44
118
  getBrandPaymentGatewayConfig({}?: any): Promise<PaymentGatewayConfigResponse>;
119
+ /**
120
+ * @param {Object} arg - Arg object.
121
+ * @param {string} arg.terminalUniqueIdentifier - Terminal unique identifier
122
+ * @returns {Promise<EdcDeviceDetailsResponse>} - Success response
123
+ * @summary: get details of a single edc device
124
+ * @description: Use this API to get details of a single edc device
125
+ */
126
+ getEdcDevice({ terminalUniqueIdentifier }?: {
127
+ terminalUniqueIdentifier: string;
128
+ }): Promise<EdcDeviceDetailsResponse>;
129
+ /**
130
+ * @param {Object} arg - Arg object.
131
+ * @returns {Promise<GetPaymentCodeResponse>} - Success response
132
+ * @summary: List Payment Options Method Codes
133
+ * @description: Get all active List Payment Options Method Codes
134
+ */
135
+ getPaymentCodeOption({}?: any): Promise<GetPaymentCodeResponse>;
136
+ /**
137
+ * @param {Object} arg - Arg object.
138
+ * @param {string} [arg.paymentLinkId] -
139
+ * @returns {Promise<GetPaymentLinkResponse>} - Success response
140
+ * @summary: Get payment link
141
+ * @description: Use this API to get a payment link
142
+ */
143
+ getPaymentLink({ paymentLinkId }?: {
144
+ paymentLinkId?: string;
145
+ }): Promise<GetPaymentLinkResponse>;
45
146
  /**
46
147
  * @param {Object} arg - Arg object.
47
148
  * @param {boolean} arg.refresh -
@@ -54,6 +155,36 @@ declare class Payment {
54
155
  refresh: boolean;
55
156
  requestType: string;
56
157
  }): Promise<PaymentOptionsResponse>;
158
+ /**
159
+ * @param {Object} arg - Arg object.
160
+ * @param {number} arg.amount - Payable amount.
161
+ * @param {string} arg.cartId - Identifier of the cart.
162
+ * @param {string} arg.pincode - The PIN Code of the destination address, e.g. 400059
163
+ * @param {string} arg.checkoutMode - Option to checkout for self or for others.
164
+ * @param {boolean} [arg.refresh] - This is a boolean value. Select `true`
165
+ * to remove temporary cache files on payment gateway and replace with the
166
+ * latest one.
167
+ * @param {string} [arg.cardReference] - Card reference id of user's debit
168
+ * or credit card.
169
+ * @param {string} arg.orderType - The order type of shipment * HomeDelivery
170
+ * - If the customer wants the order home-delivered * PickAtStore - If the
171
+ * customer wants the handover of an order at the store itself.
172
+ * @param {string} [arg.userDetails] - URIencoded JSON containing details of
173
+ * an anonymous user.
174
+ * @returns {Promise<PaymentOptionsResponse>} - Success response
175
+ * @summary: Get All Valid Payment Options
176
+ * @description: Use this API to get Get All Valid Payment Options for making payment
177
+ */
178
+ getPosPaymentModeRoutes({ amount, cartId, pincode, checkoutMode, orderType, refresh, cardReference, userDetails, }?: {
179
+ amount: number;
180
+ cartId: string;
181
+ pincode: string;
182
+ checkoutMode: string;
183
+ refresh?: boolean;
184
+ cardReference?: string;
185
+ orderType: string;
186
+ userDetails?: string;
187
+ }): Promise<PaymentOptionsResponse>;
57
188
  /**
58
189
  * @param {Object} arg - Arg object.
59
190
  * @param {string} arg.orderId -
@@ -86,6 +217,26 @@ declare class Payment {
86
217
  getUserOrderBeneficiaries({ orderId }?: {
87
218
  orderId: string;
88
219
  }): Promise<OrderBeneficiaryResponse>;
220
+ /**
221
+ * @param {Object} arg - Arg object.
222
+ * @param {PaymentInitializationRequest} arg.body
223
+ * @returns {Promise<PaymentInitializationResponse>} - Success response
224
+ * @summary: Initialize a payment (server-to-server) for UPI and BharatQR
225
+ * @description: PUse this API to inititate payment using UPI, BharatQR, wherein the UPI requests are send to the app and QR code is displayed on the screen.
226
+ */
227
+ initialisePayment({ body }?: {
228
+ body: PaymentInitializationRequest;
229
+ }): Promise<PaymentInitializationResponse>;
230
+ /**
231
+ * @param {Object} arg - Arg object.
232
+ * @param {MerchantOnBoardingRequest} arg.body
233
+ * @returns {Promise<MerchantOnBoardingResponse>} - Success response
234
+ * @summary: API to push Ajiodhan merchant data to Gringotts system
235
+ * @description: Use this API to push Ajiodhan merchant data to Gringotts system
236
+ */
237
+ merchantOnBoarding({ body }?: {
238
+ body: MerchantOnBoardingRequest;
239
+ }): Promise<MerchantOnBoardingResponse>;
89
240
  /**
90
241
  * @param {Object} arg - Arg object.
91
242
  * @param {string} arg.aggregator - Aggregator
@@ -100,6 +251,56 @@ declare class Payment {
100
251
  successRedirectUrl?: string;
101
252
  failureRedirectUrl?: string;
102
253
  }): Promise<GetOauthUrlResponse>;
254
+ /**
255
+ * @param {Object} arg - Arg object.
256
+ * @param {PaymentStatusBulkHandlerRequest} arg.body
257
+ * @returns {Promise<PaymentStatusBulkHandlerResponse>} - Success response
258
+ * @summary: Get Payment status and information for a list of order_ids
259
+ * @description: Use this API to get Payment status and information for a list of order_ids
260
+ */
261
+ paymentStatusBulk({ body }?: {
262
+ body: PaymentStatusBulkHandlerRequest;
263
+ }): Promise<PaymentStatusBulkHandlerResponse>;
264
+ /**
265
+ * @param {Object} arg - Arg object.
266
+ * @param {string} [arg.paymentLinkId] -
267
+ * @returns {Promise<PollingPaymentLinkResponse>} - Success response
268
+ * @summary: Used for polling if payment successful or not
269
+ * @description: Use this API to poll if payment through payment was successful or not
270
+ */
271
+ pollingPaymentLink({ paymentLinkId }?: {
272
+ paymentLinkId?: string;
273
+ }): Promise<PollingPaymentLinkResponse>;
274
+ /**
275
+ * @param {Object} arg - Arg object.
276
+ * @param {RepaymentDetailsSerialiserPayAll} arg.body
277
+ * @returns {Promise<RepaymentResponse>} - Success response
278
+ * @summary: API to register repayment details
279
+ * @description: Use this API to register any repayment record in the db and notify the aggrgator
280
+ */
281
+ repaymentDetails({ body }?: {
282
+ body: RepaymentDetailsSerialiserPayAll;
283
+ }): Promise<RepaymentResponse>;
284
+ /**
285
+ * @param {Object} arg - Arg object.
286
+ * @param {ResendOrCancelPaymentRequest} arg.body
287
+ * @returns {Promise<ResendOrCancelPaymentResponse>} - Success response
288
+ * @summary: API to resend and cancel a payment link which was already generated.
289
+ * @description: Use this API to perform resend or cancel a payment link based on request payload.
290
+ */
291
+ resendOrCancelPayment({ body }?: {
292
+ body: ResendOrCancelPaymentRequest;
293
+ }): Promise<ResendOrCancelPaymentResponse>;
294
+ /**
295
+ * @param {Object} arg - Arg object.
296
+ * @param {CancelOrResendPaymentLinkRequest} arg.body
297
+ * @returns {Promise<ResendPaymentLinkResponse>} - Success response
298
+ * @summary: Resend payment link
299
+ * @description: Use this API to resend a payment link for the customer
300
+ */
301
+ resendPaymentLink({ body }?: {
302
+ body: CancelOrResendPaymentLinkRequest;
303
+ }): Promise<ResendPaymentLinkResponse>;
103
304
  /**
104
305
  * @param {Object} arg - Arg object.
105
306
  * @param {string} arg.aggregator - Aggregator_slug
@@ -130,4 +331,24 @@ declare class Payment {
130
331
  setUserCODlimitRoutes({ body }?: {
131
332
  body: SetCODForUserRequest;
132
333
  }): Promise<SetCODOptionResponse>;
334
+ /**
335
+ * @param {Object} arg - Arg object.
336
+ * @param {EdcAddRequest} arg.body
337
+ * @returns {Promise<EdcDeviceAddResponse>} - Success response
338
+ * @summary: map new edc device to the terminal
339
+ * @description: Use this API to map new edc device to the terminal
340
+ */
341
+ updateEdcDevice({ body }?: {
342
+ body: EdcAddRequest;
343
+ }): Promise<EdcDeviceAddResponse>;
344
+ /**
345
+ * @param {Object} arg - Arg object.
346
+ * @param {ValidateCustomerRequest} arg.body
347
+ * @returns {Promise<ValidateCustomerResponse>} - Success response
348
+ * @summary: Validate customer for payment
349
+ * @description: Use this API to check if the customer is eligible to use credit-line facilities such as Simpl Pay Later and Rupifi.
350
+ */
351
+ verifyCustomerForPayment({ body }?: {
352
+ body: ValidateCustomerRequest;
353
+ }): Promise<ValidateCustomerResponse>;
133
354
  }