Subscribe to MFN notifications
Learn how to use the Notifications API to subscribe to notifications that are relevant to a selling partner's business.
Learn how to use the Selling Partner API for Notifications to subscribe to notifications that are relevant to a selling partner's business. With this API, you can create a destination to receive, subscribe, and delete notification subscriptions. Instead of polling for information, your application can receive information directly from Amazon when an event activates a notification to which you are subscribed.
Important
Sellers can subscribe to the
ORDER_CHANGEnotification, which is sent whenever there is an order availability status change.The
MFN_ORDER_STATUS_CHANGEandORDER_STATUS_CHANGEnotification types have been removed. Please update your applications to use theORDER_CHANGEnotification.ORDER_CHANGEsends an order-level payload whenever there is an important change in the order. Important changes include order status changes and buyer requested cancellations. For detailed information about SP-API deprecation dates, refer to the deprecations table.
Step 1. Subscribe to the ORDER_CHANGE notification
ORDER_CHANGE notificationTo set up and subscribe to the ORDER_CHANGE notification, follow the Set up notifications using the Amazon Simple Queue Service workflow. The following figure provides an illustrated overview of the tutorial.

Step 2. Poll the queue to retrieve the latest ORDER_CHANGE messages
ORDER_CHANGE messages-
Retrieve the queue URL: Connect to the SQS service and retrieve the URL for the queue that receives the
ORDER_CHANGEmessages. This URL uniquely identifies the queue and is used to interact with it. -
Configure polling parameters: Review the polling parameters to determine how frequently and how many messages to retrieve at a time. This includes the wait time between subsequent polling attempts and the maximum number of messages to retrieve in each request.
-
Poll the queue: To poll the queue, send the requests to retrieve the messages. Use the
ReceiveMessageoperation to retrieve the messages from the queue. When you call this operation, you can specify the queue URL, maximum number of messages to retrieve, and other optional parameters, such as visibility timeout.Alternatively, you can configure event source mapping to automatically invoke a Lambda function when new messages arrive to the SQS queue. For more information on event source mapping, refer to Tutorial: Using Lambda with Amazon SQS.
-
Process the messages: When you receive the messages, you can process them according to your application's requirements. In the case of
ORDER_CHANGEmessages from the SP-API, you can extract the relevant information, such as the order ID, status change details, and timestamps. -
Delete processed messages: After each message is successfully processed, make sure to delete it from the queue with the
DeleteMessageoperation provided by SQS. This step ensures that the processed messages are removed from the queue and won't be retrieved again in subsequent polling attempts.
Step 3. Process the order information and call shipment services
The ORDER_CHANGE notification returns high-level information related to the order, such as the OrderId, OrderItemId and the OrderStatus. To learn more, refer to ORDER_CHANGE.
To automate the fulfillment process, you must:
- Check notification messages with an
OrderStatusofUpComing,Pending, orUnshipped. Check thatMFNis within theFulfillmentChannelattribute.
Note
This is a restricted operation and requires a Restricted Data Token (RDT) for authorization. Some operations require restrictions because they contain customer PII data. These operations require passing an additional security review. For more information on RDT, refer to the Tokens API guide.
- Retrieve order and shipping information with the
getOrderoperation. - Pass this information to the
getEligibileShipmentServicesoperation and follow the steps in Fulfill seller-fulfilled Prime and non-Prime order.
Updated 14 days ago
