toJson method
Implementation
Map<String, dynamic> toJson() => {
if (negativePrompt != null) 'negativePrompt': negativePrompt,
'sampleCount': numberOfImages ?? 1,
if (aspectRatio != null) 'aspectRatio': aspectRatio!.toJson(),
if (addWatermark != null) 'addWatermark': addWatermark,
if (imageFormat != null) 'outputOptions': imageFormat!.toJson(),
};