Invalidation API

Create invalidation requests via API
The Invalidation API is a REST API to invalidate images from the CDN and Cloudimage resizing servers.

Step 1. Get your API key

Your API key is available in the Cloudimage admin console, under Invalidation:

Step 2. Call the Invalidation REST API

X-Client-Key: your_API_KEY
Content-Type: application/json
The body of the request must contain the invalidation url in the form /_alias_/path/image1.jpg or /origin_image_url/image2.jpg.
To invalidate all the resizes of this image, use: / or v7/

Invalidate multiple images with all their resizes

"scope": "original",
"urls": ["/",
"/", ...

Invalidate URLs with wildcards

"scope": "original",
"urls": ["/*",
"/*", ...
The example above will invalidate all images (and their resizes) starting with either / or /
Please note that original flushes require the entire log database to be searched and it can take up to 60 seconds.

Invalidate all your images

Please note that this will trigger a re-download of all images from your origin.
"scope": "all"
Flushing all images will result in Cloudimage downloading all your images from your origin image storage again. This will result in slower image loading times for the first times the images are downloaded. Contact us if you have more than 1 TB of monthly CDN traffic or 1 TB of storage.
Try it out with the doc token doc
You can use our sample image showing the time it is resized the first time: