So recurring monthly payments are pretty simple. What about auto-refill, like Skype (every time your account runs low on credit, you get auto-charged)? Is this possible using Paypal (in a somewhat seamless way)? I'm guessing it's a terrible idea to even think about storing credit card information. What about another payments solution?
Paypal has a method for recurring payments. The method of implementing it depends on which API you are using. I believe the buyer has to have a Paypal account though (meaning I don't think it works if they are just entering credit card info for a one-time purchase)
Some payment gateways offer the service of storing credit cards to charge later. TrustCommerce provides this feature with their Citadel service, which is what I am familiar with. I'm not sure if paypal has anything similar.
When the user makes their first payment, they give you credit card information, which you authorize and store with the gateway. The gateway gives you a unique id so that you can charge that credit card again. This means you don't have to be responsible for storing credit card data yourself.
response = TrustCommerce::Subscription.create(
:cc => '4111111111111111',
:exp => '0412',
:name => 'John Smith'
)
billing_id = response[:billingid]
response = TrustCommerce::Subscription.charge(
:billingid => billing_id,
:amount => 1000 # $10.00 amount is in cents
)
I'm sorry I don't know what paypal has to offer in this field but I do know that there are many other gateways that do this. I highly recommend that you check out TrustCommerce, you can use ActiveMerchant, or the TrustCommerce Gem
Solved this with reference transactions. See https://www.paypal.com/en%5FUS/vhelp/paypalmanager%5Fhelp/about%5Freference%5Ftransactions.htm