> ## Documentation Index
> Fetch the complete documentation index at: https://docs.beam.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Install the Beam CLI, sign in, and connect coding agents to the Beam MCP server with `curl -fsSL https://www.beam.cloud/install | sh`. To also create a VM, run `curl -fsSL https://www.beam.cloud/install | sh -s -- --vm`.
> VMs are persistent Linux machines without GPUs. Defaults: 4 CPUs, 8 GiB of RAM, a 50 GiB disk, Ubuntu 24.04, and a browser desktop. A running VM accrues usage until you stop, pause, or remove it, or until an idle timeout puts it to sleep.
> Stopping a VM keeps its disk and discards RAM and processes. Pausing keeps both, and resuming restores them. To pause after 5 idle minutes and wake on access, run `beam vm update NAME --ttl 300 --idle-action pause --auto-resume`.
> Core VM commands: `beam vm new NAME`, `beam vm ssh NAME`, `beam vm sync NAME ./dir`, `beam vm exec NAME -- CMD`, `beam vm expose NAME PORT --protected`, `beam vm fork NAME NEW_NAME`, `beam vm pause NAME`, `beam vm stop NAME`, `beam vm rm NAME`.
> For GPUs, use a sandbox or a deployed endpoint. Sandboxes are disposable environments that boot in seconds and fork from snapshots.
> Current rates are at https://www.beam.cloud/pricing.

# Deployment Lifecycle

> Inspect revisions, wait for endpoints, choose rollouts, and roll back

Each deployment creates a version of your app with its own ID. An active version can scale to zero while idle.

## Inspect and Wait

```bash theme={null}
beam deployment list
beam status
beam deployment wait YOUR_DEPLOYMENT_ID --timeout 300
```

`wait` checks that the deployed `endpoint` or `asgi` version is healthy. For other workloads, it waits for active status; check your app's health URL separately.

Add `--json` to `beam deploy` for deployment details in JSON.

## Rollout Strategies

```bash theme={null}
beam deploy app.py:handler --rollout auto
beam deploy app.py:handler --rollout blue-green
beam deploy app.py:handler --rollout replace
```

| Strategy | Behavior |
| - | - |
| `auto` | Default behavior; older always-on versions may keep running. |
| `blue-green` | Starts the new version alongside the old one. Requires spare capacity. |
| `replace` | Stops the old version first. Can cause downtime. |

Writable disks require replacement. Redeploying a scheduled job stops its previous schedule. Use `beam deployment list` to find and stop older versions you no longer need.

## Stop, Start, or Delete

```bash theme={null}
beam deployment stop YOUR_DEPLOYMENT_ID
beam deployment start YOUR_DEPLOYMENT_ID
beam deployment delete YOUR_DEPLOYMENT_ID
```

Stop a version to shut down its containers; start it to reactivate it. Delete it to remove the deployment record.

## Restart or Roll Back Through MCP

The MCP `redeploy` tool creates a version from existing code and configuration. Pass `name` to restart the active version, or an older `deployment_id` to roll back.

Changing resources or environment variables also deploys a new version. Update your source to preserve those changes on future CLI deploys.

See [versioned URLs](https://docs.beam.cloud/v2/endpoint/versioning.md), [logs and metrics](https://docs.beam.cloud/v2/operations/observability.md), and [container scaling](https://docs.beam.cloud/v2/hosting/containers.md#scaling-and-idle-time).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.