I’m trying to create AI images using FAL.AI API but it’s giving me an error 422, which I believe that’s probably caused by unexpected new line characters or spaces. Here is the error:
Error: 422 Unprocessable Entity
{“detail”:[{“type”:“json_invalid”,“loc”:[“body”,355],“msg”:“JSON decode error”,“input”:{},“ctx”:{“error”:“Invalid control character at”}}]}
Can anyone help?
Steps taken so far
I have tried running the module alone and it works by inputting the result from the previous module.
You probably fixed this, but anyone googling for this: Probably an issue with some special character in your prompt. I got the same error when my prompt contained a " character.
I had the same problem but with FLUX.1 from Blackforestlabs.
I had to tell the AI to not include any special character and no white space at the end.
To get sure I added a find replace to replace empty strings at the end.