Transaction class re-write to use API