Abin Mathew Abraham
Abin Mathew Abraham

Reputation: 170

response to payments callback url after purchase using local currency (local currency breaking changes)

Do we get response to payments callback url after successfully purchasing using local currency automatically?? Is there any other way other than subscribing for real time updated in the above mentioned case to get response for successful purchase?

Upvotes: 1

Views: 1925

Answers (1)

Slav
Slav

Reputation: 27495

I was just researching the same thing.

The FB.ui callback will now have confirmation of purchase. You could use that, however since it executes on client side, it can be tempered with and is not reliable.

FB will still make a call to your specified callback URL (under FB app settings), however you need to subscribe to Real Time Updates from FB app settings. To subscribe, your callback page must respond to the challenge sent my FB.

Edit

Information on how to subscribe to RTU is here
https://developers.facebook.com/docs/howtos/payments/fulfillment/#rtu

This is the FB documentation on what you need to configure in your callback.php page https://developers.facebook.com/docs/reference/api/realtime/

It's beyond me why they wouldn't provide a complete example. It is buried in their blogs somewhere, but this post gives you everything you need:
https://developers.facebook.com/blog/post/2012/01/31/how-to--subscribing-to-data-changes-using-the-real-time-updates-api/

Upvotes: 1

Related Questions