Skip to main content

pyJudilibre

pyJudilibre is a small Python wrapper to query the JUDILIBRE API from the French Supreme Court, la Cour de cassation. JUDILIBRE aims to give access to judiciary decisions.

Logo de pyjudilibre ?

Documentation

The documentation is here.

Requirements

This library relies on pydantic and httpx to perform queries to JUDILIBRE and to validate inputs and outputs. You also need credentials from PISTE.

Installation

You can install it from pyjudilibre.

pip install pyjudilibre

Simple usage

To instantiate the main class, JudilibreClient, you need to use your JUDILIBRE API key (see here).

import logging
from pyjudilibre import JudilibreClient

JUDILIBRE_API_KEY = "***"
client = JudilibreClient(
    judilibre_api_key=JUDILIBRE_API_KEY,
    logging_level=logging.DEBUG,
)

To get a decision, you need to provide its ID:

DECISION_ID = "667e51a56430c94f3afa7d0e"
decision = client.decision(decision_id=DECISION_ID)

Description of the source code

The code of the library is in lib/pyjudilibre:

  • the main class and its method are in pyjudilibre.py
  • the enums are in enums.py
  • the pydantic models are in models.py
  • spectific exceptions are defined in exceptions.py
  • decorators.py contains one decorator

Other folders are as follow:

  • tests contains unit tests.
  • docs contains documentation files.
  • scripts contains useful scripts to develop the library

Development setup

To set up a development environment, you should create a virtual environment named venv:

python3 -m venv venv
source venv/bin/activate

pip install '.[dev,build,doc,test]'

In scripts, you can use:

Metadata

Release files for pyjudilibre 0.15.1

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

Source distribution (sdist)

Source distribution for pyjudilibre 0.15.1
File Size Uploaded Provenance Actions
pyjudilibre-0.15.1.tar.gz 22.8 kB Without provenance Details for pyjudilibre-0.15.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pyjudilibre 0.15.1
File Interpreter ABI Platform Actions
pyjudilibre-0.15.1-py3-none-any.whl Python 3 none any Details for pyjudilibre-0.15.1-py3-none-any.whl

Total release size: 47.9 kB

Release files / pyjudilibre-0.15.1.tar.gz

Download URL pyjudilibre-0.15.1.tar.gz
Size 22.8 kB
Tags Source
SHA-256 checksum
How to use checksums
a33e2c00adc64da36a9781c00fdfc222021cf3e5320ffbe869ce1564326843ec
BLAKE2b-256 checksum
How to use checksums
5a4267c7e693001141bed408c045bb5fd5b515c9495d8c4e74a579389bc9c1e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.15

Release files / pyjudilibre-0.15.1-py3-none-any.whl

Download URL pyjudilibre-0.15.1-py3-none-any.whl
Size 25.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8e8692723697aa7b3f6211cd41b13f94930f2137824c0c3206c900c8bbe6001a
BLAKE2b-256 checksum
How to use checksums
fa8f3ad5a03fd459f900d6a05b7ca79c01970400ade28cd81928f59698db5f93
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.15

Security for pyjudilibre 0.15.1

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

Release history Release notifications | RSS feed

This release

0.15.1 This release

2 release files No provenance

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