Skip to Content
kosemdocs
ReferenceAPIEnvironments

Get built in image

Gets a built-in image, its preparation state and its versions. Built-in images are maintained by kosem and available to every project without counting against organization quotas.

GET
/v1/images/{image}

Gets a built-in image, its preparation state and its versions.

Built-in images are maintained by kosem and available to every project without counting against organization quotas.

Authorization

bearer
headerAuthorizationBearer <token>

An access token, or an API key.

Path Parameters

image*string

The built-in image's ID, such as python or node.

Match^[a-z][a-z0-9-]{0,31}$

Query Parameters

parent?string

Optional organization or project resource name (organizations/{organization_id} or projects/{project_id}) to count environments running each version within that scope. Requires environments.images.get on the parent.

Response Body

OK

application/json
  1. response
availability*

For an organization's image: the projects whose environments use it. Project and built-in images leave this empty.

builtIn?boolean

Whether kosem manages and prepares this image for every project without counting against organization quotas.

checkTime?string

When kosem last resolved its source; unset until it has.

Formatdate-time
createTime?string

When the image was created; unset on built-in images until kosem checks them.

Formatdate-time
description?string

Short summary of what the image contains, set on built-in images.

displayName*string

What people call the image.

followTag*boolean

Whether kosem resolves its tag again every hour, as RefreshImage does, so that it prepares each new version. A source named by a digest never moves.

keepVersions*integer

Maximum number of recent versions retained. Older versions are deleted once no environment uses them.

Formatint32
name*string

Resource name: organizations/{organization_id}/images/{image_id}, projects/{project_id}/images/{image_id} or images/{image_id} for built-in images.

refreshReason*string

Why kosem's last check of its tag couldn't refresh it, which leaves it as it was; empty once a check can.

registry?string

The registry that kosem signs in with to pull it, when it's private.

source*string

The image's reference, with a tag or a digest, in its shortest spelling, such as node:24 for docker.io/library/node:24. Set when the image is created, and never changed.

state?string

PREPARING until its latest version is ready to run, READY once it is, and FAILED if kosem can't prepare it. Unset on built-in images until kosem checks them or when kosem doesn't prepare them.

Value in"PREPARING""READY""FAILED"
stateReason*string

Why kosem can't prepare it, when it can't.

updateTime?string

When the image last changed; unset on built-in images until kosem checks them.

Formatdate-time
user?string

Default non-root user commands run as inside the image, such as vscode or node. Set on built-in images.

versions*array<>

What its source named each time it was resolved, newest first.

Example Request
curl -X GET 'https://api.kosem.ai/v1/images/string'
Example Response
{
  "availability": {
    "allProjects": true,
    "projects": [
      "string"
    ]
  },
  "builtIn": true,
  "checkTime": "2019-08-24T14:15:22Z",
  "createTime": "2019-08-24T14:15:22Z",
  "description": "string",
  "displayName": "string",
  "followTag": true,
  "keepVersions": 0,
  "name": "string",
  "refreshReason": "string",
  "registry": "string",
  "source": "string",
  "state": "PREPARING",
  "stateReason": "string",
  "updateTime": "2019-08-24T14:15:22Z",
  "user": "string",
  "versions": [
    {
      "arches": [
        "string"
      ],
      "createTime": "2019-08-24T14:15:22Z",
      "digest": "string",
      "environments": 0,
      "prepareTime": "2019-08-24T14:15:22Z",
      "sizeBytes": 0
    }
  ]
}