Update Model
curl --request PUT \
--url https://api.example.com/assets/models/{resource_uri} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"litellm_model": "<string>",
"provider": "<string>",
"tags": [
"<string>"
],
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 4.995,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>",
"credentials": {}
}
'import requests
url = "https://api.example.com/assets/models/{resource_uri}"
payload = {
"name": "<string>",
"description": "<string>",
"litellm_model": "<string>",
"provider": "<string>",
"tags": ["<string>"],
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 4.995,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>",
"credentials": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
litellm_model: '<string>',
provider: '<string>',
tags: ['<string>'],
api_base: '<string>',
api_version: '<string>',
max_input_tokens: 123,
max_output_tokens: 123,
rpm: 123,
tpm: 123,
default_temperature: 4.995,
default_max_tokens: 123,
timeout: 123,
status_message: '<string>',
credentials: {}
})
};
fetch('https://api.example.com/assets/models/{resource_uri}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/assets/models/{resource_uri}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'litellm_model' => '<string>',
'provider' => '<string>',
'tags' => [
'<string>'
],
'api_base' => '<string>',
'api_version' => '<string>',
'max_input_tokens' => 123,
'max_output_tokens' => 123,
'rpm' => 123,
'tpm' => 123,
'default_temperature' => 4.995,
'default_max_tokens' => 123,
'timeout' => 123,
'status_message' => '<string>',
'credentials' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/assets/models/{resource_uri}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.example.com/assets/models/{resource_uri}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/assets/models/{resource_uri}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"resource_uri": "<string>",
"name": "<string>",
"litellm_model": "<string>",
"organization_id": "<string>",
"project_id": "<string>",
"owner_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": "<string>",
"updated_by": "<string>",
"description": "<string>",
"tags": [],
"provider": "<string>",
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 123,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>"
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}models
Update Model
Update model
PUT
/
assets
/
models
/
{resource_uri}
Update Model
curl --request PUT \
--url https://api.example.com/assets/models/{resource_uri} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"litellm_model": "<string>",
"provider": "<string>",
"tags": [
"<string>"
],
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 4.995,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>",
"credentials": {}
}
'import requests
url = "https://api.example.com/assets/models/{resource_uri}"
payload = {
"name": "<string>",
"description": "<string>",
"litellm_model": "<string>",
"provider": "<string>",
"tags": ["<string>"],
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 4.995,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>",
"credentials": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
litellm_model: '<string>',
provider: '<string>',
tags: ['<string>'],
api_base: '<string>',
api_version: '<string>',
max_input_tokens: 123,
max_output_tokens: 123,
rpm: 123,
tpm: 123,
default_temperature: 4.995,
default_max_tokens: 123,
timeout: 123,
status_message: '<string>',
credentials: {}
})
};
fetch('https://api.example.com/assets/models/{resource_uri}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/assets/models/{resource_uri}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'litellm_model' => '<string>',
'provider' => '<string>',
'tags' => [
'<string>'
],
'api_base' => '<string>',
'api_version' => '<string>',
'max_input_tokens' => 123,
'max_output_tokens' => 123,
'rpm' => 123,
'tpm' => 123,
'default_temperature' => 4.995,
'default_max_tokens' => 123,
'timeout' => 123,
'status_message' => '<string>',
'credentials' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/assets/models/{resource_uri}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.example.com/assets/models/{resource_uri}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/assets/models/{resource_uri}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"litellm_model\": \"<string>\",\n \"provider\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"api_base\": \"<string>\",\n \"api_version\": \"<string>\",\n \"max_input_tokens\": 123,\n \"max_output_tokens\": 123,\n \"rpm\": 123,\n \"tpm\": 123,\n \"default_temperature\": 4.995,\n \"default_max_tokens\": 123,\n \"timeout\": 123,\n \"status_message\": \"<string>\",\n \"credentials\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"resource_uri": "<string>",
"name": "<string>",
"litellm_model": "<string>",
"organization_id": "<string>",
"project_id": "<string>",
"owner_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": "<string>",
"updated_by": "<string>",
"description": "<string>",
"tags": [],
"provider": "<string>",
"api_base": "<string>",
"api_version": "<string>",
"max_input_tokens": 123,
"max_output_tokens": 123,
"rpm": 123,
"tpm": 123,
"default_temperature": 123,
"default_max_tokens": 123,
"timeout": 123,
"status_message": "<string>"
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Path Parameters
Model resource URI
Body
application/json
Request body for updating a model configuration.
Required string length:
1 - 255Maximum string length:
1000Required string length:
1 - 500Maximum string length:
100Maximum string length:
1000Maximum string length:
50Supported model modes.
Available options:
chat, completion, embedding, image_generation, audio_transcription Required range:
0 <= x <= 9.99Status of a model configuration.
Available options:
PENDING, ACTIVE, ERROR, DEPRECATED, DISABLED Maximum string length:
1000Updated credentials. If provided, replaces existing credentials.
Show child attributes
Show child attributes
Response
Successful Response
Full model representation.
Status of a model configuration.
Available options:
PENDING, ACTIVE, ERROR, DEPRECATED, DISABLED Deprecated: use created_by instead. Will be removed in a future release.
Supported model modes.
Available options:
chat, completion, embedding, image_generation, audio_transcription Was this page helpful?
⌘I

