Add `mapping_set_id` to JSON response
anitacaron opened this issue · comments
Do it the same way as in #34.
Make sure that the other
field is already in JSON format.
Need to change this in the mapping_set:
{
"object_source": "http://purl.obolibrary.org/obo/hp",
"uuid": "0025bf7bc8d551c4b4f2c34d6e89d58f",
"subject_source": "http://purl.obolibrary.org/obo/mp",
"other": "PMID:32585259",
"mapping_date": "2022-02-01",
"comment": "KidsFirst; see ticket https://github.com/mgijax/mammalian-phenotype-ontology/issues/3497",
...
"mappings": {
"href": "http://localhost:8008/mapping_sets/0025bf7bc8d551c4b4f2c34d6e89d58f/mappings"
}
}
A possible solution, in case the field other
has something:
- If the content in
other
is JSON, add the keysssom_api:mapping_set_id
- If not, add the content in
other
to the keyother_sssom
, and add the keysssom_api:mapping_set_id
After some meetings, it was decided not to change the SSSOM model. The solution is to have endpoints only for the UI; we can add any field important for the UI and one that is SSSOM conform.