View Source Stripe.InvoicePayment (stripity_stripe v3.3.1)
Invoice Payments represent payments made against invoices. Invoice Payments can be accessed in two ways:
- By expanding the
paymentsfield on the Invoice resource. - By using the Invoice Payment retrieve and list endpoints.
Invoice Payments include the mapping between payment objects, such as Payment Intent, and Invoices. This resource and its endpoints allows you to easily track if a payment is associated with a specific invoice and monitor the allocation details of the payments.
Summary
Functions
When retrieving an invoice, there is an includable payments property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of payments.
Retrieves the invoice payment with the given ID.
Types
@type t() :: %Stripe.InvoicePayment{ amount_paid: integer() | nil, amount_requested: integer(), created: integer(), currency: binary(), id: binary(), invoice: binary() | Stripe.Invoice.t() | Stripe.DeletedInvoice.t(), is_default: boolean(), livemode: boolean(), object: binary(), payment: term(), status: binary(), status_transitions: term() }
The invoice_payment type.
amount_paidAmount that was actually paid for this invoice, in cents (or local equivalent). This field is null until the payment ispaid. This amount can be less than theamount_requestedif the PaymentIntent’samount_receivedis not sufficient to pay all of the invoices that it is attached to.amount_requestedAmount intended to be paid toward this invoice, in cents (or local equivalent)createdTime at which the object was created. Measured in seconds since the Unix epoch.currencyThree-letter ISO currency code, in lowercase. Must be a supported currency.idUnique identifier for the object.invoiceThe invoice that was paid.is_defaultStripe automatically creates a default InvoicePayment when the invoice is finalized, and keeps it synchronized with the invoice’samount_remaining. The PaymentIntent associated with the default payment can’t be edited or canceled directly.livemodeHas the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.objectString representing the object's type. Objects of the same type share the same value.paymentstatusThe status of the payment, one ofopen,paid, orcanceled.status_transitions
Functions
@spec list( params :: %{ optional(:created) => created() | integer(), optional(:ending_before) => binary(), optional(:expand) => [binary()], optional(:invoice) => binary(), optional(:limit) => integer(), optional(:payment) => payment(), optional(:starting_after) => binary(), optional(:status) => :canceled | :open | :paid }, opts :: Keyword.t() ) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
When retrieving an invoice, there is an includable payments property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of payments.
Details
- Method:
get - Path:
/v1/invoice_payments
@spec retrieve( invoice_payment :: binary(), params :: %{optional(:expand) => [binary()]}, opts :: Keyword.t() ) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Retrieves the invoice payment with the given ID.
Details
- Method:
get - Path:
/v1/invoice_payments/{invoice_payment}