toJson method
Implementation
Map<String, dynamic> toJson() => {
'images': images.map((img) => img.toJson()).toList(),
if (model != null) 'model': model,
if (revisedPrompt != null) 'revised_prompt': revisedPrompt,
if (usage != null) 'usage': usage!.toJson(),
};