View Source Stripe.LineItem (Striped v0.5.0) (generated)
Link to this section Summary
Functions
When retrieving an invoice, you’ll get a lines property containing the total count of line items and 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.LineItem{ amount: integer(), amount_excluding_tax: integer() | nil, currency: binary(), description: binary() | nil, discount_amounts: term() | nil, discountable: boolean(), discounts: term() | nil, id: binary(), invoice_item: binary(), livemode: boolean(), metadata: term(), object: binary(), period: term(), plan: Stripe.Plan.t() | nil, price: Stripe.Price.t() | nil, proration: boolean(), proration_details: term() | nil, quantity: integer() | nil, subscription: binary() | nil, subscription_item: binary(), tax_amounts: term(), tax_rates: term(), type: binary(), unit_amount_excluding_tax: binary() | nil }
The line_item type.
amountThe amount, in %s.amount_excluding_taxThe integer amount in %s representing the amount for this line item, excluding all tax and discounts.currencyThree-letter ISO currency code, in lowercase. Must be a supported currency.descriptionAn arbitrary string attached to the object. Often useful for displaying to users.discount_amountsThe amount of discount calculated per discount for this line item.discountableIf true, discounts will apply to this line item. Always false for prorations.discountsThe discounts applied to the invoice line item. Line item discounts are applied before invoice discounts. Useexpand[]=discountsto expand each discount.idUnique identifier for the object.invoice_itemThe ID of the invoice item associated with this line item if any.livemodeHas the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.metadataSet of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items withtype=subscriptionthis will reflect the metadata of the subscription that caused the line item to be created.objectString representing the object's type. Objects of the same type share the same value.periodplanThe plan of the subscription, if the line item is a subscription or a proration.priceThe price of the line item.prorationWhether this is a proration.proration_detailsAdditional details for proration line itemsquantityThe quantity of the subscription, if the line item is a subscription or a proration.subscriptionThe subscription that the invoice item pertains to, if any.subscription_itemThe subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.tax_amountsThe amount of tax calculated per tax rate for this line itemtax_ratesThe tax rates which apply to the line item.typeA string identifying the type of the source of this line item, either aninvoiceitemor asubscription.unit_amount_excluding_taxThe amount in %s representing the unit amount for this line item, excluding all tax and discounts.
Link to this section Functions
@spec list( client :: Stripe.t(), invoice :: 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 an invoice, you’ll get a lines property containing the total count of line items and 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/invoices/{invoice}/lines