Strip for a one-time payment. - Ruby on rails

Can I use Stripe to receive a one-time payment instead of recurring payments?

If so, what settings do I need to do?

+6
source share
3 answers

Yes, just use the Stripe :: Charge.create method . As a payment method, you can either transfer the card directly or contact the customer whose card must be debited.

+17
source

You can receive one-time payments through the Stripe toolbar. Switch to:

https://dashboard.stripe.com/payments

and click "+ New" payment. This will allow you to manually enter cc information. I do this with Pairing as Service clients all the time ... they just read me their card information and I enter it with the amount I charge them and the description. Then you need to enter your account password to complete the payment.

It's quick and easy ... I just want a way to let them directly enter information. Maybe I will do something like this ...

+1
source

Yes. You can simply create a Stripe account and use the simple Stripe payment example for Ruby on Rails I made recently. Check the code: https://github.com/ab00zar/StripePayment-example

Start the server using test keys, for example:

PUBLISHABLE_KEY=pk_test_g0XSu8r2ugAETksVJQXJjU30 SECRET_KEY=sk_test_A3rwGLOMNxEKDkaJOTgi4frd rails s 
+1
source

Source: https://habr.com/ru/post/920129/


All Articles