---
title: From your agent
description: Run coding work in Polaris from Claude Code, Codex or another agent on your computer.
---

Your coding agent can use the Polaris CLI to start a Session in the cloud,
send follow-up messages and bring the result back. You can follow the same
Session in Polaris while the agent on your computer continues other work.

## Set it up

Install the CLI on your computer, sign in and install the Polaris skill:

```bash
curl -fsSL https://plrs.sh/install.sh | sh
polaris auth login
polaris skill install
```

Sign-in opens your browser for confirmation. A sign-in acts as you: the agent
can start and stop Sessions, send messages, read work and manage variables
with your access. Only connect agents you trust with that access.

Interactive sign-in offers to install the skill. You can also install it
separately: the CLI finds existing Claude Code and Codex configuration
folders. Use `--agent claude` or `--agent codex` to choose one. The skill
teaches that agent the available commands and what to do next.

The `polaris` command on a Machine is a different tool. These instructions
are for the CLI on your computer; see [Machine commands](/docs/machine-commands)
for the command inside Polaris.

## Follow a Session

Start by listing the Projects you can use. Choose a Project to see its
available settings, then start a Session with the task from standard input:

```bash
polaris sessions options
polaris sessions options --project <project-id>
polaris sessions start --project <project-id> --prompt -
```

The start result includes a Session ID, a link and the commands to run next.
Run the printed `polaris sessions wait` command in the background. Waiting
uses no model tokens. When it finishes, use `polaris sessions result` for the
stored reply and links, or `polaris sessions read` for more conversation.
These reads leave a sleeping Machine asleep.

Each write prints its request ID. When retrying it, pass the same
`--request-id` so Polaris can recognize the original action. Each command's
`--help` explains its options and what to do next.

## Continue or stop work

The CLI can send follow-up messages, answer questions and stop a Turn.
Sending to a busy Session queues the message unless `--steer` is supplied.
A message sent after you stop the Session restarts it.

Permission approvals need a person. When the CLI cannot answer one, it
prints a link where you can review and approve it in Polaris.

To disconnect an agent, open **Settings → Profile → CLI sign-ins** and
choose **Revoke** beside its computer. Its next command asks for sign-in;
running Sessions keep running. See [Polaris CLI](/docs/cli) for all commands.

## If it doesn't work

- **Run: polaris auth login**: sign in again. If you set
  `POLARIS_ACCESS_TOKEN`, unset it first.
- **Too many requests**: wait before retrying. The CLI's wait command handles
  these pauses itself.
- **Organization Machine limit**: wait for a Machine to become available
  before trying to start another one.
- **Billing prevents compute**: follow the command's recovery instructions
  to resolve the Organization's billing before retrying.
