Implement some transaction API

Sorry not TDD, test cases coming soon