Generate
Unified image generation endpoint — the simplest way to create images.
The generate method is a simplified entry point for quick image generation. It wraps POST /generate with sensible defaults.
Basic Usage
With Extra Parameters
GenerateResult Properties
| Property | Python | JavaScript | Type | Description |
|---|---|---|---|---|
| ID | result.id | result.id | string | Request ID |
| Images | result.images | result.images | list[str] / string[] | Generated image URLs |
| First image | result.image_url | result.imageUrl | string | null | Convenience: first URL |
| Model | result.model | result.model | string | Model identifier used |
| Provider | result.provider | result.provider | string | e.g. "fal", "replicate" |
| Mode | result.mode | result.mode | string | "managed" or "byok" |
| Cost | result.cost | result.cost | float / number | Estimated cost in USD |
| Latency | result.latency_ms | result.latencyMs | int / number | Latency in milliseconds |
| Resolution | result.resolution | result.resolution | dict / object | { width, height } |
| Created at | result.created_at | result.createdAt | string | ISO timestamp |