Cart

@Serializable
data class Cart : Serializable

Cart contains information on what items are included in a transaction that will be shown on a reader when using setReaderDisplay.

The Cart only represents exactly what will be shown on the screen, and is not reflective of what the customer is actually charged. You are responsible for making sure that tax and total reflect what is in the cart.

For more information, see the official Stripe docs: Set the reader display

To create an instance of this class, use the Cart.Builder

Use of this SDK is subject to the Stripe Terminal Terms: https://stripe.com/terminal/legal

Types

Link copied to clipboard
class Builder @JvmOverloads constructor(var currency: String, var tax: Long, var total: Long, var lineItems: List<CartLineItem> = emptyList())

Properties

Link copied to clipboard

The currency of the cart

Link copied to clipboard

List of the individual items to list on the reader display.

Link copied to clipboard
val tax: Long = 0

The displayed tax amount, provided in the currency’s smallest unit

Link copied to clipboard
val total: Long = 0

The cart’s total balance, provided in the currency’s smallest unit

Functions

Link copied to clipboard