class Stripe::InvoicePaymentIntent

Overview

The PaymentIntent associated with this invoice. The PaymentIntent is generated when the invoice is finalized, and can then be used to pay the invoice. Note that voiding an invoice will cancel the PaymentIntent.

Included Modules

Defined in:

stripe/models/invoice_payment_intent.cr

Constant Summary

ERROR_MESSAGE_FOR_CANCELLATION_REASON = "invalid value for \"cancellation_reason\", must be one of [abandoned, automatic, duplicate, failed_invoice, fraudulent, requested_by_customer, void_invoice]."
ERROR_MESSAGE_FOR_CAPTURE_METHOD = "invalid value for \"capture_method\", must be one of [automatic, automatic_async, manual]."
ERROR_MESSAGE_FOR_CONFIRMATION_METHOD = "invalid value for \"confirmation_method\", must be one of [automatic, manual]."
ERROR_MESSAGE_FOR_OBJECT = "invalid value for \"object\", must be one of [payment_intent]."
ERROR_MESSAGE_FOR_SETUP_FUTURE_USAGE = "invalid value for \"setup_future_usage\", must be one of [off_session, on_session]."
ERROR_MESSAGE_FOR_STATUS = "invalid value for \"status\", must be one of [canceled, processing, requires_action, requires_capture, requires_confirmation, requires_payment_method, succeeded]."
MAX_LENGTH_FOR_CLIENT_SECRET = 5000
MAX_LENGTH_FOR_DESCRIPTION = 5000
MAX_LENGTH_FOR_ID = 5000
MAX_LENGTH_FOR_RECEIPT_EMAIL = 5000
MAX_LENGTH_FOR_STATEMENT_DESCRIPTOR = 5000
MAX_LENGTH_FOR_STATEMENT_DESCRIPTOR_SUFFIX = 5000
MAX_LENGTH_FOR_TRANSFER_GROUP = 5000
VALID_VALUES_FOR_CANCELLATION_REASON = String.static_array("abandoned", "automatic", "duplicate", "failed_invoice", "fraudulent", "requested_by_customer", "void_invoice")
VALID_VALUES_FOR_CAPTURE_METHOD = String.static_array("automatic", "automatic_async", "manual")
VALID_VALUES_FOR_CONFIRMATION_METHOD = String.static_array("automatic", "manual")
VALID_VALUES_FOR_OBJECT = String.static_array("payment_intent")
VALID_VALUES_FOR_SETUP_FUTURE_USAGE = String.static_array("off_session", "on_session")
VALID_VALUES_FOR_STATUS = String.static_array("canceled", "processing", "requires_action", "requires_capture", "requires_confirmation", "requires_payment_method", "succeeded")

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from module OpenApi::Json

after_initialize after_initialize, eql?(o : self) eql?, to_hash : Hash(String, JSON::Any) to_hash, to_json_any : JSON::Any to_json_any

Class methods inherited from module OpenApi::Json

build_from_hash(hash : Hash) build_from_hash, build_from_json_any(json_any : JSON::Any) build_from_json_any

Instance methods inherited from module OpenApi::Validatable

list_invalid_properties : Array(String) list_invalid_properties, list_invalid_properties_for(key : String) : Array(String) list_invalid_properties_for, valid? : Bool valid?, validate : Nil validate

Constructor Detail

def self.new(pull : JSON::PullParser) #

[View source]
def self.new(*, amount : Int64 | Nil = nil, amount_capturable : Int64 | Nil = nil, amount_received : Int64 | Nil = nil, application : Stripe::PaymentIntentApplication | Nil = nil, application_fee_amount : Int64 | Nil = nil, automatic_payment_methods : Stripe::PaymentFlowsAutomaticPaymentMethodsPaymentIntent | Nil = nil, canceled_at : Int64 | Nil = nil, cancellation_reason : String | Nil = nil, capture_method : String | Nil = nil, client_secret : String | Nil = nil, confirmation_method : String | Nil = nil, created : Int64 | Nil = nil, currency : String | Nil = nil, customer : Stripe::PaymentIntentCustomer | Nil = nil, description : String | Nil = nil, id : String | Nil = nil, invoice : Stripe::PaymentIntentInvoice | Nil = nil, last_payment_error : Stripe::ApiErrors | Nil = nil, latest_charge : Stripe::PaymentIntentLatestCharge | Nil = nil, livemode : Bool | Nil = nil, metadata : Hash(String, String) | Nil = nil, next_action : Stripe::PaymentIntentNextAction | Nil = nil, object : String | Nil = nil, on_behalf_of : Stripe::PaymentIntentOnBehalfOf | Nil = nil, payment_method : Stripe::PaymentIntentPaymentMethod | Nil = nil, payment_method_configuration_details : Stripe::PaymentMethodConfigBizPaymentMethodConfigurationDetails | Nil = nil, payment_method_options : Stripe::PaymentIntentPaymentMethodOptions | Nil = nil, payment_method_types : Array(String) | Nil = nil, processing : Stripe::PaymentIntentProcessing | Nil = nil, receipt_email : String | Nil = nil, review : Stripe::PaymentIntentReview | Nil = nil, setup_future_usage : String | Nil = nil, shipping : Stripe::Shipping | Nil = nil, source : Stripe::PaymentIntentSource | Nil = nil, statement_descriptor : String | Nil = nil, statement_descriptor_suffix : String | Nil = nil, status : String | Nil = nil, transfer_data : Stripe::TransferData | Nil = nil, transfer_group : String | Nil = nil, amount_details : Stripe::PaymentFlowsAmountDetails | Nil = nil) #

Initializes the object @param [Hash] attributes Model attributes in the form of hash


[View source]

Class Method Detail

def self.openapi_any_of #

List of class defined in anyOf (OpenAPI v3)


[View source]

Instance Method Detail

def ==(other : self) #

Generates #hash and #== methods from all fields #== @return [Bool] #hash calculates hash code according to all attributes. #hash @return [UInt64] Hash code


def amount : Int64 | Nil #

[View source]
def amount=(amount : Int64 | Nil) #

[View source]
def amount_capturable : Int64 | Nil #

[View source]
def amount_capturable=(amount_capturable : Int64 | Nil) #

[View source]
def amount_details : Stripe::PaymentFlowsAmountDetails | Nil #

[View source]
def amount_details=(amount_details : Stripe::PaymentFlowsAmountDetails | Nil) #

[View source]
def amount_received : Int64 | Nil #

[View source]
def amount_received=(amount_received : Int64 | Nil) #

[View source]
def application : Stripe::PaymentIntentApplication | Nil #

[View source]
def application=(application : Stripe::PaymentIntentApplication | Nil) #

[View source]
def application_fee_amount : Int64 | Nil #

[View source]
def application_fee_amount=(application_fee_amount : Int64 | Nil) #

[View source]
def automatic_payment_methods : Stripe::PaymentFlowsAutomaticPaymentMethodsPaymentIntent | Nil #

[View source]
def automatic_payment_methods=(automatic_payment_methods : Stripe::PaymentFlowsAutomaticPaymentMethodsPaymentIntent | Nil) #

[View source]
def canceled_at : Int64 | Nil #

[View source]
def canceled_at=(canceled_at : Int64 | Nil) #

[View source]
def cancellation_reason : String | Nil #

[View source]
def cancellation_reason=(cancellation_reason : String | Nil) #

[View source]
def capture_method : String | Nil #

[View source]
def capture_method=(capture_method : String | Nil) #

[View source]
def client_secret : String | Nil #

[View source]
def client_secret=(client_secret : String | Nil) #

[View source]
def confirmation_method : String | Nil #

[View source]
def confirmation_method=(confirmation_method : String | Nil) #

[View source]
def created : Int64 | Nil #

[View source]
def created=(created : Int64 | Nil) #

[View source]
def currency : String | Nil #

[View source]
def currency=(currency : String | Nil) #

[View source]
def customer : Stripe::PaymentIntentCustomer | Nil #

[View source]
def customer=(customer : Stripe::PaymentIntentCustomer | Nil) #

[View source]
def description : String | Nil #

[View source]
def description=(description : String | Nil) #

[View source]
def hash(hasher) #

Generates #hash and #== methods from all fields #== @return [Bool] #hash calculates hash code according to all attributes. #hash @return [UInt64] Hash code


def id : String | Nil #

[View source]
def id=(id : String | Nil) #

[View source]
def invoice : Stripe::PaymentIntentInvoice | Nil #

[View source]
def invoice=(invoice : Stripe::PaymentIntentInvoice | Nil) #

[View source]
def last_payment_error : Stripe::ApiErrors | Nil #

[View source]
def last_payment_error=(last_payment_error : Stripe::ApiErrors | Nil) #

[View source]
def latest_charge : Stripe::PaymentIntentLatestCharge | Nil #

[View source]
def latest_charge=(latest_charge : Stripe::PaymentIntentLatestCharge | Nil) #

[View source]
def list_invalid_properties : Array(String) #

Show invalid properties with the reasons. Usually used together with valid? @return Array for valid properties with the reasons


[View source]
def livemode : Bool | Nil #

[View source]
def livemode=(livemode : Bool | Nil) #

[View source]
def metadata : Hash(String, String) | Nil #

[View source]
def metadata=(metadata : Hash(String, String) | Nil) #

[View source]
def next_action : Stripe::PaymentIntentNextAction | Nil #

[View source]
def next_action=(next_action : Stripe::PaymentIntentNextAction | Nil) #

[View source]
def object : String | Nil #

[View source]
def object=(object : String | Nil) #

[View source]
def on_behalf_of : Stripe::PaymentIntentOnBehalfOf | Nil #

[View source]
def on_behalf_of=(on_behalf_of : Stripe::PaymentIntentOnBehalfOf | Nil) #

[View source]
def payment_method : Stripe::PaymentIntentPaymentMethod | Nil #

[View source]
def payment_method=(payment_method : Stripe::PaymentIntentPaymentMethod | Nil) #

[View source]
def payment_method_configuration_details : Stripe::PaymentMethodConfigBizPaymentMethodConfigurationDetails | Nil #

[View source]
def payment_method_configuration_details=(payment_method_configuration_details : Stripe::PaymentMethodConfigBizPaymentMethodConfigurationDetails | Nil) #

[View source]
def payment_method_options : Stripe::PaymentIntentPaymentMethodOptions | Nil #

[View source]
def payment_method_options=(payment_method_options : Stripe::PaymentIntentPaymentMethodOptions | Nil) #

[View source]
def payment_method_types : Array(String) | Nil #

[View source]
def payment_method_types=(payment_method_types : Array(String) | Nil) #

[View source]
def processing : Stripe::PaymentIntentProcessing | Nil #

[View source]
def processing=(processing : Stripe::PaymentIntentProcessing | Nil) #

[View source]
def receipt_email : String | Nil #

[View source]
def receipt_email=(receipt_email : String | Nil) #

[View source]
def review : Stripe::PaymentIntentReview | Nil #

[View source]
def review=(review : Stripe::PaymentIntentReview | Nil) #

[View source]
def setup_future_usage : String | Nil #

[View source]
def setup_future_usage=(setup_future_usage : String | Nil) #

[View source]
def shipping : Stripe::Shipping | Nil #

[View source]
def shipping=(shipping : Stripe::Shipping | Nil) #

[View source]
def source : Stripe::PaymentIntentSource | Nil #

[View source]
def source=(source : Stripe::PaymentIntentSource | Nil) #

[View source]
def statement_descriptor : String | Nil #

[View source]
def statement_descriptor=(statement_descriptor : String | Nil) #

[View source]
def statement_descriptor_suffix : String | Nil #

[View source]
def statement_descriptor_suffix=(statement_descriptor_suffix : String | Nil) #

[View source]
def status : String | Nil #

[View source]
def status=(status : String | Nil) #

[View source]
def transfer_data : Stripe::TransferData | Nil #

[View source]
def transfer_data=(transfer_data : Stripe::TransferData | Nil) #

[View source]
def transfer_group : String | Nil #

[View source]
def transfer_group=(transfer_group : String | Nil) #

[View source]
def valid? : Bool #

Check to see if the all the properties in the model are valid @return true if the model is valid


[View source]