API rework to make it more logicall