function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Swathi CseSwathi Cse 

BLOB is not a valid UTF-8 string' error

BLOB is not a valid UTF-8 string' error
IvanWuIvanWu
please try the code below, hope it can solve your problem   
HttpRequest request= new HttpRequest();
request.setBodyAsBlob(csvFileBody);
csvAsString = request.getBody();

 
Naveen KNNaveen KN
This article may be useful here..
https://www.codengine.in/2019/06/blob-is-not-a-valid-utf-8-string-salesforce-apex.html