Emitted when image editing has completed and the final image is available.

interface ImageEditCompletedEvent {
    b64_json: string;
    background: "auto" | "transparent" | "opaque";
    created_at: number;
    output_format: "jpeg" | "png" | "webp";
    quality:
        | "low"
        | "medium"
        | "high"
        | "auto";
    size:
        | "auto"
        | "1024x1024"
        | "1536x1024"
        | "1024x1536";
    type: "image_edit.completed";
    usage: OpenAIClient.Images.ImageEditCompletedEvent.Usage;
}

Properties

b64_json: string

Base64-encoded final edited image data, suitable for rendering as an image.

background: "auto" | "transparent" | "opaque"

The background setting for the edited image.

created_at: number

The Unix timestamp when the event was created.

output_format: "jpeg" | "png" | "webp"

The output format for the edited image.

quality:
    | "low"
    | "medium"
    | "high"
    | "auto"

The quality setting for the edited image.

size:
    | "auto"
    | "1024x1024"
    | "1536x1024"
    | "1024x1536"

The size of the edited image.

type: "image_edit.completed"

The type of the event. Always image_edit.completed.

For gpt-image-1 only, the token usage information for the image generation.