PayPal IPN versus API

For general questions and discussions specific to the AbleCommerce GOLD ASP.Net shopping cart software.
Post Reply
dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

PayPal IPN versus API

Post by dc8johnson » Wed Sep 02, 2015 7:04 am

We have a client using PayPal as one of their payment methods. They've had some problems with a few orders not showing up as authorized and some not showing up as captured. When they look at the PayPal site to check the orders, they can see an authorization or capture record.

We spoke with their PayPal technical representative and they asked why we weren't using the PayPal API instead of IPN calls. They said the IPN calls weren't as reliable as the API calls. It looks like the PayFlow Pro (also owned by PayPal) calls from the store are all using their API calls. There has also been an issue with the shipping address getting passed to PayPal if PayPal was used as a the payment method during checkout. If the customer uses PayPal Express Checkout the shipping address hasn't been an issue.

Has anyone else had similar problems?

Able folks - do you have plans to switch the PayPal payments to use the API instead of IPN?

Thanks!
David Johnson

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Thu Sep 03, 2015 4:15 am

Here's an example of what the payment screen looks like. The order was placed at 10pm last night and this is the status as of 8:30am this morning.
PayPalIPN_150903.gif
David Johnson

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: PayPal IPN versus API

Post by mazhar » Thu Sep 03, 2015 5:28 am

In paypal account check the IPN history. Some notifications maybe stuck and log may have information about the cause. Also you should be able to trigger those pending notification again from IPN history.

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Fri Sep 04, 2015 4:29 am

Mazhar,

Below is a snapshot of part of the IPN history. The order at 19:03 was #638 and the order at 18:36 was #636. The order that shows IPN Pending in the order screen is #637. So there is no pending IPN to trigger.
IPNHistory.png
Any thoughts?

Thanks!
David Johnson

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: PayPal IPN versus API

Post by mazhar » Fri Sep 04, 2015 5:36 am

First of all have a look at application error log. See if you find something that could be related to this particular IPN. Secondly select this IPN in history and try resend. Then again check order status and also error log. We may get something in log in case something goes wrong when handling this particular IPN notification.

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Tue Sep 08, 2015 5:12 am

Mazhar,

I don't have an IPN number for the order. The first screenshot above shows the payment screen for the order and it says "Waiting for IPN". We looked in the history and that is shown in the second screenshot. There is no IPN for the order in the history. There is an entry for the order before and after. I checked all logs for the order number and didn't find any errors associated with the order by either ordernumber or orderid.

This has happened with other orders where the status stay IPN Pending. Some orders have started as IPN Pending but then some time later (hours and sometimes days), we receive the IPN and the order is authorized or captured.

When we spoke with the PayPal support people they asked why we were using IPN instead of the API for PayPal transactions.

Thanks again for your help,
David Johnson

SteveHiner
Lieutenant (LT)
Lieutenant (LT)
Posts: 58
Joined: Thu Jun 21, 2007 8:27 pm

Re: PayPal IPN versus API

Post by SteveHiner » Sun Sep 20, 2015 10:11 pm

We have also had periodic issues with PayPal. I'm quite interested in whatever you discover. I'll have to wait for another one to fail to dig into potential reasons why so unfortunately right now I can't provide any more details for you.
Steve

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Mon Sep 21, 2015 5:37 am

Mahzar,

We had the same issue over this past weekend. Three orders in a row went through PayPal. The middle transaction was never authorized. In the Payment screen it shows IPN pending. When we look at the IPN history, we have two side-by-side records for the orders that were successful but no IPN for the order that is still awaiting authorization. In the order screen you'll see this middle order has been cancelled manually by our client since the authorization failed to complete resulting in a lost order.
OrderSummaryPage.png
IPNHistory.png
OrderPaymentHistory.png
The PayPal log file seems to only have capture requests recorded. Any thoughts on how we can troubleshoot this? As I mentioned in an earlier post, PayPal asked why we're using the IPN system instead of their APIs as with PayFlow Pro.

Thanks!
David Johnson

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: PayPal IPN versus API

Post by mazhar » Mon Sep 21, 2015 6:18 am

Can you please check if these enteritis in IPN history have any details against them? They must have some field to provide details about server response. This will give information about what happened when they sent the notification. For example was the HTTP Response Code HTTP 200 means OK or HTTP 400 page not found. It would be something like this

Image

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Mon Sep 21, 2015 9:14 am

There isn't an entry in the IPN history for the middle (missing) order so I can't get the details. The Able store says the IPN is pending but there are no entries in the IPN history for the pending order. When sorting the IPN history by date/time, I can see IPN history entries for the previous and following order and nothing in between. The two surrounding orders look fine in PayPal and on the Able store.

Is there a log on PayPal or in the Able store that shows authorization attempts?

Thanks for your help!
David Johnson

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: PayPal IPN versus API

Post by mazhar » Mon Sep 21, 2015 10:03 am

From the admin enable Debug mode for PayPal and it will log the requests/responses under Website\App_Data\Logs\paypal.log

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal IPN versus API

Post by Katie » Mon Sep 21, 2015 10:58 am

David,

What is the exact version of AbleCommerce that you are using? Your screenshots look like AC7, but you posted in the AC Gold forum.

Thanks
Katie
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Mon Sep 21, 2015 11:34 am

Marzhar: we've had debug for PayPal turned on for several months and we're only seeing these type of send entries:

Code: Select all

Send: <DoCaptureRequestType  >
Send: <DoVoidRequestType  >
Send: <DoVoidResponseType  >
And we're only seeing one type of receive entry:

Code: Select all

Receive: <DoCaptureResponseType  >
Nothing for authorizations.

Katie: we're using GoldR6 (7.0.86.6169). We're using the Fresca admin theme.
The PayPal DLL is: CommerceBuilder.PayPal: 7.86.5000.17240

Thanks again for your help,
David Johnson

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal IPN versus API

Post by Katie » Mon Sep 21, 2015 12:58 pm

Ok. I wasn't sure about the version because the first screenshot definitely looks like AC7.

If PayPal IPN is working for some orders and not others, then there are 3 possible things that I can think of -

1) A traffic jam or similar at Paypal. If you search for Paypal IPN in the forum, you will see other posts where the payment shows up pending and sometimes the data gets thru later, some times it doesn't. In this case, it's likely a Paypal problem, not an AbleCommerce problem.

2) The person did not complete the payment at paypal. If there are not any funds in paypal to capture, then they didn't pay. The only way for you to contact paypal about this would be if in that same area where it says pending, on the right side it has a transaction number. Meanwhile depending on how far they made it, you should be able to see their email address. I would send them an email indicating that you saw that they had started a transaction with you and did they need any help completing the checkout process.

3) Are the missing pending transactions coming from international addresses? Awhile back, there was some encoding issue that required specific setup on the Paypal side. If this is the case, please refer to the Merchant Guide here - http://help.ablecommerce.com/mergedProj ... paypal.htm

Find the section "Language Encoding" and make the changes as noted.

If there are errors within the AbleCommerce pages, you can look in the app_data\app.log file for details. I suspect you won't find any though. The main reason is that you have successful orders and only a few are not working. You can use the API version and enable Express Checkout and Website Payments Pro. The standard Paypal IPN has been known to be unreliable.

Hope this helps,
Katie
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Tue Sep 22, 2015 6:52 am

Katie,

Thanks for the explanation!

There have been times when the authorization has come in hours later, after our admins have already cancelled the order. They're not international orders. Your second response would indicate that the Able order is created before sending the user over to PayPal Express or PayPal on the payments page, is that correct? That might mean our client needs to adjust their processes and start contacting customers about these orders.

You said at the end that we can use the API and enable Express Checkout and Website Payments Pro. Here's our PayPal config. We're also using PayFlow Pro for credit card transactions.
PayPalConfig.png
We have the API info in the setup. But we're clearly also using the IPN. Is there something else we need to do? We have the Express Checkout button on the cart page. And I don't see anything in the payments setup about Website Payments Pro. Is this all done on the PayPal side? Is there a way to turn off IPN and just use API calls?

Thanks again!
David Johnson

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal IPN versus API

Post by Katie » Tue Sep 22, 2015 7:25 am

Hi David,

You are correct. With std PayPal payments, the order is placed and the customer needs to complete the payment by logging in to their PayPal account. It is absolutely possible that they just never complete that step or have the funds to complete the order. It is the downside to using std. Paypal. If you want to disable this feature and use Express and/or Website payment pro, then all you have to do is remove the 'PayPal' payment method (not the gateway).

I hope this helps!
Katie
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

dc8johnson
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 87
Joined: Fri Nov 20, 2009 8:46 am

Re: PayPal IPN versus API

Post by dc8johnson » Tue Sep 22, 2015 11:22 am

Thanks Katie.

I will discuss removing the PayPal payment option with our client. That seems like a worthwhile change to make.

How would we add Website payments pro to the site? Is that something done on the PayPal side or in the Able store configuration?

Thanks,
David Johnson

Post Reply