POST
/
api
/
ai
/
images
/
modify
/
v3
/
extend-image
curl --request POST \
  --url https://api.worqhat.com/api/ai/images/modify/v3/extend-image \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form 'existing_image=(binary file)' \
  --form output_type=url \
  --form leftExtend=0 \
  --form rightExtend=0 \
  --form topExtend=0 \
  --form bottomExtend=100 \
  --form 'description=Show a white field'
{
  "image": "https://example.com/processed-image.png",
  "processing_time": 15938.768708,
  "processing_id": "1e01b632-2d8f-4f71-8a27-36e219d67be5"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

multipart/form-data
existing_image
file
required

The image file to be extended.

output_type
string
required

Specifies the output format of the processed image (e.g., URL or base64 encoded image).

leftExtend
integer
required

Percentage of the original image width to extend on the left side.

rightExtend
integer
required

Percentage of the original image width to extend on the right side.

topExtend
integer
required

Percentage of the original image height to extend on the top side.

bottomExtend
integer
required

Percentage of the original image height to extend on the bottom side.

description
string
required

A description of the background and desired content for the extended image.

Response

200
application/json
Image processed successfully
image
string
required

URL of the processed image.

processing_time
number
required

Time taken to process the request in milliseconds.

processing_id
string
required

A universally unique identifier for the request.