# libtmux.json

- **Package:** libtmux/json
- **Language:** Common Lisp
- **Kind:** module
- **Source:** https://github.com/libtmux/libtmux-lisp/blob/c2e5fc4ed3befda21f45dfa5d5868c38fd138311/src/json.lisp#L1
- **Page:** https://libtmux.org/en/lisp/latest/reference/libtmux-json/

Bounded JSON interchange for native libtmux query filters.
READ-FILTER accepts a complete JSON string in schema libtmux.lisp.filter/1.
It resolves only registered names, rejects duplicate or unknown members, and
never evaluates input as Lisp code. WRITE-FILTER serializes only compiled
declarative filters; native function predicates are not query documents.

## Members

### Common operations

- [`document-limit`](/en/lisp/latest/reference/libtmux-json-document-limit/) (function): Return the exhausted document limit name, or NIL.
- [`document-path`](/en/lisp/latest/reference/libtmux-json-document-path/) (function): Return a fresh vector locating a filter-document error.
- [`filter-document-limit-exceeded`](/en/lisp/latest/reference/libtmux-json-filter-document-limit-exceeded/) (exception): A filter document exceeds a configured parsing or query-data limit.
- [`invalid-filter-document`](/en/lisp/latest/reference/libtmux-json-invalid-filter-document/) (exception): A filter document is malformed, unknown, or semantically invalid.
- [`read-filter`](/en/lisp/latest/reference/libtmux-json-read-filter/) (function): Read one bounded libtmux.lisp.filter/1 JSON string into a compiled filter.
External names resolve through closed registries and are never interned. Regex
nodes are rejected unless ALLOW-REGEX is true and libtmux/regex is loaded.
Parser limits bound UTF-8 input bytes, nesting, JSON nodes, strings, membership
arrays and integer-token digits. Decimal and exponent number syntax is rejected
before conversion. Parser limits do not interrupt CL-PPCRE execution.
- [`write-filter`](/en/lisp/latest/reference/libtmux-json-write-filter/) (function): Serialize a COMPILED-FILTER as one libtmux.lisp.filter/1 JSON document.
Return a fresh string when STREAM is NIL; otherwise write to the supplied open
output character stream and return NIL without closing it. Pathnames and binary
streams are rejected. The wire contract is native to this port and does not
imply cross-port regex or query equivalence.
