Support » Plugin: Payment Plugins Braintree For WooCommerce » Matching 3D Secure Merchant Account

  • Resolved markiljas

    (@markiljas)


    Hello,

    I noticed an error with the last attempted purchase, because the order failed. When opening the order, the note says:

    Error processing payment. Reason: Merchant account must match the 3D Secure authorization merchant account.

    I’m using Price Based on Country plugin for currency conversion and zone pricing and had no issues so far, but this happened after I updated your plugin two days ago so I assumed it was due to that.

    I’ve contacted Braintree support first and they said it could be due to plugin settings and how it is handling the default merchant token (I have three merchant accounts: EUR, USD, GBP). Should I switch the default merchant account or could it be something else?

    Thanks!

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

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author Payment Plugins

    (@mrclayton)

    Hi @markiljas,

    Thank you for contacting us. That’s interesting you would encounter that issue after the update because the mechanism for how the client token is generated has not changed. Here is how it works:

    1. When the checkout page loads, the plugin calls get_woocommere_currency() to get the current currency. Plugins like your Price Based on Country plugin hook in to the filter provided in that function.
    2. Based on the returned currency, the Braintree plugin fetches your merchant account associated with that currency then generates a client token.
    3. The client token is used to initialize the credit card form, 3D secure, etc.
    4. When billing fields like country are changed, WooCommerce triggers an event called updated_checkout. The Braintree plugin looks to see if the currency has changed and if so it generates a new client token and re-initializes the credit card form, 3D secure etc.

    Do you have a staging site where this behavior can be observed?

    Kind Regards,

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @markiljas,

    I reviewed your checkout page and ran some test, all of which indicated the plugin is working correctly. However I did come across the following error When I updated the billing country to GB.

    No Braintree merchant account was found for currency GBP. Ensure you have imported your merchant accounts in the plugin settings and that you have a merchant account for this currency.

    You must have a merchant account for each currency that you sell on your store. If you have a merchant account for British Pound Sterling navigate to the plugin’s Advanced Settings > Merchant Account Settings and click the import button.

    Kind Regards,

    Thread Starter markiljas

    (@markiljas)

    Hello @mrclayton,

    Thank you for checking it out. Funny thing is, I did not have problems with GBP, only with USD. I did have several purchases over PayPal recently, and those worked great and luckily this error hasn’t reproduced.

    I have three merchant accounts set up already, USD, GBP and EUR, and all three worked out fine so far. Maybe a while back this also happened, but I can’t really remember. What it seems to me is that sometimes the geolocation maybe gets mixed up and that’s what is causing the issue, but I’m just guessing here.

    I can copy the current site and put it on staging if needed to check for current errors. Or if you have some other recommendation as to what I might do?

    Thanks a bunch!

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @markiljas,

    Did you happen to navigate to the Advanced Settings > Merchant Account Settings and click the import button? Try that just to make sure all of your merchant accounts have been imported.

    Yes if you could copy the site to staging then reach out to me via the Help button located on all of the plugin settings and provide details. I’d like to test if there is an issue with the Price Based on Country plugin.

    Kind Regards,

    Thread Starter markiljas

    (@markiljas)

    Hello @mrclayton,

    Yup, I did it before and everything was working fine for over a year, but I redid it now again.

    I have created a fresh copy of the site on the staging site and I’ve sent you the details to access it.

    Cheers!

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @markiljas,

    Thank you for the staging site info. I was able to test and re-create the error and after reviewing the code for your price based on country plugin I see what the issue is. That plugin only converts the price if the request is utilizing the WordPress ajax API and not the WP Rest API.

    The resolution is for me to explicitly tell the plugin which currency to use while re-creating the client token when the billing country is changed because using get_woocommerce_currency() won’t reliably return the currency based on country.

    I will include that in the next version. This is not a Braintree plugin bug but rather an incompatibility which I believe was recently introduced by the Price Based on Country plugin.

    I will respond to the private support ticket so you can test the changes I make.

    Kind Regards,

    Thread Starter markiljas

    (@markiljas)

    Hello @mrclayton,

    Thank you so much for looking into it and for finding what’s wrong, this is great news!

    We didn’t have this error pop up again, so at least it’s not constant. Looking forward to the update.

    Didn’t get any response on the private support ticket, but if you need me to test anything, just let me know. As far as I am concerned, I’m sure it will be fine 🙂

    Kind regards

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @markiljas,

    Wanted to let you know I will be releasing a new version in 2 days that will include this change. I am going to set this thread to resolved.

    Kind Regards,

    Thread Starter markiljas

    (@markiljas)

    Great, thanks!

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Matching 3D Secure Merchant Account’ is closed to new replies.