fix API requests