Refactored for interface sdk 0.3.0