Page cover

FLUX-2 DEV

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-2-dev",
    "prompt": "A cute cat",
    "input_images": [
      "https://example.com/image1.png",
      "https://example.com/image2.png",
      "https://example.com/image3.png",
      "https://example.com/image4.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_images (string or object, optional)

  • Description: This is used to guide the generation.

  • Validation:

    • Must be a string or object (URL, Data URI, or base64 string) up-to 5 images.

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

      • 3:2

      • 2:3

      • 4:5

      • 5:4

      • 9:16

      • 3:4

      • 4:3

seed (integer, optional)

  • Description: A seed for deterministic generation during processing.

  • Validation:

    • Must be an integer between 0 and 4,294,967,295.

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-2-dev

Discount:
  • 30% off

Price:
  • Input Image: $0.0098 / Megapixel

  • Output Image: $0.0098 / Megapixel

Last updated