# Libtmux_json

- **Package:** libtmux-json
- **Language:** OCaml
- **Kind:** module
- **Source:** https://github.com/libtmux/libtmux-ocaml/blob/205dfda49742592b479247049d186956e4a4cfe9/json/libtmux_json.mli#L1
- **Page:** https://libtmux.org/en/ocaml/latest/reference/libtmux_json/

```ocaml
module Libtmux_json
```

Pure, bounded query and workspace JSON interchange.

[`Expr`](/en/ocaml/latest/reference/libtmux_json-expr/) validates portable queries and [`Workspace`](/en/ocaml/latest/workspace/reference/libtmux_json-workspace/) decodes configurations and encodes plans and receipts. Both return [`Decode_error.t`](/en/ocaml/latest/reference/libtmux_json-decode_error-t/) on invalid data. See the [query guide](https://github.com/libtmux/libtmux-ocaml/blob/master/docs/queries.md) and [workspace guide](https://github.com/libtmux/libtmux-ocaml/blob/master/docs/workspaces.md) for complete programs.

## Members

### Common operations

- [`Expr`](/en/ocaml/latest/reference/libtmux_json-expr/) (module): Portable scalar pane expressions. See the [wire subset](https://github.com/libtmux/libtmux-ocaml/blob/master/docs/query-interchange.md) for canonical fields, operators and bounds.

### Other members

- [`Decode_error`](/en/ocaml/latest/reference/libtmux_json-decode_error/) (module)
- [`Error`](/en/ocaml/latest/reference/libtmux_json-error/) (module): Structured native failures for JSON consumers.
- [`Workspace`](/en/ocaml/latest/workspace/reference/libtmux_json-workspace/) (module): Validate workspace documents and describe plans and retained execution. Preview output never supplies executable targets.

## Guides

Pages that discuss `Libtmux_json`.

- [OCaml workspace API reference](/en/ocaml/latest/workspace/reference/)
