# CLI deployment workflow

Initialize, validate, deploy, and smoke test an agent source project.

The Salambo CLI is the primary source-deployment interface.

## Primary commands

```bash
salambo init <name>
salambo auth set --api-url <url>
salambo auth set --key <api-key>
salambo auth status
salambo auth whoami
salambo doctor
salambo manifest --path . --json
salambo deploy
salambo smoke "Say hello"
```

## Workflow

```mermaid
flowchart LR
  Init["init"] --> Edit["Edit agent source"]
  Edit --> Doctor["doctor"]
  Doctor --> Manifest["manifest"]
  Manifest --> Deploy["deploy"]
  Deploy --> Smoke["smoke"]
```

### Initialize

```bash
salambo init support-agent
cd support-agent
```

### Authenticate

```bash
salambo auth set --api-url https://YOUR_SALAMBO_HOST
salambo auth set --key "$SALAMBO_API_KEY"
salambo auth whoami
```

### Validate

```bash
salambo doctor
salambo manifest --path . --json
```

`doctor` is read-only. It checks project configuration, the managed runtime contract, compiled agent resources, managed packages, the selected profile, and required secret environment variables. It does not require Docker or Compose.

`manifest` compiles agent settings, instructions, skills, prompts, active tools and hosted extensions without uploading source.

### Deploy

```bash
salambo deploy
```

The CLI packages the source, excludes generated dependency directories, uploads the compiled manifest, creates an immutable deployment record and verifies the source archive hash.

The hosted deployment worker prepares the managed runtime and activates the immutable deployment.

### Smoke test

```bash
salambo smoke "Return the active tools and create a small workspace file."
```

Smoke testing calls the deployed Native Runs API. It does not simulate the
hosted runtime locally.
