Help for integrating the Laravel package
Forum rules: Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
#3309 by brunojti
30 Aug 2016, 11:59
Hey there!

I was able to send the request to create a payment in my payment provider. YAY! :D :D :D

Now I can update the payment status via the provider, and I should provide a URL (So the provider can send post requests with status updates).

My question is:
Which url I should provide to receive these updates ( to trigger the `updateSync` function)?

How can I log to a text file the $params when I receive them via `updateSync`?

Thanks
#3313 by aimeos
31 Aug 2016, 17:33
brunojti wrote:I was able to send the request to create a payment in my payment provider. YAY! :D :D :D


Great! :-)

brunojti wrote:Now I can update the payment status via the provider, and I should provide a URL (So the provider can send post requests with status updates).
My question is:
Which url I should provide to receive these updates ( to trigger the `updateSync` function)?


What did you've implemented? An Omnipay driver or an Aimeos payment service provider?

brunojti wrote:How can I log to a text file the $params when I receive them via `updateSync`?


In Aimeos you have a logger object in the context. If you use
Code: Select all$this->getContext()->getLogger()->log( '...' );

it will log an error message to the madmin_log table.
#3319 by brunojti
01 Sep 2016, 12:17
What did you've implemented? An Omnipay driver or an Aimeos payment service provider?


I am using a Custom Provider (based in Omnipay's code)
Code: Select all    public function process(\Aimeos\MShop\Order\Item\Iface $order, array $params = array())
    {

        if (!isset($params['payment_type']) || empty($params['payment_type'])) {
            return $this->getPaymentForm($order, $params);
        }

        return $this->processOrder($order, $params);
    }