Parses each String as RFC 8259 JSON and emits the typed value t bound at link time, decoding the text into whatever pipelogic type the downstream connection requires. Inverse of serialize_to_json.
Typical backends
File-based typed ingest. Read a JSON text file and decode it into the typed value a downstream stage consumes.
Round-trip transform. Decode JSON to a typed value, reshape it, and re-serialise the result back to JSON text.
Caveats
- Hard constraintThe bound output
t must structurally match the JSON; a shape mismatch raises at runtime rather than at link time. - AccuracyNumbers are coerced to the bound numeric type — a bare integer literal decodes as a 64-bit integer and a literal with a decimal point as a double, so the text must be written in the matching form.
- Hard constraintA JSON null requires a nullable bound type such as Maybe; a non-nullable type rejects null.
- I/O contractBytes-typed fields are decoded from base64 strings; the parser is strict RFC 8259 and rejects comments, trailing commas, and NaN or Infinity literals.
- CostThe entire input is parsed into a tree before any output is produced, so a very large payload allocates the whole document up front.