Skip to main content

API endpoints

All endpoints are relative to the base URL https://api.llmtune.io. Send Authorization: Bearer sk_... on every request.

Inference

MethodPathDescription
POST/v1/models/{modelId}/inferenceSingle-prompt completion. Body: prompt, temperature, maxTokens, etc.
POST/v1/chat/completionsChat completions. Body: model, messages, temperature, max_tokens, optional stream.
POST/v1/batch/inferenceBatch inference (multiple prompts). Body: modelId, requests array, optional webhookUrl.

Agent

MethodPathDescription
GET/api/agent/v1/modelsList models available for the Agent.
POST/api/agent/v1/chat/completionsChat with optional tools. Body: model, messages, tools, tool_choice, etc.

Fine-tuning

MethodPathDescription
POST/api/fine-tune/training/startStart a fine-tuning job. Body: base model, dataset, hyperparameters, optional webhook.
GET/api/training/{jobId}Get job status, progress, and metrics.
POST/api/training/{jobId}/cancelCancel a running job (if supported).

Other

MethodPathDescription
GET/api/healthHealth check.
GET/api/models/listList available models (catalog).
GET/api/usage/summaryUsage summary (when authenticated).
Exact paths and request/response schemas may vary slightly; use the dashboard and the OpenAPI spec (if available) for the current contract. Error responses use standard HTTP status codes and a JSON error (and optional message) field.