Error: Invalid base64-encoded string: number of data characters (53) cannot be 1 more than a multiple of 4

I keep getting this error for gpt4-v today, but no such error before today, for the same image. What updates are made in the vision api? how should I avoid this error?

Have you check your base64 encoded string of that image?
Use a online base64 decoder or paste your imgage base64 data url on a img tag to preview if it’s broken.
Length of correct base64 string should be multiple of 4. It’s what the error message says.

@pondin6666 the thing is this did not happen yesterday, and I did not change anything about the code. So the issue is most probably from the gpt api.