Class: SolidusPaypalCommercePlatform::PayPalCheckoutSdk::Payments::AuthorizationsReauthorizeRequest
- Inherits:
-
Object
- Object
- SolidusPaypalCommercePlatform::PayPalCheckoutSdk::Payments::AuthorizationsReauthorizeRequest
- Defined in:
- lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb
Overview
Reauthorizes an authorized PayPal account payment, by ID. To ensure that funds are still available, reauthorize a payment after its initial three-day honor period expires. You can reauthorize a payment only once from days four to 29.<br/><br/>If 30 days have transpired since the date of the original authorization, you must create an authorized payment instead of reauthorizing the original authorized payment.<br/><br/> A reauthorized payment itself has a new honor period of three days. <br/><br/>You can reauthorize an authorized payment once for up to 115% of the original authorized amount, not to exceed an increase of $75 USD.<br/><br/>Supports only the ‘amount` request parameter.
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#headers ⇒ Object
Returns the value of attribute headers.
-
#path ⇒ Object
Returns the value of attribute path.
-
#verb ⇒ Object
Returns the value of attribute verb.
Instance Method Summary collapse
-
#initialize(authorization_id) ⇒ AuthorizationsReauthorizeRequest
constructor
A new instance of AuthorizationsReauthorizeRequest.
- #pay_pal_request_id(pay_pal_request_id) ⇒ Object
- #prefer(prefer) ⇒ Object
- #request_body(reauthorize_request) ⇒ Object
Constructor Details
#initialize(authorization_id) ⇒ AuthorizationsReauthorizeRequest
Returns a new instance of AuthorizationsReauthorizeRequest.
26 27 28 29 30 31 32 33 34 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 26 def initialize() @headers = {} @body = nil @verb = "POST" @path = "/v2/payments/authorizations/{authorization_id}/reauthorize?" @path = @path.gsub("{authorization_id}", CGI.escape(.to_s)) @headers["Content-Type"] = "application/json" end |
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
24 25 26 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 24 def body @body end |
#headers ⇒ Object
Returns the value of attribute headers.
24 25 26 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 24 def headers @headers end |
#path ⇒ Object
Returns the value of attribute path.
24 25 26 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 24 def path @path end |
#verb ⇒ Object
Returns the value of attribute verb.
24 25 26 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 24 def verb @verb end |
Instance Method Details
#pay_pal_request_id(pay_pal_request_id) ⇒ Object
36 37 38 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 36 def pay_pal_request_id(pay_pal_request_id) @headers["PayPal-Request-Id"] = pay_pal_request_id end |
#prefer(prefer) ⇒ Object
40 41 42 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 40 def prefer(prefer) @headers["Prefer"] = prefer end |
#request_body(reauthorize_request) ⇒ Object
44 45 46 |
# File 'lib/solidus_paypal_commerce_platform/paypal_checkout_sdk/payments/authorizations_reauthorize_request.rb', line 44 def request_body() @body = end |