Esempio n. 1
0
        private static void TestCreateSubscription(StripePayment payment)
        {
            StripeCustomer cust = payment.CreateCustomer(new StripeCustomerInfo { Card = GetCC() });
            //StripePlan temp = new StripePlan { Id = "myplan" };
            //DeletePlan (temp, payment);
            StripePlan plan = CreatePlan(payment);
            StripeSubscription sub = payment.Subscribe(
                cust.Id, new StripeSubscriptionInfo { Card = GetCC(), Plan = "myplan", Prorate = true });

            StripeSubscription sub2 = payment.GetSubscription(sub.CustomerID);

            TestDeleteSubscription(cust, payment);
            DeletePlan(plan, payment);
        }