Images (vision)
Models with a Vision badge on the Models & pricing page accept images in chat requests, using the standard OpenAI content-parts shape, so existing OpenAI SDK code works unchanged:
{
"model": "moonshotai/kimi-k2.7-code",
"messages": [
{
"role": "user",
"content": [
{ "type": "image_url", "image_url": { "url": "data:image/png;base64,..." } },
{ "type": "text", "text": "What is in this image?" }
]
}
]
}
Both data: URIs (base64-inline) and https: URLs are accepted. The API accepts request bodies
up to 32 MB; keep individual images to around 2 MB. (The Playground takes up to four images
per message, 2 MB apiece.)
Vision is verified per route
Vision is a per-deployment property, not a per-model one: the same model can accept images on one provider and not on another. Keln verifies that a route can accept images before sending image traffic to it, and re-checks continuously; a route that fails loses image routing.
Two consequences:
- Image requests go to capacity that has passed the vision check.
- If no verified vision route currently exists for a model, you get
400 modality_not_supported,"Image input is not available for this model."
PDFs and other files
Keln does not parse files: sending a file, input_audio, or other non-image part returns
400 modality_not_supported naming the part type.
To use a PDF with a Vision model, render its pages to PNG/JPEG client-side (pdf.js, pdfium,
ImageMagick) and attach them as image_url parts.
Notes
GET /v1/modelsreports each model's accepted inputs ininput_modalities(["text"]or["text", "image"]).- Switching a conversation to a text-only model drops the images from the replayed history; the
Playground shows this explicitly. Over the API, replaying image parts at a text-only model
returns the modality
400. - Keln bills image tokens as input tokens exactly as the serving provider counts them, the same pass-through accounting as text.
- Keln does not offer audio or video input.