Skip to main content
Method: POST
Endpoint: https://api.sciforium.com/v1/images/edits
Content-Type: multipart/form-data

Overview

/v1/images/edits edits one or more input images using a text prompt.

Request Body Parameters

ParameterTypeRequiredDescription
imagefile or file[]YesSource image(s). PNG/JPEG/WebP. Max file size: 50 MB each.
promptstringYesDescription of the final desired image (1 to 32,000 chars).
modelstringYesImage model ID.
maskfileNoOptional mask file for targeted edits.
input_fidelitystringNolow or high. Default: low.
nintegerNoNumber of outputs, 1 to 10. Default: 1.
sizestringNo1024x1024, 1536x1024, 1024x1536, or auto. Default: auto.
qualitystringNolow, medium, high, or auto. Default: auto.
backgroundstringNotransparent, opaque, or auto. Default: auto.
output_formatstringNopng, jpeg, or webp. Default: png.
output_compressionintegerNo0 to 100. Default: 100.
moderationstringNoauto or low. Default: auto.
num_inference_stepsintegerNoOptional step count (1 to 50).
partial_imagesintegerNoStreaming partials (0 to 3). Default: 0.
response_formatstringNob64_json or url.
userstringNoOptional user identifier.
streambooleanNoStream events when enabled.
Pro tip: describe the full final scene, not only the delta.

Example Response

{
  "created": 1775615000,
  "data": [
    {
      "b64_json": "iVBORw0KGgoAAAANSUhEUgAA...",
      "revised_prompt": "The original photograph of a living room is modified to include a modern black leather sofa where the wooden chair was, while maintaining the identical lighting and wall color."
    }
  ],
  "usage": {
    "input_tokens": 1200,
    "output_tokens": 0,
    "total_tokens": 1200
  },
  "filtered_count": 0
}