How to add a customer to Stripe Subscription

StripeConfiguration.SetApiKey(private_key);

string planA = "plan_CRE8Xijw93bjH6";
string customerID = "cus_AecrAyfISfKcVN"; //make sure customer has a payment

// Make sure to check to see if customer has a payment method

StripeSubscriptionService svc = new StripeSubscriptionService();
StripeSubscriptionCreateOptions opt = new StripeSubscriptionCreateOptions();
StripeSubscription sc = svc.Create(customerID, planA, null, null);

 

Leave a Comment