Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Fuglsang89 4 posts 35 karma points
    Jun 06, 2021 @ 20:59
    Fuglsang89
    0

    Invalid URI: The URI is empty in Payment form

    Hi

    I am developing an shop with vendr and the checkout flow have worked just fine. But then i have to change default payment method and default currency due to the shop is being used on different languages and currency. I use quickpay as payment provider but in the review step it fails. I have tried the same version and of vendr and quickpay and it works fine. I have copied the the urls from the current shop to the demo shop and it works. So i would like to ask, what url is being used in this line that i am getting an error. enter image description here

    I have setup these urls in the commerce enter image description here

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jun 07, 2021 @ 08:07
    Matt Brailsford
    100

    Hi,

    So looking at the code in Vendr the place we use new Uri(...) is when constructing the payment form and setting it's action attribute. This URI should come from the payment provider, which for quickpay should be here https://github.com/vendrcontrib/vendr-payment-provider-quickpay/blob/dev/src/Vendr.Contrib.PaymentProviders.QuickPay/QuickPayCheckoutPaymentProvider.cs#L118

    If this is returning an empty URI, my guess is that something in the payment provider is miss-configured such that the gateway isn't returning an expected result. I'd double check your configuration and maybe check the payment providers gateway to see if it can tell you what the issue is.

    Looking at the source code for the provider, it does also look like it logs an error if it fails to create the payment at the gateway https://github.com/vendrcontrib/vendr-payment-provider-quickpay/blob/dev/src/Vendr.Contrib.PaymentProviders.QuickPay/QuickPayCheckoutPaymentProvider.cs#L101 so maybe check your trace log as well to see if and why it is failing to create the payment.

    Hope this helps

    Matt

  • Fuglsang89 4 posts 35 karma points
    Jun 07, 2021 @ 21:03
    Fuglsang89
    1

    Hi Matt

    Thanks a lot for sending me in the right direction. After a lot of debugging i found that quickpay only allows 4-20 characters in the ordernumber. Then it return 400 bad request.

    Thanks for quick help and for a nice commerce-system. :)

Please Sign in or register to post replies

Write your reply to:

Draft