Fixes and further API implementation