Skip to main content

List Images

GET https://infrahub-api.nexgencloud.com/v1/core/images

Returns a list of all available operating system (OS) images, providing details about each image's corresponding virtual machine operating system. Include the optional region parameter in the query string of the request to specifically return OS images from the designated region. For more information on OS images, click here.


Query-string parameters


region string  optional

Include a region name in the query string of the request to view the OS images available in the specified region, i.e. "NORWAY-1". If no region is included in the request, images available in all regions will be retrieved.

Possible enum values: NORWAY-1 or CANADA-1.

See more information about regions.


Attributes of the Images object


status boolean

Indicates the success or failure of the retrieval of OS images.


message string

A message confirming the successful retrieval of images.


data array

An array containing information about operating system images, and the region where they are available.

Show child attributes
region_name string

Name of the region associated with the images.


type string

Operating system type that is not version specific.


logo string

URL to the logo image associated with the operating system.


images array of objects

An array of images objects containing details about individual operating system images.

Show child attributes
id integer

Unique identifier for the operating system image.


name string

Name of the operating system image.


size integer

Size of the operating system image in bytes.


region_name string

Name of the region associated with the operating system image.


display_size string

Size of the operating system image in a human-readable format in MB.


type string

Operating system type.


version string

Operating system version that the image corresponds to.

Example request
curl -X GET "https://infrahub-api.nexgencloud.com/v1/core/images" \
-H "accept: application/json"\
-H "api_key: YOUR API KEY"
Response
{
"status": true,
"message": "Getting images successful",
"data": [
{
"region_name": "NORWAY-1",
"type": "Ubuntu",
"logo": "https://api.nexgencloud.com:8080/hyperstack-os-logos/ubuntu.svg",
"images": [
{
"id": 3,
"name": "Ubuntu Server 22.04 LTS",
"region_name": "NORWAY-1",
"type": "Ubuntu",
"version": "Server 22.04 LTS",
"size": 634585088,
"display_size": "605.19 MB"
},
]
},
{...}

Returns


This response indicates the successful retrieval of the available operating system images. The desired image_name will be used in the body of the request to create a new virtual machine using the POST /core/virtual-machines endpoint.

note

In this example only one image is displayed; Ubuntu Server 22.04 LTS. Using the GET /core/images endpoint will return a list of all available OS images.


Back to top