":{"message":"not supported model for image generation (request id: 202512041526...
🚨 错误信息
我用文档里的图片编辑示例,把2.5换成了gemini-3-pro-image-preview。报错显示{"error":{"message":"not supported model for image generation (request id: 202512041526151391440619a30xkLW)","type":"new_api_error","param":"","code":"convert_request_failed"}}
🤖 AI解决方案
报错分析报告
1. 错误翻译
原文:not supported model for image generation
译文:不支持用于图像生成的模型
2. 原因分析
- 根本原因:
gemini-3-pro-image-preview模型不支持图像生成功能 - 错误位置:在调用图像编辑API时使用了不兼容的模型参数
3. 解决方案
# 正确的模型配置示例
# 使用支持图像生成的模型,如:
model = "dall-e-3" # 或 "dall-e-2"
# 或者使用官方推荐的图像生成模型
# 如果需要进行图像编辑,确保使用正确的端点
# 例如使用OpenAI的DALL-E系列模型
4. ️ 预防措施
建议:检查DMXAPI平台的模型支持列表,选择专门用于图像生成的模型进行替换。