@gofynd/fdk-client-javascript 1.4.8-beta.2 → 1.4.8

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 (198) hide show
  1. package/README.md +26 -1
  2. package/package.json +2 -2
  3. package/sdk/application/ApplicationClient.d.ts +8 -0
  4. package/sdk/application/ApplicationClient.js +14 -0
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +20 -20
  6. package/sdk/application/Cart/CartApplicationClient.js +20 -20
  7. package/sdk/application/Cart/CartApplicationModel.d.ts +2446 -664
  8. package/sdk/application/Cart/CartApplicationModel.js +783 -552
  9. package/sdk/application/Cart/CartApplicationValidator.d.ts +268 -194
  10. package/sdk/application/Cart/CartApplicationValidator.js +100 -114
  11. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +53 -53
  12. package/sdk/application/Catalog/CatalogApplicationClient.js +53 -53
  13. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +2012 -503
  14. package/sdk/application/Catalog/CatalogApplicationModel.js +603 -453
  15. package/sdk/application/Catalog/CatalogApplicationValidator.d.ts +64 -64
  16. package/sdk/application/Catalog/CatalogApplicationValidator.js +32 -32
  17. package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
  18. package/sdk/application/Common/CommonApplicationClient.js +2 -2
  19. package/sdk/application/Common/CommonApplicationModel.d.ts +170 -90
  20. package/sdk/application/Common/CommonApplicationModel.js +59 -58
  21. package/sdk/application/Common/CommonApplicationValidator.d.ts +8 -5
  22. package/sdk/application/Common/CommonApplicationValidator.js +3 -3
  23. package/sdk/application/Communication/CommunicationApplicationClient.d.ts +2 -2
  24. package/sdk/application/Communication/CommunicationApplicationClient.js +2 -2
  25. package/sdk/application/Communication/CommunicationApplicationModel.d.ts +170 -35
  26. package/sdk/application/Communication/CommunicationApplicationModel.js +54 -33
  27. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +15 -15
  28. package/sdk/application/Configuration/ConfigurationApplicationClient.js +15 -15
  29. package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +624 -443
  30. package/sdk/application/Configuration/ConfigurationApplicationModel.js +259 -248
  31. package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +32 -24
  32. package/sdk/application/Configuration/ConfigurationApplicationValidator.js +14 -13
  33. package/sdk/application/Content/ContentApplicationClient.d.ts +16 -16
  34. package/sdk/application/Content/ContentApplicationClient.js +16 -16
  35. package/sdk/application/Content/ContentApplicationModel.d.ts +1206 -281
  36. package/sdk/application/Content/ContentApplicationModel.js +342 -276
  37. package/sdk/application/Content/ContentApplicationValidator.d.ts +28 -17
  38. package/sdk/application/Content/ContentApplicationValidator.js +11 -10
  39. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +3 -3
  40. package/sdk/application/FileStorage/FileStorageApplicationClient.js +3 -3
  41. package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +146 -37
  42. package/sdk/application/FileStorage/FileStorageApplicationModel.js +38 -36
  43. package/sdk/application/Lead/LeadApplicationClient.d.ts +3 -3
  44. package/sdk/application/Lead/LeadApplicationClient.js +3 -3
  45. package/sdk/application/Lead/LeadApplicationModel.d.ts +195 -134
  46. package/sdk/application/Lead/LeadApplicationModel.js +110 -67
  47. package/sdk/application/Lead/LeadApplicationValidator.d.ts +8 -8
  48. package/sdk/application/Lead/LeadApplicationValidator.js +4 -4
  49. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +10 -10
  50. package/sdk/application/Logistic/LogisticApplicationClient.js +10 -10
  51. package/sdk/application/Logistic/LogisticApplicationModel.d.ts +1039 -221
  52. package/sdk/application/Logistic/LogisticApplicationModel.js +342 -199
  53. package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +76 -82
  54. package/sdk/application/Logistic/LogisticApplicationValidator.js +38 -41
  55. package/sdk/application/Order/OrderApplicationClient.d.ts +10 -10
  56. package/sdk/application/Order/OrderApplicationClient.js +10 -10
  57. package/sdk/application/Order/OrderApplicationModel.d.ts +1401 -324
  58. package/sdk/application/Order/OrderApplicationModel.js +392 -316
  59. package/sdk/application/Order/OrderApplicationValidator.d.ts +32 -30
  60. package/sdk/application/Order/OrderApplicationValidator.js +15 -14
  61. package/sdk/application/Payment/PaymentApplicationClient.d.ts +43 -43
  62. package/sdk/application/Payment/PaymentApplicationClient.js +43 -43
  63. package/sdk/application/Payment/PaymentApplicationModel.d.ts +1111 -1022
  64. package/sdk/application/Payment/PaymentApplicationModel.js +537 -521
  65. package/sdk/application/Payment/PaymentApplicationValidator.d.ts +82 -49
  66. package/sdk/application/Payment/PaymentApplicationValidator.js +30 -30
  67. package/sdk/application/Rewards/RewardsApplicationModel.d.ts +28 -7
  68. package/sdk/application/Rewards/RewardsApplicationModel.js +7 -7
  69. package/sdk/application/Share/ShareApplicationModel.d.ts +178 -38
  70. package/sdk/application/Share/ShareApplicationModel.js +53 -37
  71. package/sdk/application/Share/ShareApplicationValidator.d.ts +4 -2
  72. package/sdk/application/Share/ShareApplicationValidator.js +2 -1
  73. package/sdk/application/Theme/ThemeApplicationClient.d.ts +4 -4
  74. package/sdk/application/Theme/ThemeApplicationClient.js +14 -8
  75. package/sdk/application/Theme/ThemeApplicationModel.d.ts +528 -287
  76. package/sdk/application/Theme/ThemeApplicationModel.js +208 -172
  77. package/sdk/application/Theme/ThemeApplicationValidator.d.ts +17 -12
  78. package/sdk/application/Theme/ThemeApplicationValidator.js +8 -6
  79. package/sdk/application/User/UserApplicationClient.d.ts +36 -36
  80. package/sdk/application/User/UserApplicationClient.js +36 -36
  81. package/sdk/application/User/UserApplicationModel.d.ts +1062 -255
  82. package/sdk/application/User/UserApplicationModel.js +298 -244
  83. package/sdk/application/User/UserApplicationValidator.d.ts +80 -80
  84. package/sdk/application/User/UserApplicationValidator.js +40 -40
  85. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +1 -1
  86. package/sdk/application/Webhook/WebhookApplicationClient.js +1 -1
  87. package/sdk/application/Webhook/WebhookApplicationModel.d.ts +20 -5
  88. package/sdk/application/Webhook/WebhookApplicationModel.js +5 -5
  89. package/sdk/common/Clickstream.js +95 -15
  90. package/sdk/common/Constant.d.ts +9 -0
  91. package/sdk/common/Constant.js +11 -0
  92. package/sdk/common/Utility.js +19 -0
  93. package/sdk/common/utils.js +8 -1
  94. package/sdk/partner/Lead/LeadPartnerModel.d.ts +28 -7
  95. package/sdk/partner/Lead/LeadPartnerModel.js +7 -7
  96. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +75 -8
  97. package/sdk/partner/Logistics/LogisticsPartnerModel.js +59 -7
  98. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +2 -2
  99. package/sdk/partner/PartnerClient.d.ts +8 -0
  100. package/sdk/partner/PartnerClient.js +14 -0
  101. package/sdk/partner/Theme/ThemePartnerClient.d.ts +20 -0
  102. package/sdk/partner/Theme/ThemePartnerClient.js +158 -0
  103. package/sdk/partner/Theme/ThemePartnerModel.d.ts +45 -6
  104. package/sdk/partner/Theme/ThemePartnerModel.js +33 -4
  105. package/sdk/partner/Theme/ThemePartnerValidator.d.ts +2 -0
  106. package/sdk/partner/Theme/ThemePartnerValidator.js +14 -0
  107. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +28 -7
  108. package/sdk/partner/Webhook/WebhookPartnerModel.js +7 -7
  109. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +28 -7
  110. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +7 -7
  111. package/sdk/platform/Billing/BillingPlatformClient.d.ts +21 -10
  112. package/sdk/platform/Billing/BillingPlatformClient.js +167 -83
  113. package/sdk/platform/Billing/BillingPlatformModel.d.ts +2849 -565
  114. package/sdk/platform/Billing/BillingPlatformModel.js +935 -556
  115. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +30 -14
  116. package/sdk/platform/Billing/BillingPlatformValidator.js +31 -16
  117. package/sdk/platform/Cart/CartPlatformModel.d.ts +28 -7
  118. package/sdk/platform/Cart/CartPlatformModel.js +8 -8
  119. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +1 -1
  120. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +20 -0
  121. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +37 -0
  122. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +16 -0
  123. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +12 -2
  124. package/sdk/platform/Catalog/CatalogPlatformClient.js +41 -1
  125. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +46 -12
  126. package/sdk/platform/Catalog/CatalogPlatformModel.js +14 -11
  127. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +40 -0
  128. package/sdk/platform/Catalog/CatalogPlatformValidator.js +17 -0
  129. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +28 -7
  130. package/sdk/platform/Communication/CommunicationPlatformModel.js +7 -7
  131. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +28 -7
  132. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +7 -7
  133. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +0 -97
  134. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +77 -782
  135. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +24 -701
  136. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +7 -539
  137. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +1 -183
  138. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +0 -134
  139. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +0 -10
  140. package/sdk/platform/Content/ContentPlatformApplicationClient.js +0 -79
  141. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +1 -15
  142. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +0 -13
  143. package/sdk/platform/Content/ContentPlatformModel.d.ts +60 -17
  144. package/sdk/platform/Content/ContentPlatformModel.js +30 -15
  145. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +28 -7
  146. package/sdk/platform/Discount/DiscountPlatformModel.js +7 -7
  147. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +127 -25
  148. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +37 -25
  149. package/sdk/platform/Finance/FinancePlatformClient.d.ts +30 -30
  150. package/sdk/platform/Finance/FinancePlatformClient.js +30 -30
  151. package/sdk/platform/Finance/FinancePlatformModel.d.ts +1601 -348
  152. package/sdk/platform/Finance/FinancePlatformModel.js +488 -352
  153. package/sdk/platform/Lead/LeadPlatformModel.d.ts +28 -7
  154. package/sdk/platform/Lead/LeadPlatformModel.js +7 -7
  155. package/sdk/platform/Order/OrderPlatformClient.d.ts +22 -0
  156. package/sdk/platform/Order/OrderPlatformClient.js +165 -0
  157. package/sdk/platform/Order/OrderPlatformModel.d.ts +631 -39
  158. package/sdk/platform/Order/OrderPlatformModel.js +367 -41
  159. package/sdk/platform/Order/OrderPlatformValidator.d.ts +32 -1
  160. package/sdk/platform/Order/OrderPlatformValidator.js +28 -0
  161. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +30 -9
  162. package/sdk/platform/Payment/PaymentPlatformModel.js +9 -9
  163. package/sdk/platform/PlatformClient.d.ts +8 -0
  164. package/sdk/platform/PlatformClient.js +14 -0
  165. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +28 -7
  166. package/sdk/platform/Rewards/RewardsPlatformModel.js +7 -7
  167. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +12 -9
  168. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +12 -9
  169. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +1 -1
  170. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +4 -4
  171. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +139 -22
  172. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +98 -21
  173. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +4 -4
  174. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +4 -4
  175. package/sdk/platform/Share/SharePlatformModel.d.ts +28 -7
  176. package/sdk/platform/Share/SharePlatformModel.js +7 -7
  177. package/sdk/platform/Theme/ThemePlatformModel.d.ts +18 -5
  178. package/sdk/platform/Theme/ThemePlatformModel.js +7 -4
  179. package/sdk/platform/User/UserPlatformModel.d.ts +18 -20
  180. package/sdk/platform/User/UserPlatformModel.js +9 -11
  181. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +54 -33
  182. package/sdk/platform/Webhook/WebhookPlatformModel.js +33 -33
  183. package/sdk/public/Billing/BillingPublicClient.d.ts +11 -0
  184. package/sdk/public/Billing/BillingPublicClient.js +80 -0
  185. package/sdk/public/Billing/BillingPublicModel.d.ts +584 -99
  186. package/sdk/public/Billing/BillingPublicModel.js +252 -87
  187. package/sdk/public/Billing/BillingPublicValidator.d.ts +10 -1
  188. package/sdk/public/Billing/BillingPublicValidator.js +12 -0
  189. package/sdk/public/PublicClient.d.ts +0 -2
  190. package/sdk/public/PublicClient.js +0 -4
  191. package/sdk/public/index.d.ts +0 -1
  192. package/sdk/public/index.js +0 -2
  193. package/sdk/public/Inventory/InventoryPublicClient.d.ts +0 -87
  194. package/sdk/public/Inventory/InventoryPublicClient.js +0 -529
  195. package/sdk/public/Inventory/InventoryPublicModel.d.ts +0 -393
  196. package/sdk/public/Inventory/InventoryPublicModel.js +0 -448
  197. package/sdk/public/Inventory/InventoryPublicValidator.d.ts +0 -91
  198. package/sdk/public/Inventory/InventoryPublicValidator.js +0 -85
@@ -2,40 +2,50 @@ const Joi = require("joi");
2
2
 
3
3
  /**
4
4
  * @typedef OrderPage
5
- * @property {string} [type]
6
- * @property {number} [item_total]
7
- * @property {number} [current]
8
- * @property {number} [size]
9
- * @property {boolean} [has_next]
5
+ * @property {string} [type] - Specifies type of pagination. If it is 'cursor'
6
+ * based or 'number' based.
7
+ * @property {number} [item_total] - Total number of items available across all
8
+ * pages. It provides a count of all the items that match the query criteria,
9
+ * regardless of pagination.
10
+ * @property {number} [current] - Specifies the current page number. It helps in
11
+ * identifying the position within the paginated results.
12
+ * @property {number} [size] - Represents the number of items on the current
13
+ * page. It indicates how many items are included in each page of the
14
+ * paginated response.
15
+ * @property {boolean} [has_next] - Indicates whether there is a next page
16
+ * available. It is true if a next page exists and false if the current page
17
+ * is the last one.
10
18
  */
11
19
 
12
20
  /**
13
21
  * @typedef UserInfo
14
- * @property {string} [first_name]
15
- * @property {string} [gender]
16
- * @property {string} [name]
17
- * @property {string} [last_name]
18
- * @property {string} [mobile]
19
- * @property {string} [email]
22
+ * @property {string} [first_name] - First name of the user.
23
+ * @property {string} [gender] - Gender of the user.
24
+ * @property {string} [name] - Full name of the user (including first and last names).
25
+ * @property {string} [last_name] - Last name of the user.
26
+ * @property {string} [mobile] - Mobile number of the user.
27
+ * @property {string} [email] - Email address of the user.
20
28
  */
21
29
 
22
30
  /**
23
31
  * @typedef BreakupValues
24
- * @property {number} [value]
25
- * @property {string} [currency_symbol]
26
- * @property {string} [name]
27
- * @property {string} [display]
28
- * @property {string} [currency_code]
32
+ * @property {number} [value] - The numerical value associated with the entity.
33
+ * @property {string} [currency_symbol] - Symbol representing the currency used
34
+ * for the value.
35
+ * @property {string} [name] - The official name of the entity.
36
+ * @property {string} [display] - The name of the entity as it should be displayed.
37
+ * @property {string} [currency_code] - The international currency code
38
+ * representing the currency used for the value.
29
39
  */
30
40
 
31
41
  /**
32
42
  * @typedef ShipmentPayment
33
- * @property {string} [mop]
34
- * @property {string} [payment_mode]
35
- * @property {string} [status]
36
- * @property {string} [mode]
37
- * @property {string} [logo]
38
- * @property {string} [display_name]
43
+ * @property {string} [mop] - Abbreviation or code for the payment mode.
44
+ * @property {string} [payment_mode] - The specific payment mode used.
45
+ * @property {string} [status] - The current status of the payment.
46
+ * @property {string} [mode] - The payment mode.
47
+ * @property {string} [logo] - URL of the logo representing the payment mode.
48
+ * @property {string} [display_name] - The name to be displayed for the payment mode.
39
49
  */
40
50
 
41
51
  /**
@@ -43,360 +53,411 @@ const Joi = require("joi");
43
53
  * @property {string} [mop] - Stands for "Mode of Payment". This is a short code
44
54
  * (like "COD" for Cash On Delivery) that represents the payment method used.
45
55
  * @property {string} [payment_mode] - Information about the payment mode,
46
- * indicates whether COD or PREPAID
56
+ * indicates whether COD or PREPAID.
47
57
  * @property {string} [status] - Indicates the current status of the payment,
48
- * Paid or Unpaid
49
- * @property {string} [mode] - Information about the payment source. For eg, NB_ICICI
50
- * @property {string} [logo] - A URL to an image representing the payment method
58
+ * Paid or Unpaid.
59
+ * @property {string} [mode] - Information about the payment source. For eg, NB_ICICI.
60
+ * @property {string} [logo] - A URL to an image representing the payment method.
51
61
  * @property {string} [display_name] - The name of the payment method as it
52
- * should be displayed to the user
53
- * @property {number} [amount] - Amount paid using this payment method
62
+ * should be displayed to the user.
63
+ * @property {number} [amount] - Amount paid using this payment method.
54
64
  */
55
65
 
56
66
  /**
57
67
  * @typedef ShipmentUserInfo
58
- * @property {string} [first_name]
59
- * @property {string} [gender]
60
- * @property {string} [name]
61
- * @property {string} [last_name]
62
- * @property {string} [mobile]
63
- * @property {string} [email]
68
+ * @property {string} [first_name] - The unique identifier of the store.
69
+ * @property {string} [gender] - A code associated with the store.
70
+ * @property {string} [name] - The name of the store.
71
+ * @property {string} [last_name] - The name of the company associated with the store.
72
+ * @property {string} [mobile] - The identifier of the company associated with the store.
73
+ * @property {string} [email] - Email address of the user.
64
74
  */
65
75
 
66
76
  /**
67
77
  * @typedef FulfillingStore
68
- * @property {number} [id]
69
- * @property {string} [code]
70
- * @property {string} [name]
71
- * @property {string} [company_name]
72
- * @property {number} [company_id]
78
+ * @property {number} [id] - The unique identifier of the store.
79
+ * @property {string} [code] - A code associated with the store.
80
+ * @property {string} [name] - The name of the store.
81
+ * @property {string} [company_name] - The name of the company associated with the store.
82
+ * @property {number} [company_id] - The identifier of the company associated
83
+ * with the store.
73
84
  */
74
85
 
75
86
  /**
76
87
  * @typedef ShipmentStatus
77
- * @property {string} [value]
78
- * @property {string} [title]
79
- * @property {string} [hex_code]
88
+ * @property {string} [value] - The internal or code value representing the
89
+ * shipment status.
90
+ * @property {string} [title] - The title or display name representing the
91
+ * shipment status.
92
+ * @property {string} [hex_code] - The hexadecimal color code associated with
93
+ * the shipment status.
80
94
  */
81
95
 
82
96
  /**
83
97
  * @typedef Invoice
84
- * @property {string} [invoice_url]
85
- * @property {string} [updated_date]
86
- * @property {string} [label_url]
98
+ * @property {string} [invoice_url] - URL providing access to the invoice.
99
+ * @property {string} [updated_date] - The date and time when the invoice was
100
+ * last updated.
101
+ * @property {string} [label_url] - URL providing access to the invoice label.
87
102
  */
88
103
 
89
104
  /**
90
105
  * @typedef NestedTrackingDetails
91
- * @property {boolean} [is_passed]
92
- * @property {string} [time]
93
- * @property {boolean} [is_current]
94
- * @property {string} [status]
106
+ * @property {boolean} [is_passed] - Indicates whether the tracking event has
107
+ * passed or occurred.
108
+ * @property {string} [time] - The time associated with the tracking event.
109
+ * @property {boolean} [is_current] - Indicates whether the tracking event is
110
+ * the current or active status.
111
+ * @property {string} [status] - The status of the tracking event.
95
112
  */
96
113
 
97
114
  /**
98
115
  * @typedef TrackingDetails
99
- * @property {string} [value]
100
- * @property {boolean} [is_current]
101
- * @property {boolean} [is_passed]
102
- * @property {string} [status]
103
- * @property {string} [time]
104
- * @property {string} [created_ts]
105
- * @property {NestedTrackingDetails[]} [tracking_details]
116
+ * @property {string} [value] - Current value or state of the process.
117
+ * @property {boolean} [is_current] - Indicates whether the tracking event is
118
+ * the current or active status.
119
+ * @property {boolean} [is_passed] - Indicates whether the tracking event has
120
+ * passed or occurred.
121
+ * @property {string} [status] - The status of the tracking event.
122
+ * @property {string} [time] - The time associated with the tracking event.
123
+ * @property {string} [created_ts] - Timestamp when this status was created.
124
+ * @property {NestedTrackingDetails[]} [tracking_details] - Nested tracking details.
106
125
  */
107
126
 
108
127
  /**
109
128
  * @typedef TimeStampData
110
- * @property {string} [min]
111
- * @property {string} [max]
129
+ * @property {string} [min] - The minimum timestamp value.
130
+ * @property {string} [max] - The maximum timestamp value.
112
131
  */
113
132
 
114
133
  /**
115
134
  * @typedef Promise
116
- * @property {boolean} [show_promise]
135
+ * @property {boolean} [show_promise] - Indicates whether the promise details
136
+ * should be shown.
117
137
  * @property {TimeStampData} [timestamp]
118
138
  */
119
139
 
120
140
  /**
121
141
  * @typedef ShipmentTotalDetails
122
- * @property {number} [pieces]
123
- * @property {number} [total_price]
124
- * @property {number} [sizes]
142
+ * @property {number} [pieces] - The total number of pieces included.
143
+ * @property {number} [total_price] - The total price of the order or item.
144
+ * @property {number} [sizes] - The number of different sizes included.
125
145
  */
126
146
 
127
147
  /**
128
148
  * @typedef Prices
129
- * @property {number} [delivery_charge]
130
- * @property {number} [coupon_value]
131
- * @property {number} [brand_calculated_amount]
132
- * @property {number} [value_of_good]
133
- * @property {number} [price_marked]
134
- * @property {number} [coupon_effective_discount]
135
- * @property {string} [currency_symbol]
136
- * @property {number} [discount]
137
- * @property {number} [gst_tax_percentage]
138
- * @property {number} [cod_charges]
139
- * @property {number} [amount_paid]
140
- * @property {boolean} [added_to_fynd_cash]
141
- * @property {number} [transfer_price]
142
- * @property {number} [cashback_applied]
143
- * @property {number} [price_effective]
144
- * @property {number} [cashback]
145
- * @property {number} [refund_credit]
146
- * @property {number} [amount_paid_roundoff]
147
- * @property {number} [promotion_effective_discount]
148
- * @property {number} [refund_amount]
149
- * @property {string} [currency_code]
150
- * @property {number} [fynd_credits]
151
- * @property {number} [amount_to_be_collected]
149
+ * @property {number} [delivery_charge] - The delivery charge for the order.
150
+ * @property {number} [coupon_value] - The value of the coupon applied.
151
+ * @property {number} [brand_calculated_amount] - The amount calculated by the brand.
152
+ * @property {number} [value_of_good] - The value of the goods before tax and
153
+ * other charges.
154
+ * @property {number} [price_marked] - The original marked price of the item.
155
+ * @property {number} [coupon_effective_discount] - The effective discount from coupons.
156
+ * @property {string} [currency_symbol] - The symbol of the currency used.
157
+ * @property {number} [discount] - The discount applied to the item.
158
+ * @property {number} [gst_tax_percentage] - The GST tax percentage applied.
159
+ * @property {number} [cod_charges] - The cash on delivery charges, if applicable.
160
+ * @property {number} [amount_paid] - The total amount paid by the customer.
161
+ * @property {boolean} [added_to_fynd_cash] - Indicates if the refund amount was
162
+ * added to Fynd Cash.
163
+ * @property {number} [transfer_price] - The transfer price of the item.
164
+ * @property {number} [cashback_applied] - The amount of cashback applied.
165
+ * @property {number} [price_effective] - The effective price after all adjustments.
166
+ * @property {number} [cashback] - The cashback amount earned.
167
+ * @property {number} [refund_credit] - The amount credited for refund .
168
+ * @property {number} [amount_paid_roundoff] - The rounded-off amount paid by
169
+ * the customer.
170
+ * @property {number} [promotion_effective_discount] - The effective discount
171
+ * from promotions.
172
+ * @property {number} [refund_amount] - The amount refunded to the customer.
173
+ * @property {string} [currency_code] - The code of the currency used.
174
+ * @property {number} [fynd_credits] - The amount of Fynd credits used.
175
+ * @property {number} [amount_to_be_collected] - The total amount that needs to
176
+ * be collected from the customer.
152
177
  */
153
178
 
154
179
  /**
155
180
  * @typedef ItemBrand
156
- * @property {string} [logo]
157
- * @property {string} [name]
181
+ * @property {string} [logo] - The URL of the brand's logo.
182
+ * @property {string} [name] - The name of the brand.
158
183
  */
159
184
 
160
185
  /**
161
186
  * @typedef Item
162
- * @property {string[]} [image]
163
- * @property {string[]} [l1_categories]
187
+ * @property {string[]} [image] - An array of URLs pointing to images of the item.
188
+ * @property {string[]} [l1_categories] - An array of level 1 categories the item belongs.
164
189
  * @property {ItemBrand} [brand]
165
- * @property {string} [seller_identifier]
166
- * @property {string} [code]
167
- * @property {number} [id]
168
- * @property {string} [name]
169
- * @property {string} [l3_category_name]
170
- * @property {string} [slug_key]
171
- * @property {string[]} [l2_categories]
172
- * @property {string} [size]
173
- * @property {Object} [attributes]
190
+ * @property {string} [seller_identifier] - The identifier for the seller .
191
+ * @property {string} [code] - The code or SKU of the item.
192
+ * @property {number} [id] - The unique identifier of the item.
193
+ * @property {string} [name] - The name of the item.
194
+ * @property {string} [l3_category_name] - The level 3 category name.
195
+ * @property {string} [slug_key] - A unique key or identifier for the item slug.
196
+ * @property {string[]} [l2_categories] - An array of level 2 categories the
197
+ * item belongs to.
198
+ * @property {string} [size] - The size of the item.
199
+ * @property {Object} [attributes] - An object containing various attributes of the item.
174
200
  */
175
201
 
176
202
  /**
177
203
  * @typedef AppliedFreeArticles
178
- * @property {string} [article_id]
179
- * @property {Object} [free_gift_item_details]
180
- * @property {string} [parent_item_identifier]
181
- * @property {number} [quantity]
204
+ * @property {string} [article_id] - The unique identifier for the article.
205
+ * @property {Object} [free_gift_item_details] - An object containing details
206
+ * about the free gift item.
207
+ * @property {string} [parent_item_identifier] - The identifier for the parent
208
+ * item to which this free article is related.
209
+ * @property {number} [quantity] - The quantity of the free article.
182
210
  */
183
211
 
184
212
  /**
185
213
  * @typedef AppliedPromos
186
- * @property {boolean} [mrp_promotion]
187
- * @property {string} [promotion_name]
188
- * @property {number} [article_quantity]
189
- * @property {string} [promo_id]
190
- * @property {number} [amount]
191
- * @property {string} [promotion_type]
192
- * @property {AppliedFreeArticles[]} [applied_free_articles]
214
+ * @property {boolean} [mrp_promotion] - Indicates if the promotion is applied to the MRP.
215
+ * @property {string} [promotion_name] - The name of the promotion .
216
+ * @property {number} [article_quantity] - The quantity of articles required to
217
+ * qualify for the promotion.
218
+ * @property {string} [promo_id] - The unique identifier for the promotion.
219
+ * @property {number} [amount] - The discount amount provided by the promotion.
220
+ * @property {string} [promotion_type] - The type of promotion.
221
+ * @property {AppliedFreeArticles[]} [applied_free_articles] - An array
222
+ * containing details of free articles applied under the promotion.
193
223
  */
194
224
 
195
225
  /**
196
226
  * @typedef Identifiers
197
- * @property {string} [ean]
198
- * @property {string} [sku_code]
227
+ * @property {string} [ean] - The European Article Number (EAN) of the item.
228
+ * @property {string} [sku_code] - The Stock Keeping Unit (SKU) code of the item.
199
229
  */
200
230
 
201
231
  /**
202
232
  * @typedef FinancialBreakup
203
- * @property {number} [coupon_value]
204
- * @property {number} [delivery_charge]
205
- * @property {number} [brand_calculated_amount]
206
- * @property {number} [value_of_good]
207
- * @property {number} [price_marked]
208
- * @property {number} [coupon_effective_discount]
209
- * @property {string} [hsn_code]
210
- * @property {number} [discount]
211
- * @property {number} [gst_tax_percentage]
212
- * @property {number} [cod_charges]
213
- * @property {number} [amount_paid]
214
- * @property {boolean} [added_to_fynd_cash]
215
- * @property {string} [size]
216
- * @property {number} [transfer_price]
217
- * @property {number} [cashback_applied]
218
- * @property {number} [price_effective]
219
- * @property {number} [cashback]
220
- * @property {number} [refund_credit]
221
- * @property {number} [amount_paid_roundoff]
222
- * @property {number} [total_units]
233
+ * @property {number} [coupon_value] - The value of the coupon applied.
234
+ * @property {number} [delivery_charge] - The delivery charge for the order.
235
+ * @property {number} [brand_calculated_amount] - The amount calculated by the brand.
236
+ * @property {number} [value_of_good] - The value of the goods before tax and
237
+ * other charges.
238
+ * @property {number} [price_marked] - The original marked price of the item.
239
+ * @property {number} [coupon_effective_discount] - The effective discount from coupons.
240
+ * @property {string} [hsn_code] - The HSN (Harmonized System of Nomenclature)
241
+ * code of the item.
242
+ * @property {number} [discount] - The discount applied to the item.
243
+ * @property {number} [gst_tax_percentage] - The GST tax percentage applied .
244
+ * @property {number} [cod_charges] - The cash on delivery charges, if applicable.
245
+ * @property {number} [amount_paid] - The total amount paid by the customer.
246
+ * @property {boolean} [added_to_fynd_cash] - Indicates if the refund amount was
247
+ * added to Fynd Cash.
248
+ * @property {string} [size] - The size of the item .
249
+ * @property {number} [transfer_price] - The transfer price of the item.
250
+ * @property {number} [cashback_applied] - The amount of cashback applied.
251
+ * @property {number} [price_effective] - The effective price after all adjustments.
252
+ * @property {number} [cashback] - The cashback amount earned.
253
+ * @property {number} [refund_credit] - The amount credited for refund .
254
+ * @property {number} [amount_paid_roundoff] - The rounded-off amount paid by
255
+ * the customer.
256
+ * @property {number} [total_units] - The total number of units purchased.
223
257
  * @property {Identifiers} [identifiers]
224
- * @property {string} [gst_tag]
225
- * @property {string} [item_name]
226
- * @property {number} [promotion_effective_discount]
227
- * @property {number} [gst_fee]
228
- * @property {number} [refund_amount]
229
- * @property {number} [fynd_credits]
230
- * @property {number} [amount_to_be_collected]
258
+ * @property {string} [gst_tag] - The GST tag indicating the type of GST applied.
259
+ * @property {string} [item_name] - The name of the item.
260
+ * @property {number} [promotion_effective_discount] - The effective discount
261
+ * from promotions.
262
+ * @property {number} [gst_fee] - The GST fee applied to the item.
263
+ * @property {number} [refund_amount] - The amount refunded to the customer.
264
+ * @property {number} [fynd_credits] - The amount of Fynd credits used.
265
+ * @property {number} [amount_to_be_collected] - The total amount that needs to
266
+ * be collected from the customer.
231
267
  */
232
268
 
233
269
  /**
234
270
  * @typedef CurrentStatus
235
- * @property {string} [updated_at]
236
- * @property {string} [name]
237
- * @property {string} [status]
238
- * @property {string} [journey_type]
271
+ * @property {string} [updated_at] - The date and time when the status was last updated.
272
+ * @property {string} [name] - The name or label indicating the current state or status.
273
+ * @property {string} [status] - The current status of the bag.
274
+ * @property {string} [journey_type] - The type of journey for the shipment,
275
+ * indicating the direction of the shipment.
239
276
  */
240
277
 
241
278
  /**
242
279
  * @typedef Bags
243
- * @property {string} [delivery_date]
244
- * @property {number} [line_number]
245
- * @property {string} [currency_symbol]
280
+ * @property {string} [delivery_date] - The date and time when the item is
281
+ * expected to be delivered .
282
+ * @property {number} [line_number] - The line number of the item in the order.
283
+ * @property {string} [currency_symbol] - The symbol of the currency used.
246
284
  * @property {Item} [item]
247
- * @property {AppliedPromos[]} [applied_promos]
248
- * @property {number} [quantity]
285
+ * @property {AppliedPromos[]} [applied_promos] - An array containing
286
+ * information about applied promotions.
287
+ * @property {number} [quantity] - The quantity of the item.
249
288
  * @property {Prices} [prices]
250
- * @property {boolean} [can_cancel]
251
- * @property {boolean} [can_return]
252
- * @property {number} [id]
253
- * @property {string} [returnable_date]
254
- * @property {FinancialBreakup[]} [financial_breakup]
255
- * @property {Object} [parent_promo_bags]
256
- * @property {Object} [meta]
257
- * @property {string} [currency_code]
258
- * @property {string} [seller_identifier]
289
+ * @property {boolean} [can_cancel] - Indicates if the item can be canceled.
290
+ * @property {boolean} [can_return] - Indicates if the item can be returned.
291
+ * @property {number} [id] - The unique identifier for the order item.
292
+ * @property {string} [returnable_date] - The last date and time by which the
293
+ * item can be returned.
294
+ * @property {FinancialBreakup[]} [financial_breakup] - An array containing
295
+ * financial details of the item.
296
+ * @property {Object} [parent_promo_bags] - An object containing details of
297
+ * parent promotional bags.
298
+ * @property {Object} [meta] - An object containing metadata for the item.
299
+ * @property {string} [currency_code] - The code of the currency used.
300
+ * @property {string} [seller_identifier] - The identifier for the seller.
259
301
  * @property {CurrentStatus} [current_status]
260
302
  * @property {Article} [article]
261
303
  */
262
304
 
263
305
  /**
264
306
  * @typedef FulfillingCompany
265
- * @property {number} [id]
266
- * @property {string} [name]
307
+ * @property {number} [id] - The unique identifier for the fulfilling company.
308
+ * @property {string} [name] - The name of the fulfilling company.
267
309
  */
268
310
 
269
311
  /**
270
312
  * @typedef Article
271
- * @property {string[]} [tags]
313
+ * @property {string[]} [tags] - An array of tags associated with the article.
272
314
  */
273
315
 
274
316
  /**
275
317
  * @typedef Address
276
- * @property {string} [pincode]
277
- * @property {string} [phone]
278
- * @property {number} [latitude]
279
- * @property {string} [address2]
280
- * @property {string} [landmark]
281
- * @property {string} [area]
282
- * @property {string} [city]
283
- * @property {string} [address]
284
- * @property {string} [address_type]
285
- * @property {number} [longitude]
286
- * @property {string} [country_iso_code]
287
- * @property {string} [state]
288
- * @property {string} [created_at]
289
- * @property {string} [address1]
290
- * @property {string} [display_address]
291
- * @property {string} [name]
292
- * @property {string} [contact_person]
293
- * @property {string} [address_category]
294
- * @property {string} [email]
295
- * @property {string} [country_phone_code]
296
- * @property {string} [version]
297
- * @property {string} [updated_at]
298
- * @property {string} [country]
318
+ * @property {string} [pincode] - The postal code of the address.
319
+ * @property {string} [phone] - The phone number of the person associated with
320
+ * the address.
321
+ * @property {number} [latitude] - The latitude coordinate.
322
+ * @property {string} [address2] - The secondary line of the address.
323
+ * @property {string} [landmark] - A nearby landmark.
324
+ * @property {string} [area] - The area or locality.
325
+ * @property {string} [city] - The city of the address.
326
+ * @property {string} [address] - The full address.
327
+ * @property {string} [address_type] - The type of address.
328
+ * @property {number} [longitude] - The longitude coordinate.
329
+ * @property {string} [country_iso_code] - The ISO code for the country.
330
+ * @property {string} [state] - The state of the address.
331
+ * @property {string} [created_at] - The date and time when the address was created.
332
+ * @property {string} [address1] - The primary line of the address.
333
+ * @property {string} [display_address] - The formatted display address,
334
+ * typically used for printing or displaying in user interfaces.
335
+ * @property {string} [name] - The name of the person associated with the address.
336
+ * @property {string} [contact_person] - The name of the contact person.
337
+ * @property {string} [address_category] - The category of the address.
338
+ * @property {string} [email] - The email address.
339
+ * @property {string} [country_phone_code] - The country phone code.
340
+ * @property {string} [version] - The version of the address format.
341
+ * @property {string} [updated_at] - The date and time when the address was last updated .
342
+ * @property {string} [country] - The country of the address.
299
343
  */
300
344
 
301
345
  /**
302
346
  * @typedef Shipments
303
347
  * @property {ShipmentPayment} [payment]
304
- * @property {ShipmentPaymentInfo[]} [payment_info] - "Array of objects
348
+ * @property {ShipmentPaymentInfo[]} [payment_info] - Array of objects
305
349
  * containing payment methods used for placing an order. Each object will
306
- * provide information about corresponding payment method with relevant details."
307
- * @property {string} [order_type]
308
- * @property {boolean} [show_download_invoice]
309
- * @property {boolean} [can_cancel]
350
+ * provide information about corresponding payment method with relevant details.
351
+ * @property {string} [order_type] - The type of order.
352
+ * @property {string} [gstin_code] - The GSTIN code for the shipment.
353
+ * @property {boolean} [show_download_invoice] - Indicates if the download
354
+ * invoice option should be shown.
355
+ * @property {boolean} [can_cancel] - Indicates if the shipment can be canceled.
310
356
  * @property {ShipmentUserInfo} [user_info]
311
- * @property {string} [shipment_id]
357
+ * @property {string} [shipment_id] - The unique identifier for the shipment.
312
358
  * @property {FulfillingStore} [fulfilling_store]
313
- * @property {Object[]} [custom_meta]
359
+ * @property {Object[]} [custom_meta] - An object containing custom metadata for
360
+ * the shipment.
314
361
  * @property {ShipmentStatus} [shipment_status]
315
- * @property {string} [comment]
362
+ * @property {string} [comment] - Any comments related to the shipment.
316
363
  * @property {Invoice} [invoice]
317
- * @property {boolean} [show_track_link]
318
- * @property {Object} [refund_details]
319
- * @property {BreakupValues[]} [breakup_values]
320
- * @property {Object} [can_break]
321
- * @property {string} [traking_no]
322
- * @property {TrackingDetails[]} [tracking_details]
364
+ * @property {boolean} [show_track_link] - Indicates if the track link should be shown.
365
+ * @property {Object} [refund_details] - An object containing details of any refunds.
366
+ * @property {BreakupValues[]} [breakup_values] - An array containing the
367
+ * breakup of various charges and discounts.
368
+ * @property {Object} [can_break] - An object containing details about the
369
+ * breakability of the shipment.
370
+ * @property {string} [traking_no] - The tracking number for the shipment.
371
+ * @property {TrackingDetails[]} [tracking_details] - An array containing
372
+ * details of the tracking history of the shipment.
323
373
  * @property {Promise} [promise]
324
- * @property {number} [total_bags]
374
+ * @property {number} [total_bags] - The total number of bags in the shipment.
325
375
  * @property {ShipmentTotalDetails} [total_details]
326
376
  * @property {Prices} [prices]
327
- * @property {string} [returnable_date]
328
- * @property {string} [shipment_created_at]
329
- * @property {string} [shipment_created_ts]
330
- * @property {Object} [size_info]
331
- * @property {Bags[]} [bags]
332
- * @property {string} [dp_name]
333
- * @property {string} [awb_no]
334
- * @property {boolean} [beneficiary_details]
377
+ * @property {string} [returnable_date] - The last date by which the item can be returned.
378
+ * @property {string} [shipment_created_at] - The date and time when the
379
+ * shipment was created.
380
+ * @property {string} [shipment_created_ts] - The timestamp when the shipment was created.
381
+ * @property {Object} [size_info] - An object containing size information for
382
+ * the items in the shipment.
383
+ * @property {Bags[]} [bags] - An array containing details about the individual
384
+ * bags in the shipment.
385
+ * @property {string} [dp_name] - The name of the delivery partner.
386
+ * @property {string} [awb_no] - The airway bill number for the shipment.
387
+ * @property {boolean} [beneficiary_details] - Indicates if there are any
388
+ * beneficiary details.
335
389
  * @property {FulfillingCompany} [fulfilling_company]
336
- * @property {boolean} [can_return]
390
+ * @property {boolean} [can_return] - Indicates if the shipment can be returned.
337
391
  * @property {Address} [delivery_address]
338
392
  * @property {Address} [billing_address]
339
- * @property {string} [track_url]
340
- * @property {string} [order_id]
341
- * @property {string} [need_help_url]
342
- * @property {Object} [return_meta]
343
- * @property {string} [delivery_date]
393
+ * @property {string} [track_url] - The URL for tracking the shipment.
394
+ * @property {string} [order_id] - The unique identifier for the order.
395
+ * @property {string} [need_help_url] - The URL for customer support or help.
396
+ * @property {Object} [return_meta] - An object containing metadata about the
397
+ * return process.
398
+ * @property {string} [delivery_date] - The expected delivery date.
344
399
  * @property {OrderRequest} [order]
345
400
  */
346
401
 
347
402
  /**
348
403
  * @typedef BagsForReorderArticleAssignment
349
- * @property {string} [strategy]
350
- * @property {string} [level]
404
+ * @property {string} [strategy] - The strategy used for article assignment.
405
+ * @property {string} [level] - The level at which the article assignment is made.
351
406
  */
352
407
 
353
408
  /**
354
409
  * @typedef BagsForReorder
355
- * @property {string} [item_size]
356
- * @property {number} [quantity]
357
- * @property {number} [store_id]
410
+ * @property {string} [item_size] - The size of the item.
411
+ * @property {number} [quantity] - The quantity of the item.
412
+ * @property {number} [store_id] - The identifier for the store.
358
413
  * @property {BagsForReorderArticleAssignment} [article_assignment]
359
- * @property {number} [seller_id]
360
- * @property {number} [item_id]
414
+ * @property {number} [seller_id] - The identifier for the seller.
415
+ * @property {number} [item_id] - The unique identifier for the item.
361
416
  */
362
417
 
363
418
  /**
364
419
  * @typedef OrderSchema
365
- * @property {number} [total_shipments_in_order]
366
- * @property {string} [gstin_code]
420
+ * @property {number} [total_shipments_in_order] - The total number of shipments
421
+ * in the order.
422
+ * @property {string} [gstin_code] - The GSTIN code for the shipment.
367
423
  * @property {UserInfo} [user_info]
368
- * @property {BreakupValues[]} [breakup_values]
369
- * @property {string} [order_created_time]
370
- * @property {string} [order_created_ts]
371
- * @property {string} [order_id]
372
- * @property {Shipments[]} [shipments]
373
- * @property {BagsForReorder[]} [bags_for_reorder]
374
- * @property {Object} [meta]
424
+ * @property {BreakupValues[]} [breakup_values] - An array containing the
425
+ * breakup of various charges and discounts.
426
+ * @property {string} [order_created_time] - The date and time when the order was created.
427
+ * @property {string} [order_created_ts] - The timestamp when the order was created.
428
+ * @property {string} [order_id] - The unique identifier for the order.
429
+ * @property {Shipments[]} [shipments] - An array containing details of
430
+ * individual shipments within the order.
431
+ * @property {BagsForReorder[]} [bags_for_reorder] - An array containing details
432
+ * of bags available for reorder.
433
+ * @property {Object} [meta] - An object containing additional metadata for the order.
375
434
  */
376
435
 
377
436
  /**
378
437
  * @typedef OrderStatuses
379
- * @property {number} [value]
380
- * @property {boolean} [is_selected]
381
- * @property {string} [display]
438
+ * @property {number} [value] - The value representing the selection.
439
+ * @property {boolean} [is_selected] - Indicates whether this option is
440
+ * currently selected.
441
+ * @property {string} [display] - The text to display .
382
442
  */
383
443
 
384
444
  /**
385
445
  * @typedef OrderFilters
386
- * @property {OrderStatuses[]} [statuses]
446
+ * @property {OrderStatuses[]} [statuses] - An array containing the order statuses.
387
447
  */
388
448
 
389
449
  /**
390
450
  * @typedef OrderList
391
451
  * @property {OrderPage} [page]
392
- * @property {OrderSchema[]} [items]
452
+ * @property {OrderSchema[]} [items] - List of orders, each containing detailed
453
+ * information about individual orders and their respective shipments.
393
454
  * @property {OrderFilters} [filters]
394
455
  */
395
456
 
396
457
  /**
397
458
  * @typedef ApefaceApiError
398
- * @property {string} [message]
399
- * @property {boolean} [success]
459
+ * @property {string} [message] - Contains any message related to the operation.
460
+ * @property {boolean} [success] - Indicates if the operation was successful.
400
461
  */
401
462
 
402
463
  /**
@@ -411,213 +472,227 @@ const Joi = require("joi");
411
472
 
412
473
  /**
413
474
  * @typedef ResponseGetInvoiceShipment
414
- * @property {string} presigned_type
415
- * @property {boolean} success
416
- * @property {string} shipment_id
417
- * @property {string} presigned_url
475
+ * @property {string} presigned_type - Type of presigned URL.
476
+ * @property {boolean} success - Indicates if the operation was successful .
477
+ * @property {string} shipment_id - Identifier for the shipment.
478
+ * @property {string} presigned_url - The presigned URL for accessing the
479
+ * shipment data, obtained from the response data.
418
480
  */
419
481
 
420
482
  /**
421
483
  * @typedef Track
422
- * @property {string} [account_name]
423
- * @property {string} [shipment_type]
424
- * @property {string} [status]
425
- * @property {string} [last_location_recieved_at]
426
- * @property {string} [updated_time]
427
- * @property {string} [updated_at]
428
- * @property {string} [reason]
429
- * @property {string} [awb]
484
+ * @property {string} [account_name] - The name of the account handling the shipment.
485
+ * @property {string} [shipment_type] - The type of shipment.
486
+ * @property {string} [status] - The current status of the shipment.
487
+ * @property {string} [last_location_recieved_at] - The last known location of
488
+ * the shipment.
489
+ * @property {string} [updated_time] - The timestamp of the last update.
490
+ * @property {string} [updated_at] - The date and time when the shipment was last updated.
491
+ * @property {string} [reason] - The reason or additional information about the shipment.
492
+ * @property {string} [awb] - The Air Waybill (AWB) number for the shipment.
430
493
  */
431
494
 
432
495
  /**
433
496
  * @typedef ShipmentTrack
434
- * @property {Track[]} [results]
497
+ * @property {Track[]} [results] - A array containing tracking details.
435
498
  */
436
499
 
437
500
  /**
438
501
  * @typedef CustomerDetailsResponse
439
- * @property {string} [phone]
440
- * @property {string} [shipment_id]
441
- * @property {string} [name]
442
- * @property {string} [order_id]
443
- * @property {string} [country]
502
+ * @property {string} [phone] - Customer's phone number.
503
+ * @property {string} [shipment_id] - Unique identifier of the shipment.
504
+ * @property {string} [name] - Customer's name.
505
+ * @property {string} [order_id] - Unique identifier of the order.
506
+ * @property {string} [country] - Country of the customer.
444
507
  */
445
508
 
446
509
  /**
447
510
  * @typedef SendOtpToCustomerResponse
448
- * @property {string} [request_id]
449
- * @property {string} [message]
450
- * @property {boolean} [success]
451
- * @property {number} [resend_timer]
511
+ * @property {string} [request_id] - Unique identifier for the request.
512
+ * @property {string} [message] - Message indicating the result of the request.
513
+ * @property {boolean} [success] - Indicates whether the request was successful.
514
+ * @property {number} [resend_timer] - Time in seconds before the OTP can be resent.
452
515
  */
453
516
 
454
517
  /**
455
518
  * @typedef VerifyOtp
456
- * @property {string} [otp_code]
457
- * @property {string} [request_id]
519
+ * @property {string} [otp_code] - The OTP code provided by the user for verification.
520
+ * @property {string} [request_id] - Unique identifier for the request.
458
521
  */
459
522
 
460
523
  /**
461
524
  * @typedef VerifyOtpResponse
462
- * @property {boolean} [success]
525
+ * @property {boolean} [success] - Indicates whether the request was successful.
463
526
  */
464
527
 
465
528
  /**
466
529
  * @typedef BagReasonMeta
467
- * @property {boolean} [show_text_area]
530
+ * @property {boolean} [show_text_area] - Indicates whether to display a text
531
+ * box on the front end.
468
532
  */
469
533
 
470
534
  /**
471
535
  * @typedef QuestionSet
472
- * @property {number} [id]
473
- * @property {string} [display_name]
536
+ * @property {number} [id] - The unique identifier for the question.
537
+ * @property {string} [display_name] - The text displayed for the question.
474
538
  */
475
539
 
476
540
  /**
477
541
  * @typedef BagReasons
478
- * @property {string[]} [qc_type]
479
- * @property {number} [id]
480
- * @property {string} [display_name]
542
+ * @property {string[]} [qc_type] - A list of quality check types.
543
+ * @property {number} [id] - The unique identifier.
544
+ * @property {string} [display_name] - The text displayed.
481
545
  * @property {BagReasonMeta} [meta]
482
- * @property {QuestionSet[]} [question_set]
483
- * @property {BagReasons[]} [reasons]
546
+ * @property {QuestionSet[]} [question_set] - A list of questions for delivery partner.
547
+ * @property {BagReasons[]} [reasons] - A list of reasons.
484
548
  */
485
549
 
486
550
  /**
487
551
  * @typedef ShipmentBagReasons
488
- * @property {BagReasons[]} [reasons]
489
- * @property {boolean} [success]
552
+ * @property {BagReasons[]} [reasons] - A list of shipment's bag reasons.
553
+ * @property {boolean} [success] - Indicates if the operation was successful.
490
554
  */
491
555
 
492
556
  /**
493
557
  * @typedef ShipmentReason
494
- * @property {number} [priority]
495
- * @property {boolean} [show_text_area]
496
- * @property {number} [reason_id]
497
- * @property {string} [feedback_type]
498
- * @property {string} [reason_text]
499
- * @property {string} [flow]
558
+ * @property {number} [priority] - The priority level of the reason.
559
+ * @property {boolean} [show_text_area] - A flag indicating whether to show a
560
+ * textbox on the frontend.
561
+ * @property {number} [reason_id] - The unique identifier for the reason.
562
+ * @property {string} [feedback_type] - The type of feedback.
563
+ * @property {string} [reason_text] - The text describing the reason.
564
+ * @property {string} [flow] - The process flow related to the reason.
500
565
  */
501
566
 
502
567
  /**
503
568
  * @typedef ShipmentReasons
504
- * @property {ShipmentReason[]} [reasons]
569
+ * @property {ShipmentReason[]} [reasons] - A list of shipment reasons.
505
570
  */
506
571
 
507
572
  /**
508
573
  * @typedef ProductsReasonsData
509
- * @property {number} [reason_id]
510
- * @property {string} [reason_text]
574
+ * @property {number} [reason_id] - The unique identifier for the reason.
575
+ * @property {string} [reason_text] - The text describing the reason.
511
576
  */
512
577
 
513
578
  /**
514
579
  * @typedef ProductsReasonsFilters
515
- * @property {number} [line_number]
516
- * @property {number} [quantity]
517
- * @property {string} [identifier]
580
+ * @property {number} [line_number] - The specific line item of bag.
581
+ * @property {number} [quantity] - The quantity of the product.
582
+ * @property {string} [identifier] - The unique identifier for the product.
518
583
  */
519
584
 
520
585
  /**
521
586
  * @typedef ProductsReasons
522
587
  * @property {ProductsReasonsData} [data]
523
- * @property {ProductsReasonsFilters[]} [filters]
588
+ * @property {ProductsReasonsFilters[]} [filters] - Criteria applied to filter
589
+ * the products.
524
590
  */
525
591
 
526
592
  /**
527
593
  * @typedef EntityReasonData
528
- * @property {number} [reason_id]
529
- * @property {string} [reason_text]
594
+ * @property {number} [reason_id] - The unique identifier for the reason.
595
+ * @property {string} [reason_text] - The text describing the reason.
530
596
  */
531
597
 
532
598
  /**
533
599
  * @typedef EntitiesReasons
534
600
  * @property {EntityReasonData} [data]
535
- * @property {Object[]} [filters]
601
+ * @property {Object[]} [filters] - Criteria applied to filter the shipment.
536
602
  */
537
603
 
538
604
  /**
539
605
  * @typedef ReasonsData
540
- * @property {ProductsReasons[]} [products]
541
- * @property {EntitiesReasons[]} [entities]
606
+ * @property {ProductsReasons[]} [products] - Reasons data for bags.
607
+ * @property {EntitiesReasons[]} [entities] - Reasons data for shipments.
542
608
  */
543
609
 
544
610
  /**
545
611
  * @typedef Products
546
- * @property {number} [line_number]
547
- * @property {number} [quantity]
548
- * @property {string} [identifier]
612
+ * @property {number} [line_number] - The specific line item of bag.
613
+ * @property {number} [quantity] - The quantity of the product.
614
+ * @property {string} [identifier] - The unique identifier for the product.
549
615
  */
550
616
 
551
617
  /**
552
618
  * @typedef ProductsDataUpdatesFilters
553
- * @property {number} [line_number]
554
- * @property {string} [identifier]
619
+ * @property {number} [line_number] - The specific line item of bag.
620
+ * @property {string} [identifier] - The quantity of the product.
555
621
  */
556
622
 
557
623
  /**
558
624
  * @typedef ProductsDataUpdates
559
- * @property {Object} [data]
560
- * @property {ProductsDataUpdatesFilters[]} [filters]
625
+ * @property {Object} [data] - Information about the data to be updated.
626
+ * @property {ProductsDataUpdatesFilters[]} [filters] - Criteria applied to
627
+ * filter the products.
561
628
  */
562
629
 
563
630
  /**
564
631
  * @typedef EntitiesDataUpdates
565
- * @property {Object} [data]
566
- * @property {Object[]} [filters]
632
+ * @property {Object} [data] - Information about the data to be updated.
633
+ * @property {Object[]} [filters] - Criteria applied to filter the shipments.
567
634
  */
568
635
 
569
636
  /**
570
637
  * @typedef DataUpdates
571
- * @property {ProductsDataUpdates[]} [products]
572
- * @property {EntitiesDataUpdates[]} [entities]
638
+ * @property {ProductsDataUpdates[]} [products] - Data updates for bags.
639
+ * @property {EntitiesDataUpdates[]} [entities] - Data updates for shipments.
573
640
  */
574
641
 
575
642
  /**
576
643
  * @typedef ShipmentsRequest
577
644
  * @property {ReasonsData} [reasons]
578
- * @property {Products[]} [products]
645
+ * @property {Products[]} [products] - Specific bag to be updated.
579
646
  * @property {DataUpdates} [data_updates]
580
- * @property {string} identifier
647
+ * @property {string} identifier - The unique identifier for request which is
648
+ * the shipment_id.
581
649
  */
582
650
 
583
651
  /**
584
652
  * @typedef StatuesRequest
585
- * @property {ShipmentsRequest[]} [shipments]
586
- * @property {string} [exclude_bags_next_state]
587
- * @property {string} [status]
653
+ * @property {ShipmentsRequest[]} [shipments] - A list containing information
654
+ * about shipments.
655
+ * @property {string} [exclude_bags_next_state] - State to be change for
656
+ * Remaining Bag/Products.
657
+ * @property {string} [status] - The status to which the entity is to be transitioned.
588
658
  */
589
659
 
590
660
  /**
591
661
  * @typedef OrderRequest
592
- * @property {Object} [meta]
662
+ * @property {Object} [meta] - Metadata for the order.
593
663
  */
594
664
 
595
665
  /**
596
666
  * @typedef UpdateShipmentStatusRequest
597
- * @property {StatuesRequest[]} [statuses]
598
- * @property {boolean} [task]
599
- * @property {boolean} [lock_after_transition]
600
- * @property {boolean} [force_transition]
601
- * @property {boolean} [unlock_before_transition]
667
+ * @property {StatuesRequest[]} [statuses] - An array containing different status details.
668
+ * @property {boolean} [task] - Indicates whether the task is active or required.
669
+ * @property {boolean} [lock_after_transition] - Indicates whether the status
670
+ * should be locked after the transition.
671
+ * @property {boolean} [force_transition] - Indicates whether the transition
672
+ * should be forced.
673
+ * @property {boolean} [unlock_before_transition] - Indicates whether the status
674
+ * should be unlocked before the transition.
602
675
  */
603
676
 
604
677
  /**
605
678
  * @typedef StatusesBodyResponse
606
- * @property {Object[]} [shipments]
679
+ * @property {Object[]} [shipments] - List of shipments.
607
680
  */
608
681
 
609
682
  /**
610
683
  * @typedef ShipmentApplicationStatusResponse
611
- * @property {StatusesBodyResponse[]} [statuses]
684
+ * @property {StatusesBodyResponse[]} [statuses] - An array containing different
685
+ * status options of shipments.
612
686
  */
613
687
 
614
688
  /**
615
689
  * @typedef ErrorResponse
616
- * @property {string} [code]
617
- * @property {string} [message]
618
- * @property {number} [status]
619
- * @property {string} [exception]
620
- * @property {string} [stack_trace]
690
+ * @property {string} [code] - The HTTP status code of the response.
691
+ * @property {string} [message] - A message providing details about the response.
692
+ * @property {number} [status] - An additional code providing more context about
693
+ * the response.
694
+ * @property {string} [exception] - Details of any exception that occurred.
695
+ * @property {string} [stack_trace] - The stack trace of any exception that occurred.
621
696
  */
622
697
 
623
698
  class OrderApplicationModel {
@@ -981,6 +1056,7 @@ class OrderApplicationModel {
981
1056
  OrderApplicationModel.ShipmentPaymentInfo()
982
1057
  ),
983
1058
  order_type: Joi.string().allow("").allow(null),
1059
+ gstin_code: Joi.string().allow(""),
984
1060
  show_download_invoice: Joi.boolean(),
985
1061
  can_cancel: Joi.boolean(),
986
1062
  user_info: OrderApplicationModel.ShipmentUserInfo(),