<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: NULL RESPONSE ISSUE in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/64417#M38318</link>
    <description>&lt;P&gt;I also am confirming that I am getting null response from Java SDK. It seems to happen when the request is invalid, but it doesn't return the error back in the response. I had to put response != null everywhere in my code, as well as the resultCode, messages, getErrors(), etc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I had to copy the xml request into a separate REST POST to receive the error. It did not return in the JAXB response object.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was getting an error code E00003 - cardCode element is invalid - The value XX is invalid according to its datatype. In that case, &amp;lt;cardCode&amp;gt; was empty. We don't always have the security code available to process a transaction, so I am making it clear not to set the value if it is missing.&lt;/P&gt;</description>
    <pubDate>Thu, 06 Sep 2018 22:03:38 GMT</pubDate>
    <dc:creator>kschaller1979</dc:creator>
    <dc:date>2018-09-06T22:03:38Z</dc:date>
    <item>
      <title>NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/58657#M33275</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I HAVE CONFIGURED API LOGIN ID AND TRANSACTION KEY IN MY APPLICATION. I AM TRYING TO USE CHARGECREDITCARD FUNCTIONALITY. I HAVE USED THE CREDIT CARD NUMBERS PROVIDED IN TESTING GUIDE. I LOGGED INTO MY ACCOUNT AND DID THE SAME FROM VIRTUAL TERMINAL WITH THE SAME INPUTS AND IS WORKING IN CORRECT WAY. BUT WHEN I DO THE SAME FROM MY JAVA APPLICATION IT IS SHOWING AS "NULL RESPONSE". CAN YOU PLEASE CLEARLY PROVIDE ME WITH THE REASON BEHIND THE ISSUE AND WHAT CORRECTIONS SHOULD I DO IN ORDER TO SOLVE IT. I AM PASTING MY CODE BELOW.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;try {&lt;BR /&gt;&lt;BR /&gt;//Common code to set for all requests&lt;BR /&gt;ApiOperationBase.setEnvironment(Environment.SANDBOX);&lt;BR /&gt;&lt;BR /&gt;MerchantAuthenticationType merchantAuthenticationType = new MerchantAuthenticationType() ;&lt;BR /&gt;merchantAuthenticationType.setName("23xqS4PE");&lt;BR /&gt;merchantAuthenticationType.setTransactionKey("XXXXXXXXXXXX");&lt;BR /&gt;ApiOperationBase.setMerchantAuthentication(merchantAuthenticationType);&lt;BR /&gt;&lt;BR /&gt;// Populate the payment data&lt;BR /&gt;PaymentType paymentType = new PaymentType();&lt;BR /&gt;CreditCardType creditCard = new CreditCardType();&lt;BR /&gt;creditCard.setCardNumber("5424000000000015");&lt;BR /&gt;creditCard.setExpirationDate("0822");&lt;BR /&gt;paymentType.setCreditCard(creditCard);&lt;BR /&gt;&lt;BR /&gt;// Create the payment transaction request&lt;BR /&gt;TransactionRequestType txnRequest = new TransactionRequestType();&lt;BR /&gt;txnRequest.setTransactionType(TransactionTypeEnum.AUTH_CAPTURE_TRANSACTION.value());&lt;BR /&gt;txnRequest.setPayment(paymentType);&lt;BR /&gt;txnRequest.setAmount(new BigDecimal(10.00));&lt;BR /&gt;&lt;BR /&gt;// Make the API Request&lt;BR /&gt;CreateTransactionRequest apiRequest = new CreateTransactionRequest();&lt;BR /&gt;apiRequest.setTransactionRequest(txnRequest);&lt;BR /&gt;CreateTransactionController controller = new CreateTransactionController(apiRequest);&lt;BR /&gt;controller.execute();&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;CreateTransactionResponse response = controller.getApiResponse();&lt;BR /&gt;&lt;BR /&gt;if (response!=null) {&lt;BR /&gt;// If API Response is ok, go ahead and check the transaction response&lt;BR /&gt;if (response.getMessages().getResultCode() == MessageTypeEnum.OK) {&lt;BR /&gt;TransactionResponse result = response.getTransactionResponse();&lt;BR /&gt;if(result.getMessages() != null){&lt;BR /&gt;System.out.println("Successfully created transaction with Transaction ID: " + result.getTransId());&lt;BR /&gt;System.out.println("Response Code: " + result.getResponseCode());&lt;BR /&gt;System.out.println("Message Code: " + result.getMessages().getMessage().get(0).getCode());&lt;BR /&gt;System.out.println("Description: " + result.getMessages().getMessage().get(0).getDescription());&lt;BR /&gt;System.out.println("Auth Code: " + result.getAuthCode());&lt;BR /&gt;}&lt;BR /&gt;else {&lt;BR /&gt;System.out.println("Failed Transaction.");&lt;BR /&gt;if(response.getTransactionResponse().getErrors() != null){&lt;BR /&gt;System.out.println("Error Code: " + response.getTransactionResponse().getErrors().getError().get(0).getErrorCode());&lt;BR /&gt;System.out.println("Error message: " + response.getTransactionResponse().getErrors().getError().get(0).getErrorText());&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;else {&lt;BR /&gt;System.out.println("Failed Transaction.");&lt;BR /&gt;if(response.getTransactionResponse() != null &amp;amp;&amp;amp; response.getTransactionResponse().getErrors() != null){&lt;BR /&gt;System.out.println("Error Code: " + response.getTransactionResponse().getErrors().getError().get(0).getErrorCode());&lt;BR /&gt;System.out.println("Error message: " + response.getTransactionResponse().getErrors().getError().get(0).getErrorText());&lt;BR /&gt;}&lt;BR /&gt;else {&lt;BR /&gt;System.out.println("Error Code: " + response.getMessages().getMessage().get(0).getCode());&lt;BR /&gt;System.out.println("Error message: " + response.getMessages().getMessage().get(0).getText());&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;else {&lt;BR /&gt;System.out.println("Null Response.");&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;} catch(Exception e) {&lt;BR /&gt;e.printStackTrace();&lt;BR /&gt;}&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jul 2017 20:52:50 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/58657#M33275</guid>
      <dc:creator>S2ndeepN2mbiarK</dc:creator>
      <dc:date>2017-07-06T20:52:50Z</dc:date>
    </item>
    <item>
      <title>Re: NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/58709#M33324</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hi&amp;nbsp;&lt;SPAN class=""&gt;&lt;A id="link_1" class="lia-link-navigation lia-page-link lia-user-name-link" href="https://community.developer.authorize.net/t5/user/viewprofilepage/user-id/21975" target="_self"&gt;S2ndeepN2mbiarK&lt;/A&gt;,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Authorize.Net will always send a response even in the event of an error. A null response indicates that there was no successful connection when you attempt to connect to our gateway.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Joy&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jul 2017 21:03:50 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/58709#M33324</guid>
      <dc:creator>Joy</dc:creator>
      <dc:date>2017-07-06T21:03:50Z</dc:date>
    </item>
    <item>
      <title>Re: NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/59563#M34145</link>
      <description>&lt;P&gt;I realize this is over a month old, but I'm having the same issue. My sandbox account and the sample code was working just fine till the other day. Now it doesn't matter what I try to do I get a null response coming back.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Aug 2017 17:07:46 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/59563#M34145</guid>
      <dc:creator>ClintParsley</dc:creator>
      <dc:date>2017-08-28T17:07:46Z</dc:date>
    </item>
    <item>
      <title>Re: NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/62756#M37017</link>
      <description>&lt;P&gt;&lt;SPAN&gt;"Authorize.Net will always send a response even in the event of an error. A null response indicates that there was no successful connection when you attempt to connect to our gateway."&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I don't think this is true. We have many many instances where we get a null pointer back from the Java API call on the execute method.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Even in the Authorize.net example code there's logic around this. The problem is, what are we supposed to do about it? I have&amp;nbsp;baffled customers who have nothing to go on but a cryptic error message in our logs that says: "No response from Authorize.net" That's all we can say.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So what is the solution here? Retry? is there better example code (Java hopefully)? because this shouldn't ever happen:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;CreateTransactionController controller = &lt;SPAN&gt;new &lt;/SPAN&gt;CreateTransactionController(apiRequest)&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;controller.execute()&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;CreateTransactionResponse response = controller.getApiResponse()&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;if (response != null) {&lt;BR /&gt;   // do things&lt;BR /&gt;} else {&lt;BR /&gt;   // log this with a "No response from Authorize.net" &lt;BR /&gt;}&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;any guidance would be most appreciated&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 20 Apr 2018 14:19:42 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/62756#M37017</guid>
      <dc:creator>dmpalmer</dc:creator>
      <dc:date>2018-04-20T14:19:42Z</dc:date>
    </item>
    <item>
      <title>Re: NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/64417#M38318</link>
      <description>&lt;P&gt;I also am confirming that I am getting null response from Java SDK. It seems to happen when the request is invalid, but it doesn't return the error back in the response. I had to put response != null everywhere in my code, as well as the resultCode, messages, getErrors(), etc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I had to copy the xml request into a separate REST POST to receive the error. It did not return in the JAXB response object.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was getting an error code E00003 - cardCode element is invalid - The value XX is invalid according to its datatype. In that case, &amp;lt;cardCode&amp;gt; was empty. We don't always have the security code available to process a transaction, so I am making it clear not to set the value if it is missing.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Sep 2018 22:03:38 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/64417#M38318</guid>
      <dc:creator>kschaller1979</dc:creator>
      <dc:date>2018-09-06T22:03:38Z</dc:date>
    </item>
    <item>
      <title>Re: NULL RESPONSE ISSUE</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/65041#M38770</link>
      <description>&lt;P&gt;We are using the java sdk version 1.9.2&lt;/P&gt;&lt;P&gt;When we set description text on OrderType (net.authorize.api.contract.v1.OrderType), and the description happens to include the &amp;gt; (greater than) character, we ultimately get a null-pointer exception on&amp;nbsp;CreateTransactionResponse.&amp;nbsp; e.g, the response object below will be null:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CreateTransactionController controller = new CreateTransactionController(apiRequest);&lt;BR /&gt;controller.execute(this.environment);&lt;/P&gt;&lt;P&gt;CreateTransactionResponse response = controller.getApiResponse();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Nov 2018 15:54:59 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/NULL-RESPONSE-ISSUE/m-p/65041#M38770</guid>
      <dc:creator>rfd3270</dc:creator>
      <dc:date>2018-11-12T15:54:59Z</dc:date>
    </item>
  </channel>
</rss>

