Multi Image Kontext Max

FLUX.1 Kontext [max] creates stunning, photorealistic images from text prompts and input images seamlessly.


API

If you're looking for an API, you can choose from your desired programming language.

POST
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 import requests api_key = "YOUR_API_KEY" url = "https://api.segmind.com/v1/multi-image-kontext-max" # Prepare data and files data = {} files = {} data['seed'] = 42 data['prompt'] = "put the green dress on the woman while maintaining the pose of the woman as it is" data['aspect_ratio'] = "1:1" # For parameter "input_image_1", you can send a raw file or a URI: # files['input_image_1'] = open('IMAGE_PATH', 'rb') # To send a file data['input_image_1'] = 'https://segmind-resources.s3.amazonaws.com/output/9cb479d3-5c5f-4d5d-a782-972acbc42598-c1.jpg' # To send a URI # For parameter "input_image_2", you can send a raw file or a URI: # files['input_image_2'] = open('IMAGE_PATH', 'rb') # To send a file data['input_image_2'] = 'https://segmind-resources.s3.amazonaws.com/output/79feee7b-d09f-4bde-bec3-c8e8a8703f04-d2.png' # To send a URI data['output_format'] = "jpg" data['safety_tolerance'] = 1 headers = {'x-api-key': api_key} # If no files, send as JSON if files: response = requests.post(url, data=data, files=files, headers=headers) else: response = requests.post(url, json=data, headers=headers) print(response.content) # The response is the generated image
RESPONSE
image/jpeg
HTTP Response Codes
200 - OKImage Generated
401 - UnauthorizedUser authentication failed
404 - Not FoundThe requested URL does not exist
405 - Method Not AllowedThe requested HTTP method is not allowed
406 - Not AcceptableNot enough credits
500 - Server ErrorServer had some issue with processing

Attributes


seedint ( default: 42 )

Sets seed for reproducibility.


promptstr *

Describes the prompt for image transformation.


aspect_ratioenum:str ( default: 16:9 )

Sets output aspect ratio. Use '16:9' for wide images.

Allowed values:


input_image_1str *

First image for transformation


input_image_2str *

Second image for transformation.


output_formatenum:str ( default: jpg )

Sets output forma.

Allowed values:


safety_toleranceint ( default: 1 )

Controls content safety level. Use 1 for moderate strictness.

min : 0,

max : 2

To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.

Resources to get you started

Everything you need to know to get the most out of Multi Image Kontext Max

# Guide to Using FLUX.1 Kontext [max] Effectively

FLUX.1 Kontext [max] combines a multimodal transformer and diffusion engine to turn text prompts and input images into photorealistic, typography-integrated visuals. Follow this guide to optimize your results and choose the right parameters for any project.

---

## 1. Core Prompting Tips
- **Be Descriptive**  
  Insert setting, materials, lighting, camera angle.  
  _Example:_ “A golden hour mountain panorama with soft mist, DSLR perspective.”
- **Specify Typography**  
  Mention font style, weight and color for integrated text.  
  _Example:_ “Overlay ‘Autumn Sale’ in bold serif, warm orange glow.”
- **Use Style Tags**  
  Add hashtags like `#retro`, `#cyberpunk` to hint at mood and color palette.
- **Early Aspect Ratio Selection**  
  Lock `aspect_ratio` before generation to match final medium (print, mobile, film).
- **Reproducibility**  
  Fix `seed` (default 42) to regenerate identical outputs on reruns.
- **Safety Compliance**  
  Adjust `safety_tolerance` (0 = lenient, 2 = strict) when working with public-facing content.

---

## 2. Parameter Recommendations by Use Case

1. **Branding & Logo Creation**  
   - aspect_ratio: `1:1`  
   - output_format: `png` (transparency ready)  
   - seed: 100  
   - safety_tolerance: 1  
   ```json
   {
     "prompt": "Minimalist tech startup logo with neon blue gradient",
     "input_image_1": "https://example.com/sketch.png",
     "input_image_2": "https://example.com/texture.jpg",
     "aspect_ratio": "1:1",
     "output_format": "png",
     "seed": 100,
     "safety_tolerance": 1
   }
  1. •

    Editorial & Magazine Layouts

    • •aspect_ratio: 4:3 or 3:2
    • •output_format: jpg
    • •seed: 42
    • •safety_tolerance: 1
  2. •

    Social Media Campaigns

    • •Feeds (square): 1:1
    • •Stories/Reels (vertical): 9:16
    • •output_format: jpg (smaller file)
    • •seed: random or fixed per campaign
  3. •

    Creative Prototyping

    • •aspect_ratio: 16:9 or 21:9 for widescreen
    • •output_format: png
    • •seed: any integer for variation
  4. •

    Commercial Storytelling

    • •aspect_ratio: match target ad space
    • •safety_tolerance: 2 (highest moderation)

3. Advanced Settings

  • •input_image_1 / input_image_2: Use high-resolution sources to preserve detail.
  • •safety_tolerance:
    0 – Flexible (artistic freedom)
    1 – Balanced
    2 – Strict (compliance mode)

4. Example Request

{
  "prompt": "A futuristic cityscape at dusk with neon cursive headlines",
  "input_image_1": "https://example.com/city_sketch.png",
  "input_image_2": "https://example.com/sky_texture.jpg",
  "aspect_ratio": "16:9",
  "output_format": "jpg",
  "seed": 2024,
  "safety_tolerance": 1
}

Final Thoughts

By combining detailed prompts, the right aspect ratios, and controlled randomness, FLUX.1 Kontext [max] can deliver consistent, high-quality visuals across a variety of professional workflows. Experiment with seeds and style tags to discover your signature aesthetic!

Other Popular Models

Discover other models you might be interested in.

Cookie settings

We use cookies to enhance your browsing experience, analyze site traffic, and personalize content. By clicking "Accept all", you consent to our use of cookies.