The current Dall-E3 documentation describes the response object in a straightforward format as follows:
{
"created": 1589478378,
"data": [
{
"url": "https://..."
},
{
"url": "https://..."
}
]
}
But in reality, the actual response returned from the API includes a key named “revised_prompt”.
As for DALL-E 3, only n=1 is supported, so if you pass “url” as the “response_format” argument when calling the API, the response object looks like this:
{
"created":"********",
"data":[
{
b64_json: None,
revised_prompt: '...',
url: 'https://...'
}
]
}
To access the revised prompt, for example, you would specify it as:
response.data[0].revised_prompt
Here, ‘response’ represents the entire response object.
Please also refer to this: