Skip to main content
PATCH
Update a serverless endpoint

Authorizations

Authorization
string
header
required

Runpod API key authentication. Generate an API key in the Runpod console and send it in the Authorization header as Bearer <api_key>. Keys are scoped to the permissions granted when created; requests may return 403 when a valid key lacks access to the requested resource or action.

Path Parameters

id
string
required

Serverless endpoint identifier

Body

application/json

Only provided fields are changed.

args
string

Arguments passed to the container entrypoint

Example:

""

disk
integer

Container disk in GB (ephemeral, wiped on restart)

Required range: x >= 1
Example:

50

env
object

Environment variables as key-value pairs

Example:
image
string

Docker image reference

Example:

"runpod/pytorch:1.0.2-cu1281-torch280-ubuntu2404"

ports
string[]

Exposed ports, formatted as port/protocol

Example:
registry
string | null

Container registry credential ID (for private images)

Example:

null

cpu
object[]

Complete replacement CPU selection. Valid only for an existing CPU endpoint; endpoint compute family cannot be changed.

Minimum array length: 1
dataCenterIds
string[]

Preferred data centers for placement. Omit or pass an empty array to let the scheduler choose.

flashboot
enum<string>

FlashBoot cold-start acceleration mode.

  • OFF — disabled
  • FLASHBOOT — enabled
  • PRIORITY_FLASHBOOT — enabled with priority capacity
Available options:
OFF,
FLASHBOOT,
PRIORITY_FLASHBOOT
gpu
object

Partial GPU update — every field is optional and an omitted one is left unchanged. Unlike create, pools is optional, so changing only a CUDA constraint does not require resending the pool list.

excludedTypes requires pools, because the two are one selection and only a supplied pools replaces it — an exclusion on its own would otherwise be silently dropped.

name
string
Minimum string length: 1
networkVolumes
string[]
scaling
object

Autoscaling signal — a discriminated union on type: QUEUE_DELAY (queue-based endpoints only) or REQUEST_COUNT. The scaler is chosen independently of the endpoint's routing type and can be switched on update.

templateId
string

ID of a serverless template whose container settings are applied as if they were provided in this PATCH body (image, args, disk, ports, env, registry). Explicit body fields override the template's; env merges template and body per key (body wins) and, per PATCH semantics, replaces the endpoint's env. One-time application — no link to the template is retained. Must be one of your templates or a public template (unknown or inaccessible ID → 404); must be a serverless template (→ 422).

Example:

"30zmvf89kd"

timeout
integer
workers
object

Response

OK

Reusable container configuration shared across templates, pods, and serverless endpoints. Adding a field here automatically propagates to all three resources.

id
string
required
Example:

"ep_abc123"

name
string
required
Example:

"my-inference"

workers
object
required
scaling
object
required

Autoscaling signal — a discriminated union on type: QUEUE_DELAY (queue-based endpoints only) or REQUEST_COUNT. The scaler is chosen independently of the endpoint's routing type and can be switched on update.

dataCenterIds
string[]
required
Example:
networkVolumes
string[]
required
Example:
timeout
integer
required

Per-request execution timeout in milliseconds

Example:

300000

flashboot
enum<string>
required

FlashBoot cold-start acceleration mode.

  • OFF — disabled
  • FLASHBOOT — enabled
  • PRIORITY_FLASHBOOT — enabled with priority capacity
Available options:
OFF,
FLASHBOOT,
PRIORITY_FLASHBOOT
createdAt
string<date-time>
required
Example:

"2026-03-13T20:00:00Z"

args
string

Arguments passed to the container entrypoint

Example:

""

disk
integer

Container disk in GB (ephemeral, wiped on restart)

Required range: x >= 1
Example:

50

env
object

Environment variables as key-value pairs

Example:
image
string

Docker image reference

Example:

"runpod/pytorch:1.0.2-cu1281-torch280-ubuntu2404"

ports
string[]

Exposed ports, formatted as port/protocol

Example:
registry
string | null

Container registry credential ID (for private images)

Example:

null

type
enum<string>

Request-routing semantics for a modern serverless endpoint.

  • QUEUE — submit asynchronous or synchronous jobs through the managed queue.
  • LOAD_BALANCER — send requests directly to worker-defined HTTP paths. Configure via env: PORT (server port, default 80), PORT_HEALTH (health-check port, default 80), and HEALTH_CHECK_PATH (path the load balancer polls for worker health, default /ping).
Available options:
QUEUE,
LOAD_BALANCER
requestUrls
object

Request URLs appropriate to the endpoint's top-level type. Queue-based endpoints provide job submission and management URLs; load-balancing endpoints provide base and health because their remaining paths are worker-defined.

gpu
object | null
cpu
object[]

Eligible CPU configurations for each worker, in the order they were submitted. Present for CPU endpoints and omitted for GPU endpoints. Memory is derived from the selected flavor's catalog RAM multiplier.

Minimum array length: 1
Last modified on July 28, 2026