question

jms avatar image
jms asked David Marginian answered

Refunding partially paid orders

Hi, we encountered an issue where we are not able to refund an order that was partially paid for.

Order was paid for using /v1/orders/{orderId}/pay

However, when trying to completely refund the order, we get an error:

Request
POST /v1/orders/{orderId}/returns

Response
{"message":"400 Bad Request","error":{"code":"processing_error","message":"This refund would make the order's total refunded amount greater than the original order's amount."}}

Notice that (as per https://docs.clover.com/docs/ecommerce-refunding-payments#refunding-payments-without-order-items-to-be-returned) we do not include the individual lineItems, but expect the above to refund the whole order. However, we are very confused how this request fails with the mentioned reason.

This was not a problem before and the above endpoint was used to successfully refund orders.

Please let us know how we can refund these orders. I assume we can't use the /v1/refunds endpoint due to documentation explicitly mentioning that it cannot refund orders with >1 line items or tips, and the fact that we do not use the /v1/charges endpoint to create these charges.

e-commerce apiRefund
10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
David Marginian avatar image
David Marginian answered

I created a ticket for the ecomm team to take a look.

10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community