Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
/**
* This file was auto-generated by openapi-typescript.
* Do not make direct changes to the file.
*/
export interface paths {
"/envs": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
/** Environment variables */
get: {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
requestBody?: never;
responses: {
/** @description Environment variables */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": components["schemas"]["EnvVars"];
};
};
};
};
put?: never;
post?: never;
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/files": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
/** Download a file */
get: {
parameters: {
query?: {
/** @description Path to the file, URL encoded. Can be relative to the user's home directory (e.g. "file.txt" resolves to ~/file.txt). */
path?: components["parameters"]["FilePath"];
/** @description Signature used for file access permission verification. */
signature?: components["parameters"]["Signature"];
/** @description Unix timestamp (seconds) after which the signature expires. Only used with the signature parameter. */
signature_expiration?: components["parameters"]["SignatureExpiration"];
/** @description User for setting file ownership and resolving relative paths. Defaults to the sandbox's default user. */
username?: components["parameters"]["User"];
};
header?: never;
path?: never;
cookie?: never;
};
requestBody?: never;
responses: {
200: components["responses"]["DownloadSuccess"];
400: components["responses"]["InvalidPath"];
401: components["responses"]["InvalidUser"];
404: components["responses"]["FileNotFound"];
406: components["responses"]["NotAcceptable"];
500: components["responses"]["InternalServerError"];
};
};
put?: never;
/**
* Upload a file and ensure the parent directories exist. If the file exists, it will be overwritten.
* @description Any request header of the form `X-Metadata-<key>: <value>` is persisted
* as a user-defined extended attribute on the uploaded file. The
* `X-Metadata-` prefix is stripped and the remaining header name is
* lowercased to form the metadata key; the resulting map is returned on
* `EntryInfo` lookups (e.g. `Stat`, `ListDir`).
*
* Each upload replaces the file's metadata with the keys provided in
* that request: keys previously stored but absent from the new request
* are removed, and an upload that sends no `X-Metadata-*` header clears
* all existing metadata.
*
* Both keys and values must be printable US-ASCII (bytes `0x20`-`0x7E`)
* and are rejected with HTTP 400 otherwise. Each key is capped at 246
* bytes (the Linux VFS xattr-name limit minus the namespace prefix), and
* the combined size of all metadata on a file (keys plus values, with the
* namespace prefix counted per key) is capped at 4096 bytes to stay within
* the filesystem's per-inode xattr budget. Multiple files in a single
* multipart upload receive the same metadata. If the same
* `X-Metadata-<key>` header is sent more than once, only the first
* value is used.
*/
post: {
parameters: {
query?: {
/** @description Path to the file, URL encoded. Can be relative to the user's home directory (e.g. "file.txt" resolves to ~/file.txt). */
path?: components["parameters"]["FilePath"];
/** @description Signature used for file access permission verification. */
signature?: components["parameters"]["Signature"];
/** @description Unix timestamp (seconds) after which the signature expires. Only used with the signature parameter. */
signature_expiration?: components["parameters"]["SignatureExpiration"];
/** @description User for setting file ownership and resolving relative paths. Defaults to the sandbox's default user. */
username?: components["parameters"]["User"];
};
header?: never;
path?: never;
cookie?: never;
};
requestBody: components["requestBodies"]["File"];
responses: {
200: components["responses"]["UploadSuccess"];
400: components["responses"]["InvalidPath"];
401: components["responses"]["InvalidUser"];
500: components["responses"]["InternalServerError"];
507: components["responses"]["NotEnoughDiskSpace"];
};
};
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/files/compose": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
get?: never;
put?: never;
/** Compose multiple files into a single file using zero-copy concatenation. Source files are deleted after successful composition. */
post: {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
requestBody: {
content: {
"application/json": components["schemas"]["ComposeRequest"];
};
};
responses: {
/** @description Files composed successfully */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": components["schemas"]["EntryInfo"];
};
};
400: components["responses"]["InvalidPath"];
401: components["responses"]["InvalidUser"];
404: components["responses"]["FileNotFound"];
500: components["responses"]["InternalServerError"];
507: components["responses"]["NotEnoughDiskSpace"];
};
};
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/health": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
/** Check the health of the service */
get: {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
requestBody?: never;
responses: {
/** @description The service is healthy */
204: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
put?: never;
post?: never;
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/metrics": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
/** Service stats */
get: {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
requestBody?: never;
responses: {
/** @description The resource usage metrics of the service */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": components["schemas"]["Metrics"];
};
};
};
};
put?: never;
post?: never;
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
}
export type webhooks = Record<string, never>;
export interface components {
schemas: {
ComposeRequest: {
/** @description Destination file path for the composed file */
destination: string;
/** @description Ordered list of source file paths to concatenate */
source_paths: string[];
/** @description User for setting ownership and resolving relative paths */
username?: string;
};
EntryInfo: {
/** @description User-defined metadata stored as extended attributes on the file. */
metadata?: {
[key: string]: string;
};
/** @description Name of the file */
name: string;
/** @description Path to the file */
path: string;
/**
* @description Type of the file
* @enum {string}
*/
type: "file";
};
/** @description Environment variables to set */
EnvVars: {
[key: string]: string;
};
Error: {
/** @description Error code */
code: number;
/** @description Error message */
message: string;
};
/** @description Resource usage metrics */
Metrics: {
/** @description Number of CPU cores online */
cpu_count?: number;
/** @description Number of CPUs the guest can bring online */
cpu_possible?: number;
/** @description Online count last requested, 0 when none was */
cpu_target?: number;
/** @description Attempts at reaching cpu_target since it was set */
cpu_target_attempts?: number;
/**
* Format: float
* @description CPU usage percentage
*/
cpu_used_pct?: number;
/**
* Format: int64
* @description How long a CPU online or offline write has been running in the guest kernel, 0 when none is. A value that keeps growing means CPU hotplug is stuck.
*/
cpu_write_pending_ms?: number;
/** @description Total disk space in bytes */
disk_total?: number;
/** @description Used disk space in bytes */
disk_used?: number;
/** @description Cached memory (page cache) in bytes */
mem_cache?: number;
/** @description Total virtual memory in bytes */
mem_total?: number;
/** @description Used virtual memory in bytes */
mem_used?: number;
/** @description The latest 32 out-of-memory kills since the guest booted, oldest first. Reading does not consume them. Empty when there are none. Omitted when not known (while envd is still reading the kernel log, when it can't be read or envd stopped reading it, and outside Firecracker). */
oom_kills?: components["schemas"]["OOMKill"][];
/**
* Format: int64
* @description Unix timestamp in UTC for current sandbox time
*/
ts?: number;
};
/** @description A process the guest kernel killed for running out of memory */
OOMKill: {
/** @description Name of the killed process, or Unknown if the record doesn't show it */
process: string;
/**
* Format: int64
* @description Kernel log sequence number of the kill record. It only grows, across pauses and envd restarts.
*/
seq: number;
};
};
responses: {
/** @description Entire file downloaded successfully. */
DownloadSuccess: {
headers: {
[name: string]: unknown;
};
content: {
"application/octet-stream": string;
};
};
/** @description File not found */
FileNotFound: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "path '/home/user/missing.txt' does not exist",
* "code": 404
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description Internal server error */
InternalServerError: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "error opening file '/home/user/file.txt': permission denied",
* "code": 500
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description Invalid path */
InvalidPath: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "path '/home/user/docs' is a directory",
* "code": 400
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description Invalid user */
InvalidUser: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "error looking up user 'nonexistent': user: unknown user nonexistent",
* "code": 401
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description Requested encoding is not supported */
NotAcceptable: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "no acceptable encoding found, supported: [identity, gzip]",
* "code": 406
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description Not enough disk space */
NotEnoughDiskSpace: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example {
* "message": "not enough disk space available",
* "code": 507
* }
*/
"application/json": components["schemas"]["Error"];
};
};
/** @description The file was uploaded successfully. */
UploadSuccess: {
headers: {
[name: string]: unknown;
};
content: {
/**
* @example [
* {
* "path": "/home/user/hello.txt",
* "name": "hello.txt",
* "type": "file"
* }
* ]
*/
"application/json": components["schemas"]["EntryInfo"][];
};
};
};
parameters: {
/** @description Path to the file, URL encoded. Can be relative to the user's home directory (e.g. "file.txt" resolves to ~/file.txt). */
FilePath: string;
/** @description Signature used for file access permission verification. */
Signature: string;
/** @description Unix timestamp (seconds) after which the signature expires. Only used with the signature parameter. */
SignatureExpiration: number;
/** @description User for setting file ownership and resolving relative paths. Defaults to the sandbox's default user. */
User: string;
};
requestBodies: {
File: {
content: {
"application/octet-stream": string;
"multipart/form-data": {
/** Format: binary */
file?: string;
};
};
};
};
headers: never;
pathItems: never;
}
export type $defs = Record<string, never>;
export type operations = Record<string, never>;