Unable to edit the image through image tool. #9540
Unanswered
yash-makwana
asked this question in
Troubleshooting
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
I'm experiencing a problem when trying to use the image editing/uploading features in LibreChat v0.8.0. The image generation feature works without any issues, but editing a generated image or uploading a file always fails with a "Field required" error.
Previous Issue
I previously reported this #9417 (comment) and tried the suggested solution, but the issue persists in 0.8.0 (I previously used 0.7.9).
Error Details
Whenever I try to edit or upload an image, I receive the following error:
{"data":{"detail":[{"input":null,"loc":["body","image"],"msg":"Field required","type":"missing"}]},"headers":{"connection":"keep-alive","content-length":"90","content-type":"application/json","date":"Wed, 10 Sep 2025 11:04:24 GMT","request-context":"appId=cid-v1:9c50578f-15e4-40ff-9a61-4409f48de6cc","strict-transport-security":"max-age=31536000; includeSubDomains"},"level":"error","message":"[image_edit_oai] Problem editing the image: The server responded with status 422: Request failed with status code 422","stack":"AxiosError: Request failed with status code 422\n at settle (/app/node_modules/axios/dist/node/axios.cjs:2031:12)\n at IncomingMessage.handleStreamEnd (/app/node_modules/axios/dist/node/axios.cjs:3148:11)\n at IncomingMessage.emit (node:events:536:35)\n at endReadableNT (node:internal/streams/readable:1698:12)\n at process.processTicksAndRejections (node:internal/process/task_queues:82:21)\n at Axios.request (/app/node_modules/axios/dist/node/axios.cjs:4258:41)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async /app/api/app/clients/tools/structured/OpenAIImageTools.js:369:26\n at async DynamicStructuredTool.call (/app/node_modules/@langchain/core/dist/tools/index.cjs:145:22)\n at async /app/node_modules/@librechat/agents/dist/cjs/tools/ToolNode.cjs:58:32\n at async Promise.all (index 0)\n at async ToolNode.run (/app/node_modules/@librechat/agents/dist/cjs/tools/ToolNode.cjs:48:25)\n at async /app/node_modules/@librechat/...","status":422,"timestamp":"2025-09-10T11:04:25.101Z"}
It appears that the image field is missing from the request body when trying to edit an image, which results in this error. I have also checked the network tab in the developer tools but did not find any additional clues.
My Configuration
IMAGE_GEN_OAI_API_KEY=<my_key>
IMAGE_GEN_OAI_BASEURL=https://azure-domain/path/openai/deployments/gpt-image-1/
IMAGE_GEN_OAI_AZURE_API_VERSION=2025-04-01-preview
This configuration works perfectly for generating images, but not for editing or uploading.
It seems like the backend is not receiving the image data when editing or uploading. Any advice or troubleshooting tips would be appreciated!
Beta Was this translation helpful? Give feedback.
All reactions