Skip to content

Commit

Permalink
Merge pull request #72 from NCATS-Tangerine/adverse-event-operations
Browse files Browse the repository at this point in the history
Adverse event operations
  • Loading branch information
colleenXu authored Aug 4, 2021
2 parents 1efb587 + 53147f0 commit bb98838
Showing 1 changed file with 58 additions and 1 deletion.
59 changes: 58 additions & 1 deletion mychem.info/openapi_full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,8 @@ paths:
- "$ref": "#/components/x-bte-kgs-operations/targetedBy"
- "$ref": "#/components/x-bte-kgs-operations/treatedBy"
- "$ref": "#/components/x-bte-kgs-operations/contraindicatedBy"
- "$ref": "#/components/x-bte-kgs-operations/causesAdverseEvent"
- "$ref": "#/components/x-bte-kgs-operations/adverseEventCausedBy"
components:
parameters:
callback:
Expand Down Expand Up @@ -423,6 +425,9 @@ components:
MESH: chembl.drug_indications.mesh_id
max_phase: chembl.drug_indications.max_phase_for_ind
first_approval: chembl.drug_indications.first_approval
adverseEvent:
name: drugcentral.fda_adverse_event.meddra_term
MEDDRA: drugcentral.fda_adverse_event.meddra_code
x-bte-kgs-operations:
metabolizedBy:
- supportBatch: true
Expand Down Expand Up @@ -709,4 +714,56 @@ components:
predicate: treated_by
source: "infores:chembl"
response_mapping:
"$ref": "#/components/x-bte-response-mapping/chembl"
"$ref": "#/components/x-bte-response-mapping/chembl"
causesAdverseEvent:
## - chose to map to Disease semantic type due to more support for ID mapping there, will support queries
## link: https://github.com/biothings/BioThings_Explorer_TRAPI/issues/217#issuecomment-880204237
## - example: https://mychem.info/v1/query?q=drugbank.name:nitisinone&fields=drugcentral.fda_adverse_event
## - there are also counts for...having drug + adverse event (ae) (drug_ae), having drug but no adverse event (drug_no_ae)
## no drug but had adverse event (no_drug_ae), no drug and no adverse event (no_drug_no_ar)
## not sure what the llr, llr_threshold, level means
- supportBatch: true
inputSeparator: ","
parameters:
fields: drugcentral.fda_adverse_event
requestBody:
body:
q: "{inputs[0]}"
## there are 2016 records with drugcentral.fda_adverse_event fields
## most of them (1994) also have the drugcentral.xrefs.chembl_id field
scopes: drugcentral.xrefs.chembl_id
header: application/x-www-form-urlencoded
inputs:
- id: CHEMBL.COMPOUND
semantic: ChemicalSubstance
outputs:
- id: MEDDRA
semantic: Disease
predicate: causes_adverse_event ## current biolink predicate
## through drugcentral, FDA Adverse Event Reporting System (FAERS) information
source: "infores:drugcentral"
response_mapping:
"$ref": "#/components/x-bte-response-mapping/adverseEvent"
adverseEventCausedBy:
- supportBatch: true
inputSeparator: ","
parameters:
## there are 2016 records with drugcentral.fda_adverse_event fields
## most of them (1994) also have the drugcentral.xrefs.chembl_id field
fields: drugcentral.xrefs.chembl_id
size: '1000'
requestBody:
body:
q: "{inputs[0]}"
scopes: drugcentral.fda_adverse_event.meddra_code
header: application/x-www-form-urlencoded
outputs:
- id: CHEMBL.COMPOUND
semantic: ChemicalSubstance
inputs:
- id: MEDDRA
semantic: Disease
predicate: adverse_event_caused_by ## current biolink predicate
source: "infores:drugcentral"
response_mapping:
"$ref": "#/components/x-bte-response-mapping/drugcentral-chembl"

0 comments on commit bb98838

Please sign in to comment.