# FLUX 2 Max > The highest fidelity image model from Black Forest Labs. Best-in-class prompt following and the most consistent editing in the FLUX.2 lineup, with up to 8 reference images. - **Provider**: replicate - **Model ID**: black-forest-labs/flux-2-max - **Category**: image_generation - **Credits**: 160 per request - **Pricing Type**: input_based ## API Endpoint Base URL: https://api.core.today/v1 ### Create Prediction POST /predictions ### Get Status GET /predictions/{job_id} ### Cancel DELETE /predictions/{job_id} ## Authentication Header: `X-API-Key: YOUR_API_KEY` ## Input Parameters - `width` (integer, optional): Width of the generated image. Only used when aspect_ratio=custom. Must be a multiple of 16 (if it's not, it will be rounded to nearest multiple of 16). (Range: min: 256, max: 2048) - `prompt` (string, **required**): Text prompt for image generation - `seed` (integer, optional): Random seed. Set for reproducible generation - `resolution` (string, optional): Resolution in megapixels. Up to 4 MP is possible, but 2 MP or below is recommended. The maximum image size is 2048x2048, which means that high-resolution images may not respect the resolution if aspect ratio is not 1:1. Resolution is not used when aspect_ratio is 'custom'. When aspect_ratio is 'match_input_image', use 'match_input_image' to match the input image's resolution (clamped to 0.5-4 MP). (Default: `1 MP`; Options: `match_input_image`, `0.5 MP`, `1 MP`, `2 MP`, `4 MP`) - `height` (integer, optional): Height of the generated image. Only used when aspect_ratio=custom. Must be a multiple of 16 (if it's not, it will be rounded to nearest multiple of 16). (Range: min: 256, max: 2048) - `aspect_ratio` (string, optional): Aspect ratio for the generated image. Use 'match_input_image' to match the first input image's aspect ratio. (Default: `1:1`; Options: `match_input_image`, `custom`, `1:1`, `16:9`, `3:2`, `2:3`, `4:5`, `5:4`, `9:16`, `3:4`, `4:3`) - `safety_tolerance` (integer, optional): Safety tolerance, 1 is most strict and 5 is most permissive (Default: `2`; Range: min: 1, max: 5) - `output_format` (string, optional): Format of the output images. (Default: `webp`; Options: `webp`, `jpg`, `png`) - `output_quality` (integer, optional): Quality when saving the output images, from 0 to 100. 100 is best quality, 0 is lowest quality. Not relevant for .png outputs (Default: `80`; Range: min: 0, max: 100) - `input_images` (array, optional): List of input images for image-to-image generation. Maximum 8 images. Must be jpeg, png, gif, or webp. (Default: `[]`) ## Example Request ```json { "model": "black-forest-labs/flux-2-max", "input": { "aspect_ratio": "1:1", "output_format": "webp", "prompt": "A photorealistic wide shot of a large minimalist digital billboard standing in the middle of a forest filled with purple and lavender-hued trees. The billboard has a sleek metal frame with subtle overhead lights. Centered text reads \"FLUX.2 [max]\" in a modern sans-serif font. Soft daylight with a purple color cast, cinematic composition, ultra-high resolution.", "resolution": "1 MP", "output_quality": 80, "safety_tolerance": 2 } } ``` ## Response Format ```json { "job_id": "abc123", "status": "pending", "provider": "replicate", "model": "black-forest-labs/flux-schnell", "created_at": "2026-01-01T00:00:00Z", "result": null, "error": null } ``` Status values: `pending`, `processing`, `completed`, `failed`, `cancelled` ## Usage Flow 1. POST /predictions with model and input → receive job_id 2. Poll GET /predictions/{job_id} until status is `completed` or `failed` 3. Result contains output URL(s) or data ## Output Type url ## Tags flux, black-forest-labs, image-generation, text-to-image, image-editing, multi-reference, character-consistency, photorealistic, frontier ## Documentation https://replicate.com/black-forest-labs/flux-2-max