cancel
Showing results for 
Search instead for 
Did you mean: 

ARB - Update Subscripti​on Error

My C# project has reference to AuthorizeNet.dll. I am not the one who started this project but I assume it was copied from lib folder of sample code projects. CreateSubscription and CancelSubscription works fine.

 

Now, I need to update 'Invoice' of the existing Subscription and here is my code. I get error "Need a credit card number to set up this subscription". Can somebody please tell what am I doing wrong? I don't have credit card details to set in Subscription request.

 

var  request = SubscriptionRequest.CreateNew();

            

request.Invoice = InvoiceNumber;

request.SubscriptionID = subscriptionCode;           

               

var gate = new SubscriptionGateway(APILoginKey, APITransactionKey, APIServiceMode);

               

var response = gate.UpdateSubscription(request);

sim
Member
10 REPLIES 10

Hi sim,

 

I believe this was a limitation of the early version of our SDK. I recommend that you download a new version of our SDK and see if you continue to have any issues or problems.

 

Thanks,
Joy

Joy
Administrator Administrator
Administrator

Definitely not fixed, almost two years year. I'm running into the exact same issue. Looking at the 1.7.1 SDK, it's clear that invoice number is not sent along in the UpdateSubscription method, and that it is expecting other values (such as credit card information) to be passed through. I get the same exception.

I too am having an issue with updating a subscription using the .NET SDK v1.7.1. My Create and Cancel functions are working great. This is isolated to Updates. Here is my code,

 

var subscriptionGateway = new SubscriptionGateway(_apiLogin, _apiTransactionKey, ServiceMode.Test);

 

//Although it makes sense, using this method throws an error... "Method not found: 'AuthorizeNet.SubscriptionRequest AuthorizeNet.SubscriptionRequest.CreateNew()'."

//var sReq =SubscriptionRequest.CreateNew(); 

 

//so instead, I use this method, even though this is for UPDATES.

var sReq = SubscriptionRequest.CreateMonthly("email", "subscriptionName", 123.44);


sReq.SubscriptionID = ProfileId;

// I conditionally provide these, if needing to update the CC. Details removed for simplicity...

sReq.WithBillingAddress...

sReq.UsingCreditCard...

 

sReq.BillingCycles = 9999;

var resp = subscriptionGateway.UpdateSubscription(sReq);
               

----

Regardless if I supply the Billing Address and Credit Card, I get an error stating that I must provide Card information to Create a profile. Yes, to Create... despite calling the UpdateSubscription Method, that is the error that is returned.

 

Does anyone have any working examples of how to update a subscription,

1) Just amount

2) Amount and Credit Card

 

Thanks in advance,

Hello mexner,


I've reported your issue to the product team for analysis.

I'd recommend subscribing to this topic so that you'll be alerted via email if there are updates. To subscribe, click Topic Options at the top of this thread and then select Subscribe. You'll then receive an email once anyone replies to your post.

Thanks,

Richard

Thanks Richard, appreciate the help.

Richard, what is a typical response time from your team? I'm working on a project and inquiring team members are restless if we will be able to include this in our next release.

The C# SDKs source is available for download at the same place you download the binary . You can fix it if you can't wait.

Thanks Richard, we are looking into the SDK. Just curious if your thinking days, weeks, or months for a reply for your prod team?

Hello Mexner,

 

Unfortunately, I don't have any additional details on when a fix might be available for the issue.  If you subscribe to this topic, I'll update it once anything is available.

 

Richard