Reputation: 1055
I'm trying to implement the Paypal REST API for a client and I'm at the point where I need to test the webhook system. I can not get the API to generate an event; a successful payment should generate one, I've also tried using the REST API to issue refunds, and I've tried issuing refunds from the developer sandbox. None of those activities have generated an event for me.
For example, if I execute the command:
curl -v -X GET -H 'Authorization: Bearer VALID_BEARER_TOKEN' 'https://api.sandbox.paypal.com/v1/notifications/webhooks-events'
I get this:
{"events":[],"count":0}
Even after a dozen or so successful payments and maybe a half-dozen refunds, in both sandbox and live, I see "count": 0
. The sandbox merchant center and transaction detail both are aware of the correct state of each transaction, and if I query the /v1/payments/payment/{id}
resource, I see the correct state for that {id}
.
Operationally, I have everything set up correctly:
I have application logging ratcheted up to the finest detail, with no results. I have tcpdump listening on the webhook target machine just to see if any handshake is attempted, also with no results. I've even tried the old "delete and recreate" trick with the app, which didn't help. I've also registered a new PayPal merchant account and encountered the same problem.
I do see IPN traffic for one of the accounts that had a default IPN handler enabled. I would prefer to use the webhooks if at all possible, the reason my client wants to do this in the first place is to get away from IPN.
Am I missing a setting somewhere? Is there some magic undocumented flag? Or is webhook support too new and I shouldn't rely on it and just stop wasting my time and go back to IPN?
Upvotes: 1
Views: 2314
Reputation: 72
To update this thread, PayPal has added webhooks support for other funding sources for sale payment.
https://developer.paypal.com/docs/integration/direct/rest-webhooks-overview/
Upvotes: 1
Reputation: 72
There's nothing wrong on your side. If you do sale, paypal webhooks only support echeck case for now. PayPal is adding webhooks support covering other funding sources for sale payment, estimated release is in next Jan.
Upvotes: 2