PriceAdjustmentAdd and PriceAdjustmentUpdate Schema Changes

Hi,

JCP Platform API incorporated the changes for passing message list for breakup_values array. To provide these meesage list, we need to get the related changes with PriceAdjustmentAdd and PriceAdjustmentUpdate Schema’s.

“breakup_values”: {
“display”: [

{
“display”: “Delivery Charge”,
“key”: “delivery_charge”,
“original”: 250.0,
“attr”: “delivery_charge”,
“value”: 250.0,
“currency_code”: “INR”,
“currency_symbol”: “\u20b9”,
“message”: [
“Delivery charges applicable 250.0 on this order”
]
}, …

As per 1.3.10-beta.3 API, both PriceAdjustmentUpdate and PriceAdjustmentAdd is permits to pass only one message and not a list of messages.

Please refer the below structure here::

public class CartPlatformModels$PriceAdjustmentUpdate

@JsonProperty(“message”)
private String message;

public class CartPlatformModels$PriceAdjustmentAdd {
@JsonProperty(“message”)
private String message;

Kindly make the change in PriceAdjustmentUpdate and PriceAdjustmentAdd to permit the list of messages.

Used priceAdjustementAdd API and included details into Meta Object… These values are not present, when we refetch the cart using getCart API…

Note: Setting 0 delivery charge using the priceAdjustementAdd API…
2024-04-01T11:23:00.831+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.shipmentfee.utils.ControllerUtils : PriceAdjustmentAdd: delivery charge received for cart id 651fe4e3628a42523e388a96 is 0
2024-04-01T11:23:00.904+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.s.controller.CartController : cart type UNIVERSAL cart id 651fe4e3628a42523e388a96 price adjustment id 660a4bbc7818533dc53a9e2b value received from redis OK expires response received 1 current secs 1711950780 expires after 86400
2024-04-01T11:23:00.904+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.shipmentfee.utils.ControllerUtils : Redis.Set function took 1 milliseconds
2024-04-01T11:23:00.904+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.s.controller.CartController : price added via injection for cart id : 651fe4e3628a42523e388a96. injectionId 660a4bbc7818533dc53a9e2b response data id: 660a4bbc7818533dc53a9e2b value 0.0 type delivery_charge meta {defined_delivery_charge=90, delivery_charge_details_list=[{delivery_charge_config_name=SMART_BAZAAR_BUCKET, delivery_charge_msg=Yay! You get FREE delivery with this order, applied_delivery_charge=0, defined_delivery_charge=40}, {delivery_charge_config_name=JIOMART_BUCKET, delivery_charge_msg=Yay! You get FREE delivery with this order, applied_delivery_charge=0, defined_delivery_charge=50}]}
2024-04-01T11:23:00.904+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.shipmentfee.utils.ControllerUtils : addPriceAdjustment function took 75 milliseconds
2024-04-01T11:23:01.319+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.shipmentfee.utils.ControllerUtils : PlatformApplicationClient.getCart function took 415 milliseconds
2024-04-01T11:23:01.319+05:30 INFO 1 — [JioMart Shipment Fee Extension] [p-nio-80-exec-4] c.f.shipmentfee.utils.ControllerUtils : Extension.getCart function took 1348 milliseconds