Image Editing API

Edit and modify existing images with masks and prompts.

Endpoint

http
POST https://api.tk-novalink.com/v1/images/edits

Parameters

ParameterTypeRequiredDescription
modelstringYesModel name
imagefileYesOriginal image to edit
promptstringYesEditing instruction
maskfileNoMask image

Request Example

bash
curl -X POST "https://api.tk-novalink.com/v1/images/edits" \
  -H "Authorization: Bearer sk-xxxxxxxx" \
  -F model="dall-e-2" \
  -F image="@original.png" \
  -F prompt="Add a sunset background" \
  -F mask="@mask.png"

The image edit endpoint uploads files in multipart/form-data format, not JSON.

Next

Video Generation API

Continue Reading