Infery.ai
← All models

Smart Resize

smart-resize

Image editby smart-resize

Smart image resize to arbitrary dimensions, powered by Nano Banana Pro with vision-LLM-guided prompting for composition-aware recomposition. Crop, cropping, resize ads.

images

Pricing

Price
18.75 cr / image

Prices in credits (1 credit = $0.01).

Data schema

Input

FieldTypeDescription
seedOptional random seed forwarded to the inner nano-banana-pro /edit calls for reproducibility. The same seed is used for every target size when set.
promptstringOptional extra instruction that is forwarded to nano-banana-pro alongside the auto-generated resize prompt. Leave empty to let the model preserve the original image content as closely as possible.
image_urlrequiredstringThe URL of the source image to resize.
sync_modebooleanWhen True, the response contains data URIs in place of CDN URLs so the client can decode the images without an extra HTTP request. Adds latency for large outputs.
resolutionstringenum: 1K, 2K, 4KHint for the minimum resolution tier to use internally. The smart-resize algorithm may pick a higher tier automatically when the requested target size is too large for this tier. This field does not affect the final output dimensions — those come from ``target_sizes``.
target_sizesrequiredarrayThe list of target dimensions to generate, each written as ``<width>x<height>`` (e.g. ``"1920x1080"``). One output image is produced per target size (multiplied by ``num_images_per_size``). The endpoint internally picks the smallest nano-banana-pro preset that fully covers each target so the final i…
output_formatstringenum: jpeg, png, webpThe output image format.
safety_tolerancestringenum: 1, 2, 3, 4, 5, 6The safety tolerance level applied to the inner nano-banana-pro /edit calls. Higher numbers loosen safety filtering.
num_images_per_sizeintegerThe number of nano-banana-pro variants to produce for each target size. The response images list will contain ``len(target_sizes) * num_images_per_size`` images in total.

Output

FieldTypeDescription
imagesarrayAll generated images, flattened across every target size. Order matches the order of ``results`` below: the first ``num_images_per_size`` entries correspond to ``target_sizes[0]`` and so on.
resultsarrayPer-target-size breakdown with the requested width/height and the nano-banana-pro (aspect_ratio, resolution) preset that was used internally.
descriptionstringThe description of the generated images.