Paypal 10418 error - paypal

I am getting an error while doing express checkout for australian currency in PayPal. (The currencies of the shopping cart amounts must be the same) My code works fine with US dollars.
I set the currency code "AUD" correctly in both setexpresscheckout and doexpresscheckout process, but I am still getting an error.
What can I do to solve this?

You're obviously not sending the same currency in both SetExpressCheckout and DoExpressCheckoutPayment.
USD is the 'main' currency. This means that if no currency is specified, it falls back on USD by default. Which is why if you don't specify anything, it works properly.
Review (or post) your code for both SetExpressCheckout and DoExpressCheckoutPayment, as I'm sure you're not properly specifying CURRENCYCODE for either of the API calls.

I get same error code in soap message (10418) and get usefull description (The currencies of the shopping cart amounts must be the same.) in same soap message. I call setExpressCheckout with EUR currency, but I adjusted in my test account US country. My mistake occured this problem.
So it is always usefull check test/normal account adjustment!

I had this error and it was because the PaymentDetailType was not completed correctly.
Make sure both ItemTotal and OrderTotal have a BasicAmountType entered.

Related

PayPal PayFlow Pro - Credit Card Verification : CVV2 & BILLTOZIP

I using Paypal / Payflow Pro's Authorization transaction (TRXTYPE=A) to validate credit card information. I am passing 0.00 as the AMT. This works fine and can filter out wrong account number as well as card expiration date, paypal returns "RESPMSG=Invalid......".
However, the problem is in verifying both CVV2 and BILLTOZIP. When passing wrong values for these two paypal still returns "RESPMSG=Approved".
I am missing something?
Can we validate CVV2 and BILLTOZIP on paypal?
Is there another method that I can use for this?
I am using this request:
USER=XXXXXX&VENDOR=XXXXXXXX&PARTNER=PayPal&PWD=XXXX&TRXTYPE=A&TENDER=C&ACCT=4xxxx&EXPDATE=xxxx&CVV2=xxx&AMT=0&INVNUM=521aa62355f5eb5515eca3777e1f8b78&PONUM=PFDCCTEST&COMMENT1=Test Comment 1&COMMENT2=Test Comment2&VERBOSITY=HIGH&BILLTOFIRSTNAME=Frank
&BILLTOLASTNAME=Enstien&BILLTOSTREET=123 Main St.&BILLTOSTREET2=Suite 267&BILLTOCITY=GILBERT
&BILLTOSTATE=AZ&BILLTOZIP=85298&INVNUM=InvoiceNumber001&CUSTOM=CustomNumber001
Is this live or sandbox?
paypal still returns "RESPMSG=Approved
Check the rest of the return for =N , =X, other documented invalid value
If you still have issues post a full return string.

Paypal Express Checkout paymentinfo_0_amt value returned

I am testing using the sandbox at the moment new functionality to use paypal express as a payment method. I have successfully made a payment and am inspecting the returned
values from the DoExpressCheckoutPayment
One of the fields returned is PAYMENTINFO_n_AMT and my vbscript code is
PPFamt = resArray("PAYMENTINFO_0_AMT") ' The final amount charged, including any shipping and taxes from your Merchant Profile.
I would expect this value to match the total amount being requested (from the Set) but
it seems to be rounded.
i.e. if I request a payment of 217.85 - the PPFamt value is 218.00
if I request a payment of 66.90 - the PPFamt is 67.00
I am using GBP currency for both the seller and buyer accounts.
Has anyone else come across this? I can't see that I am doing anything wrong or rounding it in the code, so I am assuming Paypal is doing this.
Any advice appreciated.
User error - paypal was just returning the value I sent in the DoExpressCheckoutPayment stage.

Handling unknown shipping costs via PayPal Express nvp API

Can some confirm something for me; I've searched PayPal's docs and just can't find the answer.
If calling SetExpressCheckout with the parameter 'TOTALTYPE'= 'EstimatedTotal', how much headroom does PayPal allow for finalizing the transaction?
For example, someone carts an item that has a cost of $1. They click PayPal Express and get sent to PayPal to authorize an estimated amount of $1. Then they return to the merchant site and now that their address is known, the cart says shipping is +$20.
Is that acceptable? I'd really like to understand the groundrules on this, as I don't want to risk any authorization errors due to insufficient order amount when making the request.
Well, I have to answer my own question here. I called PayPal. The answer is "it's handled, don't worry about it". They would rather not publish the details on their proprietary algorithm because there are fraud tests, etc. going on -- but said it is a key design point for them and it is absolutely handled no worries.
If you are not passing a SHIPPINGAMT variable with the SetExpressCheckout call, then we will not display or "calculate" shipping on the PayPal page. When they are transferred to the PayPal page the customer is not authorizing the payment per se, rather they are selecting their payment method/funding source to be used when the DoExpressCheckout call is passed.
Only after the customer is transferred back to your page, and the final order total is known and passed via the DoExpressCheckout is the payment initiated. The difference between the total amount in the Set call and the Do call does not matter. Perhaps the agent with whom you were speaking with under the impression of an authorize/capture structure being in place. This will limit the final capture amount to the authorized amount +/- 20%.
Of course this is all turned on its head if you are passing the USERACTION=COMMIT variable which will "finalize" the payment on the PayPal page, while the DoExpress call is run transparently on your end. This will change the text on the button on the PayPal page to "Pay Now" instead of "Continue: You're almost done. You will confirm your payment on yourwebsitehere.com"
I hope this helps!

Using new Paypal Rest API does not accept payment in GBP

I get a 400: Bad Request error when trying to make payment in GBP, where as USD is working fine. I am getting this error since last few days earlier it was working fine, I think the issue has started after Paypal has made changes to its site rencently.
Also all the payment is going to a default sandbox account (it has a word facilitator appended to it, I did not create this account) I am not sure if I can change and set a sandbox account that I created as default account for receiving payment. Any idea?
Any suggestion would be helpful.
Currently the REST API's only support USD, passing a different currency can cause errors to be generated. There are plans to eventually support additional currencies, but currently it is only set up for USD.

For a Paypal IPN what's the difference between auth_amount and mc_gross?

I'm having a hard time finding this out from the documentation. I have some code I've inherited which needs to get he payment amount from a Paypal IPN transaction. It's expecting the variable "auth_amount" from a Paypal IPN but is not getting passed this field. It looks to me from the Paypal docs as though I should be using the field "mc_gross" which is labelled as "Full amount of the customer's payment, before transaction fee is subtracted.".
The Paypal IPN docs describe the "auth_amount" field as "Authorization amount", which doesn't mean much to me.
I'm going to change it to use mc_gross, but I just want to check first that I'm not missing something silly?
Thanks!
Check this out:
https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_html_IPNandPDTVariables
mc_gross
Full amount of the customer's
payment, before transaction fee is
subtracted. Equivalent to
payment_gross for USD payments. If
this amount is negative, it signifies
a refund or reversal, and either of
those payment statuses can be for the
full or partial amount of the original
transaction.