# FLUX Kontext Pro - Core.Today AI API > State-of-the-art text-based image editing model that transforms images through natural language. Excellent for style transfer, object modification, text replacement, background changes, and character consistency. - **Provider**: Black Forest Labs - **Model ID**: black-forest-labs/flux-kontext-pro - **Category**: Image Generation - **Credits**: 93 per image - **Speed**: Medium - **Quality**: Ultra ## Features - Text-driven image editing with high fidelity - Style transfer and transformation - Object and text replacement - Background editing - Character consistency across edits ## Use Cases - Photo retouching and stylization - Marketing creative variations - Product image background swaps - Character-consistent illustrations ## API Endpoint Base URL: https://api.core.today/v1 Create Prediction: POST /predictions Get Status: GET /predictions/{job_id} ## Authentication Header: X-API-Key: YOUR_API_KEY ## Input Parameters ### Required - **prompt**: string - Editing instruction or generation prompt ### Optional - **input_image**: string - URL of the source image to edit (jpeg, png, gif, or webp) - **aspect_ratio**: string (default: match_input_image) - Output aspect ratio. Use match_input_image to preserve the input ratio Options: match_input_image, 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 4:5, 5:4, 21:9, 9:21, 2:1, 1:2 - **output_format**: string (default: png) - Output image format Options: jpg, png - **safety_tolerance**: integer (default: 2) - Safety tolerance: 0 strictest, 6 most permissive. Max 2 when input_image is provided - **prompt_upsampling**: boolean (default: false) - Auto-improve prompt before generation - **seed**: integer - Random seed for reproducibility ## Examples ### Style Transfer Convert a photo into a 90s cartoon style ```json { "model": "black-forest-labs/flux-kontext-pro", "input": { "prompt": "Make this a 90s cartoon", "input_image": "https://replicate.delivery/pbxt/N55l5TWGh8mSlNzW8usReoaNhGbFwvLeZR3TX1NL4pd2Wtfv/replicate-prediction-f2d25rg6gnrma0cq257vdw2n4c.png", "aspect_ratio": "match_input_image", "output_format": "jpg", "safety_tolerance": 2 } } ``` ## Response Format ```json { "job_id": "abc123", "status": "pending | processing | completed | failed", "result": "URL or data (when completed)" } ``` ## Usage Flow 1. POST /predictions with model and input -> receive job_id 2. GET /predictions/{job_id} -> poll until status is completed or failed 3. Result contains output URL(s) ## Tips - Provide input_image to use editing mode — without one it generates from scratch - Use match_input_image when you want to preserve the original aspect ratio - Lower safety_tolerance values reject more outputs — start at 2 - Use a fixed seed when iterating on a single edit