Commands

The full list of available image operations are included below. For each operation listed, there will be an IMAGEURL variable. Note that this is the path to the image which is to be manipulated. It should be something such as example.com/myimage.jpg If there are any commands not listed here which you feel would be useful, please send your requests.


Resize

Resize an image.

Format

http://urlimg.com/resize/WIDTHxHEIGHT/IMAGEURL

Arguments

  • WIDTHxHEIGHTThe width and height of the desired image. Expressed as a width and height specification of the form WIDTHxHEIGHT where WIDTH and HEIGHT are both positive numbers.

Scale

Scale an image proportionally by a given percentage

Format

http://urlimg.com/scale/PERCENT/IMAGEURL

Arguments

  • PERCENTA value between 0 and 1000 by which to scale the image. If greater than 100, the image will be increased in size by that percentage amount.

Width

Scale an image proportionaly to the given width

Format

http://urlimg.com/width/SIZE/IMAGEURL

Arguments

  • SIZEA positive number specifying the target width of the image.

Height

Scale an image proportionaly to the given height

Format

http://urlimg.com/height/SIZE/IMAGEURL

Arguments

  • SIZEA positive number specifying the target height of the image.

Fit

Fit an image proportionally to be within a given size

Format

http://urlimg.com/fit/WIDTHxHEIGHT/IMAGEURL

Arguments

  • WIDTHxHEIGHTThe box that the image must be resized to fit into. Expressed as a width and height specification of the form WIDTHxHEIGHT where WIDTH and HEIGHT are both positive numbers.

Thumbnail

Create a thumbnail of an image

Format

http://urlimg.com/thumbnail/SIZE/IMAGEURL or a shorter version: http://urlimg.com/thumb/SIZE/IMAGEURL

Arguments

  • SIZEA number of pixels or a value of either "small" (64 pixels), "medium" (96 pixels) or "large" (128).

Square

Create a squared version of an image. This will resize and crop an image to create a squared version with the height and width given.

Format

http://urlimg.com/square/SIZE/IMAGEURL

Arguments

  • SIZEThe height and width of the desired square

Rotate

Rotate an image

Format

http://urlimg.com/rotate/DEGREES/IMAGEURL

Arguments

  • DEGREESA value specifying the number of degrees that the image is to be rotated in a clockwise direction. A negative number will rotate the image in a counter-clockwise direction.

Crop

Select a rectangular region of an image and remove everything outside of that region.

Format

http://urlimg.com/crop/CORNER-X,CORNER-Y,WIDTHxHEIGHT/IMAGEURL

Arguments

  • CORNER-XThe x coordinate of the top left corner of the rectangle to be cropped. Assumes that the top left corner is (0, 0).
  • CORNER-YThe y coordinate of the top left corner of the rectangle to be cropped.
  • WIDTHThe width of the rectangle to be cropped.
  • HEIGHTThe height of the rectangle to be cropped.

Watermark

Overlay some text on the image

Format

http://urlimg.com/wm/TEXT/IMAGEURL or http://urlimg.com/watermark/TEXT/IMAGEURL

Arguments

  • TEXTThe text of the watermark.

Note:

It is recommended that after generating the watermarked image, you remove the original image. Otherwise it will continue to be publicly available.

Black & White

Convert the image to black and white

Format

http://urlimg.com/bw/IMAGEURL or http://urlimg.com/blackwhite/IMAGEURL

Invert

Invert the color profile of the image

Format

http://urlimg.com/invert/IMAGEURL

Blur

Apply a blurring filter to the image

Format

http://urlimg.com/blur/IMAGEURL

Sharpen

Apply a sharpening filter to the image

Format

http://urlimg.com/sharpen/IMAGEURL

Convert

Convert the image to a different format

Format

http://urlimg.com/convert/FORMAT/IMAGEURL

Arguments

  • FORMATThe desired image format of the created image. Allowable values are: bmp, gif, im, jpeg/jpg, msp, pcx, pdf, png, ppm, tiff, xbm

Combining Commands

Commands can also be combined together. For example, you could rotate an image 90 degrees, resize it and then crop it. A command to do this would look like: http://urlimg.com/rotate/90/scale/50/crop/25,25,75x75/example.com/myimage.jpg There are no limits to how many commands you can combine, besides the limit of a web browsers address length. The commands will be performed in order of left to right.