Fix UTF encoding issues causing empty api responses