use transaction api internally