import { Ecanna } from "ecanna/dist" import { StakeVMAPI } from "ecanna/dist/apis/stakevm" const ip: string = "localhost" const port: number = 9650 const protocol: string = "http" const networkID: number = 1337 const ecanna: Ecanna = new Ecanna(ip, port, protocol, networkID) const stkchain: StakeVMAPI = ecanna.STKChain() const main = async (): Promise => { const txID: string = "2T7F1AzTLPzZrUcw22JLcC8yZ8o2muhjrM5zoQ3TBuENbAUvZd" const encoding: string = "json" const tx: string | object = await stkchain.getTx(txID, encoding) console.log(tx) } main()