IMAGES ERROR:
The API returns this error no matter what type of image i use
ERROR: .../node_modules/gemini-ai/index.js:87
if (!response.ok) throw new Error("An error occurred when fetching Gemini: \n" + json.error.message);
^
Error: An error occurred when fetching Gemini:
* GenerateContentRequest.contents[0].parts[1].inline_data.mime_type: MIME type must be image/png, image/jpeg, image/webp, image/heic, or image/heif.
const imgBuffer = fs.readFileSync("./test.jpg");
const response = await gemini.ask("Explain in detail what's in this image.", {
data: [imgBuffer],
});
console.log(response);
IMAGES ERROR: The API returns this error no matter what type of image i use