x

How to create a refund after using checkoutAPI instead of paymentAPI?

I'd rather have Square take care of the payment process. Therefore, I've opted for the Square hosted checkout form. Obviously, I need to create the form using the checkoutAPI. However, I've noticed after a successful transaction, I'm only given the transationID and the checkoutID. Incidentally, I need the paymentID in order to create a refund and it appears that the only way to get the paymentID is to create a payment using the Sqaure payment form provided by 'js.squareup.com.' So, does anyone know how to create a refund using the Square CheckoutAPI?

1,655 Views
Message 1 of 3
Report
1 Best Answer
Admin

Best Answer

Here's an update for you @Knowtifyd: You'll need to call either BatchRetrieveOrders or SearchOrders with the transaction_id. Once you have the order you can get the payment_id and use it to RefundPayment.

️ Helen
Seller Community Manager

Did you find help in the Seller Community? Mark a Best Answer to help others.

View Best Answer >

757 Views
Message 3 of 3
Report
2 REPLIES 2
Admin

Hi @Knowtifyd, I've just escalated this to an API Specialist for you. Hang in there, I'll reply here as soon as I can!

️ Helen
Seller Community Manager

Did you find help in the Seller Community? Mark a Best Answer to help others.
802 Views
Message 2 of 3
Report
Admin

Best Answer

Here's an update for you @Knowtifyd: You'll need to call either BatchRetrieveOrders or SearchOrders with the transaction_id. Once you have the order you can get the payment_id and use it to RefundPayment.

️ Helen
Seller Community Manager

Did you find help in the Seller Community? Mark a Best Answer to help others.
758 Views
Message 3 of 3
Report