Sep31Fee Details
data class Sep31FeeDetails(val total: String, val asset: String, val details: List<Sep31FeeDetailsDetails>? = null)
Fee breakdown applied to a SEP-31 transaction.
Replaces the deprecated amount_fee / amount_fee_asset fields with a structured object containing the aggregate fee (total), the fee asset (asset), and an optional list of line items (details) that further decompose the total.
The total field is String (not numeric) because SEP-31 amounts must preserve decimal precision; callers convert to a domain-specific numeric type at the application boundary.
Usage
val response = sep31Service.getTransaction(id = "tx-id", jwt = jwt)
val fees = response.feeDetails ?: return
println("Total fee: ${fees.total} ${fees.asset}")
for (line in fees.details.orEmpty()) {
println(" ${line.name}: ${line.amount}")
}Content copied to clipboard
See also
Properties
Link copied to clipboard
Optional list of fee line items whose Sep31FeeDetailsDetails.amount values sum to total. null when the anchor does not decompose the fee.