Skip to content
OpenRelay is in early access, and the /v1 API is stable. New capabilities ship in the changelog.
API ReferenceProvidersReservations

Amend a reservation (platform admin)

Changes a reservation's term end, audience, or managing orgs, or re-pins it to the node's current topology, and returns the updated reservation. Re-pinning (reaffirm) also reactivates a reservation in needs-review. The start of the term is fixed at create.

Required permission

Requires the reservation.manage permission. A caller without it gets 404. See Permissions for the roles and API key permissions that include it.

PATCH
/v1/nodes/{nodeId}/reservations/{id}

Authorization

apiKey
headerAuthorizationBearer <token>

OpenRelay API key. Send it as Authorization: Bearer or_… (legacy vl_… keys still work).

Path Parameters

nodeId*string
id*string

Request Body

application/json
  1. body
endsAt?string

Move the term end. Empty string makes it open-ended.

allowedOrgIds?array<string>

Replace the audience

managingOrgIds?array<string>

Replace the managing orgs. An empty array removes the delegation.

reaffirm?boolean

Re-pin to the node's current topology and reactivate (clears needs-review)

Response Body

OK

application/json
  1. response

Exclusive placement rights for a set of orgs over specific GPU units of one node, for a term. Scoped to units, not GPU counts, because units are the indivisible allocation primitive.

id*string
nodeId*string
reservedUnitIds*array<string>
releasedUnitIds?array<string>

The subset of reservedUnitIds currently on the spot market (double sell). Still this reservation's capacity, sellable to anyone at tier=spot only, and reclaimable at any time.

allowedOrgIds*array<string>

The audience: orgs that may place workloads on the reserved units.

managingOrgIds?array<string>

Orgs that may release these units to the market, reclaim them, and terminate the spot workloads on them, on the node owner's behalf, while the reservation is active and inside its term. Being in the audience does not confer this.

startsAt*string
endsAt?string

Absent = open-ended until cancelled

status*string

needs-review means the node's GPU topology changed under the reservation: it grants nothing (and withholds its units from everyone) until an operator re-affirms it.

Value in"pending""active""expired""cancelled""needs-review"
topologyGen?integer

Node topology generation this reservation was written against

contractRef?string
reason?string
createdAt?string
updatedAt?string
terminated?array<string>

Reclaim only: spot VM ids terminated to free the reclaimed units.

skipped?array<string>

Reclaim only: VM ids left running because they are not spot.

wouldTerminate?array<string>

Reclaim dry run only: the spot VM ids this call would terminate.

wouldSkip?array<string>

Reclaim dry run only: VM ids that would be left running.

Example Request
curl -X PATCH 'https://api.openrelay.inc/v1/nodes/string/reservations/string' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "id": "string",  "nodeId": "string",  "reservedUnitIds": [    "string"  ],  "releasedUnitIds": [    "string"  ],  "allowedOrgIds": [    "string"  ],  "managingOrgIds": [    "string"  ],  "startsAt": "string",  "endsAt": "string",  "status": "pending",  "topologyGen": 0,  "contractRef": "string",  "reason": "string",  "createdAt": "string",  "updatedAt": "string",  "terminated": [    "string"  ],  "skipped": [    "string"  ],  "wouldTerminate": [    "string"  ],  "wouldSkip": [    "string"  ]}