Class: Stripe::Charge::CaptureParams

Inherits:
RequestParams show all
Defined in:
lib/stripe/resources/charge.rb

Defined Under Namespace

Classes: PaymentDetails, TransferData

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(amount: nil, application_fee: nil, application_fee_amount: nil, expand: nil, payment_details: nil, receipt_email: nil, statement_descriptor: nil, statement_descriptor_suffix: nil, transfer_data: nil, transfer_group: nil) ⇒ CaptureParams

Returns a new instance of CaptureParams.



2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
# File 'lib/stripe/resources/charge.rb', line 2966

def initialize(
  amount: nil,
  application_fee: nil,
  application_fee_amount: nil,
  expand: nil,
  payment_details: nil,
  receipt_email: nil,
  statement_descriptor: nil,
  statement_descriptor_suffix: nil,
  transfer_data: nil,
  transfer_group: nil
)
  @amount = amount
  @application_fee = application_fee
  @application_fee_amount = application_fee_amount
  @expand = expand
  @payment_details = payment_details
  @receipt_email = receipt_email
  @statement_descriptor = statement_descriptor
  @statement_descriptor_suffix = statement_descriptor_suffix
  @transfer_data = transfer_data
  @transfer_group = transfer_group
end

Instance Attribute Details

#amountObject

The amount to capture, which must be less than or equal to the original amount.



2944
2945
2946
# File 'lib/stripe/resources/charge.rb', line 2944

def amount
  @amount
end

#application_feeObject

An application fee to add on to this charge.



2946
2947
2948
# File 'lib/stripe/resources/charge.rb', line 2946

def application_fee
  @application_fee
end

#application_fee_amountObject

An application fee amount to add on to this charge, which must be less than or equal to the original amount.



2948
2949
2950
# File 'lib/stripe/resources/charge.rb', line 2948

def application_fee_amount
  @application_fee_amount
end

#expandObject

Specifies which fields in the response should be expanded.



2950
2951
2952
# File 'lib/stripe/resources/charge.rb', line 2950

def expand
  @expand
end

#payment_detailsObject

Provides industry-specific information about the charge.



2952
2953
2954
# File 'lib/stripe/resources/charge.rb', line 2952

def payment_details
  @payment_details
end

#receipt_emailObject

The email address to send this charge’s receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.



2954
2955
2956
# File 'lib/stripe/resources/charge.rb', line 2954

def receipt_email
  @receipt_email
end

#statement_descriptorObject

For a non-card charge, text that appears on the customer’s statement as the statement descriptor. This value overrides the account’s default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](docs.stripe.com/get-started/account/statement-descriptors).

For a card charge, this value is ignored unless you don’t specify a ‘statement_descriptor_suffix`, in which case this value is used as the suffix.



2958
2959
2960
# File 'lib/stripe/resources/charge.rb', line 2958

def statement_descriptor
  @statement_descriptor
end

#statement_descriptor_suffixObject

Provides information about a card charge. Concatenated to the account’s [statement descriptor prefix](docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer’s statement. If the account has no prefix value, the suffix is concatenated to the account’s statement descriptor.



2960
2961
2962
# File 'lib/stripe/resources/charge.rb', line 2960

def statement_descriptor_suffix
  @statement_descriptor_suffix
end

#transfer_dataObject

An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](stripe.com/docs/connect/destination-charges) for details.



2962
2963
2964
# File 'lib/stripe/resources/charge.rb', line 2962

def transfer_data
  @transfer_data
end

#transfer_groupObject

A string that identifies this transaction as part of a group. ‘transfer_group` may only be provided if it has not been set. See the [Connect documentation](stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.



2964
2965
2966
# File 'lib/stripe/resources/charge.rb', line 2964

def transfer_group
  @transfer_group
end