Kimi
Kimi chat models are called through one simple endpoint: send a messages array plus the model slug and get the reply text back. This family exposes 2 models.
Overview
Send a standard messages array (user / assistant / system roles). Billing is deducted from your credit balance per response; the response includes your remaining balance.
Authentication
Create an API key at /api-keys, then send it as a Bearer token. Requests from the browser while logged in also work via the session cookie.
Authorization: Bearer <YOUR_API_KEY>OpenAI-compatible Chat Completions
POST https://api.lithovas.com/v1/chat/completionsUse this endpoint for developer integrations: point your OpenAI SDK base_url to https://api.lithovas.com/v1 and send a Lithovas API key.
model: "chat/kimi-k3"; /v1/chat/completions also accepts the OpenRouter upstream model id moonshotai/kimi-k3. OpenRouter currently lists Kimi K3 as text, image, and video input to text output; Lithovas currently supports text plus image image_url content parts, with public HTTPS URLs and data:image/...;base64,... accepted.from openai import OpenAI
client = OpenAI(
api_key="YOUR_LITHOVAS_API_KEY",
base_url="https://api.lithovas.com/v1",
)
completion = client.chat.completions.create(
model="chat/kimi-k3",
messages=[
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Hello!"},
],
)
print(completion.choices[0].message.content)curl -X POST https://api.lithovas.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "chat/kimi-k3",
"messages": [
{ "role": "system", "content": "You are a helpful assistant." },
{ "role": "user", "content": "Hello!" }
]
}'from openai import OpenAI
import base64
client = OpenAI(
api_key="YOUR_LITHOVAS_API_KEY",
base_url="https://api.lithovas.com/v1",
)
image_url = "https://example.com/photo.jpg"
# Alternative: local image as Base64 Data URL.
# with open("photo.png", "rb") as f:
# image_url = f"data:image/png;base64,{base64.b64encode(f.read()).decode('utf-8')}"
completion = client.chat.completions.create(
model="chat/kimi-k3",
messages=[{
"role": "user",
"content": [
{"type": "image_url", "image_url": {"url": image_url}},
{"type": "text", "text": "请描述这张图片,并指出重要细节"},
],
}],
)
print(completion.choices[0].message.content)Chat Completions
POST https://api.lithovas.com/api/chatBody: { "model": "<slug>", "messages": [{ "role": "user", "content": "…" }] }
Response: { "text": "<assistant reply>", "credits": <billed>, "balance": <remaining> }
Models
Kimi K3
/v1/chat/completionscurl -X POST https://api.lithovas.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "chat/kimi-k3",
"messages": [{
"role": "user",
"content": [
{ "type": "text", "text": "Describe this image." },
{ "type": "image_url", "image_url": { "url": "https://example.com/photo.jpg" } }
]
}]
}'Kimi K2.6
/v1/chat/completionscurl -X POST https://api.lithovas.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "chat/kimi-k2-6",
"messages": [{ "role": "user", "content": "Hello!" }]
}'