Skip to content
Yohan Totting edited this page Jun 19, 2017 · 2 revisions

Image Request With Different Size

The image can be requested in different size based on app needs. Below are the sample request for image

  • Orginal image by default return image with width 1440 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg
  • Return image with width 80 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg&width=80
  • Return image with width 140 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg&width=140
  • Return image with width 480 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg&width=480
  • Return image with width 640 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg&width=640
  • Return image with width 1024 pixels https://api.shuvayatra.org/v1/uploads/posts/board-pourakhi.jpg&width=1024

The image request handle by NGINX with Image filter module. It cached the requested image in 24 hours to speed up performance on same image request.

Clone this wiki locally