I'm working on a custom payment plugin which is trying to accommodate non-instant IPN response. Unlike PayPal, where customer pays directly, my third party service (one that handles mark received payments as paid) might takes some time before they can confirm if a payment has been made for an invoice. So, I'm trying to find a way, to trigger the Tansaction_Incoming method when my third party service post the IPN request to my server. I have this in mind; Create a PHP file to handle the IPN post, and parse the request. In that file, I need to setup everything so it can work with my aMember. (I don't know what are *everything*) Then, trigger the plugin incoming transaction method from that file. Can somebody lead me to the accomplish this? Thanks in advance.
I recommend you to check code of existing plugins. You just need to implement Transaction class and return instance of it from payment plugins method createTransaction. IPN url should be like http://example.com/amember/payment/PLUGINNAME/ipn You can get this url within your plugin class as $this->getPluginUrl('ipn') Also please have a look http://www.amember.com/docs/API/Paysystem We can implement plugin for your payment system. Please contact us in helpdesk (https://www.amember.com/support)
You are such a great help, caesar. I did spend some time looking at other payment plugins, and tried to implement the Transaction class. So far, my plugin can handle: Sending the invoice detail to the third-party. Receive the request from the third-party service, and mark the invoice as paid. But the problem is, now every time an order is place, no summary or thank you page is being displayed on the screen. Previously I adapt the directAction method from the offline payment plugins, but this new approach seems to have a problem displaying the thank you page. (screenshot attached) I also wondering, what is the difference between $invoice->public_id; and $invoice->getSecureId($this->getId()); Should I pay attention to some rules regarding those two id? PS: I did try to contact support, but still no response.