Is there any next event allowed after transaction is BLOCKED, REFUNDED, RETURNED, DENIED ?

jackosky
Contributor
Contributor

Currently I'm working on implementing webhook in our webapp and I was wonder if there are any events expected after we get one of these:

BLOCKED

REFUNDED

RETURNED

* DENIED

 

I was planing to map these statuses as final in our app, but I couldn't find any info about possible event flow.

 

 

Login to Me Too
4 REPLIES 4

MTS_Jennifer
Moderator
Moderator

There are about 48 webhook events for which an app can be subscribed. It depends on what API Methods the app is using, such as Sale, Authorization, Capture, Billing Agreements, and etc.

Here is a listing of every possible webhook event and the Rest API Method that is affiliated with the webhook event along with what event triggers the webhook:

Webhooks Events

 

If its a sale transaction then these are the events that you could possibly receive:
Completed
Denied
Pending
Refunded
Reversed

 

The Blocked event is associated with Payouts. If you are not sending Payouts then you will not see any events listed as Blocked.

If you do not see an event in the list then there is not currently a webhook created for the event at this time.

 

Thanks,

Jennifer

 

Login to Me Too

jackosky
Contributor
Contributor

Okay, so I didn't precise enough in what kind of webhooks I'm currently interested in.

 

So I'm integrating with PayPal using Payouts API and I'm only interested in PAYMENT.PAYOUTS-ITEM.* events to track status of individual items.

 

For some of the events I can't simulate or get the idea what transaction statuses I can expect further.

 

Consider following scenarios:

 

1. Send PayoutItem to PayPal

2. PayPal sent event PAYMENT.PAYOUTS-ITEM.BLOCKED with transaction status BLOCKED (?)

3. Is there any other event expected after getting this one? 

 

1. Send PayoutItem to PayPal

2. PayPal sent event PAYMENT.PAYOUTS-ITEM.DENIED with transaction status DENIED (?)

3. Is there any other event expected after getting this one? 

 

1. Send PayoutItem to PayPal

2. PayPal sent an event PAYMENT.PAYOUTS-ITEM.CANCELED

3. Is there any other event expected after getting this one? 

4. What kind of transaction statuses I can expect in CANCELED event?

 

Additional question:

* Is that a rule when merchant is canceling unclaimed payment through UI then PayPal is sending event PAYMENT.PAYOUTS-ITEM.RETURNED with transaction status REVERSED?

* How can I achieve RETURNED transaction status? What is the difference between REVERSED and RETURNED?

Login to Me Too

jackosky
Contributor
Contributor

Also I see some inconsistency in documentation and what webhook simulator/sandbox is doing.

 

If I cancel payment through merchant UI or by using PayPal API I only get Payment payouts-item RETURNED event with REVERSED transaction status no Payment payouts-item CANCELED event occurred - I'm okay with that as long as it will behave the same on production env.

 

But if I use webhook simulator to send CANCELED event I see that transaction status is set to CANCELED, which is weird, because it is not mentioned as valid value in documentation for transaction_status (https://developer.paypal.com/docs/api/payments.payouts-batch/#definition-payout_enumerations - see transaction_enum).

Login to Me Too

MTS_Jennifer
Moderator
Moderator

If you are using Payouts, according to the documentation this is the event you will receive if the Payout is canceled:

PAYMENT.PAYOUTS-ITEM.CANCELED A payouts item is canceled. Cancel unclaimed payout item

 

After the Payouts is cancelled you are supposed to get this event (if you subscribed to it):

PAYMENT.PAYOUTS-ITEM.RETURNED 

 

It also depends on which webhooks that are subscribed to the account.

 

Thank you,

Jennifer

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.