---
title: "POST imageEvent"
method: POST
path: "imageEvent"
tags: ["Webhooks"]
---

# POST imageEvent

`POST imageEvent` (webhook)

Webhook for image events.

Webhooks are sent to the Notification URL you provide in <ins>[Account Settings](https://alttext.ai/account/edit)</ins>.

There are two types of webhook events that are sent:
  * `uploaded` - Sent when new images are added to the library.
  * `deleted` - Sent when images are deleted from the library.

## Payload

- WebhookPayload
  - `event` 'uploaded' | 'deleted': The event name which occurred.
  - `schema_ver` string: The version of the webhook JSON payload in this request.
  - `timestamp` integer: When this event occurred, in seconds-since-epoch.
  - `data` ImagesResponse
    - `images` Image[]
      - `asset_id` string: The unique ID of the image.
      - `url` string: The URL of the image. Will be `null` if the image was added via raw file upload.
      - `alt_text` string: The assigned alt text of the image.
      - `alt_texts` object: Alt text in requested languages, with language codes as keys.
      - `tags` unknown[]: Words or phrases that you want to associate with the image.
        - unknown
      - `metadata` object: Any custom information you want to store. This will be passed back on all API requests and webhooks.
      - `created_at` integer: Creation date of the image, in seconds since epoch.
      - `errors` object: Any errors associated with this image. Note - This will be an empty object for valid images.
      - `error_code` 'insufficient_credits' | 'invalid_params' | 'general': An identifier describing the type of error, if any.

## Acknowledgement `200`

Indicates the webhook was received and will not be retried.

---

[API](https://skmtc.dev/alttext/apis/alttext-ai-api.md) · [All operations](https://skmtc.dev/alttext/apis/alttext-ai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/alttext/apis/alttext-ai-api/revisions/6eb62e8e450c?raw)
