cancel
Showing results for 
Search instead for 
Did you mean: 

Card Code Status Not Applicable with SDK

I am trying to run a card not present transaction using the C# Autorize.net dll.  I have a Card Present sandbox account setup.  When I run the following code, authorize.net does not acknoledge the CVV.  It will show "Card Code Status : Not Applicable" on the gateway.

 

            //Card Not Present
            Response.Write ("Card Not Present" + "<BR>");
            var amount = 17.0M;
            var apilogin = "XXXXXXX";
            var transkey = "XXXXXXX";
            var cc = "4007000000027";
            var expm = "01";
            var expy = "13";

            var request = new CardPresentAuthorizeAndCaptureRequest(amount, cc, expm, expy); //

            request.AddCardCode("777");
            request.AddCustomer("12335","First","Last","1234 Anystreet", "AZ","89131");
           
            var gate = new CardPresentGateway(apilogin, transkey, true);

            var response = (CardPresentResponse)gate.Send(request);

            Response.Write(response.ResponseCode);
            Response.Write(response.Message);
            Response.Write(response.AuthorizationCode);
            Response.Write(response.TransactionID);

 

I realize I am using 

CardPresentAuthorizeAndCaptureRequest

for a Card Not Present transaction, but this is the only method that works with a Card Present gateway.  It has an override to specify the transaction info, and thats what I'm using.  I need to be able to run both cardpresent and cardnotpresent through this gateway.  I don't see why the request.AddCardCode method is not working.

 

Can anyone avise?

klack
Contributor
1 ACCEPTED SOLUTION

Accepted Solutions

I try it mulitple way enter it thru as an URL and it is still not getting any card code result(it blank). So it is not an SDKs issues, I guess it just that the test server it not doing the "Triggering Specific Transaction Responses" thing for CP test account.

View solution in original post

6 REPLIES 6
RaynorC1emen7
Expert

Thanks but I am already using these card code responses, the gateway does not acknowledge.

I thought you were using 777 as the card code. I didn't see anything on the source that might be a problem.

It could be a bug, might just need to debug the gate.send to send what is sending out.

 

and the test mode on your test account is off?

Sorry for the confusion, yes i tried 900 901, etc, and nothing changed.  (i can't change the top post anymore).  Also I am out of test mode.

 

I've seen other sdk code to manualy add x params.  if I add x_card_code and set it, will that force it to be sent?

 

 

I try it mulitple way enter it thru as an URL and it is still not getting any card code result(it blank). So it is not an SDKs issues, I guess it just that the test server it not doing the "Triggering Specific Transaction Responses" thing for CP test account.

Ah!  Thank you for testing this for me!  I will try it with a real auth.net account in test mode, and even further with a real card in live mode.