Added Paolo's transaction api and unit tests.