Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

[skip ci] Release new versions

github-actions[bot]9d19e2d7c428
diff --git a/.changeset/strict-paths-kiss.md b/.changeset/strict-paths-kiss.md
deleted file mode 100644
index 01c7c72ba..000000000
--- a/.changeset/strict-paths-kiss.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@e2b/cli': minor
----
-
-Implement closeStdin to allow piping commands into the CLI
diff --git a/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/auth/page.mdx b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/auth/page.mdx
new file mode 100644
index 000000000..2c82afa69
--- /dev/null
+++ b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/auth/page.mdx
@@ -0,0 +1,58 @@
+## e2b auth
+
+
+authentication commands
+
+### Usage
+
+```bash
+e2b auth [options] [command]
+```
+## e2b auth login
+
+
+log in to CLI
+
+### Usage
+
+```bash
+e2b auth login [options]
+```
+
+
+## e2b auth logout
+
+
+log out of CLI
+
+### Usage
+
+```bash
+e2b auth logout [options]
+```
+
+
+## e2b auth info
+
+
+get information about the current user
+
+### Usage
+
+```bash
+e2b auth info [options]
+```
+
+
+## e2b auth configure
+
+
+configure user
+
+### Usage
+
+```bash
+e2b auth configure [options]
+```
+
+
diff --git a/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/sandbox/page.mdx b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/sandbox/page.mdx
new file mode 100644
index 000000000..39a3014d7
--- /dev/null
+++ b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/sandbox/page.mdx
@@ -0,0 +1,155 @@
+## e2b sandbox
+
+
+work with sandboxes
+
+### Usage
+
+```bash
+e2b sandbox [options] [command]
+```
+## e2b sandbox connect
+
+
+connect terminal to already running sandbox
+
+### Usage
+
+```bash
+e2b sandbox connect [options] <sandboxID>
+```
+
+
+## e2b sandbox list
+
+
+list all sandboxes, by default it list only running ones
+
+### Usage
+
+```bash
+e2b sandbox list [options]
+```
+
+### Options
+
+
+ - `-s, --state <state>: filter by state, eg. running, paused. Defaults to running `
+ - `-m, --metadata <metadata>: filter by metadata, eg. key1=value1 `
+ - `-l, --limit <limit>: limit the number of sandboxes returned `
+ - `-f, --format <format>: output format, eg. json, pretty `
+
+
+## e2b sandbox kill
+
+
+kill sandbox
+
+### Usage
+
+```bash
+e2b sandbox kill [options] [sandboxIDs...]
+```
+
+### Options
+
+
+ - `-a, --all: kill all sandboxes `
+ - `-s, --state <state>: when used with -a/--all flag, filter by state, eg. running, paused. Defaults to running `
+ - `-m, --metadata <metadata>: when used with -a/--all flag, filter by metadata, eg. key1=value1 `
+
+
+## e2b sandbox create
+
+
+create sandbox and connect terminal to it
+
+### Usage
+
+```bash
+e2b sandbox create [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+
+
+## e2b sandbox spawn
+
+
+create sandbox and connect terminal to it
+
+### Usage
+
+```bash
+e2b sandbox spawn [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+
+
+## e2b sandbox logs
+
+
+show logs for sandbox
+
+### Usage
+
+```bash
+e2b sandbox logs [options] <sandboxID>
+```
+
+### Options
+
+
+ - `--level <level>: filter logs by level (DEBUG, INFO, WARN, ERROR). The logs with the higher levels will be also shown. [default: INFO]`
+ - `-f, --follow: keep streaming logs until the sandbox is closed `
+ - `--format <format>: specify format for printing logs (json, pretty) [default: pretty]`
+ - `--loggers [loggers]: filter logs by loggers. Specify multiple loggers by separating them with a comma. `
+
+
+## e2b sandbox metrics
+
+
+show metrics for sandbox
+
+### Usage
+
+```bash
+e2b sandbox metrics [options] <sandboxID>
+```
+
+### Options
+
+
+ - `-f, --follow: keep streaming metrics until the sandbox is closed `
+ - `--format <format>: specify format for printing metrics (json, pretty) [default: pretty]`
+
+
+## e2b sandbox exec
+
+
+execute a command in a running sandbox
+
+### Usage
+
+```bash
+e2b sandbox exec [options] <sandboxID> <command...>
+```
+
+### Options
+
+
+ - `-b, --background: run in background and return immediately `
+ - `-c, --cwd <dir>: working directory `
+ - `-u, --user <user>: run as specified user `
+ - `-e, --env <KEY=VALUE>: set environment variable (repeatable) [default: [object Object]]`
+
+
diff --git a/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/template/page.mdx b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/template/page.mdx
new file mode 100644
index 000000000..ec92020ed
--- /dev/null
+++ b/apps/web/src/app/(docs)/docs/sdk-reference/cli/v2.7.0/template/page.mdx
@@ -0,0 +1,180 @@
+## e2b template
+
+
+manage sandbox templates
+
+### Usage
+
+```bash
+e2b template [options] [command]
+```
+## e2b template create
+
+
+build Dockerfile as a Sandbox template. This command reads a Dockerfile and builds it directly.
+
+### Usage
+
+```bash
+e2b template create [options] <template-name>
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `-d, --dockerfile <file>: specify path to Dockerfile. By default E2B tries to find e2b.Dockerfile or Dockerfile in root directory. `
+ - `-c, --cmd <start-command>: specify command that will be executed when the sandbox is started. `
+ - `--ready-cmd <ready-command>: specify command that will need to exit 0 for the template to be ready. `
+ - `--cpu-count <cpu-count>: specify the number of CPUs that will be used to run the sandbox. The default value is 2. `
+ - `--memory-mb <memory-mb>: specify the amount of memory in megabytes that will be used to run the sandbox. Must be an even number. The default value is 512. `
+ - `--no-cache: skip cache when building the template. `
+
+
+## e2b template build
+
+
+build sandbox template defined by ./e2b.Dockerfile or ./Dockerfile in root directory. By default the root directory is the current working directory. This command also creates e2b.toml config.
+
+### Usage
+
+```bash
+e2b template build [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `-d, --dockerfile <file>: specify path to Dockerfile. By default E2B tries to find e2b.Dockerfile or Dockerfile in root directory. `
+ - `-n, --name <template-name>: specify sandbox template name. You can use the template name to start the sandbox with SDK. The template name must be lowercase and contain only letters, numbers, dashes and underscores. `
+ - `-c, --cmd <start-command>: specify command that will be executed when the sandbox is started. `
+ - `--ready-cmd <ready-command>: specify command that will need to exit 0 for the template to be ready. `
+ - `-t, --team <team-id>: specify the team ID that the operation will be associated with. You can find team ID in the team settings in the E2B dashboard (https://e2b.dev/dashboard?tab=team). `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+ - `--cpu-count <cpu-count>: specify the number of CPUs that will be used to run the sandbox. The default value is 2. `
+ - `--memory-mb <memory-mb>: specify the amount of memory in megabytes that will be used to run the sandbox. Must be an even number. The default value is 512. `
+ - `--build-arg <args...>: specify additional build arguments for the build command. The format should be <varname>=<value>. `
+ - `--no-cache: skip cache when building the template. `
+
+
+## e2b template list
+
+
+list sandbox templates
+
+### Usage
+
+```bash
+e2b template list [options]
+```
+
+### Options
+
+
+ - `-t, --team <team-id>: specify the team ID that the operation will be associated with. You can find team ID in the team settings in the E2B dashboard (https://e2b.dev/dashboard?tab=team). `
+ - `-f, --format <format>: output format, eg. json, pretty `
+
+
+## e2b template init
+
+
+initialize a new sandbox template using the SDK
+
+### Usage
+
+```bash
+e2b template init [options]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `-n, --name <name>: template name (alias) `
+ - `-l, --language <language>: target language: typescript, python-sync, python-async `
+
+
+## e2b template delete
+
+
+delete sandbox template and e2b.toml config
+
+### Usage
+
+```bash
+e2b template delete [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+ - `-s, --select: select sandbox template from interactive list `
+ - `-t, --team <team-id>: specify the team ID that the operation will be associated with. You can find team ID in the team settings in the E2B dashboard (https://e2b.dev/dashboard?tab=team). `
+ - `-y, --yes: skip manual delete confirmation `
+
+
+## e2b template publish
+
+
+publish sandbox template
+
+### Usage
+
+```bash
+e2b template publish [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+ - `-s, --select: select sandbox template from interactive list `
+ - `-t, --team <team-id>: specify the team ID that the operation will be associated with. You can find team ID in the team settings in the E2B dashboard (https://e2b.dev/dashboard?tab=team). `
+ - `-y, --yes: skip manual publish confirmation `
+
+
+## e2b template unpublish
+
+
+unpublish sandbox template
+
+### Usage
+
+```bash
+e2b template unpublish [options] [template]
+```
+
+### Options
+
+
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+ - `-s, --select: select sandbox template from interactive list `
+ - `-t, --team <team-id>: specify the team ID that the operation will be associated with. You can find team ID in the team settings in the E2B dashboard (https://e2b.dev/dashboard?tab=team). `
+ - `-y, --yes: skip manual unpublish confirmation `
+
+
+## e2b template migrate
+
+
+migrate e2b.Dockerfile and e2b.toml to new Template SDK format
+
+### Usage
+
+```bash
+e2b template migrate [options]
+```
+
+### Options
+
+
+ - `-d, --dockerfile <file>: specify path to Dockerfile. Defaults to e2b.Dockerfile `
+ - `--config <e2b-toml>: specify path to the E2B config toml. By default E2B tries to find ./e2b.toml in root directory. We recommend using the new build system (https://e2b.dev/docs/template/defining-template) that does not use config files. `
+ - `-l, --language <language>: specify target language: typescript, python-sync, python-async `
+ - `-p, --path <path>: change root directory where command is executed to <path> directory `
+
+
diff --git a/apps/web/src/app/(docs)/docs/sdk-reference/js-sdk/v2.12.1/commands/page.mdx b/apps/web/src/app/(docs)/docs/sdk-reference/js-sdk/v2.12.1/commands/page.mdx
index 6187a90f2..6e72fb6c6 100644
--- a/apps/web/src/app/(docs)/docs/sdk-reference/js-sdk/v2.12.1/commands/page.mdx
+++ b/apps/web/src/app/(docs)/docs/sdk-reference/js-sdk/v2.12.1/commands/page.mdx
@@ -161,7 +161,7 @@ Either a `CommandHandle` or a `CommandResult` (depending on `opts.background`).
```ts
sendStdin(
pid: number,
- data: string,
+ data: string | Uint8Array,
opts?: CommandRequestOpts): Promise<void>
```
@@ -172,7 +172,7 @@ Send data to command stdin.
| Parameter | Type | Description |
| ------ | ------ | ------ |
| `pid` | `number` | process ID of the command. You can get the list of running commands using Commands.list. |
-| `data` | `string` | data to send to the command. |
+| `data` | `string` \| `Uint8Array` | data to send to the command. |
| `opts`? | `CommandRequestOpts` | connection options. |
###### Returns
diff --git a/packages/cli/package.json b/packages/cli/package.json
index 126033aa1..edf669e4d 100644
--- a/packages/cli/package.json
+++ b/packages/cli/package.json
@@ -1,6 +1,6 @@
{
"name": "@e2b/cli",
- "version": "2.6.1",
+ "version": "2.7.0",
"description": "CLI for managing e2b sandbox templates",
"homepage": "https://e2b.dev",
"license": "MIT",