Queries the Ledger for the current transaction fee.
The function calls the Fee request method using the WebsocketClient/AsyncWebsocketClient.
The user can decide what type of fee to get. "open" would return the open_ledger_fee field; "minimum" would return the minimum_fee field; "dynamic" would return a calculated fee based on the node's transaction queue size.
fields
type
explanation
client
WebsocketClient/AsyncWebsocketClient
A websocket client object.
max_fee
Option<u32>
The max fee the user want to spend as drops.
fee_type
Option<&str>
The type of fee to return. Must be one of: "open", "minimum", "dynamic"
get_fee
The function calls the
Fee
request method using theWebsocketClient
/AsyncWebsocketClient
.The user can decide what type of fee to get. "open" would return the
open_ledger_fee
field; "minimum" would return theminimum_fee
field; "dynamic" would return a calculated fee based on the node's transaction queue size.WebsocketClient
/AsyncWebsocketClient
Option<u32>
Option<&str>
Sources:
get_latest_validated_ledger_sequence
The function simply calls the
Ledger
request method and returns the resultsledger_index
fieldThe
ledger_index
field must be set to "validated".WebsocketClient
/AsyncWebsocketClient
Sources:
get_latest_open_ledger_sequence
The function simply calls the
Ledger
request method and returns the resultsledger_index
fieldThe
ledger_index
field must be set to "open".WebsocketClient
/AsyncWebsocketClient
Sources: