module Mobilepay::Client::CaptureAmount

Reservations_CaptureAmount

Public Instance Methods

capture_amount(args = {}) click to toggle source

Captures a previously reserved amount, either in full or partially

# File lib/mobilepay/client/capture_amount.rb, line 6
def capture_amount(args = {})
    check_args(order_id: args[:order_id])
    @body = args[:body]
    response = request(:put, "/reservations/merchants/#{merchant_id}/orders/#{args[:order_id]}")
    response.parsed_response
rescue Failure => ex
    return { error: ex.message }
end