← Help Center

Generate Your First Image in 3 Steps

Create AI-generated images with Arli AI via the API or playground

Step 1: Write Your Prompt

Describe the image you want to create. Be specific about style, lighting, composition, and subject.

Good vs Bad Prompts

Good"a photorealistic golden retriever playing in autumn leaves, warm sunlight, bokeh background, 4K, detailed fur"
Bad"dog"
Good"cyberpunk city at night, neon signs, rain reflections on wet streets, cinematic lighting, ultra detailed"
Bad"city"

Tip: Include style keywords (photorealistic, anime, oil painting), lighting (golden hour, dramatic), and quality tags (4K, detailed, high quality).

Step 2: Send Your Request

Use the API or the web playground to generate your image.

Option A: API (cURL)

curl -X POST https://api.arliai.com/v1/txt2img \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "prompt": "a photorealistic golden retriever playing in autumn leaves, warm sunlight, bokeh background",
    "negative_prompt": "blurry, low quality, distorted",
    "steps": 25,
    "sampler_name": "Euler a",
    "width": 1024,
    "height": 768,
    "cfg_scale": 7
  }' | python3 -c "
import sys, json, base64
data = json.load(sys.stdin)
img = base64.b64decode(data['images'][0])
with open('output.png', 'wb') as f:
    f.write(img)
print('Saved output.png')
"

Option B: API Gateway (No Auth)

curl -X POST https://api.kim8.s4s.host/api/v1/images/generations \
  -H "Content-Type: application/json" \
  -d '{
    "model": "stable-diffusion-xl-base-1.0",
    "prompt": "a photorealistic golden retriever playing in autumn leaves",
    "n": 1,
    "size": "1024x1024"
  }'

Option C: Web Playground

Visit generate.kim8.s4s.host, select a model, type your prompt, and click Generate.

Step 3: View Your Image

The API returns base64-encoded image data:

{
  "images": ["iVBORw0KGgoAAAANSUhEUgAA... (base64 PNG)"],
  "info": {
    "prompt": "a photorealistic golden retriever...",
    "seed": 1234567890,
    "steps": 25,
    "width": 1024,
    "height": 768
  }
}

Decode the base64 to save as a file. The playground displays images directly in your browser.

You're done!

You've generated your first AI image. Now try img2img, upscaling, or experiment with different models.

Next Steps

Image to Image Transform existing images with a text prompt Playground Guide
Upscale Increase image resolution by 2x-4x Upscale Guide
Model Guide Find the best model for your use case Model Guide
Full API Reference All endpoints, parameters, and examples API Reference

Quick Tips