GET /v1/image-resizeImage Resize / Resample
Image Utils lf-image-utils
Makes a picture bigger or smaller. Takes an image URL plus optional width, height, fit (cover, contain, or fill), and format (jpeg, png, or webp). Returns width, height, format, and a resize note.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
url | string | Yes | Source image URL |
width | integer | No | Target width |
height | integer | No | Target height |
fit | string | No | cover, contain, or fill |
format | string | No | jpeg, png, or webp |
Response Schema
width (integer): Output width
height (integer): Output height
format (string): Output format
note (string): Resize guidance
cURL Example
curl 'https://lf-image-utils.laminarforge.dev/v1/image-resize?url=<url>' -H 'Authorization: Bearer lf_YourApiKey'
Python Example
import requests
url = 'https://lf-image-utils.laminarforge.dev/v1/image-resize'
headers = {'Authorization': 'Bearer lf_YourApiKey'}
params = {'url': '<url>'}
response = requests.get(url, headers=headers, params=params)
print(response.json())