@gofynd/fdk-client-javascript 1.4.2-beta.2 → 1.4.2-beta.4

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 (126) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/Cart/CartApplicationModel.d.ts +1742 -1726
  4. package/sdk/application/Cart/CartApplicationModel.js +1497 -1481
  5. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +1917 -1917
  6. package/sdk/application/Catalog/CatalogApplicationModel.js +1611 -1611
  7. package/sdk/application/Common/CommonApplicationModel.d.ts +235 -235
  8. package/sdk/application/Common/CommonApplicationModel.js +172 -172
  9. package/sdk/application/Communication/CommunicationApplicationModel.d.ts +72 -72
  10. package/sdk/application/Communication/CommunicationApplicationModel.js +64 -64
  11. package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +1614 -1614
  12. package/sdk/application/Configuration/ConfigurationApplicationModel.js +1151 -1151
  13. package/sdk/application/Content/ContentApplicationModel.d.ts +797 -797
  14. package/sdk/application/Content/ContentApplicationModel.js +757 -757
  15. package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +79 -79
  16. package/sdk/application/FileStorage/FileStorageApplicationModel.js +84 -84
  17. package/sdk/application/Lead/LeadApplicationModel.d.ts +417 -417
  18. package/sdk/application/Lead/LeadApplicationModel.js +301 -301
  19. package/sdk/application/Logistic/LogisticApplicationModel.d.ts +666 -666
  20. package/sdk/application/Logistic/LogisticApplicationModel.js +601 -601
  21. package/sdk/application/Order/OrderApplicationModel.d.ts +852 -846
  22. package/sdk/application/Order/OrderApplicationModel.js +828 -822
  23. package/sdk/application/Payment/PaymentApplicationClient.d.ts +5 -5
  24. package/sdk/application/Payment/PaymentApplicationClient.js +10 -10
  25. package/sdk/application/Payment/PaymentApplicationModel.d.ts +2176 -2145
  26. package/sdk/application/Payment/PaymentApplicationModel.js +1474 -1453
  27. package/sdk/application/Payment/PaymentApplicationValidator.d.ts +5 -5
  28. package/sdk/application/Payment/PaymentApplicationValidator.js +3 -3
  29. package/sdk/application/PosCart/PosCartApplicationModel.d.ts +1462 -1462
  30. package/sdk/application/PosCart/PosCartApplicationModel.js +1260 -1260
  31. package/sdk/application/Rewards/RewardsApplicationModel.d.ts +214 -214
  32. package/sdk/application/Rewards/RewardsApplicationModel.js +211 -211
  33. package/sdk/application/Share/ShareApplicationModel.d.ts +114 -114
  34. package/sdk/application/Share/ShareApplicationModel.js +121 -121
  35. package/sdk/application/Theme/ThemeApplicationModel.d.ts +895 -895
  36. package/sdk/application/Theme/ThemeApplicationModel.js +684 -684
  37. package/sdk/application/User/UserApplicationClient.d.ts +2 -2
  38. package/sdk/application/User/UserApplicationClient.js +4 -7
  39. package/sdk/application/User/UserApplicationModel.d.ts +769 -764
  40. package/sdk/application/User/UserApplicationModel.js +731 -741
  41. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +63 -63
  42. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +65 -65
  43. package/sdk/partner/Lead/LeadPartnerModel.d.ts +661 -661
  44. package/sdk/partner/Lead/LeadPartnerModel.js +491 -491
  45. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +223 -223
  46. package/sdk/partner/Logistics/LogisticsPartnerModel.js +235 -235
  47. package/sdk/partner/Theme/ThemePartnerModel.d.ts +1087 -1087
  48. package/sdk/partner/Theme/ThemePartnerModel.js +819 -819
  49. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +386 -386
  50. package/sdk/partner/Webhook/WebhookPartnerModel.js +342 -342
  51. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +123 -123
  52. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +109 -109
  53. package/sdk/platform/Billing/BillingPlatformModel.d.ts +801 -801
  54. package/sdk/platform/Billing/BillingPlatformModel.js +783 -783
  55. package/sdk/platform/Cart/CartPlatformModel.d.ts +3333 -3317
  56. package/sdk/platform/Cart/CartPlatformModel.js +2936 -2920
  57. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +26 -0
  58. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +182 -0
  59. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +70 -1
  60. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +44 -0
  61. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1013 -980
  62. package/sdk/platform/Catalog/CatalogPlatformModel.js +977 -933
  63. package/sdk/platform/Common/CommonPlatformModel.d.ts +255 -255
  64. package/sdk/platform/Common/CommonPlatformModel.js +187 -187
  65. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1238 -1238
  66. package/sdk/platform/Communication/CommunicationPlatformModel.js +1273 -1273
  67. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +661 -661
  68. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +692 -692
  69. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +3198 -3198
  70. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +2247 -2247
  71. package/sdk/platform/Content/ContentPlatformModel.d.ts +1842 -1825
  72. package/sdk/platform/Content/ContentPlatformModel.js +1868 -1848
  73. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +245 -245
  74. package/sdk/platform/Discount/DiscountPlatformModel.js +248 -248
  75. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +1 -1
  76. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +4 -1
  77. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +2 -0
  78. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +2 -0
  79. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +2 -2
  80. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +7 -4
  81. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +882 -869
  82. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +894 -878
  83. package/sdk/platform/Finance/FinancePlatformModel.d.ts +1044 -1044
  84. package/sdk/platform/Finance/FinancePlatformModel.js +974 -974
  85. package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +942 -942
  86. package/sdk/platform/Inventory/InventoryPlatformModel.js +1003 -1003
  87. package/sdk/platform/Lead/LeadPlatformModel.d.ts +608 -608
  88. package/sdk/platform/Lead/LeadPlatformModel.js +465 -465
  89. package/sdk/platform/Order/OrderPlatformModel.d.ts +5192 -5176
  90. package/sdk/platform/Order/OrderPlatformModel.js +4752 -4736
  91. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +22 -22
  92. package/sdk/platform/Partner/PartnerPlatformModel.js +22 -22
  93. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +2693 -2657
  94. package/sdk/platform/Payment/PaymentPlatformModel.js +1842 -1819
  95. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +204 -204
  96. package/sdk/platform/Rewards/RewardsPlatformModel.js +199 -199
  97. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +7 -6
  98. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +11 -10
  99. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1674 -1539
  100. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +1663 -1534
  101. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +4 -4
  102. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +4 -4
  103. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +1 -1
  104. package/sdk/platform/Share/SharePlatformApplicationClient.js +19 -6
  105. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +13 -3
  106. package/sdk/platform/Share/SharePlatformApplicationValidator.js +6 -2
  107. package/sdk/platform/Share/SharePlatformModel.d.ts +147 -147
  108. package/sdk/platform/Share/SharePlatformModel.js +139 -139
  109. package/sdk/platform/Theme/ThemePlatformModel.d.ts +1046 -1046
  110. package/sdk/platform/Theme/ThemePlatformModel.js +789 -789
  111. package/sdk/platform/User/UserPlatformModel.d.ts +823 -753
  112. package/sdk/platform/User/UserPlatformModel.js +731 -661
  113. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +439 -439
  114. package/sdk/platform/Webhook/WebhookPlatformModel.js +364 -364
  115. package/sdk/public/Billing/BillingPublicModel.d.ts +55 -55
  116. package/sdk/public/Billing/BillingPublicModel.js +51 -51
  117. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +237 -237
  118. package/sdk/public/Configuration/ConfigurationPublicModel.js +174 -174
  119. package/sdk/public/Content/ContentPublicModel.d.ts +26 -26
  120. package/sdk/public/Content/ContentPublicModel.js +28 -28
  121. package/sdk/public/Inventory/InventoryPublicModel.d.ts +237 -237
  122. package/sdk/public/Inventory/InventoryPublicModel.js +257 -257
  123. package/sdk/public/Partner/PartnerPublicModel.d.ts +104 -104
  124. package/sdk/public/Partner/PartnerPublicModel.js +113 -113
  125. package/sdk/public/Webhook/WebhookPublicModel.d.ts +87 -87
  126. package/sdk/public/Webhook/WebhookPublicModel.js +93 -93
@@ -1,183 +1,176 @@
1
1
  const Joi = require("joi");
2
2
 
3
3
  /**
4
- * @typedef ChannelDisplayName
5
- * @property {string} [platform_pos]
4
+ * @typedef GenerateReportMeta
5
+ * @property {string} [brand]
6
+ * @property {string} [company]
7
+ * @property {string} [channel]
6
8
  */
7
9
 
8
10
  /**
9
- * @typedef ChannelDisplayNameResponse
10
- * @property {ChannelDisplayName} [data]
11
- * @property {boolean} [success]
11
+ * @typedef GenerateReportFilters
12
+ * @property {string[]} [brand]
13
+ * @property {string[]} [company]
14
+ * @property {string[]} [channel]
12
15
  */
13
16
 
14
17
  /**
15
- * @typedef CnDetails
16
- * @property {string} [channel_of_issuance]
17
- * @property {string} [date_issued]
18
- * @property {string} [expiry_date]
19
- * @property {string} [invoice_number]
20
- * @property {string} [order_id]
21
- * @property {string} [ordering_channel]
22
- * @property {string} [shipment_id]
23
- * @property {string} [staff_id]
24
- * @property {string} [store_id]
18
+ * @typedef GenerateReportPlatform
19
+ * @property {string} [start_date]
20
+ * @property {string} [end_date]
21
+ * @property {GenerateReportMeta} [meta]
22
+ * @property {string} [report_id]
23
+ * @property {GenerateReportFilters} [filters]
25
24
  */
26
25
 
27
26
  /**
28
- * @typedef CnDownloadReport
29
- * @property {string} [affiliate_id]
30
- * @property {string} [end_date]
31
- * @property {number} [page]
32
- * @property {number} [pagesize]
33
- * @property {string} [search]
34
- * @property {string} [search_type]
35
- * @property {string} [start_date]
36
- * @property {string[]} [status]
27
+ * @typedef GenerateReportRequest
28
+ * @property {GenerateReportPlatform} [data]
37
29
  */
38
30
 
39
31
  /**
40
- * @typedef CnGenerateReport
41
- * @property {string} [affiliate_id]
42
- * @property {string} [end_date]
43
- * @property {CnGenerateReportFilters} [filters]
44
- * @property {GenerateReportFilters} [meta]
45
- * @property {number} [page]
46
- * @property {number} [pagesize]
47
- * @property {string} [report_id]
48
- * @property {string} [search]
49
- * @property {string} [search_type]
50
- * @property {string} [start_date]
32
+ * @typedef Page
33
+ * @property {number} [item_total]
34
+ * @property {string} [next_id]
35
+ * @property {boolean} [has_previous]
36
+ * @property {boolean} [has_next]
37
+ * @property {number} [current]
38
+ * @property {string} type
39
+ * @property {number} [size]
51
40
  */
52
41
 
53
42
  /**
54
- * @typedef CnGenerateReportFilters
55
- * @property {string[]} [channel_of_issuance]
56
- * @property {string[]} [ordering_channel]
57
- * @property {string[]} [staff_id]
58
- * @property {number[]} [store_id]
59
- * @property {string[]} [types_of_transaction]
60
- * @property {string[]} [utilisation]
43
+ * @typedef Currency
44
+ * @property {string} [code]
45
+ * @property {string} [symbol]
46
+ * @property {string} [name]
61
47
  */
62
48
 
63
49
  /**
64
- * @typedef CnGenerateReportItems
65
- * @property {string} [credit_note_number]
66
- * @property {string} [date_issued]
67
- * @property {string} [expiry_date]
68
- * @property {string} [invoice_number]
69
- * @property {string} [order_id]
70
- * @property {string} [shipment_id]
71
- * @property {string} [status]
72
- * @property {number} [total_amount]
50
+ * @typedef GenerateReportJson
51
+ * @property {string[][]} [items]
52
+ * @property {Page} [page]
53
+ * @property {string} [end_date]
54
+ * @property {string[]} [headers]
55
+ * @property {string} [start_date]
56
+ * @property {number} [item_count]
73
57
  */
74
58
 
75
59
  /**
76
- * @typedef CnReferenceNumber
77
- * @property {string} [cn_reference_number]
60
+ * @typedef Error
61
+ * @property {string} [reason]
62
+ * @property {boolean} [success]
78
63
  */
79
64
 
80
65
  /**
81
- * @typedef CreateSellerCreditNoteConfig
82
- * @property {string} [affiliate_id]
83
- * @property {string} [currency_type]
84
- * @property {boolean} [is_cn_as_refund_method]
85
- * @property {CreditNoteConfigNotificationEvents} [notification_events]
86
- * @property {string[]} [ordering_channel]
87
- * @property {string} [sales_channel_name]
88
- * @property {number} [seller_id]
89
- * @property {string[]} [slug_values]
90
- * @property {string[]} [source_channel]
91
- * @property {number} [validity]
66
+ * @typedef DownloadReport
67
+ * @property {number} [page]
68
+ * @property {number} [pagesize]
69
+ * @property {string} [start_date]
70
+ * @property {string} [end_date]
92
71
  */
93
72
 
94
73
  /**
95
- * @typedef CreateSellerCreditNoteConfigRequest
96
- * @property {CreateSellerCreditNoteConfig} [data]
74
+ * @typedef DownloadReportItems
75
+ * @property {string} [start_date]
76
+ * @property {string} [end_date]
77
+ * @property {GenerateReportMeta} [meta]
78
+ * @property {string} [report_id]
79
+ * @property {GenerateReportFilters} [filters]
80
+ * @property {string} [type_of_request]
97
81
  */
98
82
 
99
83
  /**
100
- * @typedef CreateSellerCreditNoteConfigResponse
101
- * @property {string} [message]
102
- * @property {boolean} [success]
84
+ * @typedef DownloadReportList
85
+ * @property {DownloadReportItems[]} [items]
86
+ * @property {Page} [page]
87
+ * @property {number} [item_count]
103
88
  */
104
89
 
105
90
  /**
106
- * @typedef CreditlineDataPlatformPayload
107
- * @property {string} [end_end]
108
- * @property {number} [page]
109
- * @property {number} [pagesize]
110
- * @property {string} [seller_id]
111
- * @property {string} [start_end]
91
+ * @typedef GetEngineData
92
+ * @property {string} [table_name]
93
+ * @property {string[]} [project]
94
+ * @property {Object} [filters]
112
95
  */
113
96
 
114
97
  /**
115
- * @typedef CreditlineDataPlatformRequest
116
- * @property {CreditlineDataPlatformPayload} [data]
98
+ * @typedef GetEngineRequest
99
+ * @property {GetEngineData} [data]
117
100
  */
118
101
 
119
102
  /**
120
- * @typedef CreditlineDataPlatformResponse
121
- * @property {number} [code]
122
- * @property {string[]} [headers]
123
- * @property {number} [item_count]
103
+ * @typedef GetEngineResponse
104
+ * @property {boolean} [success]
124
105
  * @property {Object[]} [items]
125
- * @property {string} [message]
126
106
  * @property {Page} [page]
127
- * @property {boolean} [show_mr]
107
+ * @property {number} [item_count]
128
108
  */
129
109
 
130
110
  /**
131
- * @typedef CreditNoteConfigNotificationEvents
132
- * @property {number} [expiration_reminder_to_customer]
111
+ * @typedef GetReason
112
+ * @property {string} [reason_type]
133
113
  */
134
114
 
135
115
  /**
136
- * @typedef CreditNoteDetails
137
- * @property {number} [available_cn_balance]
138
- * @property {number} [cn_amount]
139
- * @property {CnDetails} [cn_details]
140
- * @property {string} [cn_reference_number]
141
- * @property {string} [cn_status]
142
- * @property {string} [customer_mobile_number]
143
- * @property {RedemptionDetails[]} [redemption_details]
144
- * @property {number} [remaining_cn_amount]
116
+ * @typedef GetReasonRequest
117
+ * @property {GetReason} [data]
145
118
  */
146
119
 
147
120
  /**
148
- * @typedef CreditNoteDetailsRequest
149
- * @property {CnReferenceNumber} [data]
121
+ * @typedef ReasonItem
122
+ * @property {string} [id]
123
+ * @property {string} [name]
124
+ * @property {string} [display_name]
150
125
  */
151
126
 
152
127
  /**
153
- * @typedef CreditNoteDetailsResponse
154
- * @property {CreditNoteDetails} [data]
128
+ * @typedef GetReasonResponse
155
129
  * @property {boolean} [success]
130
+ * @property {ReasonItem[]} [item_list]
131
+ * @property {number} [item_count]
132
+ * @property {Page} [page]
156
133
  */
157
134
 
158
135
  /**
159
- * @typedef Currency
160
- * @property {string} [code]
161
- * @property {string} [name]
162
- * @property {string} [symbol]
136
+ * @typedef GetReportListData
137
+ * @property {string} [role_name]
138
+ * @property {boolean} [listing_enabled]
163
139
  */
164
140
 
165
141
  /**
166
- * @typedef DeleteConfig
167
- * @property {string} [affiliate_id]
168
- * @property {number} [seller_id]
169
- * @property {string[]} [slug_values]
142
+ * @typedef GetReportListRequest
143
+ * @property {GetReportListData} [data]
170
144
  */
171
145
 
172
146
  /**
173
- * @typedef DeleteConfigRequest
174
- * @property {DeleteConfig} [data]
147
+ * @typedef GetAffiliate
148
+ * @property {number} [company_id]
175
149
  */
176
150
 
177
151
  /**
178
- * @typedef DeleteConfigResponse
179
- * @property {string} [message]
152
+ * @typedef GetReportListResponse
153
+ * @property {boolean} [success]
154
+ * @property {ReportItem[]} [items]
155
+ * @property {Page} [page]
156
+ * @property {number} [total_count]
157
+ */
158
+
159
+ /**
160
+ * @typedef ReportItem
161
+ * @property {string} [id]
162
+ * @property {string} [name]
163
+ * @property {string} [description]
164
+ * @property {string[]} [allowed_filters]
165
+ * @property {Object} [config_meta]
166
+ * @property {string} [report_type]
167
+ * @property {string} [display_date]
168
+ */
169
+
170
+ /**
171
+ * @typedef GetAffiliateResponse
180
172
  * @property {boolean} [success]
173
+ * @property {Object[]} [docs]
181
174
  */
182
175
 
183
176
  /**
@@ -190,12 +183,6 @@ const Joi = require("joi");
190
183
  * @property {DownloadCreditDebitNote} [data]
191
184
  */
192
185
 
193
- /**
194
- * @typedef DownloadCreditDebitNoteResponse
195
- * @property {DownloadCreditDebitNoteResponseData[]} [data]
196
- * @property {boolean} [success]
197
- */
198
-
199
186
  /**
200
187
  * @typedef DownloadCreditDebitNoteResponseData
201
188
  * @property {string} [id]
@@ -203,544 +190,558 @@ const Joi = require("joi");
203
190
  */
204
191
 
205
192
  /**
206
- * @typedef DownloadReport
207
- * @property {string} [end_date]
208
- * @property {number} [page]
209
- * @property {number} [pagesize]
210
- * @property {string} [start_date]
211
- */
212
-
213
- /**
214
- * @typedef DownloadReportCustomerCnRequest
215
- * @property {CnDownloadReport} [data]
193
+ * @typedef DownloadCreditDebitNoteResponse
194
+ * @property {boolean} [success]
195
+ * @property {DownloadCreditDebitNoteResponseData[]} [data]
216
196
  */
217
197
 
218
198
  /**
219
- * @typedef DownloadReportCustomerCnResponse
220
- * @property {DownloadReportResponseData[]} [data]
199
+ * @typedef PaymentProcessPayload
200
+ * @property {string} [platform]
201
+ * @property {string} [amount]
202
+ * @property {string} [transaction_type]
203
+ * @property {string} [source_reference]
204
+ * @property {string} [total_amount]
205
+ * @property {Object} [meta]
206
+ * @property {string} [currency]
207
+ * @property {string} [seller_id]
208
+ * @property {string} [mode_of_payment]
209
+ * @property {string} [invoice_number]
221
210
  */
222
211
 
223
212
  /**
224
- * @typedef DownloadReportItems
225
- * @property {string} [end_date]
226
- * @property {GenerateReportFilters} [filters]
227
- * @property {GenerateReportMeta} [meta]
228
- * @property {string} [report_id]
229
- * @property {string} [start_date]
230
- * @property {string} [type_of_request]
213
+ * @typedef PaymentProcessRequest
214
+ * @property {PaymentProcessPayload} [data]
231
215
  */
232
216
 
233
217
  /**
234
- * @typedef DownloadReportList
235
- * @property {number} [item_count]
236
- * @property {DownloadReportItems[]} [items]
237
- * @property {Page} [page]
238
- */
239
-
240
- /**
241
- * @typedef DownloadReportResponseData
242
- * @property {string} [created_at]
243
- * @property {string} [display_name]
244
- * @property {string} [download_link]
245
- * @property {string} [end_date]
246
- * @property {Object} [filters]
247
- * @property {string} [full_name]
218
+ * @typedef PaymentProcessResponse
219
+ * @property {number} [code]
220
+ * @property {string} [message]
248
221
  * @property {Object} [meta]
249
- * @property {string} [msg]
250
- * @property {string} [report_config_id]
251
- * @property {string} [report_name]
252
- * @property {Object} [request_dict]
253
- * @property {string} [requested_by]
254
- * @property {string} [start_date]
255
- * @property {string} [status]
256
- */
257
-
258
- /**
259
- * @typedef Error
260
- * @property {string} [reason]
261
- * @property {boolean} [success]
222
+ * @property {string} [transaction_id]
223
+ * @property {string} [redirect_url]
262
224
  */
263
225
 
264
226
  /**
265
- * @typedef GenerateReportCustomerCnRequest
266
- * @property {CnGenerateReport} [data]
227
+ * @typedef CreditlineDataPlatformPayload
228
+ * @property {number} [page]
229
+ * @property {string} [seller_id]
230
+ * @property {string} [end_end]
231
+ * @property {string} [start_end]
232
+ * @property {number} [pagesize]
267
233
  */
268
234
 
269
235
  /**
270
- * @typedef GenerateReportCustomerCnResponse
271
- * @property {GenerateReportCustomerCnResponseData} [data]
236
+ * @typedef CreditlineDataPlatformRequest
237
+ * @property {CreditlineDataPlatformPayload} [data]
272
238
  */
273
239
 
274
240
  /**
275
- * @typedef GenerateReportCustomerCnResponseData
276
- * @property {string[]} [allowed_filters]
277
- * @property {string} [end_date]
241
+ * @typedef CreditlineDataPlatformResponse
242
+ * @property {Object[]} [items]
243
+ * @property {number} [code]
244
+ * @property {boolean} [show_mr]
245
+ * @property {Page} [page]
246
+ * @property {string} [message]
278
247
  * @property {string[]} [headers]
279
248
  * @property {number} [item_count]
280
- * @property {CnGenerateReportItems[]} [items]
281
- * @property {Page} [page]
282
- * @property {string[]} [primary_headers]
283
- * @property {Object} [row_header_display_order]
284
- * @property {string} [start_date]
285
249
  */
286
250
 
287
251
  /**
288
- * @typedef GenerateReportFilters
289
- * @property {string[]} [brand]
290
- * @property {string[]} [channel]
291
- * @property {string[]} [company]
252
+ * @typedef IsCreditlinePayload
253
+ * @property {string} [seller_id]
292
254
  */
293
255
 
294
256
  /**
295
- * @typedef GenerateReportJson
296
- * @property {string} [end_date]
297
- * @property {string[]} [headers]
298
- * @property {number} [item_count]
299
- * @property {string[][]} [items]
300
- * @property {Page} [page]
301
- * @property {string} [start_date]
257
+ * @typedef IsCreditlinePlatformRequest
258
+ * @property {IsCreditlinePayload} [data]
302
259
  */
303
260
 
304
261
  /**
305
- * @typedef GenerateReportMeta
306
- * @property {string} [brand]
307
- * @property {string} [channel]
308
- * @property {string} [company]
262
+ * @typedef IsCreditlinePlatformResponse
263
+ * @property {boolean} [is_creditline_opted]
264
+ * @property {number} [code]
309
265
  */
310
266
 
311
267
  /**
312
- * @typedef GenerateReportPlatform
313
- * @property {string} [end_date]
314
- * @property {GenerateReportFilters} [filters]
315
- * @property {GenerateReportMeta} [meta]
316
- * @property {string} [report_id]
317
- * @property {string} [start_date]
268
+ * @typedef InvoiceTypePayloadData
269
+ * @property {boolean} [is_active]
318
270
  */
319
271
 
320
272
  /**
321
- * @typedef GenerateReportRequest
322
- * @property {GenerateReportPlatform} [data]
273
+ * @typedef InvoiceTypeRequest
274
+ * @property {InvoiceTypePayloadData} [data]
323
275
  */
324
276
 
325
277
  /**
326
- * @typedef GetAffiliate
327
- * @property {number} [company_id]
278
+ * @typedef InvoiceTypeResponseItems
279
+ * @property {string} [text]
280
+ * @property {string} [value]
328
281
  */
329
282
 
330
283
  /**
331
- * @typedef GetAffiliateResponse
332
- * @property {Object[]} [docs]
284
+ * @typedef InvoiceTypeResponse
333
285
  * @property {boolean} [success]
286
+ * @property {InvoiceTypeResponseItems[]} [invoice_type_list]
287
+ * @property {InvoiceTypeResponseItems[]} [payment_status_list]
334
288
  */
335
289
 
336
290
  /**
337
- * @typedef GetCnConfigRequest
338
- * @property {DeleteConfig} [data]
291
+ * @typedef InoviceListingPayloadDataFilters
292
+ * @property {string[]} [payment_status]
293
+ * @property {string[]} [invoice_type]
294
+ * @property {string[]} [company_id]
339
295
  */
340
296
 
341
297
  /**
342
- * @typedef GetCnConfigResponse
343
- * @property {GetCnConfigResponseData} [data]
344
- * @property {boolean} [success]
298
+ * @typedef InvoiceListingPayloadData
299
+ * @property {number} [page_size]
300
+ * @property {number} [page]
301
+ * @property {string} [start_date]
302
+ * @property {string} [end_date]
303
+ * @property {string} [search]
304
+ * @property {InoviceListingPayloadDataFilters} [filters]
345
305
  */
346
306
 
347
307
  /**
348
- * @typedef GetCnConfigResponseData
349
- * @property {string} [affiliate_id]
350
- * @property {string} [currency_type]
351
- * @property {boolean} [is_cn_as_refund_method]
352
- * @property {GetCnConfigResponseMeta} [meta]
353
- * @property {CreditNoteConfigNotificationEvents} [notification_events]
354
- * @property {string[]} [redemption_ordering_channel]
355
- * @property {number} [seller_id]
356
- * @property {number} [validity]
308
+ * @typedef InvoiceListingRequest
309
+ * @property {InvoiceListingPayloadData} [data]
357
310
  */
358
311
 
359
312
  /**
360
- * @typedef GetCnConfigResponseMeta
361
- * @property {string} [reason]
362
- * @property {string[]} [source_channel]
313
+ * @typedef UnpaidInvoiceDataItems
314
+ * @property {number} [total_unpaid_invoice_count]
315
+ * @property {string} [currency]
316
+ * @property {number} [total_unpaid_amount]
363
317
  */
364
318
 
365
319
  /**
366
- * @typedef GetCustomerCreditBalance
367
- * @property {string} [affiliate_id]
368
- * @property {string} [customer_mobile_number]
369
- * @property {number} [seller_id]
320
+ * @typedef InvoiceListingResponseItems
321
+ * @property {string} [amount]
322
+ * @property {string} [company]
323
+ * @property {string} [status]
324
+ * @property {string} [due_date]
325
+ * @property {string} [invoice_date]
326
+ * @property {string} [invoice_type]
327
+ * @property {string} [period]
328
+ * @property {string} [invoice_number]
329
+ * @property {boolean} [is_downloadable]
330
+ * @property {string} [invoice_id]
331
+ * @property {Currency} [currency]
370
332
  */
371
333
 
372
334
  /**
373
- * @typedef GetCustomerCreditBalanceRequest
374
- * @property {GetCustomerCreditBalance} [data]
335
+ * @typedef InvoiceListingResponse
336
+ * @property {UnpaidInvoiceDataItems} [unpaid_invoice_data]
337
+ * @property {InvoiceListingResponseItems[]} [items]
338
+ * @property {Page} [page]
339
+ * @property {number} [item_count]
375
340
  */
376
341
 
377
342
  /**
378
- * @typedef GetCustomerCreditBalanceResponse
379
- * @property {GetCustomerCreditBalanceResponseData} [data]
380
- * @property {boolean} [success]
343
+ * @typedef InvoicePdfPayloadData
344
+ * @property {string[]} [invoice_number]
381
345
  */
382
346
 
383
347
  /**
384
- * @typedef GetCustomerCreditBalanceResponseData
385
- * @property {string} [customer_mobile_number]
386
- * @property {number} [total_credited_balance]
348
+ * @typedef InvoicePdfRequest
349
+ * @property {InvoicePdfPayloadData} [data]
387
350
  */
388
351
 
389
352
  /**
390
- * @typedef GetEngineData
391
- * @property {Object} [filters]
392
- * @property {string[]} [project]
393
- * @property {string} [table_name]
353
+ * @typedef InvoicePdfResponse
354
+ * @property {boolean} [success]
355
+ * @property {string[]} [data]
356
+ * @property {string[]} [error]
394
357
  */
395
358
 
396
359
  /**
397
- * @typedef GetEngineRequest
398
- * @property {GetEngineData} [data]
360
+ * @typedef IsCnRefundMethodData
361
+ * @property {string} [affiliate_id]
362
+ * @property {boolean} [toggle_edit_required]
363
+ * @property {number} [seller_id]
399
364
  */
400
365
 
401
366
  /**
402
- * @typedef GetEngineResponse
403
- * @property {number} [item_count]
404
- * @property {Object[]} [items]
405
- * @property {Page} [page]
406
- * @property {boolean} [success]
367
+ * @typedef IsCnRefundMethodRequest
368
+ * @property {IsCnRefundMethodData} [data]
407
369
  */
408
370
 
409
371
  /**
410
- * @typedef GetPdfUrlViewRequest
411
- * @property {CnReferenceNumber} [data]
372
+ * @typedef IsCnRefundMethodResponseData
373
+ * @property {boolean} [is_first_time_user]
412
374
  */
413
375
 
414
376
  /**
415
- * @typedef GetPdfUrlViewResponse
416
- * @property {GetPdfUrlViewResponseData} [data]
377
+ * @typedef IsCnRefundMethodResponse
417
378
  * @property {boolean} [success]
379
+ * @property {IsCnRefundMethodResponseData} [data]
418
380
  */
419
381
 
420
382
  /**
421
- * @typedef GetPdfUrlViewResponseData
422
- * @property {string} [cn_reference_number]
423
- * @property {string} [s3_pdf_link]
383
+ * @typedef CreditNoteConfigNotificationEvents
384
+ * @property {number} [expiration_reminder_to_customer]
424
385
  */
425
386
 
426
387
  /**
427
- * @typedef GetReason
428
- * @property {string} [reason_type]
388
+ * @typedef CreateSellerCreditNoteConfig
389
+ * @property {boolean} [is_cn_as_refund_method]
390
+ * @property {string} [affiliate_id]
391
+ * @property {string[]} [source_channel]
392
+ * @property {number} [seller_id]
393
+ * @property {CreditNoteConfigNotificationEvents} [notification_events]
394
+ * @property {string} [sales_channel_name]
395
+ * @property {string[]} [ordering_channel]
396
+ * @property {number} [validity]
397
+ * @property {string} [currency_type]
398
+ * @property {string[]} [slug_values]
429
399
  */
430
400
 
431
401
  /**
432
- * @typedef GetReasonRequest
433
- * @property {GetReason} [data]
402
+ * @typedef CreateSellerCreditNoteConfigRequest
403
+ * @property {CreateSellerCreditNoteConfig} [data]
434
404
  */
435
405
 
436
406
  /**
437
- * @typedef GetReasonResponse
438
- * @property {number} [item_count]
439
- * @property {ReasonItem[]} [item_list]
440
- * @property {Page} [page]
407
+ * @typedef CreateSellerCreditNoteConfigResponse
441
408
  * @property {boolean} [success]
409
+ * @property {string} [message]
442
410
  */
443
411
 
444
412
  /**
445
- * @typedef GetReportingFilters
446
- * @property {Object[]} [options]
447
- * @property {string} [text]
448
- * @property {string} [type]
449
- * @property {string} [value]
413
+ * @typedef DeleteConfig
414
+ * @property {string} [affiliate_id]
415
+ * @property {string[]} [slug_values]
416
+ * @property {number} [seller_id]
450
417
  */
451
418
 
452
419
  /**
453
- * @typedef GetReportingFiltersResponse
454
- * @property {GetReportingNestedFilters[]} [filters]
455
- * @property {GetReportingFilters} [search]
456
- * @property {GetReportingFilters} [status]
420
+ * @typedef DeleteConfigRequest
421
+ * @property {DeleteConfig} [data]
457
422
  */
458
423
 
459
424
  /**
460
- * @typedef GetReportingNestedFilters
461
- * @property {Object[]} [options]
462
- * @property {string} [placeholder_text]
463
- * @property {boolean} [required]
464
- * @property {string} [text]
465
- * @property {string} [type]
466
- * @property {string} [value]
425
+ * @typedef DeleteConfigResponse
426
+ * @property {boolean} [success]
427
+ * @property {string} [message]
467
428
  */
468
429
 
469
430
  /**
470
- * @typedef GetReportListData
471
- * @property {boolean} [listing_enabled]
472
- * @property {string} [role_name]
431
+ * @typedef ChannelDisplayName
432
+ * @property {string} [platform_pos]
473
433
  */
474
434
 
475
435
  /**
476
- * @typedef GetReportListRequest
477
- * @property {GetReportListData} [data]
478
- */
479
-
480
- /**
481
- * @typedef GetReportListResponse
482
- * @property {ReportItem[]} [items]
483
- * @property {Page} [page]
436
+ * @typedef ChannelDisplayNameResponse
484
437
  * @property {boolean} [success]
485
- * @property {number} [total_count]
438
+ * @property {ChannelDisplayName} [data]
486
439
  */
487
440
 
488
441
  /**
489
- * @typedef InoviceListingPayloadDataFilters
490
- * @property {string[]} [company_id]
491
- * @property {string[]} [invoice_type]
492
- * @property {string[]} [payment_status]
442
+ * @typedef CnReferenceNumber
443
+ * @property {string} [cn_reference_number]
493
444
  */
494
445
 
495
446
  /**
496
- * @typedef InvoiceActivityLogError
497
- * @property {string} [reason]
447
+ * @typedef GetPdfUrlViewRequest
448
+ * @property {CnReferenceNumber} [data]
498
449
  */
499
450
 
500
451
  /**
501
- * @typedef InvoiceActivityLogsResponse
502
- * @property {InvoiceActivityLogsResponseData[]} [data]
452
+ * @typedef GetPdfUrlViewResponseData
453
+ * @property {string} [s3_pdf_link]
454
+ * @property {string} [cn_reference_number]
503
455
  */
504
456
 
505
457
  /**
506
- * @typedef InvoiceActivityLogsResponseData
507
- * @property {boolean} [is_resolved]
508
- * @property {number} [max_retry_attempts]
509
- * @property {string} [performed_by]
510
- * @property {string} [reason]
511
- * @property {number} [retry_attempts]
512
- * @property {string} [status]
458
+ * @typedef GetPdfUrlViewResponse
459
+ * @property {boolean} [success]
460
+ * @property {GetPdfUrlViewResponseData} [data]
513
461
  */
514
462
 
515
463
  /**
516
- * @typedef InvoiceListingPayloadData
517
- * @property {string} [end_date]
518
- * @property {InoviceListingPayloadDataFilters} [filters]
519
- * @property {number} [page]
520
- * @property {number} [page_size]
521
- * @property {string} [search]
522
- * @property {string} [start_date]
464
+ * @typedef CreditNoteDetailsRequest
465
+ * @property {CnReferenceNumber} [data]
523
466
  */
524
467
 
525
468
  /**
526
- * @typedef InvoiceListingRequest
527
- * @property {InvoiceListingPayloadData} [data]
469
+ * @typedef CnDetails
470
+ * @property {string} [staff_id]
471
+ * @property {string} [expiry_date]
472
+ * @property {string} [channel_of_issuance]
473
+ * @property {string} [order_id]
474
+ * @property {string} [date_issued]
475
+ * @property {string} [ordering_channel]
476
+ * @property {string} [shipment_id]
477
+ * @property {string} [store_id]
478
+ * @property {string} [invoice_number]
528
479
  */
529
480
 
530
481
  /**
531
- * @typedef InvoiceListingResponse
532
- * @property {number} [item_count]
533
- * @property {InvoiceListingResponseItems[]} [items]
534
- * @property {Page} [page]
535
- * @property {UnpaidInvoiceDataItems} [unpaid_invoice_data]
482
+ * @typedef RedemptionDetails
483
+ * @property {string} [staff_id]
484
+ * @property {string} [created_at]
485
+ * @property {string} [order_id]
486
+ * @property {string} [store_id]
487
+ * @property {string} [shipment_id]
488
+ * @property {string} [ordering_channel]
489
+ * @property {number} [amount_debited]
490
+ * @property {string} [invoice_number]
536
491
  */
537
492
 
538
493
  /**
539
- * @typedef InvoiceListingResponseItems
540
- * @property {string} [amount]
541
- * @property {string} [company]
542
- * @property {Currency} [currency]
543
- * @property {string} [due_date]
544
- * @property {string} [invoice_date]
545
- * @property {string} [invoice_id]
546
- * @property {string} [invoice_number]
547
- * @property {string} [invoice_type]
548
- * @property {boolean} [is_downloadable]
549
- * @property {string} [period]
550
- * @property {string} [status]
494
+ * @typedef CreditNoteDetails
495
+ * @property {string} [cn_status]
496
+ * @property {string} [customer_mobile_number]
497
+ * @property {string} [cn_reference_number]
498
+ * @property {CnDetails} [cn_details]
499
+ * @property {RedemptionDetails[]} [redemption_details]
500
+ * @property {number} [remaining_cn_amount]
501
+ * @property {number} [available_cn_balance]
502
+ * @property {number} [cn_amount]
551
503
  */
552
504
 
553
505
  /**
554
- * @typedef InvoicePaymentDetailsResponse
555
- * @property {InvoicePaymentDetailsResponseData} [data]
556
- * @property {boolean} [payment_details_visible]
506
+ * @typedef CreditNoteDetailsResponse
557
507
  * @property {boolean} [success]
508
+ * @property {CreditNoteDetails} [data]
558
509
  */
559
510
 
560
511
  /**
561
- * @typedef InvoicePaymentDetailsResponseData
562
- * @property {Object[]} [failed_attempts_details]
563
- * @property {PaidInvoicePaymentDetail[]} [paid_invoice_payment_details]
512
+ * @typedef GetCustomerCreditBalance
513
+ * @property {string} [affiliate_id]
514
+ * @property {number} [seller_id]
515
+ * @property {string} [customer_mobile_number]
564
516
  */
565
517
 
566
518
  /**
567
- * @typedef InvoicePdfPayloadData
568
- * @property {string[]} [invoice_number]
519
+ * @typedef GetCustomerCreditBalanceRequest
520
+ * @property {GetCustomerCreditBalance} [data]
569
521
  */
570
522
 
571
523
  /**
572
- * @typedef InvoicePdfRequest
573
- * @property {InvoicePdfPayloadData} [data]
524
+ * @typedef GetCustomerCreditBalanceResponseData
525
+ * @property {string} [customer_mobile_number]
526
+ * @property {number} [total_credited_balance]
574
527
  */
575
528
 
576
529
  /**
577
- * @typedef InvoicePdfResponse
578
- * @property {string[]} [data]
579
- * @property {string[]} [error]
530
+ * @typedef GetCustomerCreditBalanceResponse
580
531
  * @property {boolean} [success]
532
+ * @property {GetCustomerCreditBalanceResponseData} [data]
581
533
  */
582
534
 
583
535
  /**
584
- * @typedef InvoiceTypePayloadData
585
- * @property {boolean} [is_active]
536
+ * @typedef GetCnConfigRequest
537
+ * @property {DeleteConfig} [data]
586
538
  */
587
539
 
588
540
  /**
589
- * @typedef InvoiceTypeRequest
590
- * @property {InvoiceTypePayloadData} [data]
541
+ * @typedef GetCnConfigResponseMeta
542
+ * @property {string} [reason]
543
+ * @property {string[]} [source_channel]
591
544
  */
592
545
 
593
546
  /**
594
- * @typedef InvoiceTypeResponse
595
- * @property {InvoiceTypeResponseItems[]} [invoice_type_list]
596
- * @property {InvoiceTypeResponseItems[]} [payment_status_list]
547
+ * @typedef GetCnConfigResponseData
548
+ * @property {boolean} [is_cn_as_refund_method]
549
+ * @property {string} [affiliate_id]
550
+ * @property {GetCnConfigResponseMeta} [meta]
551
+ * @property {number} [seller_id]
552
+ * @property {CreditNoteConfigNotificationEvents} [notification_events]
553
+ * @property {number} [validity]
554
+ * @property {string[]} [redemption_ordering_channel]
555
+ * @property {string} [currency_type]
556
+ */
557
+
558
+ /**
559
+ * @typedef GetCnConfigResponse
597
560
  * @property {boolean} [success]
561
+ * @property {GetCnConfigResponseData} [data]
598
562
  */
599
563
 
600
564
  /**
601
- * @typedef InvoiceTypeResponseItems
602
- * @property {string} [text]
603
- * @property {string} [value]
565
+ * @typedef CnGenerateReportFilters
566
+ * @property {string[]} [staff_id]
567
+ * @property {string[]} [channel_of_issuance]
568
+ * @property {string[]} [utilisation]
569
+ * @property {string[]} [ordering_channel]
570
+ * @property {number[]} [store_id]
571
+ * @property {string[]} [types_of_transaction]
604
572
  */
605
573
 
606
574
  /**
607
- * @typedef IsCnRefundMethodData
575
+ * @typedef CnGenerateReport
576
+ * @property {number} [page]
577
+ * @property {string} [end_date]
578
+ * @property {number} [pagesize]
579
+ * @property {CnGenerateReportFilters} [filters]
608
580
  * @property {string} [affiliate_id]
609
- * @property {number} [seller_id]
610
- * @property {boolean} [toggle_edit_required]
581
+ * @property {GenerateReportFilters} [meta]
582
+ * @property {string} [search]
583
+ * @property {string} [report_id]
584
+ * @property {string} [search_type]
585
+ * @property {string} [start_date]
611
586
  */
612
587
 
613
588
  /**
614
- * @typedef IsCnRefundMethodRequest
615
- * @property {IsCnRefundMethodData} [data]
589
+ * @typedef GenerateReportCustomerCnRequest
590
+ * @property {CnGenerateReport} [data]
616
591
  */
617
592
 
618
593
  /**
619
- * @typedef IsCnRefundMethodResponse
620
- * @property {IsCnRefundMethodResponseData} [data]
621
- * @property {boolean} [success]
594
+ * @typedef CnGenerateReportItems
595
+ * @property {string} [expiry_date]
596
+ * @property {string} [status]
597
+ * @property {number} [total_amount]
598
+ * @property {string} [order_id]
599
+ * @property {string} [date_issued]
600
+ * @property {string} [shipment_id]
601
+ * @property {string} [invoice_number]
602
+ * @property {string} [credit_note_number]
622
603
  */
623
604
 
624
605
  /**
625
- * @typedef IsCnRefundMethodResponseData
626
- * @property {boolean} [is_first_time_user]
606
+ * @typedef GenerateReportCustomerCnResponseData
607
+ * @property {CnGenerateReportItems[]} [items]
608
+ * @property {Object} [row_header_display_order]
609
+ * @property {string} [end_date]
610
+ * @property {Page} [page]
611
+ * @property {string[]} [headers]
612
+ * @property {string[]} [primary_headers]
613
+ * @property {string[]} [allowed_filters]
614
+ * @property {string} [start_date]
615
+ * @property {number} [item_count]
627
616
  */
628
617
 
629
618
  /**
630
- * @typedef IsCreditlinePayload
631
- * @property {string} [seller_id]
619
+ * @typedef GenerateReportCustomerCnResponse
620
+ * @property {GenerateReportCustomerCnResponseData} [data]
632
621
  */
633
622
 
634
623
  /**
635
- * @typedef IsCreditlinePlatformRequest
636
- * @property {IsCreditlinePayload} [data]
624
+ * @typedef CnDownloadReport
625
+ * @property {number} [page]
626
+ * @property {string} [start_date]
627
+ * @property {string} [end_date]
628
+ * @property {string} [affiliate_id]
629
+ * @property {string} [search]
630
+ * @property {string[]} [status]
631
+ * @property {string} [search_type]
632
+ * @property {number} [pagesize]
637
633
  */
638
634
 
639
635
  /**
640
- * @typedef IsCreditlinePlatformResponse
641
- * @property {number} [code]
642
- * @property {boolean} [is_creditline_opted]
636
+ * @typedef DownloadReportCustomerCnRequest
637
+ * @property {CnDownloadReport} [data]
643
638
  */
644
639
 
645
640
  /**
646
- * @typedef Page
647
- * @property {number} [current]
648
- * @property {boolean} [has_next]
649
- * @property {boolean} [has_previous]
650
- * @property {number} [item_total]
651
- * @property {string} [next_id]
652
- * @property {number} [size]
653
- * @property {string} type
641
+ * @typedef DownloadReportResponseData
642
+ * @property {string} [report_config_id]
643
+ * @property {string} [full_name]
644
+ * @property {string} [requested_by]
645
+ * @property {string} [start_date]
646
+ * @property {string} [end_date]
647
+ * @property {Object} [request_dict]
648
+ * @property {string} [download_link]
649
+ * @property {string} [created_at]
650
+ * @property {Object} [meta]
651
+ * @property {string} [msg]
652
+ * @property {string} [report_name]
653
+ * @property {string} [status]
654
+ * @property {string} [display_name]
655
+ * @property {Object} [filters]
654
656
  */
655
657
 
656
658
  /**
657
- * @typedef PaidInvoicePaymentDetail
658
- * @property {number} [amount]
659
- * @property {string} [date_of_payment]
660
- * @property {PaymentDetail[]} [payment_details]
659
+ * @typedef DownloadReportCustomerCnResponse
660
+ * @property {DownloadReportResponseData[]} [data]
661
661
  */
662
662
 
663
663
  /**
664
- * @typedef PaymentDetail
665
- * @property {string} [display_name]
664
+ * @typedef GetReportingFilters
665
+ * @property {string} [text]
666
+ * @property {string} [type]
667
+ * @property {Object[]} [options]
666
668
  * @property {string} [value]
667
669
  */
668
670
 
669
671
  /**
670
- * @typedef PaymentProcessPayload
671
- * @property {string} [amount]
672
- * @property {string} [currency]
673
- * @property {string} [invoice_number]
674
- * @property {Object} [meta]
675
- * @property {string} [mode_of_payment]
676
- * @property {string} [platform]
677
- * @property {string} [seller_id]
678
- * @property {string} [source_reference]
679
- * @property {string} [total_amount]
680
- * @property {string} [transaction_type]
672
+ * @typedef GetReportingNestedFilters
673
+ * @property {string} [text]
674
+ * @property {Object[]} [options]
675
+ * @property {boolean} [required]
676
+ * @property {string} [placeholder_text]
677
+ * @property {string} [type]
678
+ * @property {string} [value]
681
679
  */
682
680
 
683
681
  /**
684
- * @typedef PaymentProcessRequest
685
- * @property {PaymentProcessPayload} [data]
682
+ * @typedef GetReportingFiltersResponse
683
+ * @property {GetReportingFilters} [search]
684
+ * @property {GetReportingNestedFilters[]} [filters]
685
+ * @property {GetReportingFilters} [status]
686
686
  */
687
687
 
688
688
  /**
689
- * @typedef PaymentProcessResponse
690
- * @property {number} [code]
691
- * @property {string} [message]
692
- * @property {Object} [meta]
693
- * @property {string} [redirect_url]
694
- * @property {string} [transaction_id]
689
+ * @typedef PaymentDetail
690
+ * @property {string} [display_name]
691
+ * @property {string} [value]
695
692
  */
696
693
 
697
694
  /**
698
- * @typedef ReasonItem
699
- * @property {string} [display_name]
700
- * @property {string} [id]
701
- * @property {string} [name]
695
+ * @typedef PaidInvoicePaymentDetail
696
+ * @property {PaymentDetail[]} [payment_details]
697
+ * @property {string} [date_of_payment]
698
+ * @property {number} [amount]
702
699
  */
703
700
 
704
701
  /**
705
- * @typedef RedemptionDetails
706
- * @property {number} [amount_debited]
707
- * @property {string} [created_at]
708
- * @property {string} [invoice_number]
709
- * @property {string} [order_id]
710
- * @property {string} [ordering_channel]
711
- * @property {string} [shipment_id]
712
- * @property {string} [staff_id]
713
- * @property {string} [store_id]
702
+ * @typedef InvoicePaymentDetailsResponseData
703
+ * @property {PaidInvoicePaymentDetail[]} [paid_invoice_payment_details]
704
+ * @property {Object[]} [failed_attempts_details]
714
705
  */
715
706
 
716
707
  /**
717
- * @typedef ReportItem
718
- * @property {string[]} [allowed_filters]
719
- * @property {Object} [config_meta]
720
- * @property {string} [description]
721
- * @property {string} [display_date]
722
- * @property {string} [id]
723
- * @property {string} [name]
724
- * @property {string} [report_type]
708
+ * @typedef InvoicePaymentDetailsResponse
709
+ * @property {InvoicePaymentDetailsResponseData} [data]
710
+ * @property {boolean} [success]
711
+ * @property {boolean} [payment_details_visible]
725
712
  */
726
713
 
727
714
  /**
728
- * @typedef UnlockCreditNoteRequest
729
- * @property {UnlockCreditNoteRequestData} [data]
715
+ * @typedef InvoiceActivityLogsResponseData
716
+ * @property {string} [performed_by]
717
+ * @property {string} [status]
718
+ * @property {string} [reason]
719
+ * @property {boolean} [is_resolved]
720
+ * @property {number} [retry_attempts]
721
+ * @property {number} [max_retry_attempts]
722
+ */
723
+
724
+ /**
725
+ * @typedef InvoiceActivityLogsResponse
726
+ * @property {InvoiceActivityLogsResponseData[]} [data]
727
+ */
728
+
729
+ /**
730
+ * @typedef InvoiceActivityLogError
731
+ * @property {string} [reason]
730
732
  */
731
733
 
732
734
  /**
733
735
  * @typedef UnlockCreditNoteRequestData
734
- * @property {string} [description]
735
- * @property {string[]} [locked_credit_notes]
736
736
  * @property {string} [seller_id]
737
+ * @property {string[]} [locked_credit_notes]
737
738
  * @property {string} [unlock_reason]
739
+ * @property {string} [description]
738
740
  */
739
741
 
740
742
  /**
741
- * @typedef UnlockCreditNoteResponse
742
- * @property {UnlockCreditNoteResponseData} [data]
743
- * @property {boolean} [success]
743
+ * @typedef UnlockCreditNoteRequest
744
+ * @property {UnlockCreditNoteRequestData} [data]
744
745
  */
745
746
 
746
747
  /**
@@ -750,236 +751,230 @@ const Joi = require("joi");
750
751
  */
751
752
 
752
753
  /**
753
- * @typedef UnpaidInvoiceDataItems
754
- * @property {string} [currency]
755
- * @property {number} [total_unpaid_amount]
756
- * @property {number} [total_unpaid_invoice_count]
754
+ * @typedef UnlockCreditNoteResponse
755
+ * @property {boolean} [success]
756
+ * @property {UnlockCreditNoteResponseData} [data]
757
757
  */
758
758
 
759
759
  class FinancePlatformModel {
760
- /** @returns {ChannelDisplayName} */
761
- static ChannelDisplayName() {
760
+ /** @returns {GenerateReportMeta} */
761
+ static GenerateReportMeta() {
762
762
  return Joi.object({
763
- platform_pos: Joi.string().allow(""),
763
+ brand: Joi.string().allow(""),
764
+ company: Joi.string().allow(""),
765
+ channel: Joi.string().allow(""),
764
766
  });
765
767
  }
766
768
 
767
- /** @returns {ChannelDisplayNameResponse} */
768
- static ChannelDisplayNameResponse() {
769
+ /** @returns {GenerateReportFilters} */
770
+ static GenerateReportFilters() {
769
771
  return Joi.object({
770
- data: FinancePlatformModel.ChannelDisplayName(),
771
- success: Joi.boolean(),
772
+ brand: Joi.array().items(Joi.string().allow("")),
773
+ company: Joi.array().items(Joi.string().allow("")),
774
+ channel: Joi.array().items(Joi.string().allow("")),
772
775
  });
773
776
  }
774
777
 
775
- /** @returns {CnDetails} */
776
- static CnDetails() {
778
+ /** @returns {GenerateReportPlatform} */
779
+ static GenerateReportPlatform() {
777
780
  return Joi.object({
778
- channel_of_issuance: Joi.string().allow(""),
779
- date_issued: Joi.string().allow(""),
780
- expiry_date: Joi.string().allow(""),
781
- invoice_number: Joi.string().allow(""),
782
- order_id: Joi.string().allow(""),
783
- ordering_channel: Joi.string().allow(""),
784
- shipment_id: Joi.string().allow(""),
785
- staff_id: Joi.string().allow(""),
786
- store_id: Joi.string().allow(""),
781
+ start_date: Joi.string().allow(""),
782
+ end_date: Joi.string().allow(""),
783
+ meta: FinancePlatformModel.GenerateReportMeta(),
784
+ report_id: Joi.string().allow(""),
785
+ filters: FinancePlatformModel.GenerateReportFilters(),
786
+ });
787
+ }
788
+
789
+ /** @returns {GenerateReportRequest} */
790
+ static GenerateReportRequest() {
791
+ return Joi.object({
792
+ data: FinancePlatformModel.GenerateReportPlatform(),
793
+ });
794
+ }
795
+
796
+ /** @returns {Page} */
797
+ static Page() {
798
+ return Joi.object({
799
+ item_total: Joi.number(),
800
+ next_id: Joi.string().allow(""),
801
+ has_previous: Joi.boolean(),
802
+ has_next: Joi.boolean(),
803
+ current: Joi.number(),
804
+ type: Joi.string().allow("").required(),
805
+ size: Joi.number(),
806
+ });
807
+ }
808
+
809
+ /** @returns {Currency} */
810
+ static Currency() {
811
+ return Joi.object({
812
+ code: Joi.string().allow(""),
813
+ symbol: Joi.string().allow(""),
814
+ name: Joi.string().allow(""),
787
815
  });
788
816
  }
789
817
 
790
- /** @returns {CnDownloadReport} */
791
- static CnDownloadReport() {
818
+ /** @returns {GenerateReportJson} */
819
+ static GenerateReportJson() {
792
820
  return Joi.object({
793
- affiliate_id: Joi.string().allow(""),
821
+ items: Joi.array().items(Joi.array().items(Joi.string().allow(""))),
822
+ page: FinancePlatformModel.Page(),
794
823
  end_date: Joi.string().allow(""),
795
- page: Joi.number(),
796
- pagesize: Joi.number(),
797
- search: Joi.string().allow(""),
798
- search_type: Joi.string().allow(""),
824
+ headers: Joi.array().items(Joi.string().allow("")),
799
825
  start_date: Joi.string().allow(""),
800
- status: Joi.array().items(Joi.string().allow("")),
826
+ item_count: Joi.number(),
801
827
  });
802
828
  }
803
829
 
804
- /** @returns {CnGenerateReport} */
805
- static CnGenerateReport() {
830
+ /** @returns {Error} */
831
+ static Error() {
832
+ return Joi.object({
833
+ reason: Joi.string().allow(""),
834
+ success: Joi.boolean(),
835
+ });
836
+ }
837
+
838
+ /** @returns {DownloadReport} */
839
+ static DownloadReport() {
806
840
  return Joi.object({
807
- affiliate_id: Joi.string().allow(""),
808
- end_date: Joi.string().allow(""),
809
- filters: FinancePlatformModel.CnGenerateReportFilters(),
810
- meta: FinancePlatformModel.GenerateReportFilters(),
811
841
  page: Joi.number(),
812
842
  pagesize: Joi.number(),
813
- report_id: Joi.string().allow(""),
814
- search: Joi.string().allow(""),
815
- search_type: Joi.string().allow(""),
816
843
  start_date: Joi.string().allow(""),
844
+ end_date: Joi.string().allow(""),
817
845
  });
818
846
  }
819
847
 
820
- /** @returns {CnGenerateReportFilters} */
821
- static CnGenerateReportFilters() {
848
+ /** @returns {DownloadReportItems} */
849
+ static DownloadReportItems() {
822
850
  return Joi.object({
823
- channel_of_issuance: Joi.array().items(Joi.string().allow("")),
824
- ordering_channel: Joi.array().items(Joi.string().allow("")),
825
- staff_id: Joi.array().items(Joi.string().allow("")),
826
- store_id: Joi.array().items(Joi.number()),
827
- types_of_transaction: Joi.array().items(Joi.string().allow("")),
828
- utilisation: Joi.array().items(Joi.string().allow("")),
851
+ start_date: Joi.string().allow(""),
852
+ end_date: Joi.string().allow(""),
853
+ meta: FinancePlatformModel.GenerateReportMeta(),
854
+ report_id: Joi.string().allow(""),
855
+ filters: FinancePlatformModel.GenerateReportFilters(),
856
+ type_of_request: Joi.string().allow(""),
829
857
  });
830
858
  }
831
859
 
832
- /** @returns {CnGenerateReportItems} */
833
- static CnGenerateReportItems() {
860
+ /** @returns {DownloadReportList} */
861
+ static DownloadReportList() {
834
862
  return Joi.object({
835
- credit_note_number: Joi.string().allow(""),
836
- date_issued: Joi.string().allow(""),
837
- expiry_date: Joi.string().allow(""),
838
- invoice_number: Joi.string().allow(""),
839
- order_id: Joi.string().allow(""),
840
- shipment_id: Joi.string().allow(""),
841
- status: Joi.string().allow(""),
842
- total_amount: Joi.number(),
863
+ items: Joi.array().items(FinancePlatformModel.DownloadReportItems()),
864
+ page: FinancePlatformModel.Page(),
865
+ item_count: Joi.number(),
843
866
  });
844
867
  }
845
868
 
846
- /** @returns {CnReferenceNumber} */
847
- static CnReferenceNumber() {
869
+ /** @returns {GetEngineData} */
870
+ static GetEngineData() {
848
871
  return Joi.object({
849
- cn_reference_number: Joi.string().allow(""),
872
+ table_name: Joi.string().allow(""),
873
+ project: Joi.array().items(Joi.string().allow("")),
874
+ filters: Joi.any(),
850
875
  });
851
876
  }
852
877
 
853
- /** @returns {CreateSellerCreditNoteConfig} */
854
- static CreateSellerCreditNoteConfig() {
878
+ /** @returns {GetEngineRequest} */
879
+ static GetEngineRequest() {
855
880
  return Joi.object({
856
- affiliate_id: Joi.string().allow(""),
857
- currency_type: Joi.string().allow(""),
858
- is_cn_as_refund_method: Joi.boolean(),
859
- notification_events: FinancePlatformModel.CreditNoteConfigNotificationEvents(),
860
- ordering_channel: Joi.array().items(Joi.string().allow("")),
861
- sales_channel_name: Joi.string().allow(""),
862
- seller_id: Joi.number(),
863
- slug_values: Joi.array().items(Joi.string().allow("")),
864
- source_channel: Joi.array().items(Joi.string().allow("")),
865
- validity: Joi.number(),
881
+ data: FinancePlatformModel.GetEngineData(),
866
882
  });
867
883
  }
868
884
 
869
- /** @returns {CreateSellerCreditNoteConfigRequest} */
870
- static CreateSellerCreditNoteConfigRequest() {
885
+ /** @returns {GetEngineResponse} */
886
+ static GetEngineResponse() {
871
887
  return Joi.object({
872
- data: FinancePlatformModel.CreateSellerCreditNoteConfig(),
888
+ success: Joi.boolean(),
889
+ items: Joi.array().items(Joi.any()),
890
+ page: FinancePlatformModel.Page(),
891
+ item_count: Joi.number(),
873
892
  });
874
893
  }
875
894
 
876
- /** @returns {CreateSellerCreditNoteConfigResponse} */
877
- static CreateSellerCreditNoteConfigResponse() {
895
+ /** @returns {GetReason} */
896
+ static GetReason() {
878
897
  return Joi.object({
879
- message: Joi.string().allow(""),
880
- success: Joi.boolean(),
898
+ reason_type: Joi.string().allow(""),
881
899
  });
882
900
  }
883
901
 
884
- /** @returns {CreditlineDataPlatformPayload} */
885
- static CreditlineDataPlatformPayload() {
902
+ /** @returns {GetReasonRequest} */
903
+ static GetReasonRequest() {
886
904
  return Joi.object({
887
- end_end: Joi.string().allow(""),
888
- page: Joi.number(),
889
- pagesize: Joi.number(),
890
- seller_id: Joi.string().allow(""),
891
- start_end: Joi.string().allow(""),
905
+ data: FinancePlatformModel.GetReason(),
892
906
  });
893
907
  }
894
908
 
895
- /** @returns {CreditlineDataPlatformRequest} */
896
- static CreditlineDataPlatformRequest() {
909
+ /** @returns {ReasonItem} */
910
+ static ReasonItem() {
897
911
  return Joi.object({
898
- data: FinancePlatformModel.CreditlineDataPlatformPayload(),
912
+ id: Joi.string().allow(""),
913
+ name: Joi.string().allow(""),
914
+ display_name: Joi.string().allow(""),
899
915
  });
900
916
  }
901
917
 
902
- /** @returns {CreditlineDataPlatformResponse} */
903
- static CreditlineDataPlatformResponse() {
918
+ /** @returns {GetReasonResponse} */
919
+ static GetReasonResponse() {
904
920
  return Joi.object({
905
- code: Joi.number(),
906
- headers: Joi.array().items(Joi.string().allow("")),
921
+ success: Joi.boolean(),
922
+ item_list: Joi.array().items(FinancePlatformModel.ReasonItem()),
907
923
  item_count: Joi.number(),
908
- items: Joi.array().items(Joi.any()),
909
- message: Joi.string().allow(""),
910
924
  page: FinancePlatformModel.Page(),
911
- show_mr: Joi.boolean(),
912
925
  });
913
926
  }
914
927
 
915
- /** @returns {CreditNoteConfigNotificationEvents} */
916
- static CreditNoteConfigNotificationEvents() {
928
+ /** @returns {GetReportListData} */
929
+ static GetReportListData() {
917
930
  return Joi.object({
918
- expiration_reminder_to_customer: Joi.number(),
931
+ role_name: Joi.string().allow(""),
932
+ listing_enabled: Joi.boolean(),
919
933
  });
920
934
  }
921
935
 
922
- /** @returns {CreditNoteDetails} */
923
- static CreditNoteDetails() {
936
+ /** @returns {GetReportListRequest} */
937
+ static GetReportListRequest() {
924
938
  return Joi.object({
925
- available_cn_balance: Joi.number(),
926
- cn_amount: Joi.number(),
927
- cn_details: FinancePlatformModel.CnDetails(),
928
- cn_reference_number: Joi.string().allow(""),
929
- cn_status: Joi.string().allow(""),
930
- customer_mobile_number: Joi.string().allow(""),
931
- redemption_details: Joi.array().items(
932
- FinancePlatformModel.RedemptionDetails()
933
- ),
934
- remaining_cn_amount: Joi.number(),
939
+ data: FinancePlatformModel.GetReportListData(),
935
940
  });
936
941
  }
937
942
 
938
- /** @returns {CreditNoteDetailsRequest} */
939
- static CreditNoteDetailsRequest() {
943
+ /** @returns {GetAffiliate} */
944
+ static GetAffiliate() {
940
945
  return Joi.object({
941
- data: FinancePlatformModel.CnReferenceNumber(),
946
+ company_id: Joi.number(),
942
947
  });
943
948
  }
944
949
 
945
- /** @returns {CreditNoteDetailsResponse} */
946
- static CreditNoteDetailsResponse() {
950
+ /** @returns {GetReportListResponse} */
951
+ static GetReportListResponse() {
947
952
  return Joi.object({
948
- data: FinancePlatformModel.CreditNoteDetails(),
949
953
  success: Joi.boolean(),
954
+ items: Joi.array().items(FinancePlatformModel.ReportItem()),
955
+ page: FinancePlatformModel.Page(),
956
+ total_count: Joi.number(),
950
957
  });
951
958
  }
952
959
 
953
- /** @returns {Currency} */
954
- static Currency() {
960
+ /** @returns {ReportItem} */
961
+ static ReportItem() {
955
962
  return Joi.object({
956
- code: Joi.string().allow(""),
963
+ id: Joi.string().allow(""),
957
964
  name: Joi.string().allow(""),
958
- symbol: Joi.string().allow(""),
959
- });
960
- }
961
-
962
- /** @returns {DeleteConfig} */
963
- static DeleteConfig() {
964
- return Joi.object({
965
- affiliate_id: Joi.string().allow(""),
966
- seller_id: Joi.number(),
967
- slug_values: Joi.array().items(Joi.string().allow("")),
968
- });
969
- }
970
-
971
- /** @returns {DeleteConfigRequest} */
972
- static DeleteConfigRequest() {
973
- return Joi.object({
974
- data: FinancePlatformModel.DeleteConfig(),
965
+ description: Joi.string().allow(""),
966
+ allowed_filters: Joi.array().items(Joi.string().allow("")),
967
+ config_meta: Joi.any(),
968
+ report_type: Joi.string().allow(""),
969
+ display_date: Joi.string().allow("").allow(null),
975
970
  });
976
971
  }
977
972
 
978
- /** @returns {DeleteConfigResponse} */
979
- static DeleteConfigResponse() {
973
+ /** @returns {GetAffiliateResponse} */
974
+ static GetAffiliateResponse() {
980
975
  return Joi.object({
981
- message: Joi.string().allow(""),
982
976
  success: Joi.boolean(),
977
+ docs: Joi.array().items(Joi.any()),
983
978
  });
984
979
  }
985
980
 
@@ -997,625 +992,653 @@ class FinancePlatformModel {
997
992
  });
998
993
  }
999
994
 
995
+ /** @returns {DownloadCreditDebitNoteResponseData} */
996
+ static DownloadCreditDebitNoteResponseData() {
997
+ return Joi.object({
998
+ id: Joi.string().allow(""),
999
+ pdf_s3_url: Joi.string().allow(""),
1000
+ });
1001
+ }
1002
+
1000
1003
  /** @returns {DownloadCreditDebitNoteResponse} */
1001
1004
  static DownloadCreditDebitNoteResponse() {
1002
1005
  return Joi.object({
1006
+ success: Joi.boolean(),
1003
1007
  data: Joi.array().items(
1004
1008
  FinancePlatformModel.DownloadCreditDebitNoteResponseData()
1005
1009
  ),
1006
- success: Joi.boolean(),
1007
1010
  });
1008
1011
  }
1009
1012
 
1010
- /** @returns {DownloadCreditDebitNoteResponseData} */
1011
- static DownloadCreditDebitNoteResponseData() {
1013
+ /** @returns {PaymentProcessPayload} */
1014
+ static PaymentProcessPayload() {
1012
1015
  return Joi.object({
1013
- id: Joi.string().allow(""),
1014
- pdf_s3_url: Joi.string().allow(""),
1016
+ platform: Joi.string().allow(""),
1017
+ amount: Joi.string().allow(""),
1018
+ transaction_type: Joi.string().allow(""),
1019
+ source_reference: Joi.string().allow(""),
1020
+ total_amount: Joi.string().allow(""),
1021
+ meta: Joi.any(),
1022
+ currency: Joi.string().allow(""),
1023
+ seller_id: Joi.string().allow(""),
1024
+ mode_of_payment: Joi.string().allow(""),
1025
+ invoice_number: Joi.string().allow(""),
1015
1026
  });
1016
1027
  }
1017
1028
 
1018
- /** @returns {DownloadReport} */
1019
- static DownloadReport() {
1029
+ /** @returns {PaymentProcessRequest} */
1030
+ static PaymentProcessRequest() {
1020
1031
  return Joi.object({
1021
- end_date: Joi.string().allow(""),
1022
- page: Joi.number(),
1023
- pagesize: Joi.number(),
1024
- start_date: Joi.string().allow(""),
1032
+ data: FinancePlatformModel.PaymentProcessPayload(),
1025
1033
  });
1026
1034
  }
1027
1035
 
1028
- /** @returns {DownloadReportCustomerCnRequest} */
1029
- static DownloadReportCustomerCnRequest() {
1036
+ /** @returns {PaymentProcessResponse} */
1037
+ static PaymentProcessResponse() {
1030
1038
  return Joi.object({
1031
- data: FinancePlatformModel.CnDownloadReport(),
1039
+ code: Joi.number(),
1040
+ message: Joi.string().allow(""),
1041
+ meta: Joi.any(),
1042
+ transaction_id: Joi.string().allow(""),
1043
+ redirect_url: Joi.string().allow(""),
1032
1044
  });
1033
1045
  }
1034
1046
 
1035
- /** @returns {DownloadReportCustomerCnResponse} */
1036
- static DownloadReportCustomerCnResponse() {
1047
+ /** @returns {CreditlineDataPlatformPayload} */
1048
+ static CreditlineDataPlatformPayload() {
1037
1049
  return Joi.object({
1038
- data: Joi.array().items(
1039
- FinancePlatformModel.DownloadReportResponseData()
1040
- ),
1050
+ page: Joi.number(),
1051
+ seller_id: Joi.string().allow(""),
1052
+ end_end: Joi.string().allow(""),
1053
+ start_end: Joi.string().allow(""),
1054
+ pagesize: Joi.number(),
1041
1055
  });
1042
1056
  }
1043
1057
 
1044
- /** @returns {DownloadReportItems} */
1045
- static DownloadReportItems() {
1058
+ /** @returns {CreditlineDataPlatformRequest} */
1059
+ static CreditlineDataPlatformRequest() {
1046
1060
  return Joi.object({
1047
- end_date: Joi.string().allow(""),
1048
- filters: FinancePlatformModel.GenerateReportFilters(),
1049
- meta: FinancePlatformModel.GenerateReportMeta(),
1050
- report_id: Joi.string().allow(""),
1051
- start_date: Joi.string().allow(""),
1052
- type_of_request: Joi.string().allow(""),
1061
+ data: FinancePlatformModel.CreditlineDataPlatformPayload(),
1053
1062
  });
1054
1063
  }
1055
1064
 
1056
- /** @returns {DownloadReportList} */
1057
- static DownloadReportList() {
1065
+ /** @returns {CreditlineDataPlatformResponse} */
1066
+ static CreditlineDataPlatformResponse() {
1058
1067
  return Joi.object({
1059
- item_count: Joi.number(),
1060
- items: Joi.array().items(FinancePlatformModel.DownloadReportItems()),
1068
+ items: Joi.array().items(Joi.any()),
1069
+ code: Joi.number(),
1070
+ show_mr: Joi.boolean(),
1061
1071
  page: FinancePlatformModel.Page(),
1072
+ message: Joi.string().allow(""),
1073
+ headers: Joi.array().items(Joi.string().allow("")),
1074
+ item_count: Joi.number(),
1062
1075
  });
1063
1076
  }
1064
1077
 
1065
- /** @returns {DownloadReportResponseData} */
1066
- static DownloadReportResponseData() {
1078
+ /** @returns {IsCreditlinePayload} */
1079
+ static IsCreditlinePayload() {
1067
1080
  return Joi.object({
1068
- created_at: Joi.string().allow(""),
1069
- display_name: Joi.string().allow(""),
1070
- download_link: Joi.string().allow(""),
1071
- end_date: Joi.string().allow(""),
1072
- filters: Joi.any(),
1073
- full_name: Joi.string().allow(""),
1074
- meta: Joi.any(),
1075
- msg: Joi.string().allow(""),
1076
- report_config_id: Joi.string().allow(""),
1077
- report_name: Joi.string().allow(""),
1078
- request_dict: Joi.any(),
1079
- requested_by: Joi.string().allow(""),
1080
- start_date: Joi.string().allow(""),
1081
- status: Joi.string().allow(""),
1081
+ seller_id: Joi.string().allow(""),
1082
1082
  });
1083
1083
  }
1084
1084
 
1085
- /** @returns {Error} */
1086
- static Error() {
1085
+ /** @returns {IsCreditlinePlatformRequest} */
1086
+ static IsCreditlinePlatformRequest() {
1087
1087
  return Joi.object({
1088
- reason: Joi.string().allow(""),
1089
- success: Joi.boolean(),
1088
+ data: FinancePlatformModel.IsCreditlinePayload(),
1090
1089
  });
1091
1090
  }
1092
1091
 
1093
- /** @returns {GenerateReportCustomerCnRequest} */
1094
- static GenerateReportCustomerCnRequest() {
1092
+ /** @returns {IsCreditlinePlatformResponse} */
1093
+ static IsCreditlinePlatformResponse() {
1095
1094
  return Joi.object({
1096
- data: FinancePlatformModel.CnGenerateReport(),
1095
+ is_creditline_opted: Joi.boolean(),
1096
+ code: Joi.number(),
1097
1097
  });
1098
1098
  }
1099
1099
 
1100
- /** @returns {GenerateReportCustomerCnResponse} */
1101
- static GenerateReportCustomerCnResponse() {
1100
+ /** @returns {InvoiceTypePayloadData} */
1101
+ static InvoiceTypePayloadData() {
1102
1102
  return Joi.object({
1103
- data: FinancePlatformModel.GenerateReportCustomerCnResponseData(),
1103
+ is_active: Joi.boolean(),
1104
1104
  });
1105
1105
  }
1106
1106
 
1107
- /** @returns {GenerateReportCustomerCnResponseData} */
1108
- static GenerateReportCustomerCnResponseData() {
1107
+ /** @returns {InvoiceTypeRequest} */
1108
+ static InvoiceTypeRequest() {
1109
1109
  return Joi.object({
1110
- allowed_filters: Joi.array().items(Joi.string().allow("")),
1111
- end_date: Joi.string().allow(""),
1112
- headers: Joi.array().items(Joi.string().allow("")),
1113
- item_count: Joi.number(),
1114
- items: Joi.array().items(FinancePlatformModel.CnGenerateReportItems()),
1115
- page: FinancePlatformModel.Page(),
1116
- primary_headers: Joi.array().items(Joi.string().allow("")),
1117
- row_header_display_order: Joi.any(),
1118
- start_date: Joi.string().allow(""),
1110
+ data: FinancePlatformModel.InvoiceTypePayloadData(),
1119
1111
  });
1120
1112
  }
1121
1113
 
1122
- /** @returns {GenerateReportFilters} */
1123
- static GenerateReportFilters() {
1114
+ /** @returns {InvoiceTypeResponseItems} */
1115
+ static InvoiceTypeResponseItems() {
1124
1116
  return Joi.object({
1125
- brand: Joi.array().items(Joi.string().allow("")),
1126
- channel: Joi.array().items(Joi.string().allow("")),
1127
- company: Joi.array().items(Joi.string().allow("")),
1117
+ text: Joi.string().allow(""),
1118
+ value: Joi.string().allow(""),
1128
1119
  });
1129
1120
  }
1130
1121
 
1131
- /** @returns {GenerateReportJson} */
1132
- static GenerateReportJson() {
1122
+ /** @returns {InvoiceTypeResponse} */
1123
+ static InvoiceTypeResponse() {
1133
1124
  return Joi.object({
1134
- end_date: Joi.string().allow(""),
1135
- headers: Joi.array().items(Joi.string().allow("")),
1136
- item_count: Joi.number(),
1137
- items: Joi.array().items(Joi.array().items(Joi.string().allow(""))),
1138
- page: FinancePlatformModel.Page(),
1139
- start_date: Joi.string().allow(""),
1125
+ success: Joi.boolean(),
1126
+ invoice_type_list: Joi.array().items(
1127
+ FinancePlatformModel.InvoiceTypeResponseItems()
1128
+ ),
1129
+ payment_status_list: Joi.array().items(
1130
+ FinancePlatformModel.InvoiceTypeResponseItems()
1131
+ ),
1140
1132
  });
1141
1133
  }
1142
1134
 
1143
- /** @returns {GenerateReportMeta} */
1144
- static GenerateReportMeta() {
1135
+ /** @returns {InoviceListingPayloadDataFilters} */
1136
+ static InoviceListingPayloadDataFilters() {
1145
1137
  return Joi.object({
1146
- brand: Joi.string().allow(""),
1147
- channel: Joi.string().allow(""),
1148
- company: Joi.string().allow(""),
1138
+ payment_status: Joi.array().items(Joi.string().allow("")),
1139
+ invoice_type: Joi.array().items(Joi.string().allow("")),
1140
+ company_id: Joi.array().items(Joi.string().allow("")),
1149
1141
  });
1150
1142
  }
1151
1143
 
1152
- /** @returns {GenerateReportPlatform} */
1153
- static GenerateReportPlatform() {
1144
+ /** @returns {InvoiceListingPayloadData} */
1145
+ static InvoiceListingPayloadData() {
1154
1146
  return Joi.object({
1155
- end_date: Joi.string().allow(""),
1156
- filters: FinancePlatformModel.GenerateReportFilters(),
1157
- meta: FinancePlatformModel.GenerateReportMeta(),
1158
- report_id: Joi.string().allow(""),
1147
+ page_size: Joi.number(),
1148
+ page: Joi.number(),
1159
1149
  start_date: Joi.string().allow(""),
1150
+ end_date: Joi.string().allow(""),
1151
+ search: Joi.string().allow(""),
1152
+ filters: FinancePlatformModel.InoviceListingPayloadDataFilters(),
1160
1153
  });
1161
1154
  }
1162
1155
 
1163
- /** @returns {GenerateReportRequest} */
1164
- static GenerateReportRequest() {
1156
+ /** @returns {InvoiceListingRequest} */
1157
+ static InvoiceListingRequest() {
1165
1158
  return Joi.object({
1166
- data: FinancePlatformModel.GenerateReportPlatform(),
1159
+ data: FinancePlatformModel.InvoiceListingPayloadData(),
1167
1160
  });
1168
1161
  }
1169
1162
 
1170
- /** @returns {GetAffiliate} */
1171
- static GetAffiliate() {
1163
+ /** @returns {UnpaidInvoiceDataItems} */
1164
+ static UnpaidInvoiceDataItems() {
1172
1165
  return Joi.object({
1173
- company_id: Joi.number(),
1166
+ total_unpaid_invoice_count: Joi.number(),
1167
+ currency: Joi.string().allow(""),
1168
+ total_unpaid_amount: Joi.number(),
1174
1169
  });
1175
1170
  }
1176
1171
 
1177
- /** @returns {GetAffiliateResponse} */
1178
- static GetAffiliateResponse() {
1172
+ /** @returns {InvoiceListingResponseItems} */
1173
+ static InvoiceListingResponseItems() {
1179
1174
  return Joi.object({
1180
- docs: Joi.array().items(Joi.any()),
1181
- success: Joi.boolean(),
1175
+ amount: Joi.string().allow(""),
1176
+ company: Joi.string().allow(""),
1177
+ status: Joi.string().allow(""),
1178
+ due_date: Joi.string().allow(""),
1179
+ invoice_date: Joi.string().allow(""),
1180
+ invoice_type: Joi.string().allow(""),
1181
+ period: Joi.string().allow(""),
1182
+ invoice_number: Joi.string().allow(""),
1183
+ is_downloadable: Joi.boolean(),
1184
+ invoice_id: Joi.string().allow(""),
1185
+ currency: FinancePlatformModel.Currency(),
1182
1186
  });
1183
1187
  }
1184
1188
 
1185
- /** @returns {GetCnConfigRequest} */
1186
- static GetCnConfigRequest() {
1189
+ /** @returns {InvoiceListingResponse} */
1190
+ static InvoiceListingResponse() {
1187
1191
  return Joi.object({
1188
- data: FinancePlatformModel.DeleteConfig(),
1192
+ unpaid_invoice_data: FinancePlatformModel.UnpaidInvoiceDataItems(),
1193
+ items: Joi.array().items(
1194
+ FinancePlatformModel.InvoiceListingResponseItems()
1195
+ ),
1196
+ page: FinancePlatformModel.Page(),
1197
+ item_count: Joi.number(),
1189
1198
  });
1190
1199
  }
1191
1200
 
1192
- /** @returns {GetCnConfigResponse} */
1193
- static GetCnConfigResponse() {
1201
+ /** @returns {InvoicePdfPayloadData} */
1202
+ static InvoicePdfPayloadData() {
1194
1203
  return Joi.object({
1195
- data: FinancePlatformModel.GetCnConfigResponseData(),
1196
- success: Joi.boolean(),
1204
+ invoice_number: Joi.array().items(Joi.string().allow("")),
1197
1205
  });
1198
1206
  }
1199
1207
 
1200
- /** @returns {GetCnConfigResponseData} */
1201
- static GetCnConfigResponseData() {
1208
+ /** @returns {InvoicePdfRequest} */
1209
+ static InvoicePdfRequest() {
1202
1210
  return Joi.object({
1203
- affiliate_id: Joi.string().allow(""),
1204
- currency_type: Joi.string().allow(""),
1205
- is_cn_as_refund_method: Joi.boolean(),
1206
- meta: FinancePlatformModel.GetCnConfigResponseMeta(),
1207
- notification_events: FinancePlatformModel.CreditNoteConfigNotificationEvents(),
1208
- redemption_ordering_channel: Joi.array().items(Joi.string().allow("")),
1209
- seller_id: Joi.number(),
1210
- validity: Joi.number(),
1211
+ data: FinancePlatformModel.InvoicePdfPayloadData(),
1211
1212
  });
1212
1213
  }
1213
1214
 
1214
- /** @returns {GetCnConfigResponseMeta} */
1215
- static GetCnConfigResponseMeta() {
1215
+ /** @returns {InvoicePdfResponse} */
1216
+ static InvoicePdfResponse() {
1216
1217
  return Joi.object({
1217
- reason: Joi.string().allow(""),
1218
- source_channel: Joi.array().items(Joi.string().allow("")),
1218
+ success: Joi.boolean(),
1219
+ data: Joi.array().items(Joi.string().allow("")),
1220
+ error: Joi.array().items(Joi.string().allow("")),
1219
1221
  });
1220
1222
  }
1221
1223
 
1222
- /** @returns {GetCustomerCreditBalance} */
1223
- static GetCustomerCreditBalance() {
1224
+ /** @returns {IsCnRefundMethodData} */
1225
+ static IsCnRefundMethodData() {
1224
1226
  return Joi.object({
1225
1227
  affiliate_id: Joi.string().allow(""),
1226
- customer_mobile_number: Joi.string().allow(""),
1228
+ toggle_edit_required: Joi.boolean(),
1227
1229
  seller_id: Joi.number(),
1228
1230
  });
1229
1231
  }
1230
1232
 
1231
- /** @returns {GetCustomerCreditBalanceRequest} */
1232
- static GetCustomerCreditBalanceRequest() {
1233
- return Joi.object({
1234
- data: FinancePlatformModel.GetCustomerCreditBalance(),
1235
- });
1236
- }
1237
-
1238
- /** @returns {GetCustomerCreditBalanceResponse} */
1239
- static GetCustomerCreditBalanceResponse() {
1233
+ /** @returns {IsCnRefundMethodRequest} */
1234
+ static IsCnRefundMethodRequest() {
1240
1235
  return Joi.object({
1241
- data: FinancePlatformModel.GetCustomerCreditBalanceResponseData(),
1242
- success: Joi.boolean(),
1236
+ data: FinancePlatformModel.IsCnRefundMethodData(),
1243
1237
  });
1244
1238
  }
1245
1239
 
1246
- /** @returns {GetCustomerCreditBalanceResponseData} */
1247
- static GetCustomerCreditBalanceResponseData() {
1240
+ /** @returns {IsCnRefundMethodResponseData} */
1241
+ static IsCnRefundMethodResponseData() {
1248
1242
  return Joi.object({
1249
- customer_mobile_number: Joi.string().allow(""),
1250
- total_credited_balance: Joi.number(),
1243
+ is_first_time_user: Joi.boolean(),
1251
1244
  });
1252
1245
  }
1253
1246
 
1254
- /** @returns {GetEngineData} */
1255
- static GetEngineData() {
1247
+ /** @returns {IsCnRefundMethodResponse} */
1248
+ static IsCnRefundMethodResponse() {
1256
1249
  return Joi.object({
1257
- filters: Joi.any(),
1258
- project: Joi.array().items(Joi.string().allow("")),
1259
- table_name: Joi.string().allow(""),
1250
+ success: Joi.boolean(),
1251
+ data: FinancePlatformModel.IsCnRefundMethodResponseData(),
1260
1252
  });
1261
1253
  }
1262
1254
 
1263
- /** @returns {GetEngineRequest} */
1264
- static GetEngineRequest() {
1255
+ /** @returns {CreditNoteConfigNotificationEvents} */
1256
+ static CreditNoteConfigNotificationEvents() {
1265
1257
  return Joi.object({
1266
- data: FinancePlatformModel.GetEngineData(),
1258
+ expiration_reminder_to_customer: Joi.number(),
1267
1259
  });
1268
1260
  }
1269
1261
 
1270
- /** @returns {GetEngineResponse} */
1271
- static GetEngineResponse() {
1262
+ /** @returns {CreateSellerCreditNoteConfig} */
1263
+ static CreateSellerCreditNoteConfig() {
1272
1264
  return Joi.object({
1273
- item_count: Joi.number(),
1274
- items: Joi.array().items(Joi.any()),
1275
- page: FinancePlatformModel.Page(),
1276
- success: Joi.boolean(),
1265
+ is_cn_as_refund_method: Joi.boolean(),
1266
+ affiliate_id: Joi.string().allow(""),
1267
+ source_channel: Joi.array().items(Joi.string().allow("")),
1268
+ seller_id: Joi.number(),
1269
+ notification_events: FinancePlatformModel.CreditNoteConfigNotificationEvents(),
1270
+ sales_channel_name: Joi.string().allow(""),
1271
+ ordering_channel: Joi.array().items(Joi.string().allow("")),
1272
+ validity: Joi.number(),
1273
+ currency_type: Joi.string().allow(""),
1274
+ slug_values: Joi.array().items(Joi.string().allow("")),
1277
1275
  });
1278
1276
  }
1279
1277
 
1280
- /** @returns {GetPdfUrlViewRequest} */
1281
- static GetPdfUrlViewRequest() {
1278
+ /** @returns {CreateSellerCreditNoteConfigRequest} */
1279
+ static CreateSellerCreditNoteConfigRequest() {
1282
1280
  return Joi.object({
1283
- data: FinancePlatformModel.CnReferenceNumber(),
1281
+ data: FinancePlatformModel.CreateSellerCreditNoteConfig(),
1284
1282
  });
1285
1283
  }
1286
1284
 
1287
- /** @returns {GetPdfUrlViewResponse} */
1288
- static GetPdfUrlViewResponse() {
1285
+ /** @returns {CreateSellerCreditNoteConfigResponse} */
1286
+ static CreateSellerCreditNoteConfigResponse() {
1289
1287
  return Joi.object({
1290
- data: FinancePlatformModel.GetPdfUrlViewResponseData(),
1291
1288
  success: Joi.boolean(),
1289
+ message: Joi.string().allow(""),
1292
1290
  });
1293
1291
  }
1294
1292
 
1295
- /** @returns {GetPdfUrlViewResponseData} */
1296
- static GetPdfUrlViewResponseData() {
1297
- return Joi.object({
1298
- cn_reference_number: Joi.string().allow(""),
1299
- s3_pdf_link: Joi.string().allow(""),
1300
- });
1301
- }
1302
-
1303
- /** @returns {GetReason} */
1304
- static GetReason() {
1293
+ /** @returns {DeleteConfig} */
1294
+ static DeleteConfig() {
1305
1295
  return Joi.object({
1306
- reason_type: Joi.string().allow(""),
1296
+ affiliate_id: Joi.string().allow(""),
1297
+ slug_values: Joi.array().items(Joi.string().allow("")),
1298
+ seller_id: Joi.number(),
1307
1299
  });
1308
1300
  }
1309
1301
 
1310
- /** @returns {GetReasonRequest} */
1311
- static GetReasonRequest() {
1302
+ /** @returns {DeleteConfigRequest} */
1303
+ static DeleteConfigRequest() {
1312
1304
  return Joi.object({
1313
- data: FinancePlatformModel.GetReason(),
1305
+ data: FinancePlatformModel.DeleteConfig(),
1314
1306
  });
1315
1307
  }
1316
1308
 
1317
- /** @returns {GetReasonResponse} */
1318
- static GetReasonResponse() {
1309
+ /** @returns {DeleteConfigResponse} */
1310
+ static DeleteConfigResponse() {
1319
1311
  return Joi.object({
1320
- item_count: Joi.number(),
1321
- item_list: Joi.array().items(FinancePlatformModel.ReasonItem()),
1322
- page: FinancePlatformModel.Page(),
1323
1312
  success: Joi.boolean(),
1313
+ message: Joi.string().allow(""),
1324
1314
  });
1325
1315
  }
1326
1316
 
1327
- /** @returns {GetReportingFilters} */
1328
- static GetReportingFilters() {
1317
+ /** @returns {ChannelDisplayName} */
1318
+ static ChannelDisplayName() {
1329
1319
  return Joi.object({
1330
- options: Joi.array().items(Joi.any()),
1331
- text: Joi.string().allow(""),
1332
- type: Joi.string().allow(""),
1333
- value: Joi.string().allow(""),
1320
+ platform_pos: Joi.string().allow(""),
1334
1321
  });
1335
1322
  }
1336
1323
 
1337
- /** @returns {GetReportingFiltersResponse} */
1338
- static GetReportingFiltersResponse() {
1324
+ /** @returns {ChannelDisplayNameResponse} */
1325
+ static ChannelDisplayNameResponse() {
1339
1326
  return Joi.object({
1340
- filters: Joi.array().items(
1341
- FinancePlatformModel.GetReportingNestedFilters()
1342
- ),
1343
- search: FinancePlatformModel.GetReportingFilters(),
1344
- status: FinancePlatformModel.GetReportingFilters(),
1327
+ success: Joi.boolean(),
1328
+ data: FinancePlatformModel.ChannelDisplayName(),
1345
1329
  });
1346
1330
  }
1347
1331
 
1348
- /** @returns {GetReportingNestedFilters} */
1349
- static GetReportingNestedFilters() {
1332
+ /** @returns {CnReferenceNumber} */
1333
+ static CnReferenceNumber() {
1350
1334
  return Joi.object({
1351
- options: Joi.array().items(Joi.any()),
1352
- placeholder_text: Joi.string().allow(""),
1353
- required: Joi.boolean(),
1354
- text: Joi.string().allow(""),
1355
- type: Joi.string().allow(""),
1356
- value: Joi.string().allow(""),
1335
+ cn_reference_number: Joi.string().allow(""),
1357
1336
  });
1358
1337
  }
1359
1338
 
1360
- /** @returns {GetReportListData} */
1361
- static GetReportListData() {
1339
+ /** @returns {GetPdfUrlViewRequest} */
1340
+ static GetPdfUrlViewRequest() {
1362
1341
  return Joi.object({
1363
- listing_enabled: Joi.boolean(),
1364
- role_name: Joi.string().allow(""),
1342
+ data: FinancePlatformModel.CnReferenceNumber(),
1365
1343
  });
1366
1344
  }
1367
1345
 
1368
- /** @returns {GetReportListRequest} */
1369
- static GetReportListRequest() {
1346
+ /** @returns {GetPdfUrlViewResponseData} */
1347
+ static GetPdfUrlViewResponseData() {
1370
1348
  return Joi.object({
1371
- data: FinancePlatformModel.GetReportListData(),
1349
+ s3_pdf_link: Joi.string().allow(""),
1350
+ cn_reference_number: Joi.string().allow(""),
1372
1351
  });
1373
1352
  }
1374
1353
 
1375
- /** @returns {GetReportListResponse} */
1376
- static GetReportListResponse() {
1354
+ /** @returns {GetPdfUrlViewResponse} */
1355
+ static GetPdfUrlViewResponse() {
1377
1356
  return Joi.object({
1378
- items: Joi.array().items(FinancePlatformModel.ReportItem()),
1379
- page: FinancePlatformModel.Page(),
1380
1357
  success: Joi.boolean(),
1381
- total_count: Joi.number(),
1358
+ data: FinancePlatformModel.GetPdfUrlViewResponseData(),
1382
1359
  });
1383
1360
  }
1384
1361
 
1385
- /** @returns {InoviceListingPayloadDataFilters} */
1386
- static InoviceListingPayloadDataFilters() {
1362
+ /** @returns {CreditNoteDetailsRequest} */
1363
+ static CreditNoteDetailsRequest() {
1387
1364
  return Joi.object({
1388
- company_id: Joi.array().items(Joi.string().allow("")),
1389
- invoice_type: Joi.array().items(Joi.string().allow("")),
1390
- payment_status: Joi.array().items(Joi.string().allow("")),
1365
+ data: FinancePlatformModel.CnReferenceNumber(),
1391
1366
  });
1392
1367
  }
1393
1368
 
1394
- /** @returns {InvoiceActivityLogError} */
1395
- static InvoiceActivityLogError() {
1369
+ /** @returns {CnDetails} */
1370
+ static CnDetails() {
1396
1371
  return Joi.object({
1397
- reason: Joi.string().allow(""),
1372
+ staff_id: Joi.string().allow(""),
1373
+ expiry_date: Joi.string().allow(""),
1374
+ channel_of_issuance: Joi.string().allow(""),
1375
+ order_id: Joi.string().allow(""),
1376
+ date_issued: Joi.string().allow(""),
1377
+ ordering_channel: Joi.string().allow(""),
1378
+ shipment_id: Joi.string().allow(""),
1379
+ store_id: Joi.string().allow(""),
1380
+ invoice_number: Joi.string().allow(""),
1398
1381
  });
1399
1382
  }
1400
1383
 
1401
- /** @returns {InvoiceActivityLogsResponse} */
1402
- static InvoiceActivityLogsResponse() {
1384
+ /** @returns {RedemptionDetails} */
1385
+ static RedemptionDetails() {
1403
1386
  return Joi.object({
1404
- data: Joi.array().items(
1405
- FinancePlatformModel.InvoiceActivityLogsResponseData()
1406
- ),
1387
+ staff_id: Joi.string().allow(""),
1388
+ created_at: Joi.string().allow(""),
1389
+ order_id: Joi.string().allow(""),
1390
+ store_id: Joi.string().allow(""),
1391
+ shipment_id: Joi.string().allow(""),
1392
+ ordering_channel: Joi.string().allow(""),
1393
+ amount_debited: Joi.number(),
1394
+ invoice_number: Joi.string().allow(""),
1407
1395
  });
1408
1396
  }
1409
1397
 
1410
- /** @returns {InvoiceActivityLogsResponseData} */
1411
- static InvoiceActivityLogsResponseData() {
1398
+ /** @returns {CreditNoteDetails} */
1399
+ static CreditNoteDetails() {
1412
1400
  return Joi.object({
1413
- is_resolved: Joi.boolean(),
1414
- max_retry_attempts: Joi.number(),
1415
- performed_by: Joi.string().allow(""),
1416
- reason: Joi.string().allow(""),
1417
- retry_attempts: Joi.number(),
1418
- status: Joi.string().allow(""),
1401
+ cn_status: Joi.string().allow(""),
1402
+ customer_mobile_number: Joi.string().allow(""),
1403
+ cn_reference_number: Joi.string().allow(""),
1404
+ cn_details: FinancePlatformModel.CnDetails(),
1405
+ redemption_details: Joi.array().items(
1406
+ FinancePlatformModel.RedemptionDetails()
1407
+ ),
1408
+ remaining_cn_amount: Joi.number(),
1409
+ available_cn_balance: Joi.number(),
1410
+ cn_amount: Joi.number(),
1419
1411
  });
1420
1412
  }
1421
1413
 
1422
- /** @returns {InvoiceListingPayloadData} */
1423
- static InvoiceListingPayloadData() {
1414
+ /** @returns {CreditNoteDetailsResponse} */
1415
+ static CreditNoteDetailsResponse() {
1424
1416
  return Joi.object({
1425
- end_date: Joi.string().allow(""),
1426
- filters: FinancePlatformModel.InoviceListingPayloadDataFilters(),
1427
- page: Joi.number(),
1428
- page_size: Joi.number(),
1429
- search: Joi.string().allow(""),
1430
- start_date: Joi.string().allow(""),
1417
+ success: Joi.boolean(),
1418
+ data: FinancePlatformModel.CreditNoteDetails(),
1431
1419
  });
1432
1420
  }
1433
1421
 
1434
- /** @returns {InvoiceListingRequest} */
1435
- static InvoiceListingRequest() {
1422
+ /** @returns {GetCustomerCreditBalance} */
1423
+ static GetCustomerCreditBalance() {
1436
1424
  return Joi.object({
1437
- data: FinancePlatformModel.InvoiceListingPayloadData(),
1425
+ affiliate_id: Joi.string().allow(""),
1426
+ seller_id: Joi.number(),
1427
+ customer_mobile_number: Joi.string().allow(""),
1438
1428
  });
1439
1429
  }
1440
1430
 
1441
- /** @returns {InvoiceListingResponse} */
1442
- static InvoiceListingResponse() {
1431
+ /** @returns {GetCustomerCreditBalanceRequest} */
1432
+ static GetCustomerCreditBalanceRequest() {
1443
1433
  return Joi.object({
1444
- item_count: Joi.number(),
1445
- items: Joi.array().items(
1446
- FinancePlatformModel.InvoiceListingResponseItems()
1447
- ),
1448
- page: FinancePlatformModel.Page(),
1449
- unpaid_invoice_data: FinancePlatformModel.UnpaidInvoiceDataItems(),
1434
+ data: FinancePlatformModel.GetCustomerCreditBalance(),
1450
1435
  });
1451
1436
  }
1452
1437
 
1453
- /** @returns {InvoiceListingResponseItems} */
1454
- static InvoiceListingResponseItems() {
1438
+ /** @returns {GetCustomerCreditBalanceResponseData} */
1439
+ static GetCustomerCreditBalanceResponseData() {
1455
1440
  return Joi.object({
1456
- amount: Joi.string().allow(""),
1457
- company: Joi.string().allow(""),
1458
- currency: FinancePlatformModel.Currency(),
1459
- due_date: Joi.string().allow(""),
1460
- invoice_date: Joi.string().allow(""),
1461
- invoice_id: Joi.string().allow(""),
1462
- invoice_number: Joi.string().allow(""),
1463
- invoice_type: Joi.string().allow(""),
1464
- is_downloadable: Joi.boolean(),
1465
- period: Joi.string().allow(""),
1466
- status: Joi.string().allow(""),
1441
+ customer_mobile_number: Joi.string().allow(""),
1442
+ total_credited_balance: Joi.number(),
1467
1443
  });
1468
1444
  }
1469
1445
 
1470
- /** @returns {InvoicePaymentDetailsResponse} */
1471
- static InvoicePaymentDetailsResponse() {
1446
+ /** @returns {GetCustomerCreditBalanceResponse} */
1447
+ static GetCustomerCreditBalanceResponse() {
1472
1448
  return Joi.object({
1473
- data: FinancePlatformModel.InvoicePaymentDetailsResponseData(),
1474
- payment_details_visible: Joi.boolean(),
1475
1449
  success: Joi.boolean(),
1450
+ data: FinancePlatformModel.GetCustomerCreditBalanceResponseData(),
1476
1451
  });
1477
1452
  }
1478
1453
 
1479
- /** @returns {InvoicePaymentDetailsResponseData} */
1480
- static InvoicePaymentDetailsResponseData() {
1454
+ /** @returns {GetCnConfigRequest} */
1455
+ static GetCnConfigRequest() {
1481
1456
  return Joi.object({
1482
- failed_attempts_details: Joi.array().items(Joi.any()),
1483
- paid_invoice_payment_details: Joi.array().items(
1484
- FinancePlatformModel.PaidInvoicePaymentDetail()
1485
- ),
1457
+ data: FinancePlatformModel.DeleteConfig(),
1486
1458
  });
1487
1459
  }
1488
1460
 
1489
- /** @returns {InvoicePdfPayloadData} */
1490
- static InvoicePdfPayloadData() {
1461
+ /** @returns {GetCnConfigResponseMeta} */
1462
+ static GetCnConfigResponseMeta() {
1491
1463
  return Joi.object({
1492
- invoice_number: Joi.array().items(Joi.string().allow("")),
1464
+ reason: Joi.string().allow(""),
1465
+ source_channel: Joi.array().items(Joi.string().allow("")),
1493
1466
  });
1494
1467
  }
1495
1468
 
1496
- /** @returns {InvoicePdfRequest} */
1497
- static InvoicePdfRequest() {
1469
+ /** @returns {GetCnConfigResponseData} */
1470
+ static GetCnConfigResponseData() {
1498
1471
  return Joi.object({
1499
- data: FinancePlatformModel.InvoicePdfPayloadData(),
1472
+ is_cn_as_refund_method: Joi.boolean(),
1473
+ affiliate_id: Joi.string().allow(""),
1474
+ meta: FinancePlatformModel.GetCnConfigResponseMeta(),
1475
+ seller_id: Joi.number(),
1476
+ notification_events: FinancePlatformModel.CreditNoteConfigNotificationEvents(),
1477
+ validity: Joi.number(),
1478
+ redemption_ordering_channel: Joi.array().items(Joi.string().allow("")),
1479
+ currency_type: Joi.string().allow(""),
1500
1480
  });
1501
1481
  }
1502
1482
 
1503
- /** @returns {InvoicePdfResponse} */
1504
- static InvoicePdfResponse() {
1483
+ /** @returns {GetCnConfigResponse} */
1484
+ static GetCnConfigResponse() {
1505
1485
  return Joi.object({
1506
- data: Joi.array().items(Joi.string().allow("")),
1507
- error: Joi.array().items(Joi.string().allow("")),
1508
1486
  success: Joi.boolean(),
1487
+ data: FinancePlatformModel.GetCnConfigResponseData(),
1509
1488
  });
1510
1489
  }
1511
1490
 
1512
- /** @returns {InvoiceTypePayloadData} */
1513
- static InvoiceTypePayloadData() {
1491
+ /** @returns {CnGenerateReportFilters} */
1492
+ static CnGenerateReportFilters() {
1514
1493
  return Joi.object({
1515
- is_active: Joi.boolean(),
1494
+ staff_id: Joi.array().items(Joi.string().allow("")),
1495
+ channel_of_issuance: Joi.array().items(Joi.string().allow("")),
1496
+ utilisation: Joi.array().items(Joi.string().allow("")),
1497
+ ordering_channel: Joi.array().items(Joi.string().allow("")),
1498
+ store_id: Joi.array().items(Joi.number()),
1499
+ types_of_transaction: Joi.array().items(Joi.string().allow("")),
1516
1500
  });
1517
1501
  }
1518
1502
 
1519
- /** @returns {InvoiceTypeRequest} */
1520
- static InvoiceTypeRequest() {
1503
+ /** @returns {CnGenerateReport} */
1504
+ static CnGenerateReport() {
1521
1505
  return Joi.object({
1522
- data: FinancePlatformModel.InvoiceTypePayloadData(),
1506
+ page: Joi.number(),
1507
+ end_date: Joi.string().allow(""),
1508
+ pagesize: Joi.number(),
1509
+ filters: FinancePlatformModel.CnGenerateReportFilters(),
1510
+ affiliate_id: Joi.string().allow(""),
1511
+ meta: FinancePlatformModel.GenerateReportFilters(),
1512
+ search: Joi.string().allow(""),
1513
+ report_id: Joi.string().allow(""),
1514
+ search_type: Joi.string().allow(""),
1515
+ start_date: Joi.string().allow(""),
1523
1516
  });
1524
1517
  }
1525
1518
 
1526
- /** @returns {InvoiceTypeResponse} */
1527
- static InvoiceTypeResponse() {
1519
+ /** @returns {GenerateReportCustomerCnRequest} */
1520
+ static GenerateReportCustomerCnRequest() {
1528
1521
  return Joi.object({
1529
- invoice_type_list: Joi.array().items(
1530
- FinancePlatformModel.InvoiceTypeResponseItems()
1531
- ),
1532
- payment_status_list: Joi.array().items(
1533
- FinancePlatformModel.InvoiceTypeResponseItems()
1534
- ),
1535
- success: Joi.boolean(),
1522
+ data: FinancePlatformModel.CnGenerateReport(),
1536
1523
  });
1537
1524
  }
1538
1525
 
1539
- /** @returns {InvoiceTypeResponseItems} */
1540
- static InvoiceTypeResponseItems() {
1526
+ /** @returns {CnGenerateReportItems} */
1527
+ static CnGenerateReportItems() {
1541
1528
  return Joi.object({
1542
- text: Joi.string().allow(""),
1543
- value: Joi.string().allow(""),
1529
+ expiry_date: Joi.string().allow(""),
1530
+ status: Joi.string().allow(""),
1531
+ total_amount: Joi.number(),
1532
+ order_id: Joi.string().allow(""),
1533
+ date_issued: Joi.string().allow(""),
1534
+ shipment_id: Joi.string().allow(""),
1535
+ invoice_number: Joi.string().allow(""),
1536
+ credit_note_number: Joi.string().allow(""),
1544
1537
  });
1545
1538
  }
1546
1539
 
1547
- /** @returns {IsCnRefundMethodData} */
1548
- static IsCnRefundMethodData() {
1540
+ /** @returns {GenerateReportCustomerCnResponseData} */
1541
+ static GenerateReportCustomerCnResponseData() {
1549
1542
  return Joi.object({
1550
- affiliate_id: Joi.string().allow(""),
1551
- seller_id: Joi.number(),
1552
- toggle_edit_required: Joi.boolean(),
1543
+ items: Joi.array().items(FinancePlatformModel.CnGenerateReportItems()),
1544
+ row_header_display_order: Joi.any(),
1545
+ end_date: Joi.string().allow(""),
1546
+ page: FinancePlatformModel.Page(),
1547
+ headers: Joi.array().items(Joi.string().allow("")),
1548
+ primary_headers: Joi.array().items(Joi.string().allow("")),
1549
+ allowed_filters: Joi.array().items(Joi.string().allow("")),
1550
+ start_date: Joi.string().allow(""),
1551
+ item_count: Joi.number(),
1553
1552
  });
1554
1553
  }
1555
1554
 
1556
- /** @returns {IsCnRefundMethodRequest} */
1557
- static IsCnRefundMethodRequest() {
1555
+ /** @returns {GenerateReportCustomerCnResponse} */
1556
+ static GenerateReportCustomerCnResponse() {
1558
1557
  return Joi.object({
1559
- data: FinancePlatformModel.IsCnRefundMethodData(),
1558
+ data: FinancePlatformModel.GenerateReportCustomerCnResponseData(),
1560
1559
  });
1561
1560
  }
1562
1561
 
1563
- /** @returns {IsCnRefundMethodResponse} */
1564
- static IsCnRefundMethodResponse() {
1562
+ /** @returns {CnDownloadReport} */
1563
+ static CnDownloadReport() {
1565
1564
  return Joi.object({
1566
- data: FinancePlatformModel.IsCnRefundMethodResponseData(),
1567
- success: Joi.boolean(),
1565
+ page: Joi.number(),
1566
+ start_date: Joi.string().allow(""),
1567
+ end_date: Joi.string().allow(""),
1568
+ affiliate_id: Joi.string().allow(""),
1569
+ search: Joi.string().allow(""),
1570
+ status: Joi.array().items(Joi.string().allow("")),
1571
+ search_type: Joi.string().allow(""),
1572
+ pagesize: Joi.number(),
1568
1573
  });
1569
1574
  }
1570
1575
 
1571
- /** @returns {IsCnRefundMethodResponseData} */
1572
- static IsCnRefundMethodResponseData() {
1576
+ /** @returns {DownloadReportCustomerCnRequest} */
1577
+ static DownloadReportCustomerCnRequest() {
1573
1578
  return Joi.object({
1574
- is_first_time_user: Joi.boolean(),
1579
+ data: FinancePlatformModel.CnDownloadReport(),
1575
1580
  });
1576
1581
  }
1577
1582
 
1578
- /** @returns {IsCreditlinePayload} */
1579
- static IsCreditlinePayload() {
1583
+ /** @returns {DownloadReportResponseData} */
1584
+ static DownloadReportResponseData() {
1580
1585
  return Joi.object({
1581
- seller_id: Joi.string().allow(""),
1586
+ report_config_id: Joi.string().allow(""),
1587
+ full_name: Joi.string().allow(""),
1588
+ requested_by: Joi.string().allow(""),
1589
+ start_date: Joi.string().allow(""),
1590
+ end_date: Joi.string().allow(""),
1591
+ request_dict: Joi.any(),
1592
+ download_link: Joi.string().allow(""),
1593
+ created_at: Joi.string().allow(""),
1594
+ meta: Joi.any(),
1595
+ msg: Joi.string().allow(""),
1596
+ report_name: Joi.string().allow(""),
1597
+ status: Joi.string().allow(""),
1598
+ display_name: Joi.string().allow(""),
1599
+ filters: Joi.any(),
1582
1600
  });
1583
1601
  }
1584
1602
 
1585
- /** @returns {IsCreditlinePlatformRequest} */
1586
- static IsCreditlinePlatformRequest() {
1603
+ /** @returns {DownloadReportCustomerCnResponse} */
1604
+ static DownloadReportCustomerCnResponse() {
1587
1605
  return Joi.object({
1588
- data: FinancePlatformModel.IsCreditlinePayload(),
1606
+ data: Joi.array().items(
1607
+ FinancePlatformModel.DownloadReportResponseData()
1608
+ ),
1589
1609
  });
1590
1610
  }
1591
1611
 
1592
- /** @returns {IsCreditlinePlatformResponse} */
1593
- static IsCreditlinePlatformResponse() {
1612
+ /** @returns {GetReportingFilters} */
1613
+ static GetReportingFilters() {
1594
1614
  return Joi.object({
1595
- code: Joi.number(),
1596
- is_creditline_opted: Joi.boolean(),
1615
+ text: Joi.string().allow(""),
1616
+ type: Joi.string().allow(""),
1617
+ options: Joi.array().items(Joi.any()),
1618
+ value: Joi.string().allow(""),
1597
1619
  });
1598
1620
  }
1599
1621
 
1600
- /** @returns {Page} */
1601
- static Page() {
1622
+ /** @returns {GetReportingNestedFilters} */
1623
+ static GetReportingNestedFilters() {
1602
1624
  return Joi.object({
1603
- current: Joi.number(),
1604
- has_next: Joi.boolean(),
1605
- has_previous: Joi.boolean(),
1606
- item_total: Joi.number(),
1607
- next_id: Joi.string().allow(""),
1608
- size: Joi.number(),
1609
- type: Joi.string().allow("").required(),
1625
+ text: Joi.string().allow(""),
1626
+ options: Joi.array().items(Joi.any()),
1627
+ required: Joi.boolean(),
1628
+ placeholder_text: Joi.string().allow(""),
1629
+ type: Joi.string().allow(""),
1630
+ value: Joi.string().allow(""),
1610
1631
  });
1611
1632
  }
1612
1633
 
1613
- /** @returns {PaidInvoicePaymentDetail} */
1614
- static PaidInvoicePaymentDetail() {
1634
+ /** @returns {GetReportingFiltersResponse} */
1635
+ static GetReportingFiltersResponse() {
1615
1636
  return Joi.object({
1616
- amount: Joi.number(),
1617
- date_of_payment: Joi.string().allow(""),
1618
- payment_details: Joi.array().items(FinancePlatformModel.PaymentDetail()),
1637
+ search: FinancePlatformModel.GetReportingFilters(),
1638
+ filters: Joi.array().items(
1639
+ FinancePlatformModel.GetReportingNestedFilters()
1640
+ ),
1641
+ status: FinancePlatformModel.GetReportingFilters(),
1619
1642
  });
1620
1643
  }
1621
1644
 
@@ -1627,98 +1650,76 @@ class FinancePlatformModel {
1627
1650
  });
1628
1651
  }
1629
1652
 
1630
- /** @returns {PaymentProcessPayload} */
1631
- static PaymentProcessPayload() {
1632
- return Joi.object({
1633
- amount: Joi.string().allow(""),
1634
- currency: Joi.string().allow(""),
1635
- invoice_number: Joi.string().allow(""),
1636
- meta: Joi.any(),
1637
- mode_of_payment: Joi.string().allow(""),
1638
- platform: Joi.string().allow(""),
1639
- seller_id: Joi.string().allow(""),
1640
- source_reference: Joi.string().allow(""),
1641
- total_amount: Joi.string().allow(""),
1642
- transaction_type: Joi.string().allow(""),
1643
- });
1644
- }
1645
-
1646
- /** @returns {PaymentProcessRequest} */
1647
- static PaymentProcessRequest() {
1653
+ /** @returns {PaidInvoicePaymentDetail} */
1654
+ static PaidInvoicePaymentDetail() {
1648
1655
  return Joi.object({
1649
- data: FinancePlatformModel.PaymentProcessPayload(),
1656
+ payment_details: Joi.array().items(FinancePlatformModel.PaymentDetail()),
1657
+ date_of_payment: Joi.string().allow(""),
1658
+ amount: Joi.number(),
1650
1659
  });
1651
1660
  }
1652
1661
 
1653
- /** @returns {PaymentProcessResponse} */
1654
- static PaymentProcessResponse() {
1662
+ /** @returns {InvoicePaymentDetailsResponseData} */
1663
+ static InvoicePaymentDetailsResponseData() {
1655
1664
  return Joi.object({
1656
- code: Joi.number(),
1657
- message: Joi.string().allow(""),
1658
- meta: Joi.any(),
1659
- redirect_url: Joi.string().allow(""),
1660
- transaction_id: Joi.string().allow(""),
1665
+ paid_invoice_payment_details: Joi.array().items(
1666
+ FinancePlatformModel.PaidInvoicePaymentDetail()
1667
+ ),
1668
+ failed_attempts_details: Joi.array().items(Joi.any()),
1661
1669
  });
1662
1670
  }
1663
1671
 
1664
- /** @returns {ReasonItem} */
1665
- static ReasonItem() {
1672
+ /** @returns {InvoicePaymentDetailsResponse} */
1673
+ static InvoicePaymentDetailsResponse() {
1666
1674
  return Joi.object({
1667
- display_name: Joi.string().allow(""),
1668
- id: Joi.string().allow(""),
1669
- name: Joi.string().allow(""),
1675
+ data: FinancePlatformModel.InvoicePaymentDetailsResponseData(),
1676
+ success: Joi.boolean(),
1677
+ payment_details_visible: Joi.boolean(),
1670
1678
  });
1671
1679
  }
1672
1680
 
1673
- /** @returns {RedemptionDetails} */
1674
- static RedemptionDetails() {
1681
+ /** @returns {InvoiceActivityLogsResponseData} */
1682
+ static InvoiceActivityLogsResponseData() {
1675
1683
  return Joi.object({
1676
- amount_debited: Joi.number(),
1677
- created_at: Joi.string().allow(""),
1678
- invoice_number: Joi.string().allow(""),
1679
- order_id: Joi.string().allow(""),
1680
- ordering_channel: Joi.string().allow(""),
1681
- shipment_id: Joi.string().allow(""),
1682
- staff_id: Joi.string().allow(""),
1683
- store_id: Joi.string().allow(""),
1684
+ performed_by: Joi.string().allow(""),
1685
+ status: Joi.string().allow(""),
1686
+ reason: Joi.string().allow(""),
1687
+ is_resolved: Joi.boolean(),
1688
+ retry_attempts: Joi.number(),
1689
+ max_retry_attempts: Joi.number(),
1684
1690
  });
1685
1691
  }
1686
1692
 
1687
- /** @returns {ReportItem} */
1688
- static ReportItem() {
1693
+ /** @returns {InvoiceActivityLogsResponse} */
1694
+ static InvoiceActivityLogsResponse() {
1689
1695
  return Joi.object({
1690
- allowed_filters: Joi.array().items(Joi.string().allow("")),
1691
- config_meta: Joi.any(),
1692
- description: Joi.string().allow(""),
1693
- display_date: Joi.string().allow("").allow(null),
1694
- id: Joi.string().allow(""),
1695
- name: Joi.string().allow(""),
1696
- report_type: Joi.string().allow(""),
1696
+ data: Joi.array().items(
1697
+ FinancePlatformModel.InvoiceActivityLogsResponseData()
1698
+ ),
1697
1699
  });
1698
1700
  }
1699
1701
 
1700
- /** @returns {UnlockCreditNoteRequest} */
1701
- static UnlockCreditNoteRequest() {
1702
+ /** @returns {InvoiceActivityLogError} */
1703
+ static InvoiceActivityLogError() {
1702
1704
  return Joi.object({
1703
- data: FinancePlatformModel.UnlockCreditNoteRequestData(),
1705
+ reason: Joi.string().allow(""),
1704
1706
  });
1705
1707
  }
1706
1708
 
1707
1709
  /** @returns {UnlockCreditNoteRequestData} */
1708
1710
  static UnlockCreditNoteRequestData() {
1709
1711
  return Joi.object({
1710
- description: Joi.string().allow(""),
1711
- locked_credit_notes: Joi.array().items(Joi.string().allow("")),
1712
1712
  seller_id: Joi.string().allow(""),
1713
+ locked_credit_notes: Joi.array().items(Joi.string().allow("")),
1713
1714
  unlock_reason: Joi.string().allow(""),
1715
+ description: Joi.string().allow(""),
1714
1716
  });
1715
1717
  }
1716
1718
 
1717
- /** @returns {UnlockCreditNoteResponse} */
1718
- static UnlockCreditNoteResponse() {
1719
+ /** @returns {UnlockCreditNoteRequest} */
1720
+ static UnlockCreditNoteRequest() {
1719
1721
  return Joi.object({
1720
- data: FinancePlatformModel.UnlockCreditNoteResponseData(),
1721
- success: Joi.boolean(),
1722
+ data: FinancePlatformModel.UnlockCreditNoteRequestData(),
1722
1723
  });
1723
1724
  }
1724
1725
 
@@ -1730,12 +1731,11 @@ class FinancePlatformModel {
1730
1731
  });
1731
1732
  }
1732
1733
 
1733
- /** @returns {UnpaidInvoiceDataItems} */
1734
- static UnpaidInvoiceDataItems() {
1734
+ /** @returns {UnlockCreditNoteResponse} */
1735
+ static UnlockCreditNoteResponse() {
1735
1736
  return Joi.object({
1736
- currency: Joi.string().allow(""),
1737
- total_unpaid_amount: Joi.number(),
1738
- total_unpaid_invoice_count: Joi.number(),
1737
+ success: Joi.boolean(),
1738
+ data: FinancePlatformModel.UnlockCreditNoteResponseData(),
1739
1739
  });
1740
1740
  }
1741
1741
  }