FLUX.2 is live! High-fidelity image generation made simple.

You can browse available text-to-image models on the models page.
For example, we'll use runwayml/stable-diffusion-v1-5.
curl -X POST \
-d '{"prompt": "A photo of a cube floating in space"}' \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer YOUR_API_KEY" \
-o cube.jpg \
'https://api.deepinfra.com/v1/inference/runwayml/stable-diffusion-v1-5'
And check out the output in cube.jpg.
You can check all the available settings on the model page or via the API documentation tab.
Use OpenAI API clients with LLaMasGetting started
# create a virtual environment
python3 -m venv .venv
# activate environment in current shell
. .venv/bin/activate
# install openai python client
pip install openai
Choose a model
meta-llama/Llama-2-70b-chat-hf
[meta-llama/L...
Art That Talks Back: A Hands-On Tutorial on Talking ImagesTurn any image into a talking masterpiece with this step-by-step guide using DeepInfra’s GenAI models.
Fork of Text Generation Inference.The text generation inference open source project by huggingface looked like a promising
framework for serving large language models (LLM). However, huggingface announced that they
will change the license of code with version v1.0.0. While the previous license Apache 2.0
was permissive, the new on...© 2025 Deep Infra. All rights reserved.