Best Practices for Refunds
Important
The Buy with Prime API is offered as a preview and might change as we receive feedback and iterate on the interfaces. We are sharing this early documentation to help you learn about the Buy with Prime API as we write and iterate on the content.
When you process a Buy with Prime refund request, you call the updateOrder
mutation and include as much information as possible about the refund. This topic provides best practices for processing refunds.
For troubleshooting information, see Troubleshoot Refund Errors and Troubleshoot Order Errors.
Processing refunds
Subscribe to Events. When you receive a REFUND_REQUESTED
event, process the event by using Steps to Process Refunds.
Providing refund IDs
When you provide refund details to updateOrder
, you provide refund IDs in RefundDetailsInput
. Heed the following best practices to avoid errors providing refund IDs.
- To avoid a
MissingRefundId
error, you must provide a refund ID toupdateOrder
. - To avoid an
InvalidRefundId
error, the refund ID that you provide toupdateOrder
must be the exactid
from therefunds.details
field returned from aREFUND_REQUESTED
event or theorder
query. - To avoid a
DuplicateRefundId
error, the refund ID that you provide toupdateOrder
must be unique across elements in therefunds.details
list for a single call toupdateOrder
.
Related topics
Updated about 17 hours ago