• Resolved stuntcoder

    (@stuntcoder)


    Hi,

    I’m setting up Vipps payment method for a client on WooCommerce enabled WordPress webshop.

    I followed the setup instructions after I installed the plugin on staging site and updated the settings with correct client ID, client secret and primary applications secret keys. Vipps payment is now showing up on the checkout page but if I select it and continue to purchase, the error message will show up: “Unfortunately, the Vipps payment method is currently unavailable. Please choose another method.”

    The checkout is enabled for Norway only, so the issue is not related with unsupported country selection. I can also tell you that Express Checkout API is V2.

    Can you please help resolve the issue?

    • This topic was modified 6 years, 8 months ago by stuntcoder.

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Iver Odin Kvello

    (@iverok)

    If you can, first check to see that you have access to the live API and not the test environment. (If you define

    define(‘VIPPS_TEST_MODE’, 1);

    in your wp-config.php file, the system will use the test api – but you will then need special apps to complete a transaction). Remember to remove this after if you try it.

    If you are definitely working against the live API and have access to the file system, errors will be logged to a file in the directory wp-content/uploads/wc-logs/. This could provide more information if you can access it.

    Thread Starter stuntcoder

    (@stuntcoder)

    Hi iverok,

    Thanks for your prompt reply. Unfortunately after following your instructions I am still getting the same error message and the log file is empty. There are no entries.

    I noticed that orders are being created and set in Pending payment status in WooCommerce.

    Any ideas?

    Best,
    Bane

    Plugin Author Iver Odin Kvello

    (@iverok)

    The orders are created before the call to Vipps so that is as expected; they will eventually be set to “Failed”.

    Are you certain that there is nothing in the WooCommerce logs? You should find them here:
    /wp-admin/admin.php?page=wc-status&tab=logs

    If so, it appears that the payment fails already while getting the access tokens from Vipps. Could you try to enable and disable the Vipps plugin? You should see “Connection to Vipps OK” as a notice when this happens.

    I will add more logging for this case in the next version, which should be available shortly.

    I would recommend double-checking your keys – especially for the access key – and verifying with Vipps that these are correct (version 2.0 live).

    Otherwise I would recommend establishing that there isn’t anything in your local setup, such as interaction with other plugins and so forth, that may be causing a problem. Try to set up a completely new test version of WP with just WooCommerce and the Vipps plugin and use the same keys there.

    Thread Starter stuntcoder

    (@stuntcoder)

    Hi iverok,

    I found something in the logs today:

    2018-07-06T13:45:47+00:00 INFO Could not get Vipps access token No response from Vipps
    2018-07-06T13:45:47+00:00 ERROR Could not get access token when initiating Vipps payment: No response from Vipps

    I disabled/enabled the plugin and the notice I receive is the same. I double-checked all the settings: Serial Number, Client Id, Application Secret, Subscription key for Access Token and eCommerce and I confirmed they are all good.

    Not sure what is blocking the communication…

    Thread Starter stuntcoder

    (@stuntcoder)

    Another thing worth mentioning is that turning off all plugins except Woocommerce and Vipps doesn’t make any difference. The same error happens.

    Plugin Author Iver Odin Kvello

    (@iverok)

    If you can, try to see that you do not have a firewall or something similar blocking connections to https://api.vipps.no on that server.

    Then, the actuall call to Vipps uses “file_get_contents”, and for this to work, “allow_url_fopen” must have the value 1 in your php.ini file. Can you verifiy that this is allowed on your system?

    Your keys are probably correct, but that won’t help if you cannot access Vipps servers.

    You can sometimes get this errors when there is too much traffic to Vipps servers, or if they time out; which is why this is handled as a temporary error; but that should be very rare and certainly not the case today or yesterday.

    Thread Starter stuntcoder

    (@stuntcoder)

    Thank you iverok, the issue is resolved thanks to your inputs. My admin tells me something was blocking the connection to the Vipps server but I didn’t get into details what it was.

    Best,
    Bane

    Thank you for your feedback. Great all worked out!
    We now close this case as resolved.

    Thanks,
    P?l Martin
    WP Hosting

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Unfortunately, the Vipps payment method is currently unavailable’ is closed to new replies.