Rescale Image API

Rescale an image to a specific width and height. The image will be resized to fit the specified width and height while maintaining the original aspect ratio unless the crop parameter is set to true. The image will be returned in the same format as the original image.

GET
https://api.apileague.com/rescale-image
Example Request and Response
GET
https://api.apileague.com/{{ examples.getRescaleImage }}

Frequently Asked Questions

Does it support cropping?

Yes, if you set the `crop` parameter to true, the API will crop the image to fit the exact dimensions you specify, rather than just resizing it.

What happens to the aspect ratio?

By default, the API maintains the aspect ratio to prevent distortion. If you enable cropping, the aspect ratio will change to match your specified width and height.

What image formats are supported?

The API supports common web image formats like JPEG, PNG, and GIF.

How is the Rescale Image API different from the Image to Ascii Art API?

The Rescale Image API resizes and crops images while maintaining their visual format, whereas the Image to Ascii Art API converts the image into a text-based representation.

Questions? Need Help? Ask Away