List Instances
curl --request GET \
--url https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances"
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'}
};
fetch('https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances', 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.novita.ai/gpu-instance/openapi/v1/gpu/instances",
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: <authorization>",
"Content-Type: <content-type>"
],
]);
$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://api.novita.ai/gpu-instance/openapi/v1/gpu/instances"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"instances": [
{
"id": "<string>",
"name": "<string>",
"clusterId": "<string>",
"clusterName": "<string>",
"status": "<string>",
"imageUrl": "<string>",
"imageAuthId": "<string>",
"command": "<string>",
"entrypoint": "<string>",
"cpuNum": "<string>",
"memory": "<string>",
"gpuNum": "<string>",
"portMappings": [
{
"port": 123,
"type": "<string>"
}
],
"productId": "<string>",
"productName": "<string>",
"rootfsSize": 123,
"volumeMounts": [
{
"type": "<string>",
"size": "<string>",
"id": "<string>",
"mountPath": "<string>"
}
],
"statusError": {
"state": "<string>",
"message": "<string>"
},
"envs": [
{
"key": "<string>",
"value": "<string>"
}
],
"kind": "<string>",
"billingMode": "<string>",
"endTime": "<string>",
"spotStatus": "<string>",
"spotReclaimTime": "<string>"
}
]
}Instance
List Instances
GET
/
gpu-instance
/
openapi
/
v1
/
gpu
/
instances
List Instances
curl --request GET \
--url https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances"
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'}
};
fetch('https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances', 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.novita.ai/gpu-instance/openapi/v1/gpu/instances",
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: <authorization>",
"Content-Type: <content-type>"
],
]);
$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://api.novita.ai/gpu-instance/openapi/v1/gpu/instances"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.novita.ai/gpu-instance/openapi/v1/gpu/instances")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"instances": [
{
"id": "<string>",
"name": "<string>",
"clusterId": "<string>",
"clusterName": "<string>",
"status": "<string>",
"imageUrl": "<string>",
"imageAuthId": "<string>",
"command": "<string>",
"entrypoint": "<string>",
"cpuNum": "<string>",
"memory": "<string>",
"gpuNum": "<string>",
"portMappings": [
{
"port": 123,
"type": "<string>"
}
],
"productId": "<string>",
"productName": "<string>",
"rootfsSize": 123,
"volumeMounts": [
{
"type": "<string>",
"size": "<string>",
"id": "<string>",
"mountPath": "<string>"
}
],
"statusError": {
"state": "<string>",
"message": "<string>"
},
"envs": [
{
"key": "<string>",
"value": "<string>"
}
],
"kind": "<string>",
"billingMode": "<string>",
"endTime": "<string>",
"spotStatus": "<string>",
"spotReclaimTime": "<string>"
}
]
}Request Headers
string
obrigatório
Enum:
application/jsonstring
obrigatório
Bearer authentication format, for example: Bearer {{API Key}}.
Query Parameters
integer
obrigatório
Maximum number of items returned per page. Integer, value >= 0.
integer
obrigatório
Page number to retrieve. Integer, value >= 0.
string
Instance name (supports fuzzy search). String, length limit: 0-255 characters.
string
Product name (supports fuzzy search). String, length limit: 0-255 characters.
string
Instance status. String, length limit: 0-63 characters. Possible values:
toCreate: Pending creationcreating: Creatingpulling: Pulling imagerunning: RunningtoStart: Pending startstarting: StartingtoStop: Pending stopstopping: Stoppingexited: StoppedtoRestart: Pending restartrestarting: RestartingtoRemove: Pending deletionremoving: Deletingremoved: DeletedtoReset: Pending reset (upgrade)resetting: Resettingmigrating: Migratingfreezing: Freezing
Response
object[]
obrigatório
Instance information.
Ocultar properties
Ocultar properties
string
obrigatório
Instance ID.
string
obrigatório
Instance name.
string
obrigatório
Cluster ID.
string
Cluster name.
string
obrigatório
Instance status.
string
obrigatório
Container image URL.
string
Image repository authentication information.
string
Container startup command.
string
Container startup entrypoint.
string
obrigatório
Number of CPU cores for the instance.
string
obrigatório
Memory size of the instance (GB).
string
obrigatório
Number of GPUs for the instance.
object[]
string
obrigatório
Product ID used to deploy the instance.
string
obrigatório
Product name used to deploy the instance.
integer
obrigatório
Root filesystem size (GB).
object[]
object
object[]
string
Instance type.
string
obrigatório
Billing mode for the instance. Values:
- onDemand: Pay-as-you-go billing.
- monthly: Subscription (monthly or yearly) billing.
- spot: Spot instance billing.
string
Expiration time for subscription instances. For pay-as-you-go instances, returns -1.
string
Spot instance status. Values:
running: Runningnotified: Notified for reclaimreclaiming: Being reclaimedterminated: Terminated
string
Spot instance reclaim time. Value “0” means reclaim has not started.
Última modificação em 15 de maio de 2026
⌘I