RunpodR
Runpod10mo ago
70 replies
Jacob

Bad requests

I have just the normal 3.6.0 sdxl docker running on my serverless but i just cannot get it to request correctly with a workflow. According to github which is literally the only place with any documentation it says a workflow can be passed but nothing I've tried works its just endless 400 bad request...
 {
        "input": {
            "prompt": prompt,
            "num_inference_steps": 50,
            "width": 1024,
            "height": 1024,
            "guidance_scale": 15,
            "high_noise_frac": 1.2
        }
    }

for some reason it will accept this but when I pass a workflow like this it just errors from the request.

{
  "input": {
    "workflow": {
      "1": {
        "inputs": {
          "ckpt_name": "sd_xl_base_1.0.safetensors"
        },
        "class_type": "CheckpointLoaderSimple",
        "_meta": {
          "title": "Load Checkpoint"
        }
      },
      "2": {
        "inputs": {
          "seed": 0,
          "steps": 20,
          "cfg": 8,
          "sampler_name": "euler",
          "scheduler": "normal",
          "denoise": 1,
          "model": [
            "1",
            0
          ],
          "positive": [
            "3",
            0
          ],
          "negative": [
            "4",
            0
          ],
          "latent_image": [
            "5",
            0
          ]
        },
        "class_type": "KSampler",
        "_meta": {
          "title": "KSampler"
        }
      },
      "3": {
        "inputs": {
          "text": "positive prompt here",
          "clip": [
            "1",
            1
          ]
        },
        "class_type": "CLIPTextEncode",
        "_meta": {
          "title": "CLIP Text Encode (Prompt)"
        }
      },
      "4": {
        "inputs": {
          "text": "negative prompt here",
          "clip": [
            "1",
            1
          ]
        },
        "class_type": "CLIPTextEncode",
        "_meta": {
          "title": "CLIP Text Encode (Prompt)"
        }
      },
      "5": {
        "inputs": {
          "width": 1024,
          "height": 1024,
          "batch_size": 1
        },
        "class_type": "EmptyLatentImage",
        "_meta": {
          "title": "Empty Latent Image"
        }
      },
      "6": {
        "inputs": {
          "samples": [
            "2",
            0
          ],
          "vae": [
            "1",
            2
          ]
        },
        "class_type": "VAEDecode",
        "_meta": {
          "title": "VAE Decode"
        }
      },
      "7": {
        "inputs": {
          "filename_prefix": "ComfyUI",
          "images": [
            "6",
            0
          ]
        },
        "class_type": "SaveImage",
        "_meta": {
          "title": "Save Image"
        }
      }
    }
  }
}
Was this page helpful?