Developers

Crop API

Crop any image to a precise region — remove unwanted edges, focus on a subject, or prepare an exact aspect ratio. Try it without code first on the free crop tool.

POST/v1/images/transform
curl https://api.pixpoo.com/v1/images/transform \
  -H "x-api-key: pxp_xxxxxxxx" \
  -F file=@photo.jpg \
  -F crop=0,0,800,600

Parameters

filefilerequired

The source image (multipart upload). Use "url" instead to fetch from a remote address.

cropstringrequired

"x,y,width,height" in source-image pixel coordinates, e.g. "0,0,800,600".

formatstring

Output format: jpeg, png, webp, avif, gif, or tiff. Omit to keep the source image's own format.

Response

The extracted region as a new image.

Prefer JSON with a base64 payload instead of raw bytes? Use /v1/images/transform/json with the same parameters.

← Back to API documentation