> For the complete documentation index, see [llms.txt](https://developer.all-images.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.all-images.ai/integration-guide/webhooks/image-generation.md).

# Image generation

For image generation, webhook is sent for the following status changes: `create`,`active`, `completed`, `failed`

The webhook contains [generic data](/integration-guide/webhooks.md#generic-data-in-webhook) and the[ Image generation object](/all-images.ai-api/api-reference/images-generation.md#get-image-generation). The `type`property depends on the status change :&#x20;

```json
{
   "id": string,
   "api_version": number,
   "created": number,
   "type": string,
   "data": { // Image Generation
      "id": "string",
      "name": "string",
      "prompt": "string",
      "status": 0,
      "params": [
        {
          "name": "sujetMode",
          "value": "string"
        }
      ],
      "images": [
        {
          "id": "string",
          "url": "string",
          "validate": true,
          "free": true,
          "titles": {}
        }
      ],
      "nbImages": 0,
      "tags": [
        "string"
      ],
      "metaData": {},
      "createdAt": "2023-10-30T14:10:34.002Z"
    }
}
```

| New status                    | Value of "Type" property |
| ----------------------------- | ------------------------ |
| `create`                      | print.created            |
| `active`                      | print.active             |
| *when one im*age is generated | print.progress           |
| `failed`                      | print.failed             |
| `completed`                   | print.completed          |
