decimal places in total price (Itemamt) and taxamt

  • Posts: 17
  • Thank you received: 0
11 years 5 months ago #70437

Subject
connecting paypal pro with account

Discussion Thread
Response Via Email (Carlo) 10/16/2012 02:26 AM
Hi Sarah,

Thanks for the update.

As you're getting API Error 10426 we can confirm now the two servers do communicate alright otherwise you'd still get 10002 which means basically "no communications for incorrect credentials or environment".

Now, let me clarify: Website Payments Standard, the basic integration via HTTP POST FORM in HTML doesn't use APIs connections with PayPal that's why it's working alright, it's already integrated.

Regarding PRO, your Cart must be adjusted by the webmaster to resolve the issue for the API Error on topic now and enable a fully working integration.

API Error Codes cms.paypal.com/us/cgi-bin/?cmd=_render-c...o_api_nvp_errorcodes

I have been receiving an error code when testing the PayPal Pro payment option. My posts to the forum indicated this is due to a configuration error. I contacted PayPal and they repsonded that the issue is because of too many decimal places generated in the total amount sent through to PayPal:

The 10426 error means "Transaction refused because of an invalid argument. See additional error messages for details. Item total is invalid." then I pull the information from the logs and here it is the issue in details:

This is the set of parameters from the Cart to PayPal: API Request
DoDirectPaymentRequest
method "DoDirectPayment"
version "51.0"
user "beatlebottoms_api1.gmail.com"
paymentaction "Sale"
currencycode "AUD"
amt "45.00"

And this is the Response from PayPal to the Cart: API Response

DoDirectPaymentResponse
timestamp "2012-10-16T00:09:49Z"
correlationid "beb08f95256a"
ack "FailureWithWarning"
version "51.0"
build "3926908"
errorcode 10426 10429 10413 15008
shortmessage "Transaction refused because of an invalid argument. See additional error messages for details." "Transaction refused because of an invalid argument. See additional error messages for details." "Transaction refused because of an invalid argument. See additional error messages for details." "Invalid Data"
longmessage "Item total is invalid." "Tax total is invalid." "The totals of the cart item amounts do not match order amounts." "This transaction has been completed\, but the total of items in the cart did not match the total of all items."
severitycode "Error" "Error" "Error" "Warning"
errorparamid "" "" "" ""
errorparamvalue "" "" "" ""
amt "9.90"
currencycode "AUD"

There are quite a few errors, not just the 10426. First of all, the webmaster must review the integration as every single error comes from misconfigurations. For example the 10426 the item total is invalid:

itemamt "31.0045455"

this should be rounded to max two digits decimals. Same for the Tax parameter which will resolve the 10429 error and so on....

taxamt "4.0954545"

Finally remember that "amt" = "itemamt" + "shippingamt" + "taxamt" see parameters description here: cms.paypal.com/us/cgi-bin/?cmd=_render-c.../howto_api_reference >> DoDirectPayment NVP cms.paypal.com/us/cgi-bin/?cmd=_render-c...vp_r_DoDirectPayment

Can you advise as to how to resolve this issue please?

itemamt "31.0045455"
shippingamt "9.9"
taxamt "4.0954545"

Please Log in or Create an account to join the conversation.

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
11 years 5 months ago #70451

Hi,

Amounts are rounded based on the number of decimals of your currency. Normally, the currency number of decimals should be 2, as it's the case by default with AUD.

So it basically means that you changed the number of decimals for the AUD currency from 2 to 7 in the menu System->Currencies.

You should put back the default value there.

If that's already the currency value, then please download again hikashop on our website and update it on yours as you might be using an old version which potentially had that problem.

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 0
11 years 5 months ago #70602

The Digits are correct in the backend. Do I have to uninstall the old version or is there an updater?

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 0
11 years 5 months ago #70630

I have checked that the decimal places are set to 2 in System> Currency and I have checked the version : You have the latest stable version : 1.6.0 . So it is configured correctly and I ahve the latest version. Can you help please?

Please Log in or Create an account to join the conversation.

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
11 years 5 months ago #70755

Please provide a backend access to your website via our contact form with a link to this thread so that we can check that.

Please Log in or Create an account to join the conversation.

  • Posts: 17
  • Thank you received: 0
11 years 5 months ago #71207

Hi, I have sent the login via your contact form as requested. Please confirm you have received this? regards, Barry

Please Log in or Create an account to join the conversation.

  • Posts: 18
  • Thank you received: 0
11 years 5 months ago #71272

Hi, just wanting to also follow up on this- we have advertising coming out this week so need everything up and running- can you please confirm with us ASAP that you have received the login information? And if you are able to resolve the issue?

Thank you!

Sarah

Please Log in or Create an account to join the conversation.

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
11 years 5 months ago #71430

Hi,

We got your credentials three days ago and tried to go on your website but it wasn't available I that time.

I think that we found and fixed the problem on your website. Please try again.

The following user(s) said Thank You: beatlebottoms

Please Log in or Create an account to join the conversation.

  • Posts: 18
  • Thank you received: 0
11 years 5 months ago #71533

thank you! It is all working and just in time! :P

Please Log in or Create an account to join the conversation.

  • Posts: 59
  • Thank you received: 2
6 years 4 months ago #282902

Hi Nicolas,
Following this thread as we also have an issue with Paypal not applying the GST, Paypal says there is a mismatch coming from too many decimals after the decimal point. I have set the International fractional digits and local fractional digits to 2. This doesn't happen often but it does happen. When it does happen, we get a successful payment notification from Paypal, but the GST is not shown, nor is it charged to the recipient. We then receive a notification from Hikashop that says Paypal payment notification refused: Invalid amount. Message further states that "A Paypal notification was refused because the amount received (91.46AUD) is different from the order amount (100.6AUD).
I note that you fixed something in the back-end of the original poster, but didn't say what you fixed and as this issue seems to be similar to this thread, I thought I would post here. All the best, Steve

Please Log in or Create an account to join the conversation.

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 4 months ago #282915

Hi,

Please note that this thread 5 years old and that issue isn't relevant anymore.
All the prices should be properly rounded with recent versions of the PayPal plugin.
Can you check that you have HikaShop 3.2.1 and that in the header of the file plugins/hikashoppayment/paypal/paypal.php you also have the version 3.2.1 ?

Please Log in or Create an account to join the conversation.

  • Posts: 59
  • Thank you received: 2
6 years 4 months ago #282965

Thank you for your time in this, I realise it is an old thread, but I couldn't find anything else that sounded similar to our problem. I have updated to Hikashop to 3.2.1 Business, so that part should now be ok. Where do I look to find the paypal version, and if I find that it is out of date, where and how do I update this? All the best, Steve

Please Log in or Create an account to join the conversation.

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 4 months ago #282974

Hi,

You need to check that file directly with a FTP client connecting to your website with the FTP information provided by your hosting, or with the file manager provided by your hosting.
If you're not sure, ask your hosting how to access the files of your website.

If the file doesn't have the version 3.2.1, it means that there are permissions issues on the plugins folder(s) of your Joomla which prevented the installer from updating the HikaShop plugins. Fix the permissions on these folders, install again the HikaShop install package and it will perform the update.

Please Log in or Create an account to join the conversation.

  • Posts: 59
  • Thank you received: 2
6 years 4 months ago #283041

Hi,
Have checked the paypal plugin header as described above and found it is version 3.2.1 which matches the Hikashop version. Will have to wait and see if the problem occurs again, like I said before, it doesn't happen all the time, only occasionally. Fingers crossed, thanks for your help, Steve

Last edit: 6 years 4 months ago by avonrivercs.

Please Log in or Create an account to join the conversation.

Time to create page: 0.074 seconds
Powered by Kunena Forum