> For the complete documentation index, see [llms.txt](https://developer.paddle.com/llms.txt).

# See the amount before payments for a transaction

Get the amount that a customer has to pay more easily using the new grand total field against totals for a transaction. It's especially useful for completed transactions.

---

## What's new?

We added a new `grand_total` field to `transaction.details.totals` to make it clearer what the total amount to pay against a [transaction](https://developer.paddle.com/api-reference/transactions/overview.md) is.

- **totals** (object): Breakdown of the total for a transaction.
  - **grand_total** (string): Amount due for a transaction after tax, discount, and credits.. Example: `16500`

## How it works

The `totals.balance` field against `transaction.details.totals` shows you how much is due after discount, tax, and any credits. However, it also includes any payments, which means that it's `0` after a transaction is completed.

This made it difficult to work out what a customer had paid after a transaction is completed. You'd need to sum `transaction.payments[].amount`, or calculate `transaction.details.totals.total` minus `transaction.details.totals.credit`.

The new `grand_total` field gives you the total for a transaction after discount, tax, and any credits but before any payments.

## Examples

```json {% title="Example transaction totals object" highlightLines="9" %}
{
  "totals": {
    "subtotal": "15500",
    "discount": "500",
    "tax": "1500",
    "total": "16500",
    "credit": "1000",
    "balance": "0",
    "grand_total": "15500",
    "fee": "825",
    "earnings": "15675",
    "currency_code": "USD"
  }
}
```

## Next steps

This change is available in version `1` of the Paddle API.

It's a non-breaking change, meaning it doesn't impact existing integrations.

You can [list transactions](https://developer.paddle.com/api-reference/transactions/list-transactions.md) or [get a transaction](https://developer.paddle.com/api-reference/transactions/get-transaction.md) using the API to see the new `grand_total` field. When listing [filter to see completed transactions](https://developer.paddle.com/api-reference/about/filter-search-sort.md) using the `status` parameter with the value `completed`.
## Summary of changes

| Name | Type | Change | Entity | Description |
| --- | --- | --- | --- | --- |
| `grand_total` | Field | added | Transaction | Amount due after tax, discounts, and credits, before payments. Under details.totals. |
