Loading Texture from binary results of a POST request

I am retrieving a JPEG file via a POST request and need to load it into a Texture. The response has binary data in it. This isn’t loading correctly: I am getting the red checkerboard pattern. Any suggestions?

const response = await $.ajax({
        url: imageUri,
        type: 'POST',
        contentType: "text/plain; charset=utf-8",
    });

const texture = BABYLON.Texture.LoadFromDataString("mapTexture", response, scene);

You should be able to load it via the texture constructor ArrayBuffer parameter and forcing the extension in the according parameter to smthg like “.png”

Something like here
https://www.babylonjs-playground.com/#1GXCNM#1
line 178, just subtract the variable ‘image’ with your response