Amux

MiniMax Image 01

MiniMax Image 01 family — text-to-image and image-to-image (character consistency reference), called via the OpenAI-compatible image endpoints

MiniMax Image 01 is the MiniMax image generation family, supporting text-to-image (T2I) and image-to-image (I2I — character-consistency reference). amux-api exposes it through OpenAI-compatible image endpoints; the gateway internally converts requests into MiniMax's native /v1/image_generation protocol upstream and converts the response back to the OpenAI shape.

Model Variants

Model IDPositioningStatus
MiniMax-Image-01General (T2I / I2I)✅ Available
MiniMax-Image-01-liveStylized (manga / energetic / medieval / watercolor)⚠️ Not yet supported

MiniMax-Image-01-live is not yet enabled on the amux platform. Use MiniMax-Image-01 instead. Once Live becomes available, this doc and the pricing table will be updated accordingly.

See https://api.amux.ai/pricing for current pricing.

Endpoints

amux-api exposes two OpenAI-compatible paths, both mapped to MiniMax's native POST /v1/image_generation:

EndpointFormatUse
POST /v1/images/generationsapplication/jsonT2I and I2I (reference image via JSON field)
POST /v1/images/editsmultipart/form-dataI2I (reference image as multipart file — amux auto-base64s it into subject_reference)
FieldValue
AuthAuthorization: Bearer <AMUX_API_KEY>
Response formatapplication/json

Request Body Fields

Common Fields (T2I / I2I)

Prop

Type

subject_reference[] (Image-to-Image — Character Reference)

MiniMax's I2I is not generic image editing — it's character-consistency reference: given the prompt and a reference image, the model preserves the subject's identity (face, hairstyle, etc.) while rendering the new scene.

Prop

Type

Three ways to submit the reference image (pick one):

  1. JSON top-level: POST /v1/images/generations with subject_reference: [{ type, image_file }] at the body root
  2. JSON extra_body (OpenAI SDK style): extra_body: { subject_reference: [...] }
  3. Multipart file: POST /v1/images/edits with the reference image as the image form field — amux reads the file → Base64 data URL → fills subject_reference[0] (type fixed to character)

Compatibility: image_file also accepts the array form (["data:..."]); amux auto-flattens by taking the first non-empty element.

style (Stylized output)

Only effective for image-01-live (image-01 ignores style upstream). Live is not yet enabled on amux today, so passing style has no real effect — included here for contract completeness.

Prop

Type

Two equivalent forms (amux normalizes both):

  • Nested object: style: { style_type: "...", style_weight: 0.8 }
  • Flat: write style_type / style_weight directly at the top level (or in extra_body)

size to aspect_ratio mapping

When you set size without aspect_ratio, amux maps the OpenAI size to MiniMax's aspect_ratio per this table:

sizeaspect_ratio
1024x10241:1
1792x102416:9
1024x17929:16
1536x1024 / 1248x8323:2
1024x1536 / 832x12482:3
1152x8644:3
864x11523:4
1344x57621:9

For other WxH sizes, amux reduces to the lowest terms; if the reduced ratio matches one of the enum values, it's forwarded; otherwise no aspect_ratio is sent and MiniMax falls back to 1:1.

Response Fields

amux converts the MiniMax response into the OpenAI image response shape:

Prop

Type

ImageData shape:

Prop

Type

Examples

Text-to-Image — Basic

curl https://api.amux.ai/v1/images/generations \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "MiniMax-Image-01",
    "prompt": "A cute baby sea otter wearing a beret, rolling in a spring courtyard with falling cherry blossoms",
    "n": 1,
    "size": "1024x1024"
  }'
import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.amux.ai/v1",
    api_key=os.environ["AMUX_API_KEY"],
)

response = client.images.generate(
    model="MiniMax-Image-01",
    prompt="A cute baby sea otter wearing a beret, rolling in a spring courtyard with falling cherry blossoms",
    n=1,
    size="1024x1024",
)
print(response.data[0].url)
import OpenAI from 'openai';

const client = new OpenAI({
  baseURL: 'https://api.amux.ai/v1',
  apiKey: process.env.AMUX_API_KEY,
});

const response = await client.images.generate({
  model: 'MiniMax-Image-01',
  prompt:
    'A cute baby sea otter wearing a beret, rolling in a spring courtyard with falling cherry blossoms',
  n: 1,
  size: '1024x1024',
});
console.log(response.data[0].url);

Text-to-Image — Custom Aspect Ratio + Multiple Outputs + seed

curl https://api.amux.ai/v1/images/generations \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "MiniMax-Image-01",
    "prompt": "Cinematic harbor at dusk, seagulls passing through, film-grain texture",
    "aspect_ratio": "21:9",
    "n": 4,
    "seed": 20260430,
    "response_format": "url",
    "prompt_optimizer": true
  }'

Text-to-Image — Return Base64

curl https://api.amux.ai/v1/images/generations \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "MiniMax-Image-01",
    "prompt": "A cup of hot coffee on a wooden table, top-down shot",
    "response_format": "b64_json",
    "n": 1
  }'

response_format accepts both b64_json (OpenAI style) and base64 (MiniMax style); amux normalizes both to MiniMax's base64.

Image-to-Image — JSON top-level subject_reference

curl https://api.amux.ai/v1/images/generations \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "MiniMax-Image-01",
    "prompt": "Close-up of a harbor worker with sunglasses, cinematic look",
    "aspect_ratio": "1:1",
    "n": 1,
    "subject_reference": [
      { "type": "character", "image_file": "https://example.com/face.jpg" }
    ]
  }'

Base64 data URLs are also accepted:

{
  "subject_reference": [
    { "type": "character", "image_file": "data:image/jpeg;base64,/9j/4AAQSkZJRg..." }
  ]
}

Image-to-Image — Multipart Upload (/v1/images/edits)

POST /v1/images/edits takes the reference image as the multipart image form field; amux reads the file → Base64 data URL → fills subject_reference[0] (type fixed to character). Only MiniMax-Image-01 is accepted.

curl https://api.amux.ai/v1/images/edits \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -F "model=MiniMax-Image-01" \
  -F "prompt=Close-up of a harbor worker with sunglasses, cinematic look" \
  -F "n=1" \
  -F "size=1024x1024" \
  -F "image=@/path/to/face.jpg"

Image-to-Image — OpenAI SDK via extra_body

The OpenAI SDK doesn't natively know subject_reference; pass it through extra_body:

from openai import OpenAI

client = OpenAI(base_url="https://api.amux.ai/v1", api_key="...")

response = client.images.generate(
    model="MiniMax-Image-01",
    prompt="Close-up of a harbor worker with sunglasses, cinematic look",
    n=1,
    size="1024x1024",
    extra_body={
        "subject_reference": [
            {"type": "character", "image_file": "https://example.com/face.jpg"}
        ]
    },
)
print(response.data[0].url)
import OpenAI from 'openai';

const client = new OpenAI({
  baseURL: 'https://api.amux.ai/v1',
  apiKey: process.env.AMUX_API_KEY,
});

const response = await client.images.generate(
  {
    model: 'MiniMax-Image-01',
    prompt: 'Close-up of a harbor worker with sunglasses, cinematic look',
    n: 1,
    size: '1024x1024',
  },
  {
    body: {
      subject_reference: [
        { type: 'character', image_file: 'https://example.com/face.jpg' },
      ],
    },
  },
);
console.log(response.data[0].url);

Current amux Limitations

ItemStatusNotes
MiniMax-Image-01-live model❌ Not yet supportedNot yet enabled on the platform — use MiniMax-Image-01. The style field still flows through but has no effect
width / height standalone fields❌ Not forwardedCurrently only size / aspect_ratio control the picture ratio; request adapter support if you need pixel-level control

Error Response

amux maps MiniMax upstream errors into the OpenAI error shape:

{
  "error": {
    "message": "...",
    "type": "minimax_image_error",
    "code": "<MiniMax base_resp.status_code>"
  }
}
HTTP StatusMeaning
200Success
400Bad request (empty prompt, invalid size, missing image file on /v1/images/edits, etc.)
401Missing or invalid API key
403Model not authorized (e.g. using MiniMax-Image-01-live) or blocked by content-safety policy
429Rate limit triggered or insufficient balance
500 / 502 / 503Server-side error or upstream unavailable

FAQ

On this page