You can send a Webhook notification when media is changed (created/updated/deleted).
This can be configured from "Media Management" → "Media Settings".

You can set the timing for issuing Webhooks when configuring each Webhook.

Notifications will be sent when new media is created (uploaded) in the management screen.
Webhook notifications will not be sent in the following cases. Please note.
Notifications will be sent when media is re-uploaded in the management screen or when the file name is changed.
Webhook notifications will not be sent in the following cases. Please note.
Notifications will be sent when media is deleted from the management screen.
Webhook notifications will not be sent in the following cases. Please note.
The media webhook notifications send POST requests to a specified URL. The receiving end can perform custom processing upon receiving the request.
The request header includes Content-Type: application/json.
The request body contains information about the affected content and API.
{
"service": "someId",
"type": "edit",
"old": {
"url": "https://images.microcms-assets.io/assets/xxxx/yyyy/zzzz.jpg",
"width": 100,
"height": 100,
"alt": "Some sample alt text."
},
"new": {
"url": "https://images.microcms-assets.io/assets/xxxx/yyyy/zzzz.jpg",
"width": 100,
"height": 100,
"alt": "Some sample alt text."
},
}This contains the subdomain of the service to which the modified media belongs.
This indicates the type of change. For new additions, it will be new; for edits, edit; and for deletions, delete.
This contains the content before the media was edited or deleted. It will be null when a new media is created.
This contains the content after the media has been created or edited. It will be null when the media is deleted.
This contains the URL of the media.
This contains the width of the media. It will be null for non-image files.
This contains the height of the media. It will be null for non-image files.
This contains the alternative text set from the media management screen. If there is no setting or for non-image files, the key itself will not be included.
The server receiving notifications from microCMS must be publicly accessible.
Therefore, depending on the processing, it is necessary to consider measures that account for the possibility of receiving POST requests from third parties.
Specifically, when setting the URL, you can configure a value known only to microCMS and the receiving server, such as ?auth=XXX, and verify whether this value is correct on the receiving server (i.e., whether the request is from microCMS).
Similar to the content's Webhook, we are considering the implementation of adding a signature value (Signature) to the headers of the Webhook request.
Retry processing will not be performed even if the webhook notification fails due to network errors or 4xx, 5xx errors.
Webhook notifications will be sentonly once for each configured timing.
In principle, webhook notifications are sent in the order of operations executed.
However, since strict control is not implemented, the order is not guaranteed.
The source IP address of the webhook is a dynamic IP address.
Additionally, the range of IP addresses is not publicly disclosed.