Interpret booleans in database as booleans and fix api endpoint