Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Subscriptions with Paypal IPN

People also ask

Can PayPal be used for subscriptions?

Update your payment info in one place. Fixing billing info for subscriptions one-by-one is time consuming. With PayPal, you do it once and control all your subscriptions from one, convenient hub.

How do I create a subscription plan on PayPal?

Create a product to represent your goods or services. Create a plan to represent the payment cycles for your subscription. Use the PayPal JavaScript SDK to present the PayPal button. When the buyer selects the button, the subscription experience begins.

Where do I find my recurring subscriptions on PayPal?

Open the Recurring payments dashboard. Log in to your PayPal Business or Premier account at www.paypal.com. Click Tools > All Tools at the top of the page, and then select Recurring Payments from the Tools page. The Recurring payments dashboard opens.

How do PayPal subscriptions work?

PayPal attempts to collect recurring payments from subscribers on the day after the previous billing cycle or trial period ends. Billing cycles can be daily, weekly, monthly or yearly, depending on the terms of the original subscription.


subscr_eot is sent when a user's last paid interval has expired. subscr_cancel is sent as soon as the use cancels the subscription - for example:

User signs up on day 1 for a subscription which is billed once a month. subscr_signup is sent immediately, subscr_payment is sent as soon as payment goes through (usually immediately as well).

On day 13, the user cancels. subscr_cancel is immediately sent, although the user has technically paid through to day 30. Cancelling at this point is up to you.

On day 30, subscr_eot is sent - the user has cancelled, and this is the day which his last payment paid until.

Not much changes with trial subscriptions - if a user cancels before a trial subscription is up, subscr_cancel is sent immediately, and subscr_eot is sent at the end of the trial.


Also, one interesting detail is how subscr_eot works with subscr_failed.

It looks like subscr_eot comes after the FINAL subscr_failed. So if in your account you set it to automatically retry failed payments 3 times, then it should go like this:

first failed payment => subscr_failed second failed payment => subscr_failed third failed payment => subscr_failed and subscr_eot

so basically in your code you can set subscr_failed to trigger an email like

hi user, please take moment to check your payment info, you may need to update the credit card expiration date, etc. You still have access, we'll try again in a few days.

And setup subscr_eot to actually turn their subscription off and trigger an email like

Sorry, we still havent' gotten payment and have taken your profile down. You can still reactivate it by logging in and updating your payment info

Basically this is the "nice" way of doing it so customers have a grace period, and their account isn't shut off unexpectedly just because of an expired credit card or something like that.


The thread posted by Chris has been updated recently.

Sometime in 2010, PayPal stopped using subscr_eot when a user cancelled their account. After a number of complaints, they reinstated this, but took 6 months to do so. All this means is that you can once again handle your subscription notifications as described by Peter in the accepted answer.

From a PayPal representative:

subscr_cancel means the profile is canceled and there will not be future payments. However, if the buyer has already paid for the current billing cycle as they are charged up-front, then you can use the subscr_eot to terminate the profile.

Still unsure what happens in the event of multiple failed payment attempts, however. PayPal documentation at the moment is terrible.


It depends on the account if it is new or not whether subscr_eot gets sent, which is kinda beyond me?

I haven't found the proper way to manage subscriptions yet. Calculating the dates on the server could go wrong very fast if there is a delay in payment.