<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "ApplePayontheWeb",
  "identifier" : "/documentation/ApplePayontheWeb/ApplePayPaymentRequest/total",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Apple Pay on the Web"
    ],
    "preciseIdentifier" : "instp/ApplePayPaymentRequest/total"
  },
  "title" : "total"
}
-->

# total

A line item that represents the total for the payment.

```
required ApplePayLineItem total;
```

## Discussion

See [`ApplePayLineItem`](/documentation/ApplePayontheWeb/ApplePayLineItem).

The [`amount`](/documentation/ApplePayontheWeb/ApplePayLineItem/amount) of the `total` must be greater than or equal to zero and the [`label`](/documentation/ApplePayontheWeb/ApplePayLineItem/label) must be non-empty to pass validation.

Provide a business name in the [`label`](/documentation/ApplePayontheWeb/ApplePayLineItem/label) field. Use the same business name people see when they look for the charge on their bank or credit card statement, for example, `“COMPANY, INC."`.

```javascript
"total": {
    "label": "COMPANY, INC.",
    "type": "final",
    "amount": "38.06"
}
```

> Note:
> In versions of Apple Pay JS prior to version 4, the `amount` of the `total` must be greater than zero. Check for version availability using ``doc://com.apple.applepayontheweb/documentation/ApplePayontheWeb/ApplePaySession/supportsVersion`` before setting a zero `amount`.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)