class Razorpay::Payment
Payment
class is the most commonly used class and is used to interact with Payments, the most common type of transactions
Public Class Methods
all(options = {})
click to toggle source
# File lib/razorpay/payment.rb, line 18 def self.all(options = {}) request.all options end
capture(id, options)
click to toggle source
# File lib/razorpay/payment.rb, line 22 def self.capture(id, options) request.post "#{id}/capture", options end
fetch(id)
click to toggle source
# File lib/razorpay/payment.rb, line 14 def self.fetch(id) request.fetch id end
request()
click to toggle source
# File lib/razorpay/payment.rb, line 10 def self.request Razorpay::Request.new('payments') end
Public Instance Methods
bank_transfer()
click to toggle source
# File lib/razorpay/payment.rb, line 52 def bank_transfer self.class.request.get "#{id}/bank_transfer" end
capture(options)
click to toggle source
# File lib/razorpay/payment.rb, line 36 def capture(options) self.class.request.post "#{id}/capture", options end
capture!(options)
click to toggle source
# File lib/razorpay/payment.rb, line 40 def capture!(options) with_a_bang { capture options } end
method()
click to toggle source
# File lib/razorpay/payment.rb, line 48 def method method_missing(:method) end
refund(options = {})
click to toggle source
# File lib/razorpay/payment.rb, line 26 def refund(options = {}) self.class.request.post "#{id}/refund", options end
refund!(options = {})
click to toggle source
# File lib/razorpay/payment.rb, line 30 def refund!(options = {}) refund = refund options with_a_bang { self.class.request.fetch id } refund end
refunds()
click to toggle source
# File lib/razorpay/payment.rb, line 44 def refunds self.class.request.get "#{id}/refunds" end