load_lora_adapter
POST
/v1/load_lora_adapter
const url = 'https://example.com/v1/load_lora_adapter';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"lora_name":"production","lora_path":"/srv/adapters/production"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/load_lora_adapter \ --header 'Content-Type: application/json' \ --data '{ "lora_name": "production", "lora_path": "/srv/adapters/production" }'Registered only when runtime LoRA mutation is enabled. CLI servers enable it with MISTRALRS_ALLOW_RUNTIME_LORA_UPDATING.
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
expected_generation
Replace only if the alias still points at this generation.
string | null
load_inplace
Atomically replace an existing alias. Defaults to false, matching vLLM.
boolean
lora_name
required
Request-facing adapter alias.
string
lora_path
required
Local server filesystem directory containing PEFT safetensors files.
string
model
string | null
Example
{ "lora_name": "production", "lora_path": "/srv/adapters/production"}Responses
Section titled “ Responses ”LoRA adapter loaded
Media typeapplication/json
object
bytes
required
integer format: int64
generation
required
string
id
required
string
object
required
string
rank
required
integer
revision
string | null
source
string | null
Examplegenerated
{ "bytes": 1, "generation": "example", "id": "example", "object": "example", "rank": 1, "revision": "example", "source": "example"}Invalid request
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Adapter path is not allowed
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Model or adapter path was not found
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}LoRA runtime is unavailable or at capacity
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Adapter input files exceed the configured safety limit
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Request content type is not JSON
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Another adapter load is already in progress
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Adapter loading task failed
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}Adapter storage or model device is unavailable
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
type
required
string
Examplegenerated
{ "error": { "code": "example", "message": "example", "type": "example" }}