-
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allowed the SimpleBillingProvider to support cancellation
- Loading branch information
1 parent
ed6e9e2
commit 054c1c3
Showing
16 changed files
with
331 additions
and
188 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,9 @@ Initially, SaaStack comes configured with a built-in `IBillingProvider` called ` | |
|
||
This provider is a stand-in provider to be used in the early days of product development until the point you decide to replace it with an integration to a third-party Billing Management System (BMS), such as [Chargebee](https://www.chargebee.com/), [Maxio (formerly Chargify)](https://www.maxio.com/subscription-management), [Recurly](https://recurly.com/), [Zoho](https://www.zoho.com/us/billing/), and [Stripe Billing](https://stripe.com/billing). | ||
|
||
At that point, you may have already onboarded many new customers, and each of them is going to have already created a billing `Subscription`. Now, the job will be to migrate the data that has been captured by the `SimpleBillingProvider` and use it to pre-populate subscriptions in your chosen third-party BMS. | ||
At that point, you may have already onboarded many new customers, and each of them is going to have already created a billing `Subscription`. | ||
|
||
Now, the job will be to migrate the data that has been captured by the current `IBillingProvider` and use it to pre-populate subscriptions in your chosen third-party BMS. | ||
|
||
> The last thing you would want is to manually input the data you have already collected from existing customers into your new BMS. | ||
|
@@ -44,35 +46,33 @@ This is the data you will need to import into your chosen BMS, during the migrat | |
```json | ||
{ | ||
"subscriptions": [{ | ||
"id": "subscription_QR5hju7FDMIklw39GVCs", | ||
"buyerId": "user_wYU128873MRRBRtjj3E", | ||
"owningEntityId": "org_M36utr98Fdde8890BDEcS2", | ||
"providerName": "simple_billing_provider", | ||
"providerState": { | ||
"SubscriptionId": "simplesub_dd45baa2188c43d39745344356781123" | ||
}, | ||
"buyer": { | ||
"id": "user_wYU128873MRRBRtjj3E", | ||
"companyReference": "org_MM36utr98Fdde8890BDEcS2", | ||
"firstName": "firstname", | ||
"name": "{\"FirstName\":\"afirstname\",\"LastName\":\"alastname\"}", | ||
"emailAddress": "[email protected]", | ||
"address": "{\"City\":\"\",\"CountryCode\":\"NZL\",\"Line1\":\"\",\"Line2\":\"\",\"Line3\":\"\",\"State\":\"\",\"Zip\":\"\"}" | ||
}, | ||
} | ||
], | ||
"metadata": { | ||
"total": 3, | ||
"limit": 100, | ||
"offset": -1, | ||
"sort": { | ||
"direction": "Ascending" | ||
}, | ||
"filter": { | ||
"fields": [] | ||
} | ||
"subscriptions": [ | ||
{ | ||
"buyer": { | ||
"Address": "{\"City\":\"\",\"CountryCode\":\"NZL\",\"Line1\":\"\",\"Line2\":\"\",\"Line3\":\"\",\"State\":\"\",\"Zip\":\"\"}", | ||
"CompanyReference": "org_SmpntwRFK0OOtQcoMu9N7g", | ||
"EmailAddress": "[email protected]", | ||
"Id": "user_KSASWz7eUq6zcVeUbGSzw", | ||
"Name": "{\"FirstName\":\"afirstname\",\"LastName\":\"alastname\"}" | ||
}, | ||
"buyerId": "user_KSASWz7eUq6zcVeUbGSzw", | ||
"owningEntityId": "org_SmpntwRFK0OOtQcoMu9N7g", | ||
"providerName": "simple_billing_provider", | ||
"providerState": { | ||
"BuyerId": "user_KSASWz7eUq6zcVeUbGSzw", | ||
"SubscriptionId": "simplesub_4a84ac3c69c344568cca2867c29d6cc0" | ||
}, | ||
"id": "subscription_MkiRvPBa0i4e7C2yjn3AA" | ||
} | ||
], | ||
"metadata": { | ||
"filter": { | ||
"fields": [] | ||
}, | ||
"limit": 100, | ||
"offset": -1, | ||
"total": 1 | ||
} | ||
} | ||
``` | ||
|
||
|
@@ -104,11 +104,11 @@ Next, you would need to test and refine these scripts thoroughly so that they ar | |
|
||
In your chosen BMS, you will need to design and define the new pricing plans you intend to support for all your customers moving forward in this BMS. | ||
|
||
> If you are using the `SimpleBillingProvider` prior to this step, you won't see much plan information in the exported data from the previous step, that's because this provider does not maintain much plan information at all. That's because it hardcodes a single plan for everyone's use. You can find that single hardcoded plan information in the `InProcessInMemSimpleBillingGatewayService`. | ||
> If you are using the `SimpleBillingProvider` prior to this step, you won't see much plan information in the exported data from the previous step, that's because this provider does not maintain much plan information at all. It hardcodes a single plan for everyone's use. You can find that single hardcoded plan information in the `InProcessInMemSimpleBillingGatewayService`. | ||
> | ||
> You also need to remember that the `SimpleBillingProvider` has everyone on a "free" plan that requires no payment method and does not support a Trial period. | ||
This means that when you import these subscriptions (created by the `SimpleBillingProvider`) into your new BMS, you need to import them into a "free" plan that does not require them to have a valid `PaymentMethod`. If migrating from the `SimpleBillingProvider`, your customers will not have given any `PaymentMethod` yet. | ||
This means that when you import these subscriptions (created by the `SimpleBillingProvider`) into your new BMS, you need to import them into a "free" plan that does not require them to have a valid payment method. If migrating from the `SimpleBillingProvider`, your customers will not have provided any payment method yet. | ||
|
||
In the product, by default, we have defined the following tiers (see: `SubscriptionTier`): | ||
|
||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
1 change: 0 additions & 1 deletion
1
src/.idea/.idea.SaaStack/.idea/inspectionProfiles/Project_Default.xml
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.