- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
error loop - response 102 then response 103
I am stuck in a loop trying to perform credit card refunds using AIM and Classic ASP. When I try a refund including the tran-key, I get error 102 (warning to not use the tran key) When I pull tran-key out, I get response code 103 (warning that I need to use the tran-key.
this seems to me to be a classic catch 22. Anyone have ideas on what I need to do to get out of this vicious loop?
Thanks....paul
01-10-2012 01:45 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are you sure you are not doing SIM, which required x_fp_hash, x_fp_sequence and x_fp_timestame, but NOT x_tran_key.
Post your code without your LoginID and TranKey.
Also, SIM don't support refund transaction type.
01-10-2012 02:02 PM - edited 01-10-2012 02:03 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The verbose versions of 102 and 103 are:
A transaction key was submitted with this WebLink request.
A valid fingerprint, Transaction Key, or password is required for this transaction.
This would seem to indicate that a transaction key is not wanted, but a fingerprint or password is. Sounds more like SIM than AIM, as Raynor says.
01-10-2012 02:18 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here it is, hopefully I've removed all the security related stuff:
<input type="hidden" name="x_Delim_Data" value="TRUE">
<input type="hidden" name="x_Email_Customer" value="FALSE">
<input type="hidden" name="x_Relay_Response" value="TRUE">
<input type="hidden" name="x_Relay_URL" value="myurl/checkin/relayresponsecredit.asp">
<input type="hidden" name="x_Test_Request" value="FALSE">
<input type="hidden" name="x_Invoice_Number" value="18540">
<input type="hidden" name="x_Description" value="Powdercats Refund">
<input type="hidden" name="x_Method" value="CC">
<input type="hidden" name="x_Type" value="CREDIT">
<input type="hidden" name="x_Login" value="hiddenbyme">
<input type="hidden" name="x_Version" value="3.1">
<input type="hidden" name="x_Companyid" value="1">
<input type="hidden" name="x_Groupid" value="18540">
<input type="hidden" name="x_Cust_ID" value="16704">
<input type="hidden" name="x_cctest" value="">
<input type="hidden" name="x_ccexp" value="">
<input type="hidden" name="x_amount" value="-1">
<input type="hidden" name="x_Trans_ID" value="">
<input type="hidden" name="x_Card_Num" value="5990">
<input type="hidden" name="x_Exp_Date" value="0913">
<input type="hidden" name="x_fp_sequence" value="18540">
<input type="hidden" name="x_fp_timestamp" value="1326666662">
<input type="hidden" name="x_fp_hash" value="stringofgobbledygookchanged by me">
Sorry about the delay - your help is a godsend, thanks!...p
01-15-2012 02:35 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That's all very well for the form data (I assume you're using SIM?), but we also need to see the code you used to generate the values, specifically the fp_hash. Please post in a code box, using the fourth from left option in Rich Text mode. Incidently, is the amount really supposed to be -1? I thought you just didn't pass anything if you were crediting the entire transaction.
01-15-2012 03:39 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So it this SIM or AIM?
For AIM, you can't have x_relay_response to true and it don't need the last 3 x_fp_xxx
For SIM, you cannot set x_delim_data to true. Need x_show_form to "PAYMENT_FORM"
And like TJPride said the amount cannot be a negative number, and have to be in 0.00 format for the x_fp_hash generation.
01-15-2012 05:31 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here's how I generate the fingerprint:
tsec = datediff("s","1970-01-01 00:00:00 AM",now())
sequence = Session("groupID")
loginid = "my login here"
txnkey = "my tran key"
tstr = "my login^" & sequence & "^" & tsec & "^" & formatnumber(tcredamount,2) & "^"
Fingerprint = HMAC (tstr, "my trankey here")
ret = InsertFP ("mylogin here", "my tran key here", formatnumber(tcredamount,2), session("groupID")) )
Notes: tcredamount is a positive number equaling desired credit amount
Thanks again for the help. I have tried most of the ideas posted by RaynorC1emen7, no luck yet.
And to be honest, I don't know if this is SIM or AIM. I built this about 10 years ago, and just dont' remember!
01-16-2012 04:55 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the continued assistance!
I've tried the combinations below, to no avail. I could send you the individual results, as I tried each item seperately one at a time & documented my results, but that might be a bit much.
Most of the changes resulted in error 103 being the continued problem.
One question - in any of these cases should I pass the tran key?
And as I told jpride, I'm not even sure if it's AIM or SIM, frankly should I care as long as it works?
Thanks!
01-16-2012 05:01 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not sure what it call 10 years ago, but if you are doing a form post is SIM.
This is what I have for SIM from sample code.
<input name="x_login" type="hidden" id="x_login" value="LOGINID" /> <input name="x_amount" type="hidden" id="x_amount" value="19.99" /> <input name="x_description" type="hidden" id="x_description" value="Sample Transaction" /> <input name="x_invoice_num" type="hidden" id="x_invoice_num" value="20120116071106" /> <input name="x_fp_sequence" type="hidden" id="x_fp_sequence" value="818" /> <input name="x_fp_timestamp" type="hidden" id="x_fp_timestamp" value="1326719466" /> <input name="x_fp_hash" type="hidden" id="x_fp_hash" value="f3e9b090a9210dad021d7569eaddcf01" /> <input type='hidden' name='x_show_form' value='PAYMENT_FORM' /> <input type='hidden' name='x_relay_response' value='TRUE' /> <input type='hidden' name='x_relay_url' value="RELAY_URL" /> <input name="buttonLabel" type="submit" id="buttonLabel" value="Submit Payment" />
and you can NOT do CREDIT transaction type with SIM. documentation at
01-16-2012 05:16 AM - edited 01-16-2012 05:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm afraid I got lost there with the last post.
1). I'm only having problems doing refunds, credit card charges are working great!
2). Are you saying that you can not do credit card refunds at all with SIM, or just that the documentation isn't accurate?
3). Yes I am posting a form, but it is a custom form and not one provided by A/N.
4). Exactly what is the difference between AIM and SIM? Is it just a couple of x_ type variables that are passed, or something more specific?
Thanks!
01-18-2012 05:31 AM