<?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 Transaction File field refTransId setiting and retrieving in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Transaction-File-field-refTransId-setiting-and-retrieving/m-p/75232#M46884</link>
    <description>&lt;P&gt;I need a little help please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to pass information into the transaction on creation and retrieve that information when I download the transaction.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using the field&amp;nbsp;refTransId to do this with. The problem is that I'm not getting the&amp;nbsp;refTransId information back when I pull the transaction detail file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the creation of the transaction where the&amp;nbsp;refTransId is set in the orderType object:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;            // standard api call to retrieve response
            var paymentType = new paymentType { Item = oBankAccount };

            string Reference = ContributorID.ToString() + "-EC-" + ECIDNo.ToString();
            orderType oOrderType = new orderType
            {
                invoiceNumber = ContributorID.ToString(),
                description = "Shrine Services Contribution",
                authorizedContactName = oBankAccount.nameOnAccount
            };

            var transactionRequest = new transactionRequestType
            {
                transactionType = transactionTypeEnum.authCaptureTransaction.ToString(), 
                payment = paymentType,
                amount = SaleAmount,
                refTransId = Reference,
                order = oOrderType
            };

            var request = new createTransactionRequest { transactionRequest = transactionRequest };

            // instantiate the controller that will call the service
            var controller = new createTransactionController(request);
            controller.Execute();&lt;/PRE&gt;&lt;P&gt;This is the code for getting the information when retrieving the transaction detail:&lt;/P&gt;&lt;PRE&gt;var request = new getTransactionDetailsRequest();
            request.transId = TransactionID;

            // instantiate the controller that will call the service
            var controller = new getTransactionDetailsController(request);
            controller.Execute();

            // get the response from the service (errors contained if any)
            var response = controller.GetApiResponse();

            if (response != null &amp;amp;&amp;amp; response.messages.resultCode == messageTypeEnum.Ok)
            {
                if (response.transaction == null)
                {
                    ErrorMessage = "No details returned";
                    return null;
                }

                oTranItem = new TransItem
                {
                    TransID = response.transaction.transId,
                    TransStatus = response.transaction.transactionStatus,
                    SettlementDate = response.transaction.submitTimeLocal,
                    TransAmount = response.transaction.authAmount,
                    TransSettle = response.transaction.settleAmount,
                    Invoice = response.transaction.order.invoiceNumber,
                    ReferanceID = response.transaction.refTransId
                };
            }
            else if (response != null)
            {
                ErrorMessage = "No details returned";
                return null;
            }
            return oTranItem;&lt;/PRE&gt;&lt;P&gt;Question:&lt;/P&gt;&lt;P&gt;1) Is there a way to be sure that the information is actually set on the creation of the transaction?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Why is the retrieval of the transaction detail empty?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any help provided.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 05 Mar 2021 13:51:16 GMT</pubDate>
    <dc:creator>ShrineServices</dc:creator>
    <dc:date>2021-03-05T13:51:16Z</dc:date>
    <item>
      <title>Transaction File field refTransId setiting and retrieving</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Transaction-File-field-refTransId-setiting-and-retrieving/m-p/75232#M46884</link>
      <description>&lt;P&gt;I need a little help please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to pass information into the transaction on creation and retrieve that information when I download the transaction.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using the field&amp;nbsp;refTransId to do this with. The problem is that I'm not getting the&amp;nbsp;refTransId information back when I pull the transaction detail file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the creation of the transaction where the&amp;nbsp;refTransId is set in the orderType object:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;            // standard api call to retrieve response
            var paymentType = new paymentType { Item = oBankAccount };

            string Reference = ContributorID.ToString() + "-EC-" + ECIDNo.ToString();
            orderType oOrderType = new orderType
            {
                invoiceNumber = ContributorID.ToString(),
                description = "Shrine Services Contribution",
                authorizedContactName = oBankAccount.nameOnAccount
            };

            var transactionRequest = new transactionRequestType
            {
                transactionType = transactionTypeEnum.authCaptureTransaction.ToString(), 
                payment = paymentType,
                amount = SaleAmount,
                refTransId = Reference,
                order = oOrderType
            };

            var request = new createTransactionRequest { transactionRequest = transactionRequest };

            // instantiate the controller that will call the service
            var controller = new createTransactionController(request);
            controller.Execute();&lt;/PRE&gt;&lt;P&gt;This is the code for getting the information when retrieving the transaction detail:&lt;/P&gt;&lt;PRE&gt;var request = new getTransactionDetailsRequest();
            request.transId = TransactionID;

            // instantiate the controller that will call the service
            var controller = new getTransactionDetailsController(request);
            controller.Execute();

            // get the response from the service (errors contained if any)
            var response = controller.GetApiResponse();

            if (response != null &amp;amp;&amp;amp; response.messages.resultCode == messageTypeEnum.Ok)
            {
                if (response.transaction == null)
                {
                    ErrorMessage = "No details returned";
                    return null;
                }

                oTranItem = new TransItem
                {
                    TransID = response.transaction.transId,
                    TransStatus = response.transaction.transactionStatus,
                    SettlementDate = response.transaction.submitTimeLocal,
                    TransAmount = response.transaction.authAmount,
                    TransSettle = response.transaction.settleAmount,
                    Invoice = response.transaction.order.invoiceNumber,
                    ReferanceID = response.transaction.refTransId
                };
            }
            else if (response != null)
            {
                ErrorMessage = "No details returned";
                return null;
            }
            return oTranItem;&lt;/PRE&gt;&lt;P&gt;Question:&lt;/P&gt;&lt;P&gt;1) Is there a way to be sure that the information is actually set on the creation of the transaction?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Why is the retrieval of the transaction detail empty?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any help provided.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Mar 2021 13:51:16 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Transaction-File-field-refTransId-setiting-and-retrieving/m-p/75232#M46884</guid>
      <dc:creator>ShrineServices</dc:creator>
      <dc:date>2021-03-05T13:51:16Z</dc:date>
    </item>
  </channel>
</rss>

