Further reworking of API