Assets change image format via url

is there any way to get an image in a specific format on the fly (i.e. like we can do to resize the image via the asset URL using query strings)?

You can use format=WebP or use auto=true to use the best supported format:

Here are a list of all parmeters:

1 Like

Thanks, @Sebastian for the prompt reply. Just did some tests and it’s working. For some reason, if the source asset format is in WEBP, &format=PNG works but not to JPG. Is that by design?

Perhaps because transparency or something like this? Can you give me an example?

there was no transparency…

attached pic

https://i.postimg.cc/FKHX3bGV/Manifold-Gunk-558x460-4.webp

I mean do you have an example URL to your squidex instance where you make the resize.

https://rycocms.azurewebsites.net/api/assets/rycodev/874a04b8-af1c-4fa8-9b97-81c12fd107bb/

Works for me: https://rycocms.azurewebsites.net/api/assets/rycodev/874a04b8-af1c-4fa8-9b97-81c12fd107bb/?format=JPEG

1 Like

oh my mistake i was doing JPG… :roll_eyes:

1 Like