List Deployments
curl --request GET \
--url https://{host}/api/model-deployments \
--header 'Authorization: Bearer <token>'import requests
url = "https://{host}/api/model-deployments"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/api/model-deployments', 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://{host}/api/model-deployments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{host}/api/model-deployments"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/api/model-deployments")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/model-deployments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"enabled": true,
"max_gpus": 123,
"items": [
{
"id": "<string>",
"name": "<string>",
"owner_user_id": 123,
"owner_username": "<string>",
"desired_state": "<string>",
"status": "<string>",
"endpoint_path": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"fleet_id": "",
"serve_mode": "proxied",
"current_revision_id": "<string>",
"candidate_revision_id": "<string>",
"last_error": "<string>",
"current_revision": {
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
},
"candidate_revision": {
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
},
"revisions": [
{
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
}
],
"tokens": [
{
"id": "<string>",
"deployment_id": "<string>",
"name": "<string>",
"prefix": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_used_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z"
}
],
"reflow_sample_rate": 0,
"reflow_retention_days": 30,
"reflow_capture_system_prompt": true,
"reflow_dropped_total": 0,
"reflow_trimmed_total": 0
}
]
}List Deployments
GET
/
api
/
model-deployments
List Deployments
curl --request GET \
--url https://{host}/api/model-deployments \
--header 'Authorization: Bearer <token>'import requests
url = "https://{host}/api/model-deployments"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/api/model-deployments', 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://{host}/api/model-deployments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{host}/api/model-deployments"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/api/model-deployments")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/model-deployments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"enabled": true,
"max_gpus": 123,
"items": [
{
"id": "<string>",
"name": "<string>",
"owner_user_id": 123,
"owner_username": "<string>",
"desired_state": "<string>",
"status": "<string>",
"endpoint_path": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"fleet_id": "",
"serve_mode": "proxied",
"current_revision_id": "<string>",
"candidate_revision_id": "<string>",
"last_error": "<string>",
"current_revision": {
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
},
"candidate_revision": {
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
},
"revisions": [
{
"id": "<string>",
"deployment_id": "<string>",
"sequence": 123,
"engine": "<string>",
"model_source": {},
"config": {},
"status": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"runtime_ref": "<string>",
"runtime_meta": {},
"internal_endpoint": "<string>",
"error": "<string>",
"ready_at": "2023-11-07T05:31:56Z",
"retired_at": "2023-11-07T05:31:56Z"
}
],
"tokens": [
{
"id": "<string>",
"deployment_id": "<string>",
"name": "<string>",
"prefix": "<string>",
"created_by": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_used_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z"
}
],
"reflow_sample_rate": 0,
"reflow_retention_days": 30,
"reflow_capture_system_prompt": true,
"reflow_dropped_total": 0,
"reflow_trimmed_total": 0
}
]
}