Class: Stripe::Issuing::AuthorizationCaptureParams
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::Issuing::AuthorizationCaptureParams
- Defined in:
- lib/stripe/params/issuing/authorization_capture_params.rb
Defined Under Namespace
Classes: PurchaseDetails
Instance Attribute Summary collapse
-
#capture_amount ⇒ Object
The amount to capture from the authorization.
-
#close_authorization ⇒ Object
Whether to close the authorization after capture.
-
#expand ⇒ Object
Specifies which fields in the response should be expanded.
-
#purchase_details ⇒ Object
Additional purchase information that is optionally provided by the merchant.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(capture_amount: nil, close_authorization: nil, expand: nil, purchase_details: nil) ⇒ AuthorizationCaptureParams
constructor
A new instance of AuthorizationCaptureParams.
Methods inherited from RequestParams
attr_accessor, coerce_params, coerce_value, new, #to_h
Constructor Details
#initialize(capture_amount: nil, close_authorization: nil, expand: nil, purchase_details: nil) ⇒ AuthorizationCaptureParams
340 341 342 343 344 345 346 347 348 349 350 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 340 def initialize( capture_amount: nil, close_authorization: nil, expand: nil, purchase_details: nil ) @capture_amount = capture_amount = = @purchase_details = purchase_details end |
Instance Attribute Details
#capture_amount ⇒ Object
The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](docs.stripe.com/currencies#zero-decimal).
332 333 334 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 332 def capture_amount @capture_amount end |
#close_authorization ⇒ Object
Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
334 335 336 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 334 def end |
#expand ⇒ Object
Specifies which fields in the response should be expanded.
336 337 338 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 336 def end |
#purchase_details ⇒ Object
Additional purchase information that is optionally provided by the merchant.
338 339 340 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 338 def purchase_details @purchase_details end |
Class Method Details
.field_encodings ⇒ Object
352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 |
# File 'lib/stripe/params/issuing/authorization_capture_params.rb', line 352 def self.field_encodings @field_encodings = { purchase_details: { kind: :object, fields: { fleet: { kind: :object, fields: { reported_breakdown: { kind: :object, fields: { fuel: { kind: :object, fields: { gross_amount_decimal: :decimal_string } }, non_fuel: { kind: :object, fields: { gross_amount_decimal: :decimal_string } }, tax: { kind: :object, fields: { local_amount_decimal: :decimal_string, national_amount_decimal: :decimal_string, }, }, }, }, }, }, fuel: { kind: :object, fields: { quantity_decimal: :decimal_string, unit_cost_decimal: :decimal_string }, }, receipt: { kind: :array, element: { kind: :object, fields: { quantity: :decimal_string } }, }, }, }, } end |