Send an image input
Importresponses, constants, and utils from the SDK. Given model and ctx:
attachment:// reference is opaque SDK state, not a public URL that a direct provider call can fetch.
Generate an image
For generation through a compatible Responses model, addTools: []responses.ToolUnion{{OfImageGeneration: &responses.ImageGenerationTool{}}} to the request. The completed OfImageGenerationCall item carries the result. Do not assume an image appears in a text delta.
For a dedicated image endpoint, call model.NewImageGeneration with image_generation.Request. The result’s Images entries may contain base64 data or URLs; inspect the populated field and MIME type. NewImageEdit is a separate operation for editing input images.