# libtmux.workspace:fetch-workspace-state

**Workspace Manager concept example** A working example of the core library. It can change without notice.

- **Package:** libtmux/workspace
- **Language:** Common Lisp
- **Kind:** function
- **Source:** https://github.com/libtmux/libtmux-lisp/blob/830d86ccdf4081f547301cde2845840c372ec87c/src/workspace-api.lisp#L279
- **Public owner:** libtmux.workspace
- **Page:** https://libtmux.org/en/lisp/latest/workspace/reference/libtmux-workspace-fetch-workspace-state/

```
(fetch-workspace-state client workspace &key cancel-token (timeout (slot-value client (quote timeout))) (output-limit (slot-value client (quote output-limit))) (record-limit 100000))
```

Acquire ready/vacant owned metadata and a captured graph explicitly through CLIENT.
WORKSPACE must use schema /2; /1 is refused before I/O. TIMEOUT and OUTPUT-LIMIT
share the bounded read policy across attempts. RECORD-LIMIT is an integer from
1 through 100000; CANCEL-TOKEN is shared. No mutation occurs. Returns a
WORKSPACE-STATE for local planning, usable after client close. Actual read
failures signal WORKSPACE-STATE-ERROR with partial evidence; invalid arguments
remain validation failures. Failure is never reported as vacancy.

See also: `libtmux.workspace:inspect-workspace`, `libtmux.workspace:plan-workspace`, `libtmux.workspace:state-causes`, `libtmux.workspace:state-data`, `libtmux.workspace:state-outcomes`, `libtmux.workspace:state-snapshot`.

## Parameters

- `client`
- `workspace`
- `cancel-token?`
- `timeout?`
  Default: `(slot-value client (quote timeout))`.
- `output-limit?`
  Default: `(slot-value client (quote output-limit))`.
- `record-limit?`
  Default: `100000`.

## Guides

Pages that discuss `fetch-workspace-state`.

### Guides

- [Getting started](/en/lisp/latest/guides/getting-started/)

### Workspace

- [Workspace guide](/en/lisp/latest/workspace/source-guide/)
