Skip to content

Subscription Model

Kartikey Tanna edited this page Jul 29, 2017 · 3 revisions

The page describes the subscription model of the application.

Whenever the user signs up, they are on a free trial of one month. All the functionalities are available for the user during the trial period.

If the user wants to use the application after one month they will have to subscribe for $9/month - which is the only available plan at the moment.

During the trial period, the user can add their credit card information in the application. But they will be charged only after the trial period of one month is over.

If the user does not wish to enter the card details before the trial ends, they will be able to login and enter the card details anytime later.

Currents application does not store any sensitive information about the user's credit cards. The information is stored on the popular payment gateway, Stripe. The application only stores the secure token created by Stripe upon submission of the user's card details to Stripe.

Without the subscription, after the trial is over, the user will be able to visit all the pages except Reports and Heatmap which are the main features of the application.

If any time in the future if Currents application is failed to charge the user's credit card, the application will try to charge the card again after 1 days, 3 days and 5 days. Even after three days, if the payment is not succeeded then the subscription will be canceled. Between this failed attempts if the user updates the credit card information, the application will attempt to charge the user.

Upon subscription cancellation, the application will remove user's subscription details along with the payment source token.

After the cancellation of the subscription, the user can re-subscribe anytime again by providing the card details.

The user will be notified about all the successful and failed payment attempts through emails.

Alerts

If the user is under the trial period, regardless of the card details added or not, he/she will be shown the remaining days of the trial. If the card details are not added, link to add the card will also be shown.

If the user's trial period is over and the user is not subscribed/active, for any reason, he/she will see the alert to subscribe for the portal.

If the user is not subscribed/active and visits Reports or HeatMap page, they will be redirected to the new_card page.

Technical Details

User's Customer ID, Subscription ID, and Payment Source ID are stored on the local database as well. No actual payment information is stored on the application's servers.
There is a flag is_active stored in the database. Which changes as per the various events related to payments. If the user.is_active is set to false, then the user can sign in but will not be able to access all the pages.

Subscription Creation

  • Whenever a new user signs up, a new customer is created on Stripe along with the subscription of the user to the monthly plan with the trial period of 31 days. No credit card is required on Sign up.
  • If a user's subscribed is canceled, the user can re-subscribe again by providing the card details on card/new page or my_account page.

Subscription Cancellation

  • After three failed attempts users subscription will be canceled. This setting can be configured from the Stripe.
  • Upon subscription cancellation event, the application will remove subscription_id for the user.

Events Webhook

Stripe sends POST requests on certain events. Those events are received by stripe_events path on the application. So the URL should be {host}/stripe_events on Stripe settings.

Clone this wiki locally