ApiX Docs
Docs / Vision
·View as Markdown

Vision

Models with the image input modality read images. Send an HTTPS URL or a base64 data URL:

json
{
  "model": "3/qwen-3.8-27b:free",
  "messages": [{
    "role": "user",
    "content": [
      {"type": "text", "text": "What is in this image?"},
      {"type": "image_url", "image_url": {"url": "data:image/png;base64,iVBORw0..."}}
    ]
  }]
}

Anthropic clients use the image block:

json
{"type": "image", "source": {"type": "base64", "media_type": "image/png", "data": "..."}}

Keys have media limits per request (max_media_bytes_per_request, max_media_units_per_request). Going over returns 400 MEDIA_BYTES_EXCEEDED or 400 MEDIA_UNITS_EXCEEDED.