Skip to content

Images

The project's own images.

Paths are relative to your API address. See Authentication and Operations. Changes that answer 202 Accepted return an operation to follow.

Request and response examples are generated from the schema; the tables under Schemas are the reference.

Import an image from an address

POST /v1/orgs/{org_id}/projects/{project_id}/images

Makes a private image of the project in one location, which the location's image service downloads from an https address. Accepted at once: follow the returned operation; the image is importing until the download ends, and an import that fails leaves nothing behind. Delete the image to stop an import in progress.

Input parameters

Parameter In Type Default Nullable Description
Authorization header string N/A No Bearer followed by a service account's API key. The console uses your signed-in session instead.
idempotency-key header string Yes
org_id path string No
project_id path string No

Request body

{
    "architecture": "string",
    "disk_format": "string",
    "display_name": "string",
    "execute_before": "2022-04-13T15:42:05.901Z",
    "location": "string",
    "min_disk_gb": 0,
    "min_ram_mb": 0,
    "os_distro": "string",
    "os_version": "string",
    "source_url": "string"
}

Responses

{
    "operation": {
        "href": "string",
        "id": "string",
        "state": "string"
    }
}
{
    "detail": [
        {
            "ctx": {},
            "input": null,
            "loc": [
                null
            ],
            "msg": "string",
            "type": "string"
        }
    ]
}

Delete an image

DELETE /v1/orgs/{org_id}/projects/{project_id}/images/{image_id}

Deletes one of the project's own images. Instances started from it keep running. Accepted at once: follow the returned operation until it finishes.

Input parameters

Parameter In Type Default Nullable Description
Authorization header string N/A No Bearer followed by a service account's API key. The console uses your signed-in session instead.
idempotency-key header string Yes
image_id path string No
org_id path string No
project_id path string No

Responses

{
    "operation": {
        "href": "string",
        "id": "string",
        "state": "string"
    }
}
{
    "detail": [
        {
            "ctx": {},
            "input": null,
            "loc": [
                null
            ],
            "msg": "string",
            "type": "string"
        }
    ]
}

Rename an image

PATCH /v1/orgs/{org_id}/projects/{project_id}/images/{resource_id}

Changes the name of one of the project's own images (an image has no description; sending one is refused). Accepted at once: follow the returned operation until it finishes.

Input parameters

Parameter In Type Default Nullable Description
Authorization header string N/A No Bearer followed by a service account's API key. The console uses your signed-in session instead.
idempotency-key header string Yes
org_id path string No
project_id path string No
resource_id path string No

Request body

{
    "description": "string",
    "display_name": "string",
    "execute_before": "2022-04-13T15:42:05.901Z"
}

Responses

{
    "operation": {
        "href": "string",
        "id": "string",
        "state": "string"
    }
}
{
    "detail": [
        {
            "ctx": {},
            "input": null,
            "loc": [
                null
            ],
            "msg": "string",
            "type": "string"
        }
    ]
}

Schemas

Accepted

Name Type Description
operation OperationLink

HTTPValidationError

Name Type Description
detail Array<ValidationError>

ImageImportBody

Name Type Description
architecture string | null
disk_format string
display_name string
execute_before string(date-time) | null
location string
min_disk_gb integer
min_ram_mb integer
os_distro string | null
os_version string | null
source_url string The image file's https address, readable without a password: no query or fragment, so an address that carries a signature or token is refused (NubeStack Cloud does not keep secrets in commands).
Name Type Description
href string Where to read the operation; also the Location header.
id string The operation's ID (op_…).
state string | null Its state when accepted, normally queued.

UpdateBody

Name Type Description
description string | null
display_name string
execute_before string(date-time) | null

ValidationError

Name Type Description
ctx
input
loc Array<>
msg string
type string