This section describes how to configure the annotation pane using REST APIs. It contains the following sections:
Gets all the annotation pane UI details as JSON.
PATH | <server url>/ohpm/opmconfigapi/v1.0/config/annotationPane |
ACCEPTS | application/json |
RETURNS | application/json |
METHOD | GET |
Code | Reason | Representation (Example) |
---|---|---|
200 | success |
{ "eltWid": 1, "type": "PANE", "level": 0, "displayOrder": 0, "label": "Annotation", "items": [{ "eltWid": 2, "type": "INPUT", "level": 1, "displayOrder": 0, "label": "Significance", "data_type": "ENUM", "attr_wid": 57, "data_key": "significance", "options": { "multiple": false, "read_only": false, "display": true, "allow_custom": false }, "values": [{ "wid": 2, "label": "Likely Benign", "value": 2, "displayOrder": 3 }, { "wid": 1, "label": "Unknown Significance", "value": 1, "displayOrder": 4 }] }, { "eltWid": 3, "type": "INPUT", "level": 1, "displayOrder": 1, "label": "Associated Diagnosis", "data_type": "LOOKUP", "attr_wid": 71, "data_key": "var_associated_diseases", "data_url": "diagnoses", "options": { "multiple": true, "read_only": false, "display": true, "allow_custom": true } }] }
This updates the label, display (True or False) and Display Order on the Annotation pane. The user has to be admin role of pm_admin_group.
Note:
While updating, make sure the display order is correct. This value cannot be duplicated for all siblings.PATH | <server url>/ohpm/opmconfigapi/v1.0/config/annotationPane/changed |
ACCEPTS | application/json |
RETURNS | application/json |
METHOD | PUT |
PARAMETER | DESCRIPTION | PARAMETER TYPE | DATA TYPE/ REPRESENTATION |
---|---|---|---|
body | body |
[{ "etlWid":Number, "label":String, "display" : String, "displayOrder" : String }] |
[{ "eltWid": 2, "label": "Significance", "display": true, "displayOrder": 0 }, { "eltWid": 3, "label": "Associated Diagnosis", "display": true, "displayOrder": 1 }]
Code | Reason | Representation (Example) |
---|---|---|
200 | success |
This lets the user update the Label element on the annotation pane. The user must have the admin role of pm_admin_group.
PATH | <server url>/ohpm/opmconfigapi/v1.0/config/panes/annotation/labels |
ACCEPTS | application/json |
RETURNS | application/json |
METHOD | PUT |
PARAMETER | DESCRIPTION | PARAMETER TYPE | DATA TYPE/ REPRESENTATION |
---|---|---|---|
body | body |
{ "eltType": String, "eltDataKey": String, "label": String }] |
[{ "eltType":"SECTION", "eltDataKey":"external_information", "label":"Externals" }, { "eltType":"INPUT", "eltDataKey":"significance", "label":"Variant Significance" }]
Code | Reason | Representation (Example) |
---|---|---|
200 | success |
The following table shows examples of request body for different element types.
Element Types | Body |
---|---|
Group SECTION Label |
[{ "eltType":"SECTION", "eltDataKey":"external_information", "label":"Externals" }] |
INPUT Label |
[{ "eltType":"INPUT", "eltDataKey":"significance", "label":"Variant Significance" }] |
SECTION Label for COMBO |
[{ "eltType":"SECTION", "eltDataKey":"clinvar", "label":"ClinVar Info" }] |
INPUT Label for COMBO: set it null |
[{ "eltType":"INPUT", "eltDataKey":"clinvar", "label":null }] |
INPUT Label for COMBO: set it value |
[{ "eltType":"INPUT", "eltDataKey":"n_of_one", "label":"Send to Interpret" }] |
INPUT Label: set it value |
[{ "eltType":"INPUT", "eltDataKey":"drug_response_phenotype", "label":"Drug Response" }] |
Error: Wrong eltType |
[{ "eltType":"PANE1", "eltDataKey":null, "label":"Annotation Pane" }] |
Error: Wrong eltDataKey |
[{ "eltType":"INPUT", "eltDataKey":"significance1", "label":"Variant Significance" }] |
Error: Element is marked as deleted eltDataKey |
[{ "eltType":"INPUT", "eltDataKey":"drug_response_phenotype", "label":"Variant Drug Response Phenotype" }] |
This lets the user manipulate the display of SECTION/INPUT elements (hide or show) on the annotation pane. The user must have the admin role of pm_admin_group.
PATH | <server url>/ohpm/opmconfigapi/v1.0/config/panes/annotation/display |
ACCEPTS | application/json |
RETURNS | application/json |
METHOD | PUT |
PARAMETER | DESCRIPTION | PARAMETER TYPE | DATA TYPE/ REPRESENTATION |
---|---|---|---|
body | body |
[ { "eltDataKey": String, "position": String, "refPointEltDataKey": String } ]Note: Elements referenced by eltDataKey and refPointEltDataKey must be on the same level on the Annotation Pane layout. |
[{ "eltDataKey":"cell_line", "position":"first", "refPointEltDataKey":null }, { "eltDataKey":"clinvar", "position":"last", "refPointEltDataKey":null }, { "eltDataKey":"external_information", "position":"after", "refPointEltDataKey":"cell_line" }, { "eltDataKey":"significance", "position":"before", "refPointEltDataKey":"comments" }]
Code | Reason | Representation (Example) |
---|---|---|
200 | success |
The following table shows examples of request body for different element types.
Element Types | Body |
---|---|
Group SECTION Hide
For group section Show or display=true, an error is generated. You do not need to show any empty group section. But if you need to show at least one child INPUT or COMBO INPUT (SECTION + INPUT) - this group section is automatically displayed. |
[{ "eltType":"SECTION", "eltDataKey":"external_information", "display":"false" }] |
SECTION for COMBO Hide/Show |
[{ "eltType":"SECTION", "eltDataKey":"clinvar", "display":"false" }] |
INPUT for COMBO Hide/Show |
[{ "eltType":"INPUT", "eltDataKey":"clinvar", "label":"ClinVar Info" }] |
INPUT Label for COMBO: set it null |
[{ "eltType":"INPUT", "eltDataKey":"clinvar", "label":null }] |
INPUT |
[{ "eltType":"INPUT", "eltDataKey":"significance", "display":"false" }] |
Error: Wrong eltType
{ "errorMessage": "Unsupported action for UI element SECTION was requested", "httpMessage": "Internal Server Error", "httpStatusCode": 500, "appErrorCode": "19-02787-47284", "errorMessageKey": "MI_CONFIG_ELEMENT_TYPE_UNSUPPORTED_ACTION" } |
[{ "eltType":"SECTION", "eltDataKey": "external_information", "display":"true" }] |
Error: Wrong eltDataKey
{ "errorMessage": "Querying ui element table produced no results for annotation", "httpMessage": "Internal Server Error", "httpStatusCode": 500, "appErrorCode": "19-02784-95113", "errorMessageKey": "MI_CONFIG_EMPTY_ANNOTATION_QUERY_RESULT" |
[{ "eltType":"INPUT", "eltDataKey":"significance1", "display":"false" }] |
Error: Element is marked as deleted eltDataKey
{ "errorMessage": "Querying ui element table produced no results for annotation", "httpMessage": "Internal Server Error", "httpStatusCode": 500, "appErrorCode": "19-02783-48347", "errorMessageKey": "MI_CONFIG_EMPTY_ANNOTATION_QUERY_RESULT" } |
[{ "eltType":"INPUT", "eltDataKey":"drug_response_phenotype", "display":"false" }] |
This lets the user reorder SECTION/INPUT elements on the same level of the annotation pane. The user must have the admin role of pm_admin_group.
PATH | <server url>/ohpm/opmconfigapi/v1.0/config/panes/annotation/reorder |
ACCEPTS | application/json |
RETURNS | application/json |
METHOD | PUT |
PARAMETER | DESCRIPTION | PARAMETER TYPE | DATA TYPE/ REPRESENTATION |
---|---|---|---|
body | body |
[{ "eltType": String, "eltDataKey": String, "display": String }] |
[{ "eltType":"SECTION", "eltDataKey":"external_information", "display":"false" }, { "eltType":"SECTION", "eltDataKey":"clinvar", "display":"false" }]
Code | Reason | Representation (Example) |
---|---|---|
200 | success |
The following table shows examples of request body for different element types.
Element Types | Body |
---|---|
Move external_information after cell_line on the Annotation Pane:
No change – default order |
[{ "eltDataKey":"external_information", "position":"after", "refPointEltDataKey":"cell_line" }] |
Move external_information as first element on the Annotation Pane |
[{ "eltDataKey":"external_information", "position":"first", "refPointEltDataKey":null }] |
Move external_information as last element on the Annotation Pane |
[{ "eltDataKey":"external_information", "position":"last", "refPointEltDataKey":null }] |
Restore external_information after cell_line on the Annotation Pane |
[{ "eltDataKey":"external_information", "position":"after", "refPointEltDataKey":"cell_line" }] |
Restore n_of_one after clinvar in the External Information Section |
[{ "eltDataKey":" n_of_one", "position":"after", "refPointEltDataKey":"clinvar" }] |