Page cover

FLUX KONTEXT PRO

Base-Path:

https://api.hyprlab.io/v1

Image Path:

https://api.hyprlab.io/v1/images/generations

Making Request:

curl https://api.hyprlab.io/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $HYPRLAB_API_KEY" \
  -d '{
    "model": "flux-kontext-pro",
    "prompt": "A cute cat",
    "input_image": "https://site.com/path/of/image.png",
    "aspect_ratio": "1:1",
    "response_format": "url",
    "output_format": "png"
  }'
chevron-right📌 Request Body Documentationhashtag

prompt (string, required)

  • Description: The main text prompt that influences the output generation.

  • Validation:

    • Must be a non-empty string.

input_image (string, optional)

  • Description: This is used to guide the generation.

  • Validation:

    • Must be a string (URL, Data URI, or base64 string).

aspect_ratio (string, optional)

  • Description: Defines the aspect ratio of the generated output.

  • Validation:

    • Must be one of the following:

      • 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

response_format (string, optional)

  • Description: The format in which the response will be returned.

  • Validation:

    • Must be either:

      • "url" or

      • "b64_json".

output_format (string, optional)

  • Description: The file format for the output.

  • Validation:

    • Must be one of the following formats:

      • png, jpeg, webp.


Pricing Details

Model Name:
  • flux-kontext-pro

Discount:
  • 30% off

Price:
  • $0.028 / Image

Last updated