hey @_j
I tested the model a few days back and the model (gpt-image-2) api was supporting the background: transpaarent but when I checked today it’s no longer supported that
error: {
message: 'Transparent background is not supported for this model.',
type: 'image_generation_user_error',
param: 'background',
code: 'invalid_value'
},
code: 'invalid_value',
param: 'background',
type: 'image_generation_user_error'
}
Hey folks
just wanted to add an update to this,
A few days back, the api was supporting the transparant background option, however I just tested now and turns out it is no longer accepting it. Don’t know if its a glitch or what but anyone else also facing the same issue with model `gpt-image-2`
error: {
message: 'Transparent background is not supported for this model.',
type: 'image_generation_user_error',
param: 'background',
code: 'invalid_value'
},
code: 'invalid_value',
param: 'background',
type: 'image_generation_user_error'
}
const result = await this.openai.images.edit({
model: 'gpt-image-2',
image: imageFile,
quality: 'medium',
prompt,
size: '1024x1536',
background: 'transparent'
});
Yes, I have the same issue. and my work affected by this
Hi and welcome to the community!
Did you see this post from @LarisaHaster ?
The solution is to update the model.
Transparency preview in gpt-image-2 is discontinued. Gpt-image-2.5 family has more robust transparency support. Even sending just the background: transparent parameter will cause the model to find some use of transparency even if not prompted. Same costs when you remap the three prior quality value enums to the five expanded ones.