-
Notifications
You must be signed in to change notification settings - Fork 121
start_at when creating recurring profile #23
Comments
Yes, I misunderstanding start_time, too. This explain save my time. Thanks! |
I think this should be in the docs too! |
This is also giving me double charges. I know this thread is old, but what's the code for setting that first recurring charge to one month from now? |
@danieljlewis if you want monthly payments, just use |
Thanks for the reply! I didn't expect one so quickly. The difficulty is that my service offers both monthly and yearly subscription plans. So would it be better to use your code (with a simple conditional variable to make it 1.month or 1.year), or to setup a trial?
|
@danieljlewis Can you use params? Then you could do something like: This wouldn't handle the trial period, though. For doing so, you could do something like:
|
The trial period was only my thought of how to work around this issue. I'm not the Rails developer myself—I'm the one who hired the overseas devs. I want to launch and I spotted this glitch testing with live users (the problem doesn't show up in sandbox). So that to say I don't understand everything here. But here's a preview of the code. The if/else statement was already there, I just tapped into it for myself.
This seems to work perfectly now. I get the instant initial payment, and their next billing date is set to start the recurring payment (1 month away for monthly, 1 year away for yearly). Thanks for your help! |
Glad I could help |
How am I able to know the end_date of a monthly subscription, I want to know if the user cancels their recurring payment at 15 days before their subscription ends, how do I handle this? |
@JSantana90 if I understood your question the notification has this information on |
@samuelsimoes thank you, I will read it. |
When creating the recurring profile, I assumed that start_at would be Time.now. This causes a double charge with PayPal: the initial checkout charge, and the first payment for the recurring profile.
The start_at should be the date that the first recurring payment should be taken eg. a month from now if your frequency is monthly.
Could the docs be updated to reflect this as it's not explicit?
The text was updated successfully, but these errors were encountered: