Skip to main content
POST
Error

Authorizations

Authorization
string
header
required

IAM bearer token issued by the Nebius IAM service. Sent as Authorization: Bearer <iam-token>. Must be combined with the Project header (see IAMProjectHeader).

This is the recommended authentication scheme for new clients.

Project
string
header
required

Nebius project ID associated with the IAM token. Required together with IAMBearerAuth. Identifies the project context the request is scoped to.

Body

application/json
command
string
required

The command to execute. In case if shell is set to true, this MUST contain shell expression. For example echo hello world or ls -l /app. If shell is set to false, this must be a relative or absolute path to the executable inside the image rootfs. For example: /bin/app or /usr/bin/find. Do not forget pass necessary PATH variable to env field, by default PATH is set to /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin.

Example:

"/bin/app"

image
required

An base image for run a new instance. May be either image UUID or image tag (prefixed with "tag:"). After creation of the instance, if tag is used, this value will be resolved to the image UUID, and the UUID will be stored in the metadata.

Example:

"tag:busybox:latest"

disposable
boolean
default:false

Creates a disposable execution environment no any state will be saved.

hostname
string
default:linuxkit

Hostname to set when execution.

Example:

"container-name"

args
string[]

Arguments to pass to the command if shell is set to false.

Example:
shell
boolean
default:false

Whether to run the command through a shell. If true, the command must be a shell expression and all values from args will be ignored. If false, the command field must be a path to an executable and args will be used. When true, environment variables from the image are automatically inherited. When false, they are not - use the env field to pass them explicitly.

env
object | null

Environment variables to set in the container. These are merged with image-defined variables when shell is true. When shell is false, only variables specified here are available - image-defined variables are not inherited.

Example:
preserve_env
boolean
default:false

Preserve environment variables in resulting image after execution. When true, the image's existing environment variables from metadata/env are merged with user-provided env values (user values take priority on conflicts), and the combined result is written back to metadata/env after command execution. Setting a variable to an empty string or null removes it from the preserved environment.

cwd
string
default:""

Path to the working directory, must be absolute or a special value the empty string. It means the default working directory of the image or server default will be used. If field is omitted it will be set to the empty string. The directory will be created automatically if it does not exist.

Pattern: ^((/[^/]*)+/?)?$
Example:

"/app"

uid
integer
default:0

User ID to run the process as.

Required range: x >= 0
Example:

0

gid
integer
default:0

Group ID to run the process as.

Required range: x >= 0
Example:

0

resources_limits
object
stdin
object
timeout
integer

Maximum execution time in seconds

Example:

60

truncate_output_at
integer
default:1048576

Maximum number of bytes to keep from stdout/stderr. Default is 1048576 (1 MiB). The maximum value is 10485760 (10 MiB).

Example:

65535

files
object

Map of absolute file paths to file metadata

Example:

Response

Created - The instance has been successfully created and its execution has been queued. When operation created successfully, the response will contain Location header with URL to check the operation status. and the body will contain the parsed request body with additional uuid field.

uuid
string<uuid>

A UUID string

Example:

"12345678-9abc-baba-deda-0123456789ab"

command
string
image
string<uuid>

A UUID string

Example:

"12345678-9abc-baba-deda-0123456789ab"

hostname
string
args
string[]
shell
boolean
env
object | null
preserve_env
boolean
cwd
string
uid
integer
gid
integer
resources_limits
object
stdin
object
timeout
integer
truncate_output_at
integer
disposable
boolean
files
object
result
object | null

Result of an instance execution