You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Alternative idea (both could be implemented, but they serve the same purpose):
Allow creating not only a single PID, but multiple ones which may refer to each other. Input would be an array of records.
References could look like one of these approaches:
indexing into the input array like "my-pid-reference": "input[0]" or similar
reference names: The pid records do have an optional PID field which is used for returning JSON and for the (optional, non-default, and not recommended) case where a suffix may be provided. We could use this suffix as a reference
In pull request #247, I implemented an endpoint which allows creating interconnected PID records. During this process, I was thinking what could be additional steps towards a “Relationship Management API”. Due to time constraints and a lack of current use case for this feature, I am posting some features I identified as possibly useful here:
create POST /api/v1/pit/relationship endpoint for creating new relationships
add unidirectional relationships between two single FAIR-DOs with one key
add unidirectional relationships between one start and a list of target FAIR-DOs with one key
add multiple unidirectional relationships between one start and 1..n target FAIR-DOs with each one key
add bidirectional relationships between two single relationships and optionally different keys for each direction
add bidirectional relationships between one start and a list of target FAIR-DO with optionally different keys for each direction
add multiple bidirectional relationships between one start and 1..n target FAIR-DOs
create PUT /api/v1/pit/relationship endpoint for overwriting relationships
bidirectionally remove all relationships to/from this FAIR-DO
unidirectionally remove all relationships from this FAIR-DO
redirect creation of new relationships to POST endpoint
create PATCH /api/v1/pit/relationship endpoint for overwriting single relationships
remove all outgoing relationships for a specific key
remove all incoming relationships for a specific key
redirect creation of new relationships to POST endpoint
create DELETE /api/v1/pit/relationship endpoint for removing relationships
unidirectional removal for single selected outgoing relationship
unidirectional removal for all outgoing relationships of a single FAIR-DO
unidirectional removal for single selected incoming relationship
unidirectional removal for all incoming relationships of a single FAIR-DO
bidirectional removal of multiple selected relationships for a single FAIR-DO (parameters: direction, key)
bidirectional removal of all relationships for a single FAIR-DO
Consider an API which makes it more convenient to add relations by providing a triple (a, rel, b), to create a relation rel from a to b.
Consider the following options:
If profile is given, relation term may be human-readable instead of pid.
Implications:
Bonus thought: we could also request single attributes/relations, would this ease things in practice?
The text was updated successfully, but these errors were encountered: