Liking cljdoc? Tell your friends :D
All platforms.

hive-kdenlive.kdenlive.json

JSON, both directions, with no dependency.

hive-kdenlive deliberately carries no JSON library, and until 2026-09-20 it showed: the encoder handled a FLAT map of scalars and rendered anything else with str, so :paths ["a.mp4" "b.mp3"] went out as the Clojure literal ["a.mp4" "b.mp3"] (no commas) and :params {:duration 5} as {:duration 5}. Both are the shapes hive-creator's :finish actually sends, to :media/import and :clip/append-effect. There was no decoder at all, so every answer came back as a raw string and a caller that needed an id out of it got nothing.

Neither had been noticed because the HTTP transport was never exercised end to end; the headless document transport was.

write and read live together so a round trip can be property-tested, which is the only way a hand-written codec stays honest.

Portable: clojure.core and clojure.string, and no host interop. There is no StringBuilder here and no (int \c), because neither exists on cljw or cljrs.

read answers Clojure data with STRING keys, exactly as the wire spells them, because the route catalog's :result names a wire field.

JSON, both directions, with no dependency.

hive-kdenlive deliberately carries no JSON library, and until 2026-09-20 it
showed: the encoder handled a FLAT map of scalars and rendered anything
else with `str`, so `:paths ["a.mp4" "b.mp3"]` went out as the Clojure
literal `["a.mp4" "b.mp3"]` (no commas) and `:params {:duration 5}` as
`{:duration 5}`. Both are the shapes hive-creator's :finish actually sends,
to :media/import and :clip/append-effect. There was no decoder at all, so
every answer came back as a raw string and a caller that needed an id out
of it got nothing.

Neither had been noticed because the HTTP transport was never exercised end
to end; the headless document transport was.

`write` and `read` live together so a round trip can be property-tested,
which is the only way a hand-written codec stays honest.

Portable: clojure.core and clojure.string, and no host interop. There is no
StringBuilder here and no `(int \c)`, because neither exists on cljw or
cljrs.

`read` answers Clojure data with STRING keys, exactly as the wire spells
them, because the route catalog's :result names a wire field.
raw docstring

readclj/s

(read s)

Parse s as JSON. Answers {:ok value} or {:error :json/unparseable}.

Object keys stay STRINGS, spelled as the wire spells them: the route catalog's :result names a wire field, and keywordizing here would make the catalog and the answer disagree.

Parse `s` as JSON. Answers {:ok value} or {:error :json/unparseable}.

Object keys stay STRINGS, spelled as the wire spells them: the route
catalog's :result names a wire field, and keywordizing here would make the
catalog and the answer disagree.
sourceraw docstring

writeclj/s

(write x)

x as a JSON string. Maps, vectors, sets, strings, keywords, numbers, booleans and nil. A keyword is written as its name, so :binId is "binId" and the fork's camelCase survives.

`x` as a JSON string. Maps, vectors, sets, strings, keywords, numbers,
booleans and nil. A keyword is written as its name, so :binId is "binId"
and the fork's camelCase survives.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
←Move to previous article
→Move to next article
Ctrl+/Jump to the search field
× close