Paddle Billing
Search

Include the total for all adjustments for a transaction

Include an object with the total for all the adjustments against a transaction, including a breakdown by adjustment action.

What's new?

We added a new adjustments_totals object that you can include when working with transactions.

adjustments_totalsobject

Breakdown of all the adjustments made against a transaction in the transaction currency.

subtotalstring

Total before tax.

taxstring

Total tax on the subtotal.

totalstring

Total after tax.

feestring

Total fee taken by Paddle.

earningsstring

Total earnings. This is the subtotal minus the Paddle fee. For tax adjustments, this value is negative, which means a positive effect in the transaction earnings. This is because the fee is originally calculated from the transaction total, so if a tax adjustment is made, then the fee portion of it is returned. As a result, the earnings from all the adjustments performed could be either negative, positive or zero.

breakdownobject

Breakdown of the total adjustments by adjustment action.

currency_codestring

Three-letter ISO 4217 currency code used for adjustments for this transaction.

You can use the include parameter with the value adjustments_totals when working with transaction entities to return it.

How it works

You can return adjustments for a transaction when working with the Paddle API by using the include parameter with the value adjustments. However, this doesn't return the total for all adjustments.

To calculate totals for adjustments, you'd need to sum transaction.adjustments[].totals yourself.

The new adjustments_totals object returns totals for you. You don't need to include adjustments to get adjustments_totals. It includes a breakdown of the totals for each adjustment action: credit, refund, and chargeback.

Examples

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 or get a transaction using the API to work with the new adjustments_totals object. Use the include parameter with the value adjustments_totals when working with transaction entities to return it.

Learn more