Update multiple instances
⚠️ This endpoint is in public preview.
Update one or more instances atomically. All listed instances must be in the same workspace; mixed-workspace batches are rejected with 422.
Authorizations
Create an API token using sf tokens create or at https://sfcompute.com/account/api-keys.
Body
Request body for PATCH /v2/instances (batch). Each entry in data applies a partial patch to one instance; instances not mentioned are untouched. All entries must succeed or none — a single failure rolls back every other entry's writes (422).
When the same id appears more than once in data, the last occurrence wins.
Response
Instances updated.
Response shape for PATCH /v2/instances (batch). Mirrors the input list — one InstanceResponse per unique id in the request body, reflecting the post-write state. Unlike the paginated list response, there's no cursor or has_more: the response is exactly the instances the caller mentioned, no pagination involved.