Skip to main content

jlens

JSONata for Python, with an engine written in Rust. It filters, queries and transforms JSON documents, and it can explain how a result was reached: which comparisons passed or failed, and which items a filter rejected.

pip install jlens
from jlens import Expression

expr = Expression("$sum(items[type = $kind].(price * qty))")
expr.evaluate({"items": [{"type": "a", "price": 2.5, "qty": 4}]}, {"kind": "a"})  # 10

jlens passes the official JSONata 2.2.2 test suite, and its package is typed. Wheels cover CPython 3.10 and later, and free-threaded Python 3.15 and later, on Linux, macOS and Windows. The package is in beta until jlens 1.0.

API

Name Purpose
Expression(source) Compiles an expression; raises a JlensError on syntax errors
expr.evaluate(input=None, bindings=None, **options) Evaluates against Python values, read as the expression reaches them; None when the result is undefined or null
expr.evaluate_json(text=None, bindings=None, **options) The same with JSON text in and out
Document(value), Document.from_json(text) A document converted once, for expr.evaluate_document(document, bindings=None, **options); shareable between threads
expr.evaluate_with_audit(input=None, bindings=None, *, level, limits, **options) Result, audit tree and explanation; errors are reported, not raised
expr.register_function(name, implementation, signature=None) Makes a Python callable available as $name to every evaluation

Callables in the bindings are host functions too. The options are timeout (seconds), max_depth, max_string_length, max_array_length, max_result_size, now and seed. Errors are JlensError exceptions with the JSONata error code, plus position, start, end, token and value; offsets count code points, like str indexes.

The full guide is the Python chapter of the jlens book.

License

MIT. The code and documentation ported or adapted from JSONata are also under the MIT license; see LICENSE.

Metadata

Release files for jlens 0.22.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for jlens 0.22.0
File Size Uploaded Provenance
jlens-0.22.0.tar.gz 454.2 kB With provenance Details

Built distributions (wheels)

Table of built distributions (wheels) for jlens 0.22.0
File
jlens-0.22.0-cp315-abi3.abi3t-win_amd64.whl CPython 3.15 abi3t, abi3 Windows x86-64 Details
jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_x86_64.whl CPython 3.15 abi3t, abi3 Linux musl 1.2+ x86-64 Details
jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_aarch64.whl CPython 3.15 abi3t, abi3 Linux musl 1.2+ ARM64 Details
jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_x86_64.whl CPython 3.15 abi3, abi3t Linux glibc 2.28+ x86-64 Details
jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_aarch64.whl CPython 3.15 abi3t, abi3 Linux glibc 2.28+ ARM64 Details
jlens-0.22.0-cp315-abi3.abi3t-macosx_11_0_arm64.whl CPython 3.15 abi3t, abi3 macOS 11.0+ ARM64 Details
jlens-0.22.0-cp315-abi3.abi3t-macosx_10_12_x86_64.whl CPython 3.15 abi3t, abi3 macOS 10.12+ x86-64 Details
jlens-0.22.0-cp310-abi3-win_amd64.whl CPython 3.10 abi3 Windows x86-64 Details
jlens-0.22.0-cp310-abi3-musllinux_1_2_x86_64.whl CPython 3.10 abi3 Linux musl 1.2+ x86-64 Details
jlens-0.22.0-cp310-abi3-musllinux_1_2_aarch64.whl CPython 3.10 abi3 Linux musl 1.2+ ARM64 Details
jlens-0.22.0-cp310-abi3-manylinux_2_28_x86_64.whl CPython 3.10 abi3 Linux glibc 2.28+ x86-64 Details
jlens-0.22.0-cp310-abi3-manylinux_2_28_aarch64.whl CPython 3.10 abi3 Linux glibc 2.28+ ARM64 Details
jlens-0.22.0-cp310-abi3-macosx_11_0_arm64.whl CPython 3.10 abi3 macOS 11.0+ ARM64 Details
jlens-0.22.0-cp310-abi3-macosx_10_12_x86_64.whl CPython 3.10 abi3 macOS 10.12+ x86-64 Details

Total release size: 18.8 MB

Release files / jlens-0.22.0.tar.gz

Download URL jlens-0.22.0.tar.gz
Size 454.2 kB
Tags Source
SHA-256 checksum
How to use checksums
c4e2f4ccf05de3c37d6f5ad58de1bd51c5aa0c1861bdf47ee7362cf1ef725a26
BLAKE2b-256 checksum
How to use checksums
eb98d67753e1df18904186ad66d6b9e5b3836dfdf9ff298cf2fb4a9efea20a57
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-win_amd64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-win_amd64.whl
Size 1.2 MB
Tags CPython 3.15 Windows x86-64 abi3 abi3t
SHA-256 checksum
How to use checksums
3e66c34e687f929e993adcadb81f763ee850557835344320abf05ef8c574af64
BLAKE2b-256 checksum
How to use checksums
319c008adf945e9869ab06a30a018601184a7cde12866520da01162ffd35e3ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_x86_64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_x86_64.whl
Size 1.5 MB
Tags CPython 3.15 Linux musl 1.2+ x86-64 abi3 abi3t
SHA-256 checksum
How to use checksums
c87bf23947b75d3522d959abc4bb0ceeef1eeb953d040ec1ce30dc5d6c44cd71
BLAKE2b-256 checksum
How to use checksums
559f14e097877116644bd7aedad8a0f80f8935d0b0a43c8bc9f353074b5f0cf3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_aarch64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-musllinux_1_2_aarch64.whl
Size 1.4 MB
Tags CPython 3.15 Linux musl 1.2+ ARM64 abi3 abi3t
SHA-256 checksum
How to use checksums
5d34eaf3f4ea92aefbd66db77b008c21488eb253b841be2f265ac59c3b68a1ee
BLAKE2b-256 checksum
How to use checksums
2a36866d9fc5035c015b9bb081f58b41bf5cc1f29b68f8ec021d7a02534f6067
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_x86_64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_x86_64.whl
Size 1.3 MB
Tags CPython 3.15 Linux glibc 2.28+ x86-64 abi3 abi3t
SHA-256 checksum
How to use checksums
77b7cd6650000169b32c74036c19032f137164864c72b46c00be5f99554e71d1
BLAKE2b-256 checksum
How to use checksums
4970f6e4aebc710c46586e24a9662f30c13b9fb61a221dd1a04b1be1f4cccec0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_aarch64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-manylinux_2_28_aarch64.whl
Size 1.3 MB
Tags CPython 3.15 Linux glibc 2.28+ ARM64 abi3 abi3t
SHA-256 checksum
How to use checksums
b6e1d05698951be93435de9327ad695624b73e0e6c0d0208d39e22e8dc06d38b
BLAKE2b-256 checksum
How to use checksums
32f8125938d881f6efa1fd7beef5002eca7e4d7dbd304e52747110df1901a97e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-macosx_11_0_arm64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-macosx_11_0_arm64.whl
Size 1.2 MB
Tags CPython 3.15 abi3 abi3t macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
a8c663c46b060578290c2b5748091adefb768a4bcfc85e79f40fef8a7afaefb9
BLAKE2b-256 checksum
How to use checksums
88ae84a179c09cee451bfdaabc27817461eae05cd2e2f113e517879e5e23e33e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp315-abi3.abi3t-macosx_10_12_x86_64.whl

Download URL jlens-0.22.0-cp315-abi3.abi3t-macosx_10_12_x86_64.whl
Size 1.2 MB
Tags CPython 3.15 abi3 abi3t macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
c36d0629547eb554b3987c3cbf7fe358bb34e2ab616cd76ebb82c033a13ae025
BLAKE2b-256 checksum
How to use checksums
560b2028d8182ef5dc4245585f52be5ec7dc3b6d4e0e83ea976b37fc8bfeecdc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-win_amd64.whl

Download URL jlens-0.22.0-cp310-abi3-win_amd64.whl
Size 1.2 MB
Tags CPython 3.10 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
8fe4934df3849c6ccbe35f20b573c877cd31433082ff310affc855fd60739e5b
BLAKE2b-256 checksum
How to use checksums
5633aabde5440fb027d04118dd117fdaafc6a69ddd504f816fa38590225dea0b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-musllinux_1_2_x86_64.whl

Download URL jlens-0.22.0-cp310-abi3-musllinux_1_2_x86_64.whl
Size 1.5 MB
Tags CPython 3.10 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
67712171858a0a0730527d6242bb87eec0099dff11dc31461b852c09c2b1e421
BLAKE2b-256 checksum
How to use checksums
85f45e89a2adcda7276dc7f25256206f0b042e6a1de7a941d8f5d5ed9acc9abe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-musllinux_1_2_aarch64.whl

Download URL jlens-0.22.0-cp310-abi3-musllinux_1_2_aarch64.whl
Size 1.4 MB
Tags CPython 3.10 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
4a03b37edbb9cbaaee3f246e738ec679fd69311803e1b4cde49019c666b4f66a
BLAKE2b-256 checksum
How to use checksums
8e6ce76879d0311500eaebe9f2011e16078c343f21e0e2b33468b72938ddb04d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-manylinux_2_28_x86_64.whl

Download URL jlens-0.22.0-cp310-abi3-manylinux_2_28_x86_64.whl
Size 1.3 MB
Tags CPython 3.10 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
e914bcf75140ef6aa8846fde4a151a20252662d103bbe499b859b0e0f1448ba7
BLAKE2b-256 checksum
How to use checksums
49c4783b83a418e03e351a463770c8bc34000c80ffb4655d6b1795fbfed85f12
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-manylinux_2_28_aarch64.whl

Download URL jlens-0.22.0-cp310-abi3-manylinux_2_28_aarch64.whl
Size 1.3 MB
Tags CPython 3.10 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
29fddb5955f7556fa78cac8eb6c30854bb2e762756a3fb9af717d55f86d167d0
BLAKE2b-256 checksum
How to use checksums
b6e1a10d7606be33d62c1b63df5d2c95590df0b63b6a661b8565d408617f0df4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-macosx_11_0_arm64.whl

Download URL jlens-0.22.0-cp310-abi3-macosx_11_0_arm64.whl
Size 1.2 MB
Tags CPython 3.10 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
e87fa11d2a37f137e10c7d9c49c4842dffb0fac2d5aeb1a23cb9c60a16cf8b37
BLAKE2b-256 checksum
How to use checksums
679d5510f2a7fa8472e64265971ae4225ce43067411ea8741370cab205fce961
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / jlens-0.22.0-cp310-abi3-macosx_10_12_x86_64.whl

Download URL jlens-0.22.0-cp310-abi3-macosx_10_12_x86_64.whl
Size 1.2 MB
Tags CPython 3.10 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
c8456515025e9484c771183dba40487f85e31719eec6fd63f00441879e04307a
BLAKE2b-256 checksum
How to use checksums
8253a24be7bd317cf1fc447afab53ed05ed94a6e570691e38f2483b2a2bb41c5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Security for jlens 0.22.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 15 files in this release have been uploaded with provenance metadata.

Select from 15 files

Attestation for jlens-0.22.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page