What image type does inference text-to-image API return?

My POST request to a hugging face text-to-image model is returning a data string that starts with:


How do I convert to this to a Blob, base64 or File?

got it working by including a responseType param in the POST request to hugging face.

Outlined the Node.js request here.