This page provides the list of events and associated payloads for the Order microservice.

List of Events

SL.#NameDescriptionPublish LocationRouting KeyDurabilityPayload Type
1Order CreatedThis event will be triggered when an order is created.Topic: ecommorder.createdFALSENotification
2Order CanceledThis event is triggered when the user cancels the order or order items.Topic: ecommorder.cancelledFALSENotification
3Order DeletedThis event will be triggered when an order is deleted.Topic: ecommorder.deletedFALSENotification
4Order to InventoryEvent to publish the inventory to block the item in the inventory. When the order's inventory has to be blocked, this event will be called.Queue: inventory.bulktransactionsInventory check eventFALSEInventoryBulkTransaction
5Order to PromotionEvent to publish the promotion to the block or apply operations for the applied promotions in the order. When the order's promotions have to be blocked, a block promotion event is sent. When the order's promotion has to be assigned, an assign promotion event is sent.Queue: promotion.block/assignPromotion check eventFALSEPromotionBulkTransaction
6Order to PaymentEvent to publish the payment to charge, refund, or authorize the payment. When the order has to be authorized with the payment given by the user, either charge for the order or refund the amount to the user if the order is canceled, deleted or returned.Queue: payment.bulkTransactionRequestQueuePayment check eventFALSEPaymentBulkTransaction
7Order ReturnThis event will be triggered when an order or order item return is accepted.Topic:ecommorder.returnFALSENotification
8Order ShippedThis event will be triggered when an order is shipped.Topic:ecommorder.shippedFALSENotification
9Check FraudThis event will be triggered when a fraud check is performed.Topic: OmsMsgTopicorder.checkfraudFALSECheckFraud
10Preprocess InventoryThis event will be triggered to show the process on the inventory block when an order is created or updated.Topic: OmsMsgTopicorder.preprocessinventoryFALSEPreProcessInventory
11Preprocess PaymentThis event will be triggered to show the processing on the payment block when an order is created or updated.Topic: OmsMsgTopicorder.preprocesspaymentFALSEPreProcessPayment
12Preprocess PromotionThis event will be triggered to show the process on the promotion block when an order is created or updated.Topic: OmsMsgTopicorder.preprocesspromotionFALSEPreProcessPromotion
13Order Return SubmittedThis event will be triggered, when an order or order item return is submitted.Topic:ecommorder.return.submittedFALSENotification
14Undo Preprocess InventoryThis event will be triggered when undo a preprocessing of inventory in an order.Topic: OmsMsgTopicorder.undopreprocessinventoryFALSEPreProcessInventory
15Undo Preprocess PaymentThis event will be triggered when undo a preprocessing of the payment in an order.Topic: OmsMsgTopicorder.undopreprocesspaymentFALSEPreProcessPayment
16Update ShipmentThis event will be triggered when shipment status is updated.Topic: OmsMsgTopicorder.updateshipmentFALSEOrderDelegate
17Create Exchange OrderThis event is triggered when an exchange order is created.Topic:ecommorder.exchangeFALSENotification
18Create Replace OrderThis event is triggered when a replace order is created.Topic:ecommorder.replaceFALSENotification

List of Fat Events 

When order patch is done to change the order status, the fat events override the existing thin events. Below are the properties that are processed for the fat events: 

PROPERTYValueDESCRIPTION
enableExternalEventTrueSends the event to the external target system.
enableFatEventTrueEnables the fat event.
externalFatEventClassIndicates the plugin class name that is used to modify and add the event payload data.
eventbridgeIndicates the AWS service used to send the event from source to target.
regionIndicates the AWS eventbridge region.
eventBusNameIndicates the event bridge bus name.
 
Note:

Payload Models

Below are the payloads for the Order microservice events.

InventoryBulkTransaction

PROPERTYTYPEDESCRIPTIONEXAMPLE
binItems.binNameStringIndicates the name of the bin in Inventory.bin1
binItems.skuIdStringIndicates the SKU ID of the order.sku1
binItems.transaction.idStringIndicates the ID of the transaction.1
binItems.transaction.typeIntegerIndicates the type of the transaction. The possible transaction types are: NONE (0), ADD (1), REMOVE (2), or TRANSFER (3).1
binItems.transaction.atpQtyIntegerIndicates the available quantity to purchase.3
binItems.transaction.notesStringSpecifies the information about the transaction.This is the bin which contains shoes
allOrNoneBooleanIndicates whether the transaction type is All or None.TRUE

PromotionBulkTransaction

PROPERTYTYPEDESCRIPTIONEXAMPLE
idStringIndicates the ID of the order.Order1
typeStringIndicates the type of the transaction whether it is ASSIGN or BLOCK.BLOCK
promoCodesInfo[].confirmationCodeStringIndicates the confirmation code, which is to be checked.confirm1
promoCodesInfo[].promoCodeStringIndicates the promo code, which is used.FLAT50

PaymentBulkTransaction

PROPERTYTYPEDESCRIPTIONEXAMPLE
transactions[].valuelongIndicates the value of the transaction.1000
transactions[].typeStringIndicates the type of transaction, such as AUTH, CANCELAUTH, CHARGE, and REFUND.REFUND
transactions[].properties[].nameStringIndicates the custom property of the transaction.It is a charge transaction
transactions[].properties[].valueStringIndicates the value of the property transaction.1000
transactions[].paymentItemIdStringIndicates the ID of the payment item.p1
transactions[].idStringIndicates the ID of the transaction.p1
transactions[].statusStringIndicates the status of the transaction.CHARGE
transactions[].responseCodeStringIndicates the response code of the transaction.200
transactions[].responseMessageStringIndicates the response message of the transaction.Success
transactions[].createdByStringIndicates the user, who has created the transaction.p1
transactions[].createdTimelongIndicates the created timestamp (in milliseconds) of the transaction.1548328965
allOrNonebooleanIndicates whether all the transactions has to be processed or not.TRUE

OrderDelegate

PROPERTYTYPEDESCRIPTIONEXAMPLE
collectionIdlongIndicates the collection ID of the order, which is created, canceled, or deleted.1
localestringIndicates the locale of the message.en-US
orderIdStringIndicates the ID of the order.Order1
orderPatchDTO.statusStringIndicates the status of the transaction.CHARGE
orderPatchDTO.reasoncodeStringIndicates the reason code of the operation made on the order.200
orderPatchDTO.reasonmessageStringIndicates the reason message of the operation made on the order.Success
orderPatchDTO.properties[].nameStringIndicates the custom property of the order.It is a charge transaction
orderPatchDTO.properties[].valueStringIndicates the value of the order property.1000
orderPatchDTO.orderItemPatchDTO[].idStringIndicates the item ID of the order.OI1
orderPatchDTO.orderItemPatchDTO[].statusStringIndicates the status of the item.Shipped
orderPatchDTO.orderItemPatchDTO[].reasoncodeStringIndicates the reason code of the operation made on the order.200
orderPatchDTO.orderItemPatchDTO[].reasonmessageStringIndicates the reason message of the operation made on the order.Success
orderPatchDTO.orderItemPatchDTO[].properties[].nameStringIndicates the custom property of the item.It is a charge transaction
orderPatchDTO.orderItemPatchDTO[].properties[].valueStringIndicates the value of the item property.1000
orderPatchDTO.orderItemPatchDTO[].otherproperties[].nameStringIndicates the additional property of the item.It is a charge transaction
orderPatchDTO.orderItemPatchDTO[].otherproperties[].valueStringIndicates the value of the item property.1000
orderPatchDTO.orderItemPatchDTO[].quantityIntegerIndicates the quantity of the item.3
orderPatchDTO.orderItemPatchDTO[].returnableBooleanIndicates whether the item can be returned or not.TRUE
orderPatchDTO.UserPatchDTO.useridStringIndicates the ID of the user.USER1
orderPatchDTO.userTrackingDTO.firstnameStringIndicates the first name of the user.john
orderPatchDTO.userTrackingDTO.lastnameStringIndicates the last name of the user.smith
orderPatchDTO.userTrackingDTO.zipStringIndicates the zip code of the user address.11111
orderPatchDTO.userTrackingDTO.guestuserbooleanIndicates whether the user is guest user or not.FALSE
orderPatchDTO.userTrackingDTO.guestuseridStringContains the ID of the guest user.guest1
orderPatchDTO.userTrackingDTO.ipStringIndicates the IP address of the user.1.1.1.1
orderPatchDTO.userTrackingDTO.accountidStringIndicates the account ID of the user.account1
orderPatchDTO.userTrackingDTO.useridStringIndicates the ID of the user.USER1
orderPatchDTO.userTrackingDTO.usercontact.phoneStringIndicates the phone number of the user.91000000000
orderPatchDTO.userTrackingDTO.usercontact.emailStringIndicates the email ID of the user.someone@example.com
orderPatchDTO.userTrackingDTO.usercontact.preferredcontactStringIndicates the preferred contact of the user.EMAIL, TEXT, PHONE
orderPatchDTO.otherpropertiesListIndicates the custom properties of the order.shipmentid: “id1234”
paymentTrans[].valuelongIndicates the value of the transaction.1000
paymentTrans[].typeStringIndicates the type of transaction – AUTH, CANCELAUTH, CHARGE, and REFUND.REFUND
paymentTrans[].properties[].nameStringIndicates the custom property of the transaction.It is a charge transaction
paymentTrans[].properties[].valueStringIndicates the value of the transaction property.1000
paymentTrans[].paymentItemIdStringIndicates the ID of the payment item.p1
paymentTrans[].idStringIndicates the ID of the transaction.p1
paymentTrans[].statusStringIndicates the status of the transaction.CHARGE
paymentTrans[].responseCodeStringIndicates the response code of the transaction.200
paymentTrans[].responseMessageStringIndicates the response message of the transaction.Success
paymentTrans[].createdByStringIndicates the user, who has created the transaction.p1
paymentTrans[].createdTimelongIndicates the created timestamp (in milliseconds) of the transaction.1548328965

CheckFraud

PROPERTYTYPEDESCRIPTIONEXAMPLE
orderidStringIndicates the unique ID of the order, which is created, canceled, or deleted.Order1
statusStringIndicates the status of the order.Shipped
fraudbooleanIndicates whether the transaction is fraud or not.FALSE

PreProcessInventory

PROPERTYTYPEDESCRIPTIONEXAMPLE
orderidStringIndicates the unique ID of the order, which is created, canceled, or deleted.Order1
collectionIdlongIndicates the collection ID of the order, which is created, canceled, or deleted.1
inventoryCollectionIdlongIndicates the collection ID of the inventory associated with the current order.1
binItems[].binNameStringIndicates the name of the bin in the inventory.bin1
binItems[].skuIdStringIndicates the SKU ID of the order.sku1
binItems[].transaction.idStringIndicates the ID of the transaction.1
binItems[].transaction.typeIntegerIndicates the type of transaction. The possible transaction types are: NONE (0), ADD (1), REMOVE (2), TRANSFER (3).1
binItems[].transaction.atpQtyIntegerIndicates the available quantity to purchase.3
binItems[].transaction.notesStringIndicates the notes added to the transaction.This is the bin which contains shoes

PreProcessPayment

PROPERTYTYPEDESCRIPTIONEXAMPLE
orderidStringIndicates the unique ID of the order, which is created, canceled, or deleted.Order1
collectionIdlongIndicates the collection ID of the order, which is created, canceled, or deleted.1
paymentCollectionIdlongIndicates the collection ID of the payment associated with the current order.1
allOrNoneBooleanIndicates whether the transaction type is All or None.TRUE
transactions[].valuelongIndicates the value of the transaction.1000
transactions[].typeStringIndicates the type of the transaction. The possible transaction types are: AUTH, CANCELAUTH, CHARGE, and REFUND.REFUND
transactions[].properties[].nameStringIndicates the custom property of the transaction.It is a charge transaction
transactions[].properties[].valueStringIndicates the value of the transaction property.1000
transactions[].paymentItemIdStringIndicates the ID of the payment item.p1
transactions[].idStringIndicates the ID of the transaction.p1
transactions[].statusStringIndicates the status of the transaction.CHARGE
transactions[].responseCodeStringIndicates the response code of the transaction.200
transactions[].responseMessageStringIndicates the response message of the transaction.Success
transactions[].createdByStringIndicates the user, who has created the transaction.p1
transactions[].createdTimelongIndicates the created timestamp (in milliseconds) when the transaction is created.1548328965

PreProcessPromotion

PROPERTYTYPEDESCRIPTIONEXAMPLE
orderidStringIndicates the unique ID of the order, which is created, canceled, or deleted.Order1
collectionIdlongIndicates the collection ID of the order, which is created, canceled, or deleted.1
promotionCollectionIdlongIndicates the collection ID of the promotion associated with the current order.1
promotionList[].confirmationCodeStringIndicates the confirmation code, which is to be checked.confirm1
promotionList[].promoCodeStringIndicates the promo code, which is used.FLAT50

Notification

PROPERTYTYPEDESCRIPTIONEXAMPLE
idLongIndicates the unique ID of the notification.1000
createdtimeLongIndicates the created time of the notification in milliseconds.1516789034567
createdbyStringContains the ID of the user, who has created the notification.123
statusStringSpecifies the status of the notification.Cancelled
descriptionStringIndicates the description of the notification.Order/ Order item is canceled.
typeStringIndicates the type of the notification. The possible values are: ORDER_CREATED
ORDER_DELETED, ORDER_CANCELLED, ORDER_RETURN_SUBMIT, and ORDER_RETURN_ACCEPTED.
ORDER_RETURN_SUBMIT
itemIdStringIndicates the ID of the item to be canceled.SHOE
paymentitemidStringIndicates the ID of the payment item, which is associated with the item to be canceled.567
propertiesHashMapContains the custom properties of the notification.

Event Payload With and Without Fat Event

Event NamePayload
Without Fat Event{
"version": "0",
"id": "7876b55f-a6d6-78dd-8b0e-6006dfebf4ea",
"detail-type": "omsservices/orders/create",
"source": "omsservices",
"account": "769072969658",
"time": "2023-04-24T06:25:45Z",
"region": "us-east-1",
"resources": [],
"detail": {
"timestamp": 1682317543767,
"eventType": "omsservices/orders/create",
"userId": "111",
"actOnBehalfOfUser": 0,
"roles": [
"ROLE_SUPER_ADMIN"
]
}
}
With Fat Event{
id: '185de16879co0to',
orderdetails: [Object],
orderinfo: [Object],
orderitems: [Array],
status: [Array],
nextstatus: [Array],
allowedPatchFields: null,
failedReason: null,
otherproperties: [Object],
payments: [Array],
math: [Array],
transactions: [Array],
fraud: null,
usertracking: [Object],
notes: [Array],
itemLevelPatchAllowed: true,
priceFacets: null,
specialProducts: null
}
 

 

Revision History
2023-06-13 | SW – Updated the content for 8.14 release.
2020-01-14 | Ananthi – Updated content for February 2020 release.
2019-10-31 | Mary – Updated content for November 2019 release. 
2019-05-16 | Ananthi – Updated to a new table tool. 
2019-05-06 | PLK – Minor copyedits.
2019-04-11 | MA – Content updated for April 2019 release.
2019-01-23 | PLK – Content uploaded.