<?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: Updating a Subscription errors out on unchanged subscription amount - C# API in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53422#M28540</link>
    <description>&lt;P&gt;I submitted an issue here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/AuthorizeNet/sdk-dotnet/issues/122" target="_blank"&gt;https://github.com/AuthorizeNet/sdk-dotnet/issues/122&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 30 Dec 2015 18:04:56 GMT</pubDate>
    <dc:creator>ksanchezssmci1</dc:creator>
    <dc:date>2015-12-30T18:04:56Z</dc:date>
    <item>
      <title>Updating a Subscription errors out on unchanged subscription amount - C# API</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53419#M28537</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to update a subscription's expiration date and billing info. &amp;nbsp;These are the ONLY fields I need to update. &amp;nbsp;When I create my request using the C# API:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;var subscriptionType = new ARBSubscriptionType
{
    billTo = addressInfo,
    payment = cc
};

var request = new ARBUpdateSubscriptionRequest
{
    subscription = subscriptionType, 
    subscriptionId = updateModel.AuthNetSubId.ToString()
};

var controller = new  ARBUpdateSubscriptionController(request);

controller.Execute();

var xml = AuthorizeNet.Util.XmlUtility.GetXml(request);

var response = controller.GetApiResponse();&lt;/PRE&gt;&lt;P&gt;I get the following error message via the controller's error messages:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;Error: E00003 The 'AnetApi/xml/v1/schema/AnetApiSchema.xsd:amount' element is invalid - The value '0' is invalid according to its datatype 'Decimal' - The MinInclusive constraint failed.&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Even though I did NOT specify an amount, when I view the XML, I get the following:&lt;/P&gt;&lt;PRE&gt;&amp;lt;?xml version=\"1.0\" encoding=\"utf-8\"?&amp;gt;
&amp;lt;ARBUpdateSubscriptionRequest
    xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
    xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"
    xmlns=\"AnetApi/xml/v1/schema/AnetApiSchema.xsd\"&amp;gt;
    &amp;lt;merchantAuthentication&amp;gt; 
        &amp;lt;name&amp;gt;6Cr7vYe4LM&amp;lt;/name&amp;gt;
        &amp;lt;transactionKey&amp;gt;4N62cdy6Zn92DK7F&amp;lt;/transactionKey&amp;gt; 
    &amp;lt;/merchantAuthentication&amp;gt;
    &amp;lt;subscriptionId&amp;gt;3044281&amp;lt;/subscriptionId&amp;gt;
    &amp;lt;subscription&amp;gt;
        &amp;lt;amount&amp;gt;0&amp;lt;/amount&amp;gt;   
        &amp;lt;trialAmount&amp;gt;0&amp;lt;/trialAmount&amp;gt;  
        &amp;lt;payment&amp;gt;
            &amp;lt;creditCard&amp;gt;        
                &amp;lt;cardNumber&amp;gt;4111111111111111&amp;lt;/cardNumber&amp;gt;    
                &amp;lt;expirationDate&amp;gt;1017&amp;lt;/expirationDate&amp;gt;      
            &amp;lt;/creditCard&amp;gt;
        &amp;lt;/payment&amp;gt;    
        &amp;lt;billTo&amp;gt;      
            &amp;lt;firstName&amp;gt;SomeFirstName&amp;lt;/firstName&amp;gt; 
            &amp;lt;lastName&amp;gt;SomeLastName&amp;lt;/lastName&amp;gt;      
            &amp;lt;address&amp;gt;SomeAddress&amp;lt;/address&amp;gt;      
            &amp;lt;city&amp;gt;SomeCity&amp;lt;/city&amp;gt;      
            &amp;lt;zip&amp;gt;91234&amp;lt;/zip&amp;gt;    
        &amp;lt;/billTo&amp;gt;  
    &amp;lt;/subscription&amp;gt;
&amp;lt;/ARBUpdateSubscriptionRequest&amp;gt;&lt;/PRE&gt;&lt;P&gt;As you can see, even though I did not specify an amount or trial amount, they are still showing up in the XML. &amp;nbsp;I even tried setting:&lt;/P&gt;&lt;PRE&gt;request.subscription.amountSpecified = false;
request.subscription.trialAmountSpecified = false;&lt;/PRE&gt;&lt;P&gt;It was my understanding, via reading the documentation and posts on this site, that during a subscription update, one only needed to include the fields that were changing. &amp;nbsp;Is this no longer the case? &amp;nbsp;Or am I doing something else incorrectly that's causing the error message above?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;-K&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 16:45:58 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53419#M28537</guid>
      <dc:creator>ksanchezssmci1</dc:creator>
      <dc:date>2015-12-30T16:45:58Z</dc:date>
    </item>
    <item>
      <title>Re: Updating a Subscription errors out on unchanged subscription amount - C# API</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53420#M28538</link>
      <description>&lt;P&gt;I would just like to add that if &amp;nbsp;I examine the request object BEFORE the controller.Execute() line, the amountSpecified and trialAmountSpecified are both false. &amp;nbsp;They both change to true once the controller.Execute() line is run.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;-K&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 16:51:31 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53420#M28538</guid>
      <dc:creator>ksanchezssmci1</dc:creator>
      <dc:date>2015-12-30T16:51:31Z</dc:date>
    </item>
    <item>
      <title>Re: Updating a Subscription errors out on unchanged subscription amount - C# API</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53421#M28539</link>
      <description>&lt;P&gt;add an issue at github&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/AuthorizeNet/sdk-dotnet/issues" target="_blank"&gt;https://github.com/AuthorizeNet/sdk-dotnet/issues&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 17:14:33 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53421#M28539</guid>
      <dc:creator>RaynorC1emen7</dc:creator>
      <dc:date>2015-12-30T17:14:33Z</dc:date>
    </item>
    <item>
      <title>Re: Updating a Subscription errors out on unchanged subscription amount - C# API</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53422#M28540</link>
      <description>&lt;P&gt;I submitted an issue here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/AuthorizeNet/sdk-dotnet/issues/122" target="_blank"&gt;https://github.com/AuthorizeNet/sdk-dotnet/issues/122&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 18:04:56 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Updating-a-Subscription-errors-out-on-unchanged-subscription/m-p/53422#M28540</guid>
      <dc:creator>ksanchezssmci1</dc:creator>
      <dc:date>2015-12-30T18:04:56Z</dc:date>
    </item>
  </channel>
</rss>

