bugfixes and extra endpoints