I'm having some issues doing a credit request using the C# SDK. Here is the code I am using:
var txid = "2181163453";
var amount = 1.0M; var lastfour = "1111"; //test account var apilogin = "xxx"; var transkey = "xxx"; var request = new CreditRequest(txid, amount, lastfour); var gate = new CardPresentGateway(apilogin, transkey, true); var response = (CardPresentResponse)gate.Send(request);
I get a
The credit card number is invalid
error message using the last four. If i enter a full credit card number it tells me to enter an exipration date. I don't understand, it should just take the txid and work.
12-21-2012 12:50 PM - edited 12-21-2012 12:52 PM
Also I am using a sandbox account
12-21-2012 01:19 PM
Looks like a bug in the SDK. I'm looking at the post values being sent and it is sending x_trans_id instead of x_ref_transid
Looking for a workaround...
12-21-2012 02:26 PM
If you are using the Credit Present API, use the CardPresentCredit
then use request.Amount, request.CardNum.
12-21-2012 02:50 PM
request.AddMerchantValue("x_ref_trans_id", txid);
Need to use the addmerchantvalue to add teh x_ref_trans_id.
Working now
12-21-2012 03:25 PM
Ah yes i seen this method but it didn't have input params for amount and cardnum. The SDK needs some better documenation!
01-02-2013 01:03 PM