Fixes for api