{"info":{"title":"ideogram/v4/image-to-image","version":"1.0.0"},"paths":{"/":{"post":{"summary":"Generate","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Output"}}},"description":"Successful Response"}},"operationId":"ideogram_v4_image_to_image_generate","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Input"}}},"required":true}}}},"openapi":"3.1.0","components":{"schemas":{"Input":{"type":"object","title":"Input","required":["image_url","prompt"],"properties":{"seed":{"type":"integer","title":"Seed","x-order":8,"description":"The same seed and the same prompt given to the same version of the model will output the same image every time."},"prompt":{"type":"string","title":"Prompt","x-order":1,"description":"The text prompt describing how to transform the image. Put any words you want rendered inside the image in quotes."},"strength":{"type":"number","title":"Strength","default":0.8,"maximum":1,"minimum":0,"x-order":3,"description":"How much to transform the input image, from 0 to 1. Higher values follow the prompt more and drift further from the reference; lower values stay closer to the input."},"image_url":{"type":"string","title":"Image URL","format":"uri","x-order":0,"description":"URL of the input image to transform. The output keeps the composition of this image, reinterpreted according to the prompt."},"image_size":{"anyOf":[{"$ref":"#/components/schemas/ImageSize"},{"$ref":"#/components/schemas/ImageSizeEnum"}],"title":"Image Size","default":"auto","x-order":2,"description":"The size of the generated image. Use 'auto' to match the input image, a preset string (e.g. 'landscape_16_9'), or a custom {width, height} object."},"num_images":{"type":"integer","title":"Number of Images","default":1,"maximum":4,"minimum":1,"x-order":7,"description":"The number of images to generate."},"acceleration":{"enum":["none","low","regular","high"],"type":"string","title":"Acceleration","default":"none","x-order":6,"description":"The acceleration level to use."},"output_format":{"enum":["jpeg","png"],"type":"string","title":"Output Format","default":"jpeg","x-order":10,"description":"The format of the generated image."},"expansion_model":{"enum":["None","Medium","Large"],"type":"string","title":"Expansion Model","default":"Medium","x-order":4,"description":"Magic Prompt: automatically enriches the prompt before generation. None uses the prompt as written; Large applies the most enrichment for the highest-quality result."},"rendering_speed":{"enum":["TURBO","BALANCED","QUALITY"],"type":"string","title":"Rendering Speed","default":"BALANCED","x-order":5,"description":"The speed/quality/cost tradeoff. TURBO is fastest and cheapest, BALANCED is the default, QUALITY is best but slowest and most expensive. Affects both speed and cost."},"enable_safety_checker":{"type":"boolean","title":"Enable Safety Checker","default":true,"x-order":9,"description":"If set to true, the safety checker will be enabled."}},"x-fal-order-properties":["image_url","prompt","image_size","strength","expansion_model","rendering_speed","acceleration","num_images","seed","enable_safety_checker","output_format"]},"Output":{"type":"array","items":{"type":"string","format":"uri"},"title":"Output","description":"The generated image files."},"ImageSize":{"type":"object","title":"ImageSize","properties":{"width":{"type":"integer","title":"Width","default":512,"maximum":14142,"description":"The width of the generated image.","exclusiveMinimum":0},"height":{"type":"integer","title":"Height","default":512,"maximum":14142,"description":"The height of the generated image.","exclusiveMinimum":0}}},"ImageSizeEnum":{"enum":["auto","square_hd","square","portrait_4_3","portrait_16_9","landscape_4_3","landscape_16_9"],"type":"string","title":"ImageSizeEnum","description":"Predefined image sizes. 'auto' matches the input image dimensions."}}}}