{"info":{"title":"ideogram/character","version":"1.0.0"},"paths":{"/":{"post":{"summary":"Generate","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Output"}}},"description":"Successful Response"}},"operationId":"ideogram_character_generate","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Input"}}},"required":true}}}},"openapi":"3.1.0","components":{"schemas":{"Input":{"type":"object","title":"Input","required":["prompt","reference_image_urls"],"properties":{"seed":{"type":"integer","title":"Seed","x-order":6,"description":"The same seed and the same prompt given to the same version of the model will output the same image every time."},"style":{"allOf":[{"$ref":"#/components/schemas/StyleEnum"}],"title":"Style","default":"AUTO","x-order":3,"description":"The style type to generate with. AUTO lets the model choose, REALISTIC biases toward photographic results, FICTION toward stylized/illustrative results. Cannot be used with style_codes."},"prompt":{"type":"string","title":"Prompt","x-order":0,"description":"The text prompt describing the image to generate. The character's identity comes from the reference image; describe the scene, pose, wardrobe, and style here. Put any words you want rendered inside the image in quotes."},"image_size":{"anyOf":[{"$ref":"#/components/schemas/ImageSize"},{"$ref":"#/components/schemas/ImageSizeEnum"}],"title":"Image Size","default":"square_hd","x-order":5,"description":"The size of the generated image. Use a preset string (e.g. 'landscape_16_9') or a custom {width, height} object."},"image_urls":{"type":"array","items":{"type":"string","format":"uri"},"title":"Style Reference Image URLs","x-order":9,"description":"Optional style reference images (distinct from the character references). Cannot be used together with style_codes."},"style_codes":{"type":"array","items":{"type":"string"},"title":"Style Codes","x-order":10,"description":"Optional 8-character hex style codes. Cannot be used together with style or style reference images."},"expand_prompt":{"type":"boolean","title":"Expand Prompt","default":true,"x-order":4,"description":"If true, automatically enriches the prompt with extra descriptive detail before generation (Magic Prompt). Set false to use your prompt exactly as written."},"negative_prompt":{"type":"string","title":"Negative Prompt","default":"","x-order":7,"description":"A description of what you do NOT want in the generated image."},"rendering_speed":{"allOf":[{"$ref":"#/components/schemas/RenderingSpeedEnum"}],"title":"Rendering Speed","default":"BALANCED","x-order":2,"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."},"reference_mask_urls":{"type":"array","items":{"type":"string","format":"uri"},"title":"Reference Mask URLs","x-order":8,"description":"Optional masks for the character reference images, restricting which regions are used as references."},"reference_image_urls":{"type":"array","items":{"type":"string","format":"uri"},"title":"Reference Image URLs","x-order":1,"description":"A set of images to use as character references. Currently only the first image is used; the rest are ignored (maximum total size 10MB). JPEG, PNG, or WebP."}},"x-fal-order-properties":["prompt","reference_image_urls","rendering_speed","style","expand_prompt","image_size","seed","negative_prompt","reference_mask_urls","image_urls","style_codes"]},"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}}},"StyleEnum":{"enum":["AUTO","REALISTIC","FICTION"],"type":"string","title":"StyleEnum","description":"The style type to generate with."},"ImageSizeEnum":{"enum":["square_hd","square","portrait_4_3","portrait_16_9","landscape_4_3","landscape_16_9"],"type":"string","title":"ImageSizeEnum","description":"Predefined image sizes."},"RenderingSpeedEnum":{"enum":["TURBO","BALANCED","QUALITY"],"type":"string","title":"RenderingSpeedEnum","description":"The rendering speed to use."}}}}