- You want agent commands to run in an isolated VM per machine, in an account you control and can audit.
- Your agents need a toolchain that you would rather build into a template once than install on every run.
- You want a per-connection network log and an egress allowlist for the machines your agents use.
How it works
- Omnara runs the agent and decides when it needs a machine. It reads the pool’s Superserve API key from an Omnara secret and calls the Superserve API to create and delete sandboxes. The key stays in Omnara and never enters a sandbox.
- You create the pool, choose the template, and set the size and capacity limits. You grant the pool to a project, and agents in that project use it through
machine_sources. - Superserve runs the machines. Each pool machine is one sandbox named
omnara-mch-..., tagged withomnara-installationandomnara-machinemetadata. Omnara starts theomnaraddaemon in the sandbox, and the daemon connects out to Omnara over HTTPS. Omnara sends the agent’s commands over that connection.
Prerequisites
- A Superserve account and API key
- An Omnara account on app.omnara.com, or a self-hosted Omnara installation
- Node.js 22+ for the Omnara CLI (
npx omnara) - A model your Omnara project can use. See Omnara’s model providers.
1
Create a Superserve API key
In the console, open Settings → API keys and click Create key. Export it in the shell where you run the Omnara CLI:Omnara selects the Superserve region from the key prefix, so no API URL is needed.
2
Log in to Omnara
npx omnara login --no-browser, then open the printed approval page on another device. For scripts and CI, set OMNARA_API_KEY to an Omnara API key instead of logging in.Check the session, then point the CLI at your organization and project:--org and --project to each command, or save defaults with npx omnara config.3
Store the key as an Omnara secret
Pools belong to the organization, so store the key as an organization secret:Note the secret id (
sec_...) in the output. The pool uses it to authenticate to Superserve.4
Choose a template
A template sets each machine’s vCPU, memory, and disk. Omnara cannot override them per machine.
The template must have the status
ready before a pool can use it. See System templates for the full contents of each template.5
Create the pool
'"superserve"'. The per-machine maximums must be at least the template’s size: 2 vCPU and 4096 MiB for the system templates. The --max-total-* flags cap the whole pool. Note the pool id (mpo_...) in the output.See Omnara’s Superserve provider page for startup_script, allowed_templates, and other fields.To use the dashboard instead, open Machines, click New pool, and choose Superserve.6
Grant the pool to a project
npx omnara grant pools add --help for the overlay flags.7
Launch an agent
Save an agent config that uses the pool as a machine source:Launch it with a first message:The agent creates a machine from the pool and runs the commands on it. Machine creation takes a few seconds, and the agent waits for the machine to come online before its first command. Note the agent id (
agent.yaml
agt_...) in the output.To follow the run, read the agent’s event log, or send another message to the same agent:Find the sandbox
A sandbox namedomnara-mch-... appears in the console while Omnara provisions the machine. Its hostname is sandbox- followed by the first part of the sandbox id, so uname -a from the agent tells you which sandbox ran the command. Open the sandbox terminal to inspect the machine. The daemon binary is at /home/user/.omnarad/bin/omnarad.
The omnara-machine tag holds the Omnara machine id (mch_...). Run npx omnara machines list to get it, then find the sandbox from code:
Pause and resume a machine
Omnara does not pause or resume Superserve sandboxes. When a pool machine’s sandbox is paused, for example from the console or the SDK, the daemon stops. About two minutes later, when the daemon’s lease expires, Omnara marks the machineoffline with the reason daemon_lease_expired. Commands for that machine then fail with machine_id_unavailable, and the sandbox stays paused.
Resume the sandbox to bring the machine back:
online again. The agent continues on the same machine. The workspace and background processes are restored from the checkpoint as the agent left them. See Pause, resume, and delete.
Lock down egress
Omnara creates pool sandboxes with open egress: they can reach any public IP. To restrict a machine, update the network rules on its sandbox while it isactive. The machine needs outbound HTTPS to:
- The Omnara API:
api.omnara.comfor app.omnara.com, or your installation’s public API host if you self-host - The DNS resolvers
1.1.1.1/32and8.8.8.8/32, without which nothing resolves - The git hosts, package registries, and internal services the agent’s work needs
The rules belong to one sandbox. Omnara does not set network rules when it
creates a machine, so apply them to each new machine the pool creates. At
boot, before you can apply rules, the daemon downloads its binary from
Omnara’s release host,
releases.omnara.com on app.omnara.com.Credentials for agent commands
Omnara does not bind Superserve secrets when it creates a machine, and a secret attached later reaches only processes started after the attach call, not the daemon that runs the agent’s commands. To give the agent’s commands a credential, such as aGH_TOKEN for gh and git, use Omnara’s secret environment variables: --default-machine-secret-env on the pool, --default-machine-secret-env-overlay on the grant, or secret_env_overlay in the agent config. See Omnara’s agent configuration. Omnara resolves the value into the machine’s environment, so any process on the machine can read it. Scope these tokens to what the agent needs.
Archive the agent
404, and npx omnara machines list no longer shows the machine.
Clean up
Delete the pool before the secret it uses. Deleting the pool also removes its project grants. Omnara rejects the secret deletion witherror: API 409 [conflict]: conflict while a pool still references it.
Troubleshooting
The first command fails with no_active_agent_machine_binding
The first command fails with no_active_agent_machine_binding
The sandbox is up, but the daemon has not connected to Omnara yet. The agent retries on its own. If the error continues, open the sandbox terminal and check that the machine can reach the Omnara API host and the daemon download host.
The pool cannot create machines: template not found or not ready
The pool cannot create machines: template not found or not ready
Omnara reports
superserve template "<name>" was not found or is not ready. Check the template name and its status in the console. A team template must belong to the same team as the API key.pools create fails with a JSON or validation error
pools create fails with a JSON or validation error
--provider superserve fails with expects valid JSON; pass --provider '"superserve"'. Leaving out --default-machine-provider-options gives expected record, received undefined, and leaving out --max-total-machines gives expected number. Pass both, as in the pool step.agents launch fails with does not have an active project grant
agents launch fails with does not have an active project grant
The model in the config is not granted to the project. Grant it with
npx omnara grant models add --configured-model-id <model-id>, or pick a model the project already has.Sandboxes stay in the console after the agents are gone
Sandboxes stay in the console after the agents are gone
Archive the agents that own them. Every pool sandbox carries
omnara-machine metadata, so filter Sandbox.list() by it to find them.Resources
Omnara Superserve provider
Pool fields, provider options, and template allowlists.
Omnara machine pools
Pools, grants, and how machine settings combine.
Templates
Build reusable images with your toolchains built in.
Pause, resume, and delete
Checkpoint a sandbox and restore it on demand.
Network rules
Allow and deny outbound traffic per sandbox.
Network log
HTTP and HTTPS connections on ports 80 and 443, allowed or blocked.