APIs References


Interactive API docs

Explore interactively the API.

Alternative API docs

Alternative reference to the API generated by ReDoc.

Coming soon...

GraphQL API docs

Explore interactively the API.

Creation process

Frequently Asked Questions & Examples

You have a question about the ECHR or the ECHR Open Data?

Please, open a ticket in GitHub issue tracker and we might add a new answer and example.

How to access a specific section in a judgment?

We assume you need a textual representation of a specific section of the judgment document, for instance The Facts.

We also assume that you do not want to use SQL but rather a python library such as pandas.

1. Locating the proper section in the judgment document

First, you need to load the file containing all the information about all cases: build/unstructured/cases.json.

The file contains a list of dictionary where each dictionary represents all the information about a case.
The content of documents associated to a given case is under the key content. The field content contains itself a dictionary of documents related to a case.
Currently, there is only one document which is the judgment document.
The judgment representation has the form of a tree where each node is:
	'content': "paragraph_or_section_title"
	'elements': []

For first level nodes, corresponding to the main sections of the judgment, there is an attribute section_name to identify specific sections.

It is then enough to find the node with the attribute section_name": "facts".

2. Reconstructing the text for the specific section

With the content of the section, if you need just the full text, you need to recursively reconstruct it.

This can be done by recursively aggregating each node using the following function:

  1. Alexandre Quemy and Robert Wrembel:
    On Integrating and Classifying Legal Text Documents. Database and Expert Systems Applications - 31st International Conference, (DEXA), 2020
    [pdf] [bibtex]
  2. Alexandre Quemy:
    European Court of Human Right Open Data project. CoRR abs/1810.03115 (2018)
    [pdf] [bibtex]