question

mankee10200 avatar image
mankee10200 asked David Marginian Deactivated commented

Refund Webhook Events

I'm trying to intercept refund events using the webhook functionality.

First of all, I'd like to understand how to trigger a refund from the sandbox environment in order to be able to test this. I don't see any option to do this.

In addition, I would like to know which events to listen to in the webhook in order to intercept refunds?

OrdersPaymentsWebhooksRefund
10 |2000

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

David Marginian avatar image
David Marginian Deactivated answered mankee10200 commented

I believe you will need to listen for Payment events. Payments can be refunded via the ECommerce API - https://docs.clover.com/docs/ecommerce-refunding-payments.

6 comments
10 |2000

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

mankee10200 avatar image mankee10200 commented ·

What about this part of the question - "First of all, I'd like to understand how to trigger a refund from the sandbox environment in order to be able to test this. I don't see any option to do this."

0 Likes 0 ·
David Marginian avatar image David Marginian ♦♦ mankee10200 commented ·

If you don't have a devkit, payments can be refunded via the ECommerce API - https://docs.clover.com/docs/ecommerce-refunding-payments.

0 Likes 0 ·
mankee10200 avatar image mankee10200 David Marginian ♦♦ commented ·

In that case, can you provide an example of a refund webhook payload (when a merchant would trigger the refund from their clover device)? On the webhook API docs here: https://docs.clover.com/docs/webhooks I see the event types etc, but not full payload examples, and what's included in the updates.

This would help us understand how to parse the webhook response.

0 Likes 0 ·
Show more comments
tony11 avatar image
tony11 answered David Marginian Deactivated commented

Hi David, please send a sample of the payload. I’m running into the same issue. Thanks

5 comments
10 |2000

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

David Marginian avatar image David Marginian ♦♦ commented ·
I don't have the availability to do that. You will need to trigger a refund on your end at some point anyway, can't imagine you would want to not test messages. Also, in order to use web hooks you have to have an approved app, have you started going through the approval process?
0 Likes 0 ·
tony11 avatar image tony11 David Marginian ♦♦ commented ·
I understand what you’re saying, but how do we test it? Also, it’s ideal and makes more sense to have everything correctly done before the approval process. However, if that’s what you suggest, we will go ahead with this option.
0 Likes 0 ·
David Marginian avatar image David Marginian ♦♦ tony11 commented ·
You can test it by making a refund via the ECommerce API per the link I previously sent you.
0 Likes 0 ·
Show more comments

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