v6
OpenAPI 3.0.22026-08-07110243421.2 KBgenerate
Reframe a source image to a target size, by asset id or by uploaded bytes
Reframe a source image to a target size.
Supply the source image as either an AssetIdentifier reference (image_asset_identifier) or the raw image bytes directly (image, multipart requests only) -- callers are never required to call POST /v2/assets first. Provide exactly one of the two; supplying both, or neither, is rejected with a 400.
The target resolution (WIDTHxHEIGHT) sets the target aspect ratio and selects the reframing layout, so it is required.
The model is fixed by the route, so no model field is accepted.
The request blocks until the reframed image(s) are ready and returns them directly in the response.
post/v1/resizer
Request body
Example request
{
"image_asset_identifier": {
"asset_type": "RESPONSE",
"asset_id": "7uS_VESkRI6O3-sVgHQp_A"
}
}Response
The reframed image(s).
Example response
{
"data": [
{
"url": "https://openapi-generator.tech",
"is_image_safe": true
},
{
"url": "https://openapi-generator.tech",
"is_image_safe": true
}
],
"created": "2000-01-23T04:56:07+00:00"
}