refactored client code to be more modular like worker.
fetch_transaction()
fetch_last_height
fetch_block_header