Remote Environments
Manage named Letta server connections — like git remotes for your agent infrastructure.
remote add
Register a named Letta server. The first remote added is automatically activated.
lettactl remote add <name> <url> [options]Options
| Flag | Type | Description |
|---|---|---|
| --api-key | string | API key for authentication (required for Letta Cloud) |
Examples
lettactl remote add local http://localhost:8283lettactl remote add production https://api.letta.com --api-key sk-xxxlettactl remote add staging https://staging.example.com --api-key sk-stg-xxxNotes
The first remote added is auto-activated.
Remote configs are stored in ~/.lettactl/remotes.json.
remote remove
Remove a named remote. If the active remote is removed, the first remaining remote becomes active.
lettactl remote remove <name>Examples
lettactl remote remove stagingremote use
Set the active remote. All subsequent commands will target this server.
lettactl remote use <name>Examples
lettactl remote use productionlettactl remote use staging && eval $(lettactl remote env)Notes
The active remote is loaded automatically on every CLI invocation.
Explicit LETTA_BASE_URL environment variable always takes precedence over the active remote.
remote list
List all configured remotes. The active remote is marked with an asterisk (*).
lettactl remote listExamples
lettactl remote listremote show
Show details of a specific remote including URL and API key status.
lettactl remote show <name>Examples
lettactl remote show productionremote env
Output shell export statements for the active remote. Use with eval to apply to current session.
lettactl remote envExamples
eval $(lettactl remote env)eval $(lettactl remote env 2>/dev/null)Notes
Outputs to stdout for use with eval. Errors go to stderr.
Useful for CI/CD scripts that need environment variables set.