> For the complete documentation index, see [llms.txt](https://thegrid.ai/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://thegrid.ai/docs/integrations-and-best-practices/integrations/agentsea.md).

# AgentSea | Launch AI agents wired to The Grid

[AgentSea](https://agentsea.thegrid.ai) is a command-line launcher for popular open-source AI agents. One command installs the agent and its dependencies, authenticates with your Grid key, wires the OpenAI-compatible endpoints and model routing, and drops you into the running agent. You can run it on your own machine or on a fresh cloud VM that AgentSea provisions for you.

If you would rather configure an agent by hand, the per-tool guides in [Integrations](/docs/integrations-and-best-practices/integrations.md) still apply. AgentSea is the fast path to the same result.

## Supported agents

Live today: OpenClaw, Hermes Agent, Kilo Code, Claude Code, OpenCode.

Coming soon: Codex CLI, Cursor CLI, Pi, T3 Code, Junie.

Each agent is verified against The Grid on the target environment before launch. For agent-specific configuration detail, see its dedicated guide, for example [OpenClaw](/docs/integrations-and-best-practices/integrations/openclaw.md) or [Hermes Agent](/docs/integrations-and-best-practices/integrations/hermes-agent.md).

## Prerequisites

* macOS, Linux, or WSL with `bash`, `curl`, `ssh`, and `jq` available.
* A Grid account at [app.thegrid.ai](https://app.thegrid.ai) with a usable consumption balance. The Grid is prepaid; zero credits returns 402.
* A Grid consumption API key from **Settings → API Keys**. Use a consumption key, not a trading key. Trading keys do not authorize inference.
* For cloud launches: an account with a supported provider (DigitalOcean, Hetzner, AWS, GCP) and its credentials available locally.

## Install

Run the installer in a terminal:

```bash
curl -fsSL https://agentsea.thegrid.ai/install.sh | bash
```

When it finishes, the `agentsea` command is on your path. The first launch prompts for your Grid API key and saves it under `~/.config/agentsea/`.

## Launch an agent

{% tabs %}
{% tab title="Local machine" %}
No cloud account needed. AgentSea installs the agent and its dependencies directly on your computer.

```bash
agentsea openclaw
```

AgentSea installs the agent, prompts for your Grid key on first run, sets the environment variables, Grid API endpoints, and model routing, then launches the agent in your terminal with full TTY support.
{% endtab %}

{% tab title="Cloud VM" %}
On each cloud launch, AgentSea provisions a fresh VM in your cloud account and installs the agent via cloud-init. No Terraform or YAML configs to write.

The flow: provision the VM, install the agent and dependencies, inject your Grid key and cloud credentials, configure the OpenAI-compatible endpoints and routing, then open an SSH session so you can drive the agent from your terminal. The VM inherits `THEGRID_API_KEY` and base URLs targeting the Grid API.
{% endtab %}
{% endtabs %}

{% hint style="info" %}
For the exact command flags, provider selection, and per-agent options, see the CLI Reference at [agentsea.thegrid.ai](https://agentsea.thegrid.ai).
{% endhint %}

## Manage deployments

```bash
agentsea ls
```

Lists your deployments. For agents that ship a web UI, such as Hermes Agent and OpenClaw, use **Open Dashboard** from the listing.

## Model routing

AgentSea wires each agent to The Grid's instruments automatically, so you do not pick a vendor model. If you want to pin or change the instrument an agent uses, follow that agent's dedicated integration guide and the [current instruments list](/docs/instrument-specifications/current-instruments.md).

## Verification

Send a prompt in the launched agent. A normal completion confirms end-to-end routing through The Grid. If the call fails, check the troubleshooting items below.

## Troubleshooting

{% hint style="warning" %}
**401 Unauthorized.** The saved key is a Grid trading key, not a consumption key. Re-run authentication and paste a consumption key from **Settings → API Keys**.
{% endhint %}

{% hint style="warning" %}
**402 Payment Required.** Your credits are at zero. Top up at [app.thegrid.ai](https://app.thegrid.ai).
{% endhint %}

{% hint style="info" %}
**`agentsea: command not found`.** The installer did not finish, or your shell has not reloaded. Confirm `bash`, `curl`, `ssh`, and `jq` are installed, re-run the install command, then open a new terminal.
{% endhint %}

{% hint style="info" %}
**Cloud provisioning fails.** AgentSea could not reach your cloud provider. Confirm the provider is supported (DigitalOcean, Hetzner, AWS, GCP) and that its credentials are available in your local environment.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://thegrid.ai/docs/integrations-and-best-practices/integrations/agentsea.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
