Skip to main content

Hi-res Fix

You can use our in-house enhancement workflow to make the image better and scale by 2x.

All you need to do is add "hires": true to your params.

Tip
  • Supports only 1 image generation per API call; Keep samples as 1
  • Supports only sd 1.5 endpoints text2image, image2image, controlnet and inpainting
ImagePipeline-Post
https://api.imagepipeline.io/sd/text2image/v1
ImagePipeline-Auth
API-Key


{
"seed": 568878,
"width": 512,
"height": 512,
"prompt": "a blonde woman wearing a swimsuit on the beach, ultrarealistic, highly detailed, 8k",
"samples": 1,
"model_id": "0b397287-3449-4801-9a86-536465f6189f",
"scheduler": "EulerDiscreteScheduler",
"guidance_scale": 7,
"negative_prompt": "deformed anatomy",
"num_inference_steps": 20,
"hires": true
}
Lightning sdxl model image pipeline

JSON Parameters

ParameterPermissible valuesNotes
model_idstrmodel_id can be found in models page. Filter by SD-1.5 models
promptstr, 75 tokensCheck our Prompt Guide for tips
negative_promptstr, 75 tokensCheck our Prompt Guide for tips
num_inference_stepsint, [1-100]Noise is removed with each step, resulting in a higher-quality image over time. Ideal value 20-30
samplesint, [1-4]Generates a maximum of 4 samples per API call
guidance_scalefloat, [1-20]Higher guidance scale prioritizes text prompt relevance but sacrifices image quality. Ideal value 7.5-12.5
widthintWidth in pixels. Lower than or equal to 512 for best results
heightintHeight in pixels. Lower than or equal to 512 for best results
hiresboolSet to true for better image quality and 2x upscaling, but samples generated will be 1

Status

Your response will include a status.

  • If the status = SUCCESS, you will also have download_urls that will have the links to your generated image based on the number of samples you have entered. The maximum number of samples that can be generated is 4.
  • If the status = PENDING, you will receive a id. You can use the status endpoint to fetch your image using the id.
  • If the status = FAILURE, you will receive only an error message.

Endpoint: [GET]

  • https://api.imagepipeline.io/sd/text2image/v1/status/{{id}}

Pass the API-Key as the authorization in the header.