fee
Gets the fee for a deposit or withdrawal operation.
Note: This endpoint is deprecated in SEP-24. Anchors should use SEP-38 quotes for fee calculation instead. This method is provided for compatibility with anchors that still support the legacy fee endpoint.
Return
Sep24FeeResponse containing the fee amount
Parameters
request
Fee request parameters
Throws
If authentication is required but not provided
On validation error
On anchor server error
Example:
val feeResponse = sep24.fee(Sep24FeeRequest(
operation = "deposit",
assetCode = "USDC",
amount = "100"
))
println("Fee: ${feeResponse.fee}")Content copied to clipboard