Skip to content

Commit

Permalink
Bring back description to retain backwards-compatibility.
Browse files Browse the repository at this point in the history
  • Loading branch information
merkys committed Nov 18, 2024
1 parent 893bb04 commit a40c0e0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion optimade.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2016,9 +2016,10 @@ As described in the section `Relationships`_, it is possible for the API impleme
The API implementation MAY support queries on relationships with an entry type :filter-fragment:`<entry type>`:

- :filter-fragment:`<entry type>.id` references a list of IDs of relationships with entries of the type :filter-fragment:`<entry type>`.
- :filter-fragment:`<entry type>.description` references a correlated list of the human-readable descriptions of these relationships.
- :filter-fragment:`<entry type>.target.<property>` references a list of property :property:`<property>` values for related entries (i.e., the :filter-fragment:`target` entry of the relationship) of type :filter-fragment:`<entry type>`.

Hence, the filter language acts as, for every entry type, there is a property with that name which contains a list of dictionaries with entry properties plus :property:`id`.
Hence, the filter language acts as, for every entry type, there is a property with that name which contains a list of dictionaries with entry properties plus :property:`id` and :property:`description`.
For example: a client queries the :endpoint:`structures` endpoint with a filter that references :filter-fragment:`calculations.id`.
For a specific structures entry, the nested property behaves as the list :filter-fragment:`["calc-id-43", "calc-id-96"]` and would then, e.g., match the filter :filter:`calculations.id HAS "calc-id-96"`.
This means that the structures entry has a relationship with the calculations entry of that ID.
Expand Down

0 comments on commit a40c0e0

Please sign in to comment.