Skip to main content
PUT
Create or Update Deployment

Authorizations

Authorization
string
header
required

API key must be provided in the Authorization header

Body

application/json
name
string

Deployment name (letters, numbers, hyphens, dots, underscores; must start with letter or number; max 128 chars).

Example:

"my-model"

tag
string

Deployment tag used to differentiate variants of the same named deployment; defaults to 'default'.

Example:

"v2"

image
string

Docker image to run on worker instances; required.

Example:

"pytorch/pytorch:2.0.0"

search_params
string

GPU offer filter expression for selecting worker machines.

Example:

"gpu_ram>=16 num_gpus=1"

file_hash
string

SHA-256 (or similar) hash of the deployment artifact to upload; required and used as a cache key.

Example:

"e3b0c44298fc1c149afb"

file_size
integer

Size in bytes of the deployment artifact; required when file_hash is provided.

Example:

1048576

env
string

Environment variable string to inject into workers (e.g. '-e FOO=bar').

Example:

"-e MODEL=llama"

storage
number

Disk storage to allocate per worker in GB; must be positive; defaults to 50.

Example:

100

ttl
number

Seconds after the last heartbeat before the deployment is automatically deleted; negative disables auto-expiry.

Example:

3600

version_label
string

Human-readable label for this artifact version; defaults to first 6 chars of file_hash.

Example:

"release-1.0"

docker_login_user
string

Docker registry username for pulling private images.

docker_login_pass
string

Docker registry password for pulling private images.

docker_login_repo
string

Docker registry hostname/repo to authenticate against.

Example:

"docker.io"

cold_workers
integer

Fixed number of cold standby workers for the backing endpoint.

Example:

2

max_workers
integer

Maximum number of workers for the backing endpoint.

Example:

10

min_load
number

Minimum load threshold for the backing endpoint.

Example:

0

min_cold_load
number

Minimum cold load threshold for the backing endpoint.

Example:

0

target_util
number

Target utilization ratio (0-1) for the backing endpoint.

Example:

0.9

cold_mult
number

Cold-standby multiplier for the backing endpoint.

Example:

3

max_queue_time
number

Maximum acceptable queue time in seconds.

Example:

60

target_queue_time
number

Target queue time in seconds.

Example:

10

inactivity_timeout
number

Seconds of inactivity before the endpoint may be suspended.

Example:

300

overrecruit_ratio
number

Ratio by which to over-recruit workers for traffic spike absorption.

Example:

1.2

autoscaler_instance
string

Autoscaler deployment environment.

Example:

"prod"

Response

Returns {success: true, action: 'created'|'soft_update'|'autoscale_update'|'exists', deployment_id, endpoint_id, upload_url?, upload_fields?, evicted_versions?}

success
boolean

Always true on success.

action
string

One of: created, soft_update, autoscale_update, exists.

deployment_id
integer

ID of the deployment.

endpoint_id
integer

ID of the associated endpoint.

upload_url
string

Presigned S3 URL to upload the deployment blob (present when a new version needs to be uploaded).

upload_fields
object

Additional fields required for the S3 multipart POST upload (present with upload_url).

evicted_versions
object[]

List of evicted version objects ({id, file_hash, version_label, file_size}) if LRU eviction occurred.