> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://stelltec.com/rhebok/docs/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://stelltec.com/rhebok/docs/_mcp/server.

# List coding agents

GET http://127.0.0.1:7331/api/agents

Probes each coding agent rhebok supports and returns whether it is
installed, whether rhebok is connected to it, what a connection gives
it, and config snippets for any other MCP client.


Reference: https://stelltec.com/rhebok/docs/api/agents/list-agents

## Response

### 200

Every supported agent and the generic snippets.

- `agents` (list of AgentListAgentsItems, required) — One entry per supported agent. If probing one agent fails, its entry is `{"error": "agent probe panicked"}`.
- `snippets` (AgentSnippets, required)

## Errors

### 421 Misdirected Request Error

The `Host` header does not name this dashboard (see the rules at the top of this page).

- `error` (string, required) — What went wrong, in plain words.

## Types

### AgentListAgentsItems

- Agent: Agent
- Error: Error

### AgentSnippets

- `mcp_json` (string, required) — An `mcpServers` JSON snippet for any MCP client.
- `codex_toml` (string, required) — An `[mcp_servers.rhebok]` TOML snippet.

### Agent

- `id` (enum, required)
  - Allowed values: `claude-code`, `codex`, `claude-desktop`, `cursor`, `gemini`
- `name` (string, required)
- `detected` (AgentDetected, required)
- `status` (AgentStatus, required)
- `capabilities` (AgentCapabilities, required)
- `snippet` (string, required, nullable)
- `instructions` (boolean, optional) — Present only for agents with an instructions block (Codex's `AGENTS.md`); true when it is in place.

### Error

- `error` (string, required) — What went wrong, in plain words.

### AgentDetected

- `installed` (boolean, required)
- `version` (string, required, nullable)
- `config_path` (string, required, nullable)

### AgentStatus

- `state` (enum, required)
  - Allowed values: `connected`, `not_connected`, `stale`, `broken`
- `reason` (string, optional) — Present when `state` is `stale` or `broken`.

### AgentCapabilities

- `mcp` (boolean, required)
- `prompt_hook` (boolean, required)
- `session_hook` (boolean, required)
- `transcripts` (boolean, required)
- `instructions` (boolean, required)

## Examples

**Response**

```json
{
  "agents": [
    {
      "capabilities": {
        "instructions": false,
        "mcp": true,
        "prompt_hook": true,
        "session_hook": true,
        "transcripts": true
      },
      "detected": {
        "config_path": "/Users/me/Library/Application Support/rhebok/plugin",
        "installed": true,
        "version": "2.1.0 (Claude Code)"
      },
      "id": "claude-code",
      "name": "Claude Code",
      "snippet": "claude plugin marketplace add \"/Users/me/Library/Application Support/rhebok/plugin\"\nclaude plugin install rhebok@rhebok\n",
      "status": {
        "state": "connected"
      }
    },
    {
      "capabilities": {
        "instructions": true,
        "mcp": true,
        "prompt_hook": true,
        "session_hook": false,
        "transcripts": true
      },
      "detected": {
        "config_path": "/Users/me/.codex/config.toml",
        "installed": true,
        "version": "codex-cli 0.157.1"
      },
      "id": "codex",
      "instructions": false,
      "name": "Codex",
      "snippet": "[mcp_servers.rhebok]\ncommand = \"/Users/me/Library/Application Support/rhebok/bin/rhebok\"\nargs = [\"mcp\"]\n",
      "status": {
        "reason": "the `rhebok` server runs /opt/homebrew/bin/rhebok, not /Users/me/Library/Application Support/rhebok/bin/rhebok",
        "state": "stale"
      }
    }
  ],
  "snippets": {
    "mcp_json": "{\n  \"mcpServers\": {\n    \"rhebok\": {\n      \"command\": \"/Users/me/Library/Application Support/rhebok/bin/rhebok\",\n      \"args\": [\n        \"mcp\"\n      ]\n    }\n  }\n}\n",
    "codex_toml": "[mcp_servers.rhebok]\ncommand = \"/Users/me/Library/Application Support/rhebok/bin/rhebok\"\nargs = [\"mcp\"]\n"
  }
}
```

**SDK Code**

```python Agents_listAgents_example
import requests

url = "http://127.0.0.1:7331/api/agents"

response = requests.get(url)

print(response.json())
```

```javascript Agents_listAgents_example
const url = 'http://127.0.0.1:7331/api/agents';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Agents_listAgents_example
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "http://127.0.0.1:7331/api/agents"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Agents_listAgents_example
require 'uri'
require 'net/http'

url = URI("http://127.0.0.1:7331/api/agents")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
```

```java Agents_listAgents_example
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("http://127.0.0.1:7331/api/agents")
  .asString();
```

```php Agents_listAgents_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'http://127.0.0.1:7331/api/agents');

echo $response->getBody();
```

```csharp Agents_listAgents_example
using RestSharp;

var client = new RestClient("http://127.0.0.1:7331/api/agents");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
```

```swift Agents_listAgents_example
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "http://127.0.0.1:7331/api/agents")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```