[temp] refactor interface code