Reservations

Get Availability

get

Get availability information for reservations.

This endpoint supports three different modes for querying availability:

Mode: latest_end_time (default)

Get the latest possible end time for a reservation given a start time and quantity.

Required parameters:

  • start_time: Desired start time for the reservation

  • quantity: Number of instances needed

  • project: Project FID

  • instance_type: Instance type FID

  • region: Region name

Returns: Latest possible end time and availability status

Example:

GET /reservation/availability?
    start_time=2024-01-01T00:00:00Z&
    quantity=4&
    project=proj_01h8x2k9m3n4p5q6r7s8t9u0v&
    instance_type=it_01h8x2k9m3n4p5q6r7s8t9u0v&
    region=us-central1-a

Mode: slots

Get all available slots in a time range.

Required parameters:

  • earliest_start_time: Start of the time range to search

  • latest_end_time: End of the time range to search

  • project: Project FID

  • instance_type: Instance type FID

  • region: Region name

Returns: List of available time slots with quantities

Example:

Mode: check

Check if a specific time slot is available for reservation.

Required parameters:

  • start_time: Start of the desired time slot

  • end_time: End of the desired time slot

  • quantity: Number of instances needed

  • project: Project FID

  • instance_type: Instance type FID

  • region: Region name

Returns: Boolean indicating if the slot is available

Example:

Common Parameters

All modes require these parameters:

  • project: Project FID

  • instance_type: Instance type FID

  • region: Region name

Authentication

Requires authentication and user must be a member of the specified project.

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Query parameters
projectstringRequired
instance_typestringRequired
regionstringRequired
modestring · enumOptionalDefault: latest_end_timePossible values:
earliest_start_timestring · datetime · nullableOptionalExample: 2024-01-01T00:00:00Z
latest_end_timestring · datetime · nullableOptionalExample: 2024-01-01T00:00:00Z
start_timestring · datetime · nullableOptionalExample: 2024-01-01T00:00:00Z
end_timestring · datetime · nullableOptionalExample: 2024-01-01T00:00:00Z
quantityinteger · nullableOptional
Responses
chevron-right
200

Successful Response

application/json
get
/v2/reservation/availability

Get Reservations

get

Get all reservations for a project

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Query parameters
next_cursorany · nullableOptional
sort_bystring · enum · nullableOptionalPossible values:
sort_dirstring · enum · nullableOptionalPossible values:
projectstringRequired
instance_typestring · nullableOptionalExample: it_abc123456
regionstring · nullableOptionalExample: us-central1-a
statusstring · enum · nullableOptionalPossible values:
limitinteger · min: 1 · max: 100 · nullableOptional
Responses
chevron-right
200

Successful Response

application/json
get
/v2/reservation

Create Reservation

post

Create a new reservation

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
projectstringRequiredExample: proj_abc123456
instance_typestringRequiredExample: it_abc123456
regionstringRequiredExample: us-central1-a
start_timestring · datetimeRequiredExample: 2024-01-01T00:00:00Z
end_timestring · datetimeRequiredExample: 2024-01-01T00:00:00Z
instance_quantityintegerRequiredExample: 4
namestringRequired
Responses
post
/v2/reservation

Get Extension Availability

get

Get extension availability for a reservation

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
reservation_fidstringRequiredExample: res_abc123456
Responses
chevron-right
200

Successful Response

application/json
get
/v2/reservation/{reservation_fid}/extension-availability

Extend Reservation

post

Extend a reservation to the requested time.

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
reservation_fidstringRequiredExample: res_abc123456
Body
end_timestring · datetimeRequiredExample: 2024-01-01T00:00:00Z
Responses
chevron-right
200

Successful Response

application/json
post
/v2/reservation/{reservation_fid}/extend

Update Reservation

patch

Update a reservation's pause/resume status and/or volumes

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
reservation_fidstringRequiredExample: res_abc123456
Body
pausedboolean · nullableOptional
volumesstring[] · nullableOptional
Responses
chevron-right
200

Successful Response

application/json
patch
/v2/reservation/{reservation_fid}

Last updated