View Source Stripe.CreditNoteLineItem (stripity_stripe v3.1.1)

The credit note line item object

Link to this section Summary

Types

t()

The credit_note_line_item type.

Functions

When retrieving a credit note, you’ll get a lines property containing the the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

Link to this section Types

@type t() :: %Stripe.CreditNoteLineItem{
  amount: integer(),
  amount_excluding_tax: integer() | nil,
  description: binary() | nil,
  discount_amount: integer(),
  discount_amounts: term(),
  id: binary(),
  invoice_line_item: binary(),
  livemode: boolean(),
  object: binary(),
  quantity: integer() | nil,
  tax_amounts: term(),
  tax_rates: term(),
  type: binary(),
  unit_amount: integer() | nil,
  unit_amount_decimal: binary() | nil,
  unit_amount_excluding_tax: binary() | nil
}

The credit_note_line_item type.

  • amount The integer amount in cents (or local equivalent) representing the gross amount being credited for this line item, excluding (exclusive) tax and discounts.
  • amount_excluding_tax The integer amount in cents (or local equivalent) representing the amount being credited for this line item, excluding all tax and discounts.
  • description Description of the item being credited.
  • discount_amount The integer amount in cents (or local equivalent) representing the discount being credited for this line item.
  • discount_amounts The amount of discount calculated per discount for this line item
  • id Unique identifier for the object.
  • invoice_line_item ID of the invoice line item being credited
  • livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode.
  • object String representing the object's type. Objects of the same type share the same value.
  • quantity The number of units of product being credited.
  • tax_amounts The amount of tax calculated per tax rate for this line item
  • tax_rates The tax rates which apply to the line item.
  • type The type of the credit note line item, one of invoice_line_item or custom_line_item. When the type is invoice_line_item there is an additional invoice_line_item property on the resource the value of which is the id of the credited line item on the invoice.
  • unit_amount The cost of each unit of product being credited.
  • unit_amount_decimal Same as unit_amount, but contains a decimal value with at most 12 decimal places.
  • unit_amount_excluding_tax The amount in cents (or local equivalent) representing the unit amount being credited for this line item, excluding all tax and discounts.

Link to this section Functions

Link to this function

list(credit_note, params \\ %{}, opts \\ [])

View Source
@spec list(
  credit_note :: binary(),
  params :: %{
    optional(:ending_before) => binary(),
    optional(:expand) => [binary()],
    optional(:limit) => integer(),
    optional(:starting_after) => binary()
  },
  opts :: Keyword.t()
) ::
  {:ok, Stripe.List.t(t())} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

When retrieving a credit note, you’ll get a lines property containing the the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

Details

  • Method: get
  • Path: /v1/credit_notes/{credit_note}/lines