In order to deliver and transform existing web images via Cloudinary, you can specify a remote HTTP URL as the 'file' parameter of our upload API. Cloudinary will automatically download the image from this remote URL and you will be able to transform it as you wish.
In addition, we support adding Cloudinary's fetch URL as a prefix to any URL for dynamically transforming remote images and delivering through a CDN, see our blog post for more details: http://cloudinary.com/blog/delivering_all_your_websites_images_through_a_cdn
Here's a sample fetch URL that creates a 150x150 crop focused on Benedict’s face ('g_face') and with rounded corners of 20 pixels ('r_20') and generates the following image:
https://res.cloudinary.com/demo/image/fetch/w_150,h_150,r_20,c_thumb,g_face/https://upload.wikimedia.org/wikipedia/commons/1/13/Benedict_Cumberbatch_2011.png
Comments
7 comments
Hi Cloudinary,
I'm mainly interested in your service for its on-the-fly resizing through the fetch method, but due to the nature of the app I'm creating, for security reasons, I'd be passing many temporary URLs through Cloudinary. I noticed that for each fetch -- even a fetch with the same image but a different query string -- a new image is stored in my Media Library and counted against my total storage count. I want images added to my library through fetch to expire after a certain period of time. Is this possible?
Thanks!
Tim
Hi Tim,
Cloudinary currently doesn't support automatic timely purging of fetched resources.
Until this feature is made available, you can implement timely deletions yourself using Cloudinary's Admin APIs.
Itay
5 years on, can someone confirm if this is now possible?
Jesse.
Hi Jesse,
For fetched images, we have this TTL options:
The fetch TTL can be changed and is currently at 7 days by default.
Please let me know if this is something that could be helpful for you?
Cheers,
Yakir
Very helpful - thank you :)
How do I include the TLL in an URL like this?
https://res.cloudinary.com/demo/image/fetch/w_150,h_150,r_20,c_thumb,g_face/https://upload.wikimedia.org/wikipedia/commons/1/13/Benedict_Cumberbatch_2011.png
As an example, I want to set TTL=Once
Thank you
Hi Morten,
The TTL is an option that can be set in your account in the backend, by default it is set to Once.
You can create a support ticket so we can check your account.
Regards,
Francis
Please sign in to leave a comment.