VivaPayments / API

Index of Viva Wallet open source projects on GitHub.
139 stars 163 forks source link

Connecting Viva Wallet to WooCommerce Critical Error #1777

Closed Si17br18 closed 4 years ago

Si17br18 commented 4 years ago

Hi Im trying to connect VW to WC. I followed the link they provided and downloaded the zip file. Followed all the steps correctly except for uploading their plugin to WP. When I do this it fails to upload the PHP file. To resolve this I searched for the plugin through WP and installed it. everything seems connected fine and when I go to checkout I get the following error:

Fatal error: Uncaught Exception: Unable to reach Viva Payments (Not Found) in /home/customer/www/hempharmony.co/public_html/wp-content/plugins/vivawallet-woocommerce-gateway/wc-vivawallet.php:310 Stack trace: #0 /home/customer/www/hempharmony.co/public_html/wp-content/plugins/vivawallet-woocommerce-gateway/wc-vivawallet.php(428): WC_VIVAWALLET->generate_form(582) #1 /home/customer/www/hempharmony.co/public_html/wp-includes/class-wp-hook.php(287): WC_VIVAWALLET->receipt_page(582) #2 /home/customer/www/hempharmony.co/public_html/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters('', Array) #3 /home/customer/www/hempharmony.co/public_html/wp-includes/plugin.php(478): WP_Hook->do_action(Array) #4 /home/customer/www/hempharmony.co/public_html/wp-content/plugins/woocommerce/templates/checkout/order-receipt.php(44): do_action('woocommerce_rec...', 582) #5 /home/customer/www/hempharmony.co/public_html/wp-content/plugins/woocommerce/includes/wc-core-functions.php(344): include('/home/customer/...') #6 /home/customer/www/he in /home/customer/www/hempharmony.co/public_html/wp-content/plugins/vivawallet-woocommerce-gateway/wc-vivawallet.php on line 310

please feel free to visit the site and see for yourself

www.hempharmony.co

Kind regards Simon

matthewrgourd commented 4 years ago

HI @Si17br18, sorry to hear this. We now have two versions of our plugin for WC available, 3.6.2 (redirect checkout) and 1.0.1 (native). The second one is the most up-to-date so you should install that one. The relevant links are below:

VivaWallet WooCommerce Gateway (v3.6.2) Download page Documentation

Viva Wallet for WooCommerce (v1.0.1) Download page Documentation

Which one are you referring to? Thanks!

matthewrgourd commented 4 years ago

By the way, you should upload the entire ZIP rather than individual files to WP.

Si17br18 commented 4 years ago

Hi

Thank you for the links, it would appear that integration was successful!

I am trying to do a test purchase, however, it is not letting me proceed saying card info is incorrect. Please see attached screen shot as well as test credentials. I have tried this with both my own card and the one provided and still receiving the same error

Look forward to hearing from you

Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 10:29, matthewrgourd notifications@github.com wrote:

By the way, you should upload the entire ZIP rather than individual files to WP.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658077305, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRULMBYJ4SSPK2PKHYB3R3QQRHANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18 the screenshot didn't come through? Can you try again or send to my email address (mgourd@vivawallet.com).

matthewrgourd commented 4 years ago

Hi @Si17br18 when using demo mode, you should only use the test card number provided. I know this seems a bit odd, but the failure may be because you didn't fill in a valid phone number. Can you putting in your real mobile number with no spaces? Thanks!

Si17br18 commented 4 years ago

Hi

Ive tried that solution but no luck Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 12:20, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 when using demo mode, you should only use the test card number provided. I know this seems a bit odd, but the failure may be because you didn't fill in a valid phone number. Can you putting in your real mobile number with no spaces? Thanks!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658124023, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUP4RFSWPG32GZKTZNLR3Q5QDANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18 I think you're using the old version of our plugin, downloaded from here:

https://developer.vivawallet.com/e-commerce-plugins/woocommerce/

You need to deactivate, delete, and install from the below page:

https://woocommerce.com/products/viva-wallet-for-woocommerce

Si17br18 commented 4 years ago

Hi

I downloaded and installed the one you sent me this morning Viva Wallet for WooCommerce (v1.0.1) Download page https://woocommerce.com/products/viva-wallet-for-woocommerce Documentation https://docs.woocommerce.com/document/viva-wallet-for-woocommerce

Is this not the correct one?

Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 13:58, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 I think you're using the old version of our plugin, downloaded from here:

https://developer.vivawallet.com/e-commerce-plugins/woocommerce/ https://developer.vivawallet.com/e-commerce-plugins/woocommerce/ You need to deactivate, delete, and install from the below page:

https://woocommerce.com/products/viva-wallet-for-woocommerce https://woocommerce.com/products/viva-wallet-for-woocommerce — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658163929, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUL36JJR7R2F6HKSSYLR3RI6JANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Yes, that's correct! Sorry, let me check again and see what's going on here...

matthewrgourd commented 4 years ago

Hi @Si17br18 you've installed the plugin but I don't think you've copied your WooCommerce credentials from your Viva Wallet demo account.

IN VIVA WALLET SELFCARE

  1. Log in to your Viva Wallet demo account.
  2. Go to Settings > API access.
  3. Scroll down to WooCommerce Credentials and click on Generate a pair of credentials. Make a temporary copy of the values in notepad (or similar).

IN WORDPRESS

  1. Go to WooCommerce > Settings > Payments.
  2. Select the Enable Viva Wallet checkbox at the top of the page.
  3. Tick the Enable demo mode checkbox.
  4. Enter your Demo Client ID and Demo Client Secret (obtained from your Viva Wallet account earlier). A confirmation message will be displayed with the payment source code that the plugin set up automatically within your Viva Wallet account.
Si17br18 commented 4 years ago

Hi

My credentials seem to be fine, please find Attached

Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 14:42, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 you've installed the plugin but I don't think you've copied your WooCommerce credentials from your Viva Wallet demo account.

IN VIVA WALLET SELFCARE

Log in https://demo.vivapayments.com/en/signup to your Viva Wallet demo account. Go to Settings > API access. Scroll down to WooCommerce Credentials and click on Generate a pair of credentials. Make a temporary copy of the values in notepad (or similar). IN WORDPRESS

Go to WooCommerce > Settings > Payments. Select the Enable Viva Wallet checkbox at the top of the page. Tick the Enable demo mode checkbox. Enter your Demo Client ID and Demo Client Secret (obtained from your Viva Wallet account earlier).

A confirmation message will be displayed with the payment source code that the plugin set up automatically within your Viva Wallet account. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658186855, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUMWQ4PURGYSJZA6HYTR3ROGHANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18, sorry, I can't see the attachment. It appears you did follow the process but there's an error at the beginning of your Client ID. Please see below screenshot. The "http://" that I've indicated is not required. Where did you get this from out of interest? Can you also confirm that you're using the credentials from your demo Viva account and not live?

Screenshot_2020-07-14_at_11_45_02

Si17br18 commented 4 years ago

Hi

My client Just copied and pasted them over so god knows lol!

thank You ive made the Changes now but still same error.

Demo Client: jyu1g1zgi0dc8a56r6ia89uo6284ax13spw1n1gbhej18.apps.vivapayments.com/ http://jyu1g1zgi0dc8a56r6ia89uo6284ax13spw1n1gbhej18.apps.vivapayments.com/ Demo Client Secret: vzeLGE0XHvn67225x7mJH9ngppPx2U Live Client ID: aly3ef1ga6bxq6doq95lfqggxmcj0sznwvnkvs58t1f22.apps.vivapayments.com/ http://aly3ef1ga6bxq************wvnkvs58t1f22.apps.vivapayments.com/ Live Client Secret: sK9Z4N4***tZ8j81wG3P

Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 14:53, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18, sorry, I can't see the attachment. It appears you did follow the process but there's an error at the beginning of your Client ID. Please see below screenshot. The "http://" that I've indicated is not required. Where did you get this from out of interest? Can you also confirm that you're using the credentials from your demo Viva account and not live?

https://user-images.githubusercontent.com/44943019/87433940-cb755800-c5e1-11ea-8b92-d5242cc21f1b.png — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658193405, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUJUX5I557FUHCAUCNTR3RPPPANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18 can you send me the Merchant ID for the client's demo account, please? I need to check the account details.

Si17br18 commented 4 years ago

Hi

Merchant ID is : 19c2f8e-68-4490-a342-6497a0448 Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 15:16, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 can you send me the Merchant ID for the client's demo account, please? I need to check the account details.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658205858, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUM7QKTTE5E6CFWZFZTR3RSCPANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18 that's the Merchant ID for the live account so I'm going to obscure part of it immediately. Please send through the demo Merchant ID. If they don't have a demo account, simply get them to disable demo mode and the plugin will work. However, they'll have to test with a real card. But easy to do a refund from WooCommerce orders page.

Si17br18 commented 4 years ago

Hi

Just tried to do a normal payment and now getting the following error (see attached)

Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 15:24, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 that's the Merchant ID for the live account so I'm going to obscure part of it immediately. Please send through the demo Merchant ID. If they don't have a demo account, simply get them to disable demo mode and the plugin will work. However, they'll have to test with a real card. But easy to do a refund from WooCommerce orders page.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658210506, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUJQOZW6DKC7K3J2EYLR3RTALANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18 the source code hasn't been created so no payment will be possible. This should happen automatically so I think the credentials are still wrongly entered. Can you add me as a user to your WP site as I'm having difficulty working out what exactly the client is doing wrong! Email mgourd@vivawallet.com

Si17br18 commented 4 years ago

Hi

All set up for you Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 16:33, matthewrgourd notifications@github.com wrote:

mgourd@vivawallet.com mailto:mgourd@vivawallet.com

matthewrgourd commented 4 years ago

Hi @Si17br18 thanks for that. I can see that everything is correctly installed so it must be the credentials. Please double-check that they have been copied exactly as shown from the WooCommerce Credentials section of the API access page in the Viva Wallet banking app as indicated below. Unfortunately I can't check these for you as they're viewable only by the account owner.

screencapture-members-vivawallet-selfcare-en-security-apiaccess-2020-07-14-16_52_18

Thanks!

Matt

Si17br18 commented 4 years ago

Hi

Thank. You for looking into it. I managed to get access to my clients account and I copied the WC client ID as well as generated a new secret and still receiving the same issue Kind regards, Simon Brooker

Co-Founder JCS Infusions Ltd

Tel: +44(0)790 413 3580 Whatsapp: +44(0)7377 391 441

On 14 Jul 2020, at 16:57, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18 thanks for that. I can see that everything is correctly installed so it must be the credentials. Please double-check that they have been copied exactly as shown from the WooCommerce Credentials section of the API access page in the Viva Wallet banking app as indicated below. Unfortunately I can't check these for you as they're viewable only by the account owner.

https://user-images.githubusercontent.com/44943019/87447830-f0be9200-c5f2-11ea-8a80-820a9bbe6c41.png Thanks!

Matt

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658262366, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUNESZUEBHKLHHHPE7DR3R543ANCNFSM4OYKWRKA.

matthewrgourd commented 4 years ago

Hi @Si17br18, I've checked and there was an errant forward slash at the end of the Client ID. I removed that and the payment source is now in the process of being verified. This can take up to 2 business days to complete. In the meantime, if the client wants to test using a demo account they should sign up for one here. Payment source activation is immediate in this case. They can then switch to demo mode in the WC settings and test using the 4111 1111 1111 1111 card. Thanks!

Si17br18 commented 4 years ago

Amazing, thank you so much for your help

On 14 Jul 2020, at 18:23, matthewrgourd notifications@github.com wrote:

Hi @Si17br18 https://github.com/Si17br18, I've checked and there was an errant forward slash at the end of the Client ID. I removed that and the payment source is now in the process of being verified. This can take up to 2 business days to complete. In the meantime, if the client wants to test using a demo account they should sign up for one here https://demo.vivapayments.com/en/signup. Payment source activation is immediate in this case. They can then switch to demo mode in the WC settings and test using the 4111 1111 1111 1111 card. Thanks!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/VivaPayments/API/issues/1777#issuecomment-658307831, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQIQRUIQILCEEXXUB4VP3H3R3SIATANCNFSM4OYKWRKA.