Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PayFlow - Shipping Only Bug #872

Closed
angelleye opened this issue Sep 13, 2017 · 0 comments
Closed

PayFlow - Shipping Only Bug #872

angelleye opened this issue Sep 13, 2017 · 0 comments
Assignees
Labels
Milestone

Comments

@angelleye
Copy link
Collaborator

I feel like we've addressed in this in the past, but have a fresh report of this problem happening on our latest release.

They're trying to sell a product that is free but the buyer has to pay for shipping, so shipping is the only charge on the order. The user says that with Express Checkout things work fine, but with PayFlow it's still not working. Here is a sample PayFlow request that failed.

2017-09-01T14:11:33+00:00 INFO PayFlow Request: Array
(
    [tender] => C
    [trxtype] => S
    [acct] => ****
    [expdate] => 0620
    [amt] => 3.21
    [currency] => USD
    [dutyamt] => 
    [freightamt] => 3.21
    [taxamt] => 0
    [taxexempt] => 
    [custom] => {"order_id":1797,"order_key":"wc_order_59a9bef55af4d"}
    [comment1] => 
    [comment2] => 
    [cvv2] => ****
    [recurring] => 
    [swipe] => 
    [orderid] => 1797
    [orderdesc] => Order 1797 on Primal Health and Nutrition
    [billtoemail] => sevenbs@gmail.com
    [billtophonenum] => 
    [billtofirstname] => Brad
    [billtomiddlename] => 
    [billtolastname] => Owen
    [billtostreet] => 1364 Snow Hill LN 
    [billtocity] => ST GEORGE
    [billtostate] => UT
    [billtozip] => 84770
    [billtocountry] => US
    [origid] => 
    [custref] => 
    [custcode] => 
    [custip] => 209.33.236.210
    [invnum] => 1797
    [ponum] => 
    [starttime] => 
    [endtime] => 
    [securetoken] => 
    [partialauth] => 
    [authcode] => 
    [merchdescr] => 
    [SHIPTOFIRSTNAME] => Brad
    [SHIPTOLASTNAME] => Owen
    [SHIPTOSTREET] => 1364 Snow Hill LN 
    [SHIPTOCITY] => ST GEORGE
    [SHIPTOSTATE] => UT
    [SHIPTOCOUNTRY] => US
    [SHIPTOZIP] => 84770
)

2017-09-01T14:11:34+00:00 INFO PayFlow Endpoint: https://payflowpro.paypal.com
2017-09-01T14:11:34+00:00 INFO PayFlow Response: Array
(
    [RESULT] => 7
    [PNREF] => BL0PEECB1E78
    [RESPMSG] => Field format error: 10413-The totals of the cart item amounts do not match order amounts.
    [HOSTCODE] => 10413
    [TRANSTIME] => 2017-09-01 13:11:34
    [BILLTOFIRSTNAME] => Brad
    [BILLTOLASTNAME] => Owen
    [AMT] => 3.21
    [ACCT] => 4242
    [EXPDATE] => 0620
    [CARDTYPE] => 0
    [RAWREQUEST] => BUTTONSOURCE[24]=AngellEYE_SP_WooCommerce&VERBOSITY[4]=HIGH&USER[7]=*****&VENDOR[8]=*****&PARTNER[6]=PayPal&PWD[10]=*****&TENDER[1]=C&TRXTYPE[1]=S&ACCT[16]=****&EXPDATE[4]=****&AMT[4]=3.21&CURRENCY[3]=USD&FREIGHTAMT[4]=3.21&CUSTOM[54]={"order_id":1797,"order_key":"wc_order_59a9bef55af4d"}&CVV2[3]=****&ORDERID[4]=1797&ORDERDESC[41]=Order 1797 on Primal Health and Nutrition&BILLTOEMAIL[17]=sevenbs@gmail.com&BILLTOFIRSTNAME[4]=Brad&BILLTOLASTNAME[4]=Owen&BILLTOSTREET[18]=1364 Snow Hill LN &BILLTOCITY[9]=ST GEORGE&BILLTOSTATE[2]=UT&BILLTOZIP[5]=84770&BILLTOCOUNTRY[2]=US&CUSTIP[14]=209.33.236.210&INVNUM[4]=1797&SHIPTOFIRSTNAME[4]=Brad&SHIPTOLASTNAME[4]=Owen&SHIPTOSTREET[18]=1364 Snow Hill LN &SHIPTOCITY[9]=ST GEORGE&SHIPTOSTATE[2]=UT&SHIPTOCOUNTRY[2]=US&SHIPTOZIP[5]=84770
    [RAWRESPONSE] => RESULT=7&PNREF=BL0PEECB1E78&RESPMSG=Field format error: 10413-The totals of the cart item amounts do not match order amounts.&HOSTCODE=10413&TRANSTIME=2017-09-01 13:11:34&BILLTOFIRSTNAME=Brad&BILLTOLASTNAME=Owen&AMT=3.21&ACCT=4242&EXPDATE=0620&CARDTYPE=0
)

We can see that FREIGHTAMT was included in the request along with AMT. When a value for FREIGHTAMT is passed, though, the PayPal system requires that we also include other line item details, tax, handling, etc. So, on orders where shipping is the only thing being charged we need to leave FREIGHTAMT out and just use AMT by itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant