# navigate

Go to an agent, task, workflow, document, schedule or worktree, or to a screen and the record on it, in every client following navigations.

writes · not idempotent · CLI only · [Navigation](https://komrad.dev/latest/api/navigation.md)

Fails when no client is following, or when every one is behind.

## Calling it

```bash
curl -X POST http://127.0.0.1:8787/komrad.navigation.v1.NavigationService/Navigate \
  -H 'Content-Type: application/json' \
  -d '{
  "agent": "<agent>"
}'
```

```bash
komrad rpc navigate \
  --agent '<AgentDestination>'
```

## Request

### NavigateRequest

NavigateRequest names one record, or one screen and the record on it, to go to.

| Field | Type | Description |
| --- | --- | --- |
| [one of](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-destination)\* |  | The record, or location, to go to. |
| [`agent`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-agent) | [AgentDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-AgentDestination) | An agent. |
| [`task`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-task) | [TaskDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-TaskDestination) | A task. |
| [`workflow`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-workflow) | [WorkflowDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorkflowDestination) | A workflow. |
| [`document`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-document) | [DocumentDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-DocumentDestination) | A document. |
| [`schedule`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-schedule) | [ScheduleDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-ScheduleDestination) | A schedule. |
| [`worktree`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-worktree) | [WorktreeDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorktreeDestination) | A worktree. |
| [`location`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-NavigateRequest-location) | [Location](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location) | A screen, and the record on it to stand on. |

## Response

### Empty

No fields.

## Types

### AgentDestination

AgentDestination is an agent to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`id`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-AgentDestination-id) | uuid\* | The agent's id. |

### TaskDestination

TaskDestination is a task to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`id`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-TaskDestination-id) | uuid\* | The task's id. |

### WorkflowDestination

WorkflowDestination is a workflow to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`id`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorkflowDestination-id) | uuid\* | The workflow's id. |

### DocumentDestination

DocumentDestination is a document to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`id`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-DocumentDestination-id) | uuid\* | The document's id. |

### ScheduleDestination

ScheduleDestination is a schedule to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`id`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-ScheduleDestination-id) | uuid\* | The schedule's id. |

### WorktreeDestination

WorktreeDestination is a worktree to go to.

| Field | Type | Description |
| --- | --- | --- |
| [`dir`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorktreeDestination-dir) | string\* | The worktree's directory. |

### Location

Location is a screen, the record it stands on, and what the screen needs to stand there.

| Field | Type | Description |
| --- | --- | --- |
| [`screen`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-screen) | [Screen](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen)\* | The screen to show. |
| [one of](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-record) |  | The record the screen stands on. Unset to show the screen's list from the top. |
| [`agent`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-agent) | [AgentDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-AgentDestination) | An agent. |
| [`task`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-task) | [TaskDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-TaskDestination) | A task. |
| [`workflow`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-workflow) | [WorkflowDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorkflowDestination) | A workflow. |
| [`document`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-document) | [DocumentDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-DocumentDestination) | A document. |
| [`schedule`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-schedule) | [ScheduleDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-ScheduleDestination) | A schedule. |
| [`worktree`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-worktree) | [WorktreeDestination](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-WorktreeDestination) | A worktree. |
| [`system_kind`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Location-system_kind) | [SystemKind](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-SystemKind) | What the system screen lists. Unset keeps the kind it listed last. |

### Screen

Screen is one of the panel's screens, which a location stands on.

| Value | Description |
| --- | --- |
| [`agents`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-agents) | The agents, grouped under their workflows and tasks. |
| [`schedules`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-schedules) | The schedules that start agents on a timer. |
| [`review`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-review) | The review of a task's change. |
| [`documents`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-documents) | The documents agents have written. |
| [`logs`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-logs) | The logs of komrad or an agent. |
| [`status_checks`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-status_checks) | The status checks run on a task's pull request. |
| [`status_check_logs`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-status_check_logs) | The logs of the status checks run on a task's pull request. |
| [`system`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-Screen-system) | What komrad and its agents hold in memory and on disk. |

### SystemKind

SystemKind is what the system screen lists.

| Value | Description |
| --- | --- |
| [`memory`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-SystemKind-memory) | What komrad and each agent hold in memory. |
| [`storage`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-SystemKind-storage) | What komrad and each worktree hold on disk. |
| [`tokens`](https://komrad.dev/latest/api/navigation/navigate.md#komrad-navigation-v1-SystemKind-tokens) | What each agent spent in tokens today. |
