-
tatum-js
🚀 Tatum SDK: A 💪 powerful, 🌟 feature-rich TypeScript/JavaScript 📚 library that streamlines the 🛠️ development of 🌐 blockchain applications.
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
The data structure of transactions does not have a field for fees. Instead, fees are implied as the difference between the sum of inputs and the sum of outputs. Any excess amount that remains after all outputs have been deducted from all inputs is the fee that is collected by the miners: https://github.com/bitcoinbook/bitcoinbook/blob/develop/ch06.asciidoc#adding-fees-to-transactions
Now I understand what I was doing wrong! I thought I had to first call prepareLitecoinSignedTransaction, and then sendLitecoinTransaction. But actually, looking at the sendLitecoinTransaction function at https://github.com/tatumio/tatum-js/blob/master/src/transaction/litecoin.ts line 88, I see it calls prepareLitecoinSignedTransaction! So, the second parameter it passes to the function prepareLitecoinSignedTransaction should be a transferBtcBasedBlockchain (a json object), not the prepared result (a hexa string). The 'constructor of undefined' error was happening because my prepare object was a hexadecimal string.