POST
/
gpu-instance
/
openapi
/
v1
/
endpoint
/
update
curl --request POST \
  --url https://api.novita.ai/gpu-instance/openapi/v1/endpoint/update \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: <content-type>' \
  --data '{
  "id": "<string>",
  "name": "<string>",
  "clusterID": "<string>",
  "workerConfig": [
    {
      "minNum": 123,
      "maxNum": 123,
      "freeTimeout": 123,
      "maxConcurrent": 123,
      "gpuNum": 123
    }
  ],
  "ports": [
    {
      "port": "<string>"
    }
  ],
  "policy": [
    {
      "type": "<string>",
      "value": 123
    }
  ],
  "image": [
    {
      "image": "<string>",
      "authId": "<string>",
      "command": "<string>"
    }
  ],
  "volumeMounts": [
    {
      "type": "<string>",
      "size": 123,
      "id": "<string>",
      "mountPath": "<string>"
    }
  ],
  "envs": [
    {
      "key": "<string>",
      "value": "<string>"
    }
  ],
  "healthy": [
    {
      "path": "<string>"
    }
  ]
}'

Description

When updating an endpoint, all parameters must be provided in full.

Request Headers

Content-Type
string
required

Enum: application/json

Authorization
string
required

Bearer authentication format, for example: Bearer {{API Key}}.

Request Body

id
string
required

The ID of the endpoint to update.

name
string

Endpoint name.

clusterID
string

Cluster information. Required when mounting cloud storage, and must match the cluster ID where the cloud storage resides. String, length limit: 0-255 characters.

workerConfig
object[]
required

Worker configuration. The valid range can be dynamically obtained via the parameter range API.

ports
object[]
required

HTTP ports. Only one is supported. Supported port range: 1-65535, except for 2222, 2223, and 2224 which are reserved for internal use.

policy
object[]
required

Auto-scaling policy. The valid range can be dynamically obtained via the parameter range API.

image
object[]
required

Image information.

volumeMounts
object[]

Storage information (GB).

envs
object[]

Environment variables.

healthy
object[]

Health check endpoint path.