Setting things up
Installing Node and VS Code EditorInstalling "XRPL JS TS Demo" and DependenciesXRP Ledger accounts
Learning More About XRP Ledger AccountGenerating XRPL AccountDerive r-address From SecretBrief Overview of The XRP LedgerFirst XRPL interaction
Activate Existing XRPL Account on Test NetworkConnecting and Interacting with XRP Ledger: account_infoInteracting with XRP Ledger using JSON-RPCError Handling and Best PracticesBasics of XRP and Issued CurrencySigning Payment TransactionAssignment SolutionVerifying SignatureSubmit Transaction Signature To XRP LedgerSubscription MethodsSubscription Methods To Build Responsive AppTransaction VerificationBalance DetailTransaction CostMeasures to Avoid Ledger SpammingSource And Destination TagsAccountSet Transaction: Domain, GravatarAccountSet Transaction: SetFlag, ClearFlagDeposit AuthorizationTokens, transactions
Issuing Token on XRPLToken(IOU): Payment TransactionCommands To Fetch TrustLine InformationFreeze a TrustLineIssuer: Transfer FeesMore about TrustLineCurrency Code In Hex FormatRemoving a TrustLineRequire authorization FlagLedger features
AccountDelete TransactionTickets: TheoryTicketCreate TransactionDelete Ticket ObjectSetRegularKey
SetRegularKey: The ConceptAssigning RegularKeyChange RegularKeyRemove RegularKeyBlackhole An AccountMultiSigning
MultiSigning: The ConceptReplace SignerListCreate SignerListReplace SignerListMulti-signed Payment TransactionRemoving SignerListTransaction Cost
Intro
Let’s fetch the transaction fee from the ledger.
Video
Topics covered
- Current Transaction Cost in Drops = (base_fee × load_factor) ÷ load_base
- Fetch network fee from server_state command.
References
Update
const { state } = await client.send({
command: "server_state",
});
console.log(
"Current Transaction Cost in Drops ",
(state.validated_ledger.base_fee * state.load_factor) / state.load_base
);
Final tip: It’s always better to fetch the transaction fee directly from the ledger, as it depends upon the network load and we can not guess the load at any given time.
← Previous
Next →