Paypal REST integration - no error, but payment not processed - paypal-rest-sdk

After some other issues we managed to go live with the PayPal REST integration. Sandbox works fine, by the way, so we assume that the code is o.k.
Well this is what happened on live System:
My first customer initiated her first payment via paypal.
The payment request shows as successfully executed on the Paypal Dashboard. No error!
But the customer always got the message that something is wrong with their creditcard.
According to Paypal customer support the credit Card is fine (and the customer successfully made other payments using the same credit Card with Paypal) but that somthing must be wrong with the payment request.
But as mentioned above I cannot see an error in the dashboard nor in the logfile.
Paypal Tech Support is not responding (since over a week), so maybe somebody here has seen this before and can advise?
Thanks a lot
Christoph

Related

How do I know if a payment is successfull in stripe

I have integrated the stripe Api in my website to process payments and It is working fine. The only problem is that after the a successfull payment, i don't get any response or an object to know if the payment is successful or not.
Stripe does process the payment and everything is fine but the question is how would I know that it is successful after stripe redirects the client to the success url ?
You can implement webhook in your application. After a payment is completed stripe will call webhook/callback of your application with the payment_status and other details. Have a look at documentation here Triggering actions with webhooks
Using webhooks and events is definitely the right way to go. You can listen for successful payments, failed payments, and other event types, then add some server code to take some action based on those events.
There's a mention of webhooks in Stripe's custom payments quickstart guide: https://stripe.com/docs/payments/quickstart#use-webhook
They also have a standalone webhooks guide: https://stripe.com/docs/webhooks/quickstart

Stripe Payment Intents API: How to confirm the payment on the server side?

Before migrating to the Payment Intents API the user's credit card payment was confirmed and charged on the server side using the token (received from stripe.createToken) after the purchase has been completed. This gave us the possibility not to confirm the payment in case any errors happens.
Now, with the Payment Intents API the payment confirmation happens already on the client side (stripe.confirmCardPayment) which is a problem in case an error happens on the server side while completing the purchase as the credit card has already been charged. A refund is not valid solution your Stripe fees won't be refunded.
How can we implement card payments with the Payment Intents API but confirm the payment at the final end of the purchase (as in the legacy workflow)? Or how can we prevent the credit card from being charged in case an error occurs during the checkout workflow?
Unfortunately, we couldn't find a solution to this problem in the documentation.
Help appreciated!
Here are the docs: https://stripe.com/docs/payments/payment-intents/migration
What you are looking for is modeled via "manual confirmation" of a PaymentIntent: https://stripe.com/docs/payments/accept-a-payment-synchronously.
It isn't Stripe's recommended integration. The recommended approach is to confirm client-side and listen to webhooks for payment confirmation.
This is because with manual confirmation, there is a higher chance of customer "drop off" where they authenticate your PaymentIntent on your webpage but close it out, meaning you lose your client->server roundtrip, leaving your payment unconfirmed (eventhough the customer thinks they authenticated hence paid).
Additionally, manual confirmation only works for card type payments, it is not supported for other payment methods based in other regions like iDEAL or SEPA Debit etc.
In our case, we wanted to authenticate the card payment at the end directly after making the charge. The Stripe support was able to help us with the following answer:
As I understand you would like to authenticate the payment at the end directly after making the charge. There is a solution to this, with the capture_method being set to Manual - https://stripe.com/docs/api/payment_intents/create#create_payment_intent-capture_method. What this would mean is, that the charge will be made and the user / client would be able to confirm the payment afterwards in the Dashboard directly.
This method is called Auth and Capture. Place a hold on a card to reserve funds now but only capture them after your business completes the service. When a payment is authorized, the bank guarantees the amount and holds it on the customer’s card for up to seven days, or two days for in-person payments using Terminal. You can find more information along with the API's under this Link: https://stripe.com/docs/payments/capture-later#authorize-only

Looking for some one who has implemented Moneris recurring payments for a website subcription

My client is using moneris as our payment gateway for a new subscription based website that I am working on.
I will be using the language PHP
I've looked through their documentation for PHP api and am comfortable with how it works, it seems very straight forward.
One thing was missing in the documentation for me though. There is mention of how to start a recurring payment, how to update a recurring payment, but no mention of how to query a recurring payment?
Some payment gateways allow you to have a POST back URL of sorts that get updates on recurring billing status. This does not seem to be possible with moneris.
How do I go about automatting the process of tracking recurring payments with Moneris? I'd like for my customers to log in and be able to view their transaction history on my site.
This information will also make it easier for me to know when to close accounts. Ie. when a payment fails to go through, or a credit card expires? I don't want for my cleint(owner of website) to have to keep track of the recurring payments and cancel accounts manually?
I got an answer from Moneris:
Hi David, We currently do not have a reporting API or any way of
posting the information from our recurring payments back to your
server. It is something that has been mentioned previously and is
being looked into. We do not have a current ETA on such a solution.

Recurring payments IPN

Working on implementation of paypal's recurring payments, I've got encountered some problems. I have followed paypal's documentation from here:
PayPal Express Checkout: Recurring Payments Process Flow
It seems that everything works properly and I get ProfileID at the end (from result of CreateRecurringPaymentsProfile() query). Recurring profile is also being created.
The problem is there's no IPN confirmation after running CreateRecurringPaymentsProfile() , but according to:
PayPal Express Checkout: PayPal Notifications - it should be.
From my experience this happens only when IPN (Instant Payment Notifications) are not enabled in your merchant account. You can enable IPN in Profile > Instant Payment Notification Preferences.

Paypal payment for access to restricted area

I'd like to set up a part of my site as a 'restricted' area that you need to pay via Paypal to access. Can anyone offer some advice on how to do this? Ideally I'd like to have a 'subscribed' value in my database that I can check when people attempt to access the site to check if they have subscribed. I've started looking into IPN which might be the way to do it?
Many thanks
I'm working on a new store that will integrate with PayPal. From what I've read, yes, IPN seems like the way to do it. Have a Subscribe button, and when you receive an IPN message that indicates successful payment, update the user's 'subscribed' field. I think IPN also sends a message when their subscription runs out.

Resources