# libtmux:list-keys

- **Package:** libtmux
- **Language:** Common Lisp
- **Kind:** function
- **Source:** https://github.com/libtmux/libtmux-lisp/blob/c2e5fc4ed3befda21f45dfa5d5868c38fd138311/src/key-bindings.lisp#L41
- **Public owner:** libtmux
- **Page:** https://libtmux.org/en/lisp/latest/reference/libtmux-list-keys/

```
(list-keys client &key table key format cancel-token timeout output-limit)
```

Inspect key bindings; return owned UTF-8 printer text and a command outcome.
Omit TABLE to list every key table. TABLE and KEY are literal strings; native
unknown-table and invalid-key failures remain errors. An unbound valid KEY is
an error except on tmux 3.7 through 3.7c, which return empty text. Those releases
also send a single matching row to the server message log and any selected
frontend's status line instead of stdout. Empty text does not prove absence.
FORMAT is explicit tmux format source
and requires live tmux 3.7 or newer; older daemons signal UNSUPPORTED-CAPABILITY
before payload dispatch. Omission uses the native human-readable listing.

FORMAT has no time expansion. #() can start asynchronous command-client jobs,
whose output may be incomplete and whose cleanup follows client disconnect.
Empty expanded lines may be omitted. Native escaping, whitespace and after-hook
output are preserved; the text is not a parsed or replayable configuration.
Blocks under shared preflight/dispatch limits and never retries. Invalid UTF-8 signals
DECODING-ERROR; operational failures retain their outcome.

See also: `libtmux:bind-key`, `libtmux:error-outcome`, `libtmux:list-commands`, `libtmux:unbind-key`.

## Parameters

- `client`
- `table?`
- `key?`
- `format?`
- `cancel-token?`
- `timeout?`
- `output-limit?`

## Guides

Pages that discuss `list-keys`.

- [Explicit operations](/en/lisp/latest/guides/operations/)
