# Discovery

URL: https://tuios.dev/docs/protocol-verbs/discovery

> Discovery: part of the Protocol Verbs of TUIOS.

This page is one part of `docs/protocol-verbs.md` of the [tuios repository](https://github.com/Gaurav-Gosain/tuios/blob/f32fbfd7faca14e5260a1d711262cb81c49f68a6/docs/protocol-verbs.md). The [Protocol Verbs](https://tuios.dev/docs/protocol-verbs) page lists every part.

## `hello` (Added in v0.8.0)

Handshake: report the protocol version this daemon speaks and the version range it accepts. Also tells the daemon the caller's terminal, so a session this connection later creates (new-session, switch-session's create) gets it rather than the daemon's fallback.

| Param        | Type   | Required | Default | Description                                                                                                                                        |
| ------------ | ------ | -------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| `client`     | string |          |         | Name of the calling program, for the daemon log.                                                                                                   |
| `version`    | string |          |         | Version string of the calling program.                                                                                                             |
| `protocol`   | int    |          |         | Protocol version the caller speaks. The daemon reports a mismatch rather than failing later.                                                       |
| `term`       | string |          |         | The caller's TERM. Omit, or pass empty, for a caller with no terminal of its own (a script, CI, an agent): its sessions get the daemon's fallback. |
| `color_term` | string |          |         | The caller's COLORTERM.                                                                                                                            |

```json
{"id":1,"verb":"hello","params":{"client":"tuios","version":"1.2.3","protocol":1}}
```

## `list-verbs` (Added in v0.8.0)

List every supported verb with its parameter schema and examples, plus the protocol version and error-code catalog.

| Param  | Type   | Required | Default | Description                                            |
| ------ | ------ | -------- | ------- | ------------------------------------------------------ |
| `verb` | string |          |         | Describe only this verb. Omit to describe all of them. |

```json
{"id":1,"verb":"list-verbs"}
```

```json
{"id":1,"verb":"list-verbs","params":{"verb":"capture-pane"}}
```
