WIP: API refactor