Difference between revisions of "Resource Index REST Web Service User Guide"
(103 intermediate revisions by 7 users not shown) | |||
Line 1: | Line 1: | ||
+ | '''version 2.0 (REST Web Services API) is obsolete | ||
+ | NCBO BioPortal v4.0 REST services are documented at: http://data.bioontology.org/documentation''' | ||
+ | |||
===Introduction=== | ===Introduction=== | ||
The Resource Index API is available through a REST web services interface. | The Resource Index API is available through a REST web services interface. | ||
Line 5: | Line 8: | ||
The Resource index API is based on the web service that returns annotations from the Resource Index (called via a REST post). Additionally some simplified REST get services returned simplified results. | The Resource index API is based on the web service that returns annotations from the Resource Index (called via a REST post). Additionally some simplified REST get services returned simplified results. | ||
+ | |||
+ | |||
+ | ---- | ||
===Sample HTTP Client for the Resource Index REST Web Service=== | ===Sample HTTP Client for the Resource Index REST Web Service=== | ||
− | Test HTML Page : http://rest.bioontology.org/resource_index/test | + | * Test HTML Page : http://rest.bioontology.org/resource_index/test |
+ | |||
+ | * Test HTML Page ('''element per concept(s)''') : http://rest.bioontology.org/resource_index/test/search | ||
+ | |||
+ | === List of Resource Index Resources === | ||
+ | * Resources Page : http://rest.bioontology.org/resource_index/resources/list/ | ||
− | + | ===Service endpoints=== | |
+ | * To retrieve "annotations" either per element or per concept(s) : http://rest.bioontology.org/resource_index/ | ||
− | + | * To retrieve "element" per concept(s) : http://rest.bioontology.org/resource_index/search | |
− | + | === Resource Index Web service Validation === | |
+ | * '''<font color='red'>Note</font>''': All NCBO REST Web services will be required to contain the parameter "apikey=YourApiKey" starting June 2011. The parameter will be added to all Web service calls for the April 27, 2011 release but will not be required until June 2011. To obtain an API key, login to BioPortal and go to "Account" where your API key will be displayed. The addition of the API key replaces the use of the email parameter. | ||
+ | |||
+ | * '''''Note for Application Developers''''': Application developers will also need to include the apikey parameter on all NCBO Web service calls. This allows us to track usage of our system at the level of an application. To obtain an API key, login to BioPortal and go to "Account" where your API key will be displayed. The addition of the API key replaces the use of the email parameter. | ||
=== POST calls === | === POST calls === | ||
− | POST your requests at the service | + | POST your requests at the service endpoints. |
− | ==== | + | ====Parameters==== |
The Resource Index web service offers a set of parameters that allows a user to customize the annotations returned according to his specific requirements. For example, the annotations returned can be limited to a specific set of ontology and a specific set of semantic types. Plus, the expanded annotations can be filtered. | The Resource Index web service offers a set of parameters that allows a user to customize the annotations returned according to his specific requirements. For example, the annotations returned can be limited to a specific set of ontology and a specific set of semantic types. Plus, the expanded annotations can be filtered. | ||
Line 26: | Line 41: | ||
Please see below for the list of parameters and the possible values. | Please see below for the list of parameters and the possible values. | ||
− | {| border="1" cellpadding="2" | + | '''Note** :''' ''Parameter '''apikey''' and '''applicationid''' applies to all POST and GET calls.'' |
+ | |||
+ | {| border="1" cellpadding="2" | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''apikey**''' | ||
+ | |width="10%"|{apikey} | ||
+ | |width="10%"|default: null | ||
+ | |width="70%"|User identification query parameter with the pattern of "apikey=YourAPIKey". This parameter replaces the email parameter. The parameter will be required in June 2011. | ||
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''applicationid**''' |
+ | |width="10%"|{applicationid} | ||
+ | |width="10%"|default: null | ||
+ | |width="70%"|Identifies the application calling the REST service. To receive your "applicationid" please request one from [mailto:support@bioontology.org Support]. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''ontologiesToKeepInResult''' | ||
|width="10%"|{localOntology1,...,localOntologyN} | |width="10%"|{localOntology1,...,localOntologyN} | ||
|width="10%"|default: empty (i.e. all ontologies) | |width="10%"|default: empty (i.e. all ontologies) | ||
|width="70%"|Specifies the list of ontologies you want to filter in the result from the annotation process. The list of ontologies that can be used is available in the sample HTML page. The values are separated with comma (without spaces) | |width="70%"|Specifies the list of ontologies you want to filter in the result from the annotation process. The list of ontologies that can be used is available in the sample HTML page. The values are separated with comma (without spaces) | ||
− | * For example, | + | * For example, 42789,42838,42142. |
+ | |||
|-valign="top" | |-valign="top" | ||
|width="10%"|'''semanticTypes''' | |width="10%"|'''semanticTypes''' | ||
|width="10%"|{semanticType1,...,semanticTypeN} | |width="10%"|{semanticType1,...,semanticTypeN} | ||
|width="10%"|default: empty (i.e. all semanticTypes) | |width="10%"|default: empty (i.e. all semanticTypes) | ||
− | |width="70%"|Specifies the list of semantic types to use in the annotation process. The list of semantic types that can be used is available at the /obs/semanticTypes URL. Note that the restriction to semantic types is also applied during the semantic expansion steps. | + | |width="70%"|Specifies the list of UMLS semantic types to use in the annotation process. The list of semantic types that can be used is available at the /obs/semanticTypes URL. Note that the restriction to semantic types is also applied during the semantic expansion steps. |
* For example, T047,T048,T191. | * For example, T047,T048,T191. | ||
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''levelMax''' |
|width="10%"|{integer} | |width="10%"|{integer} | ||
|width="10%"|default: 0 | |width="10%"|default: 0 | ||
− | |width="70%"|Specifies the | + | |width="70%"|Specifies the maximum level a parent concept must have to be considered for the is_a semantic closure expansion step. |
− | * For example, an annotation done with | + | * For example, an annotation done with levelMax=3 will expand a direct annotations done with a concept up to the 3rd level parent in the is_a hierarchy for this concept. An annotation done with levelMax=0 is equivalent to disable the is_a transitive closure expansion step. |
+ | |||
|-valign="top" | |-valign="top" | ||
|width="10%"|'''mappingTypes''' | |width="10%"|'''mappingTypes''' | ||
|width="10%"|{null,mappingType1,...,mappingTypeN} | |width="10%"|{null,mappingType1,...,mappingTypeN} | ||
|width="10%"|default: empty (i.e. all mappingTypes) | |width="10%"|default: empty (i.e. all mappingTypes) | ||
− | |width="70%"|Specifies the list of mapping | + | |width="70%"|Specifies the list of mapping types to use during the mapping expansion step. The list of rmapping types that can be used is available at the /obs/mappingTypes URL. The current list is described in section Mapping types. |
− | * For example, | + | * For example, Automatic,Manual. |
− | * Note that the use of the key word "'''null'''" in the mappingTypes list disables the mapping expansion component. | + | * Note that the use of the key word "'''null'''" in the mappingTypes list disables the mapping expansion component. |
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''filterNumber''' | ||
+ | |width="10%"|{true, false} | ||
+ | |width="10%"|default: true | ||
+ | |width="70%"|Specifies whether the concept recognition step to filter numbers or not. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''minTermSize''' | ||
+ | |width="10%"|{integer} | ||
+ | |width="10%"|default: 0 | ||
+ | |width="70%"|Specifies the minimum length of the term to be included in the annotations. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''withSynonyms''' | ||
+ | |width="10%"|{true, false} | ||
+ | |width="10%"|default: true | ||
+ | |width="70%"|Specifies either or not the direct annotations are done with or without Synonyms. By default it includes all the synonyms and preferred name. If 'false' is selected, the direct annotations are done with only preferred name. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''additionalStopWords''' | ||
+ | |width="10%"|{stopWord1,...,stopWordN} | ||
+ | |width="10%"|default: empty (i.e. none) | ||
+ | |width="70%"|Specifies the list of additional stop words to use. Already used stop words are available here: [[http://rest.bioontology.org/obs/stopwords]] | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''isStopWordsCaseSenstive ''' |
− | |width="10%"|{ | + | |width="10%"|{true, false} |
+ | |width="10%"|default: false | ||
+ | |width="70%"|Specifies whether stopwords are case-sensitive or not. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''conceptids''' | ||
+ | |width="10%"|{conceptid1,...,conceptidn} | ||
|width="10%"|default: empty (i.e. all concepts) | |width="10%"|default: empty (i.e. all concepts) | ||
− | |width="70%"|Specifies the list of concept to use to query the Resource index (i.e., get the annotations done with this list). This parameter must be jointly specified with the mode parameter. If | + | |width="70%"|Specifies the list of concept to use to query the Resource index (i.e., get the annotations done with this list). This parameter must be jointly specified with the mode parameter. If conceptids contains only one element then the mode parameter can be ignored. The values are separated with comma (without spaces). |
− | * For example, | + | * For example, 40401/D008545,4513/Virtual_surface. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''isVirtualOntologyId''' |
|width="10%"|{true, false} | |width="10%"|{true, false} | ||
|width="10%"|default: false | |width="10%"|default: false | ||
− | |width="70%"|Specifies the if the list of ontologies are all BioPortal virtual ontology | + | |width="70%"|Specifies the if the list of ontologies are all BioPortal virtual ontology ids. This parameter applies to both conceptids and ontologiesToKeepInResult parameters. |
|-valign="top" | |-valign="top" | ||
Line 70: | Line 132: | ||
|width="10%"|{union, intersection} | |width="10%"|{union, intersection} | ||
|width="10%"|default: union | |width="10%"|default: union | ||
− | |width="70%"|Specifies the mode to use when querying the resource index with several concept (parameter | + | |width="70%"|Specifies the mode to use when querying the resource index with several concept (parameter conceptids ). The union mode returns the union of all the annotations (filtered eventually with other parameters) done with each specified conceptid. The intersection mode returns the intersection. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''elementid''' |
|width="10%"| | |width="10%"| | ||
|width="10%"|default: all | |width="10%"|default: all | ||
− | |width="70%"|Specifies the identifier of the resource element for which annotations are requested. The | + | |width="70%"|Specifies the identifier of the resource element for which annotations are requested. The elementid is defined by the original resource e.g., PMID for PubMed, NCT for ClinicalTrials. The full list of the elementid type is defined in Section Local element ID used. |
* For example, NCT00001589 or GDS2735. | * For example, NCT00001589 or GDS2735. | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''resourceids''' |
|width="10%"| | |width="10%"| | ||
|width="10%"|default: all | |width="10%"|default: all | ||
− | |width="70%"|Specifies the resource to filter the annotations with. The | + | |width="70%"|Specifies the resource to filter the annotations with. The resourceids identifies a resource in the Resource Index. They are defined in section Resource identifiers. The list of resourceids can be used is available at the /obs/resources URL. |
* For example, GEO,CT,AE. | * For example, GEO,CT,AE. | ||
Line 96: | Line 158: | ||
|width="10%"|{true, false} | |width="10%"|{true, false} | ||
|width="10%"|default: true | |width="10%"|default: true | ||
− | |width="70%"|Specifies whether the annotations context information to be available or not.If turn to false, the set of annotations returned will be simplified and will not detail the context information for an annotation. Only the score will be returned | + | |width="70%"|Specifies whether the annotations context information to be available or not. If turn to false, the set of annotations returned will be simplified and will not detail the context information for an annotation. Only the score will be returned. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''offset and limit''' |
− | |width="10%"|{ | + | |width="10%"|{integer} |
− | |width="10%"|default: | + | |width="10%"|default: 0/10 respectively |
− | |width="70%"|Specifies an offset | + | |width="70%"|Specifies an offset and limits the number of annotation results. |
|-valign="top" | |-valign="top" | ||
|width="10%"|'''format''' | |width="10%"|'''format''' | ||
− | |width="10%"|{ | + | |width="10%"|{text, tabDelimited, owl, rdf, xml} |
− | |width="10%"|default: | + | |width="10%"|default: xml |
− | |width="70%"|Specifies the desired format of the response. | + | |width="70%"|Specifies the desired format of the response. RDF and OWL outputs are defined according to a RDFS schema and OWL ontology respectively available here: http://obs.bioontology.org/ontologies/BioPortalAnnotation.rdfs and http://obs.bioontology.org/ontologies/NCBO_OBS_ontology.owl |
+ | |||
+ | |} | ||
+ | |||
+ | ===Web Service Response=== | ||
+ | |||
+ | '''Response Format''' | ||
+ | {| border="1" cellpadding="2" | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''text''' | ||
+ | |width="90%"| Returns plain text representation of the ObrResultBean(Detailled). | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''tabDelimited''' | ||
+ | |width="90%"| Shorter version of "Text" format, returns not the full result content but the annotations only (no statistics, etc.). The format of the tab delimited file is: score \t conceptId \t preferredName \t synonyms (separated by ' /// ') \t semanticType (separated by ' /// ') \t contextName \t isDirect \t other context information (e.g., childConceptId, mappedConceptId, level, mappingType) (separated by ' /// '). | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''xml''' | ||
+ | |width="90%"| Returns XML representation of the ObrResultBean(Detailled). | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''owl''' | ||
+ | |width="90%"| Returns OWL representation of the ObrResultBean(Detailled). The elementsof the result (dictionary, parameters, annotations, etc) are described as instances in the following ontology: http://obs.bioontology.org/ontologies/NCBO_OBS_ontology.owl | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''rdf''' | ||
+ | |width="90%"| Returns RDF representation of the annotations in ObrResultBean(Detailled). The elements of the result are described as instances in the following ontology: http://obs.bioontology.org/ontologies/BioPortalAnnotation.rdfs | ||
+ | |} | ||
+ | |||
+ | '''Note :''' ''if request parameter withContext is true, then returns representation of the ObrResultBeanDetailed and if request parameter withContext is false, then returns representation of the ObrResultBean.'' | ||
+ | |||
+ | '''Response Content: ObrResultBeanDetailed''' | ||
+ | |||
+ | Response ObrResultBeanDetailed contains all the contents of ObrResultBean. Those contents are described in section Response Content: ObrResultBean. | ||
+ | |||
+ | Following are remaining contents for ObrResultBeanDetailed : | ||
+ | |||
+ | {| border="1" cellpadding="2" | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''directAnnotations''' | ||
+ | |width="90%"| One '''annotation''' is represented by ''ObrAnnotationBean''. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''isaAnnotations''' | ||
+ | |width="90%"| One '''annotation''' is represented by ''ObrAnnotationBean''. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''mappingAnnotations''' | ||
+ | |width="90%"| One '''annotation''' is represented by ''ObrAnnotationBean''. | ||
+ | |||
+ | |} | ||
+ | |||
+ | '''Note :''' ''Response contents of the ObrAnnotationBean are described in section ObrResultBean annotations'' | ||
+ | |||
+ | |||
+ | '''Response Content: ObrResultBean''' | ||
+ | {| border="1" cellpadding="2" | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''resultId''' | ||
+ | |width="90%"| | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''dictionary''' | ||
+ | |width="90%"| Dictionary contains the metadata (not the content) of the dictionary used for a result. dictionaryId, dictionaryName, and dictionaryDate identify the dictionary on the server side and give information about its content. Dictionary versioning is strongly linked to the evolution of the ontologies used. Each time ontologies change, the dictionary is updated. All the dictionary information may be useful for comparing results of the Annotator Restlet service on time. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''resultStatistics''' | ||
+ | |width="90%"| Each '''statistics''' contains information on the number of annotations done for a given context. The contextName keyword identifies the type of context and annotationCount is the number of annotations of this type. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''parameters''' | ||
+ | |width="90%"| Parameters summarizes all the parameters specified by the user when requesting the Annotator Restlet service. Those parameters are described in section Service parameters | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''ontologies''' | ||
+ | |width="90%"| To keep the model simple, we provide only the global ontology identifier, localOntologyId the name (ontologyName) and version (ontologyVersion). This information come from the original repositories (UMLS/BioPortal) and might help the user to select the right ontology to use. When an ontology is used in the annotation, a result has a set of OntologyUsed which specify 2 other properties: nbAnnotation, the number of annotation that have been made with concepts from this ontology. score, the sum of all the scores of the annotations done with concepts from this ontology (if parameter scored=true). Therefore, score represents the most accurate ontology to annotate the given text. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''annotations''' | ||
+ | |width="90%"| ''ObrAnnotationBean/ObrAnnotationBeanDetailed'' is a representation of one '''annotation/annotationDetailed'''. If ''elementDetails'' parameter is true the service return response of type '''annotation''', otherwise '''annotationDetailed'''. An annotation has a score which represents the accuracy of the annotation computed by the scoring algorithm (if the scored=true parameter was chosen, otherwise score=-1). An annotation is done with a concept in a context. | ||
+ | |||
+ | '''Response Content: ObrAnnotationBeanDetailled''' | ||
+ | |||
+ | Response ObrAnnotationBeanDetailed contains all the contents of ObrAnnotationBean. Those contents are described in section Response Content: ObrAnnotationBean. | ||
+ | |||
+ | Following are remaining contents for ObrAnnotationBeanDetailed : | ||
+ | |||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''element''' | ||
+ | |width="90%"| | ||
+ | * ''localElementId'' - Global identifier for the resource element. | ||
+ | * ''elementStructure'' - Represents Structure of an element for a given resource. | ||
+ | |||
+ | '''Response Content: Structure''' | ||
+ | |||
+ | {| border="2" style="background:#ABCDEF;"<!-- The nested table must be on a new line --> | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''resourceId''' | ||
+ | |width="90%"|resource identifier for Resource. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''contexts''' | ||
+ | |width="90%"|list of context for resource. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''itemKeys''' | ||
+ | |width="90%"|list of itemKeys for resource. | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''weights''' | ||
+ | |width="90%"|map contain weights (as double) for each context (as String). | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''ontoIds''' | ||
+ | |width="90%"|map contain ontologyIds for each context (as String). | ||
+ | |} | ||
+ | |||
+ | |} | ||
+ | |||
+ | '''Response Content: ObrAnnotationBean''' | ||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''localElementId''' | ||
+ | |width="90%"| Identifier for resource element. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''score''' | ||
+ | |width="90%"| | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''concept''' | ||
+ | |width="90%"| | ||
+ | * ''localConceptId'' - global identifier for the concept in its original repository. | ||
+ | * ''localOntologyId'' - identifier for the ontology in which the concept is defined. | ||
+ | * ''isTopLevel'' - specifies if the concept is a root concept in its ontology. | ||
+ | * ''preferredName'' - label or preferred term for this concept (as assigned by the original repository). | ||
+ | * ''synonyms'' - the set of possible terms that represent the concept but are not preferred. | ||
+ | * ''semanticTypes'' - the set of the semantic types of the concept (assigned by UMLS + T000 and T999). | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''context''' | ||
+ | |width="90%"| Context specifies if it is a direct or expanded annotation and give precision about the origin of the annotation. ''contextName'' identifies the type of context. The context properties vary with the type of concept. There are 3 possible contexts identified by their contextName: | ||
+ | {| border="2" style="background:#ABCDEF;" <!-- The nested table must be on a new line --> | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''MGREP''' | ||
+ | |width="90%"| represents direct annotations done with the Mgrep concept recognizer. A Mgrep context has 3 properties: | ||
+ | * ''termName'' - the expression (preferred name or synonyms) that was matched by Mgrep. | ||
+ | * ''from'' and ''to'' - specify the character index in the given text for the matched expression. Attention, those values are in number of bytes, not characters e.g., ½ is a two-byte character, thus will count for 2 characters. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''ISA_CLOSURE''' | ||
+ | |width="90%"| represents expanded annotations done with the ''is_a'' transitive closure expansion component. A ISA_CLOSURE context has 2 properties: | ||
+ | * ''childConceptId'' - the concept from which the annotation was derived. | ||
+ | * ''level'' - the distance in the is_a hierarchy between the annotating concept and the concept from which the annotation was derived. | ||
+ | * ''from'' and ''to'' - specify the character index in the given text for the matched expression. | ||
+ | * For example, if a direct annotation with NCI/C0025202 (melanoma) was done, the is_a transitive closure component may expand it to another annotation with NCI/C1302746 (Melanocytic Neoplasm) because the latter is a direct parent (i.e., level 1) concept of the former. The ISA_CLOSURE annotation generated will have the following properties {NCI/C0025202, 1}. | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''MAPPING''' | ||
+ | |width="90%"| represents expanded annotations done with the mapping expansion component. A MAPPING context has 2 properties: | ||
+ | * mappedConceptId identifies the concept from which the annotation was derived. | ||
+ | * mappingType specifies the type of mapping. | ||
+ | * ''from'' and ''to'' - specify the character index in the given text for the matched expression. | ||
|} | |} | ||
+ | |} | ||
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''localElementId localConceptIds mode withContext elementDetails counts offsetStart offsetMax''' | ||
+ | |width="90%"| Parameters summarizes all the parameters specified by the user when requesting the Resource Index Restlet service. Those parameters are described in section Service parameters | ||
+ | |} | ||
− | ===GET | + | ===GET calls=== |
Following section describes all other simplified GET services available in Resource_Index_API. | Following section describes all other simplified GET services available in Resource_Index_API. | ||
====Annotation by Concept Service==== | ====Annotation by Concept Service==== | ||
− | Returns the set of annotations done with a given | + | Returns the set of annotations done with a given localConceptId. |
− | *GET Request Format : ''/byconcept/{ | + | *GET Request Format : '''/byconcept/{ontologyid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}''' |
− | *Example : http://rest.bioontology.org/resource_index/byconcept/ | + | *Example : http://rest.bioontology.org/resource_index/byconcept/42838/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey |
− | + | *Old Request Format* : | |
− | *Response Content : ObrResultBean/ | + | **/byconcept/{ontologyID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID} |
+ | **/byconcept/{ontologyID}/{conceptID}/{withContext}/{counts}/{from}/{number} | ||
+ | |||
+ | *Response Content : ''ObrResultBean/ObrResultBeanDetailed'' is a representation of '''result/resultDetailed'''. If request parameter withContext is true, then returns representation of the '''resultDetailed''' and if request parameter withContext is false, then returns representation of the '''result'''. | ||
====Annotation for BioPortal virtual ontology Concept Service ==== | ====Annotation for BioPortal virtual ontology Concept Service ==== | ||
− | Returns the set of all annotations done with a given | + | Returns the set of all annotations done with a given localConceptId using BioPortal virtual ontology id. |
− | *GET Request Format : ''/byconcept/virtual/{ | + | *GET Request Format : '''/byconcept/virtual/{virtual_ontology_id}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}''' |
− | *Example : http://rest.bioontology.org/resource_index/byconcept/virtual/ | + | *Example : http://rest.bioontology.org/resource_index/byconcept/virtual/1032/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey |
+ | *Old Request Format* : | ||
+ | **/byconcept/virtual/{virtualOntologyID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID} | ||
+ | **/byconcept/virtual/{virtualOntologyID}/{conceptID}/{withContext}/{counts}/{from}/{number} | ||
− | *Response Content : ObrResultBean/ | + | *Response Content : ''ObrResultBean/ObrResultBeanDetailed'' is a representation of '''result/resultDetailed'''. |
====Annotation By Concept And Resource Service ==== | ====Annotation By Concept And Resource Service ==== | ||
− | Returns the set of all annotations done with a given | + | Returns the set of all annotations done with a given localConceptId for given resourceId. |
− | *GET Request Format : ''/byconcept/{ | + | *GET Request Format : '''/byconcept/{ontologyid}/{resourceid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}''' |
− | *Example : http://rest.bioontology.org/resource_index/byconcept/ | + | *Example : http://rest.bioontology.org/resource_index/byconcept/42838/AE/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey |
+ | *Old Request Format* : | ||
+ | **/byconcept/{ontologyID}/{resourceID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID} | ||
+ | **/byconcept/{ontologyID}/{conceptID}/{resourceID}/{withContext}/{counts}/{from}/{number}/{from}/{number} | ||
− | *Response Content : ObrResultBean/ | + | *Response Content : ''ObrResultBean/ObrResultBeanDetailed'' is a representation of '''result/resultDetailed'''. |
====Annotation for BioPortal virtual ontology Concept And Resource Service ==== | ====Annotation for BioPortal virtual ontology Concept And Resource Service ==== | ||
− | Returns the set of all annotations done with a given | + | Returns the set of all annotations done with a given localConceptId using BioPortal virtual ontology id and using particular resourceId. |
+ | |||
+ | *GET Request Format : '''/byconcept/virtual/{virtual_ontology_id}/{resourceid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}''' | ||
+ | *Example : http://rest.bioontology.org/resource_index/byconcept/virtual/1032/AE/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey | ||
+ | *Old Request Format* : | ||
+ | **/byconcept/virtual/{virtualOntologyID}/{resourceID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID} | ||
+ | **/byconcept/virtual/{virtualOntologyID}/{conceptID}/{resourceID}/{withContext}/{counts}/{from}/{number} | ||
+ | |||
+ | *Response Content : ''ObrResultBean/ObrResultBeanDetailed'' is a representation of '''result/resultDetailed'''. | ||
− | *GET Request Format : ''/ | + | '''For Multiple resources using service at basis URL''' |
− | *Example : http://rest.bioontology.org/resource_index/ | + | *GET Request Format : '''/?conceptids={conceptids}&isVirtualOntologyId=true&resourceids={resourceids}&withContext={withContext}&counts={counts}&offset={offset}&limit={limit}&levelMax=2147483647&filterNumber=false''' |
− | + | *Example : http://rest.bioontology.org/resource_index/?conceptids=1032/Melanoma&isVirtualOntologyId=true&resourceids=CT,DBK,OMIM,RXRD&withContext=true&counts=true&offset=0&limit=10&levelMax=2147483647&filterNumber=false&apikey=YourAPIKey | |
− | *Response Content : ObrResultBean/ | + | |
+ | *Response Content : '''result/resultDetailed''' for each resource. ''ObrResultBean/ObrResultBeanDetailed'' is a representation of one '''result/resultDetailed''' | ||
====Annotation By Resource Element Service ==== | ====Annotation By Resource Element Service ==== | ||
− | Returns the set of all annotations done with a given resource element | + | Returns the set of all annotations done with a given resource element localElementId for all the concepts. |
− | *GET Request Format : ''/byelement/{ | + | *GET Request Format : '''/byelement/{resourceid}/{elementDetails}{withContext}/{counts}/{offset}/{limit}?elementid={elementid}''' |
− | *Example : http://rest.bioontology.org/resource_index/byelement/ | + | *Example 1 : http://rest.bioontology.org/resource_index/byelement/AE/false/true/false/0/10?elementid=E-GEOD-18509&apikey=YourAPIKey |
+ | *Example 1 : http://rest.bioontology.org/resource_index/byelement/AE/true/true/false/0/10?elementid=E-GEOD-18509&apikey=YourAPIKey | ||
+ | |||
+ | *Old Request Format* : | ||
+ | **/byelement/{resourceID}/{withContext}/{counts}/{from}/{number}?elementID={localElementID} | ||
+ | **/byelement/{resourceID}/{localElementID}/{withContext}/{counts}/{from}/{number} | ||
− | *Response Content : ObrResultBean/ | + | *Response Content : ''ObrResultBean/ObrResultBeanDetailed'' is a representation of '''result/resultDetailed'''. |
====Annotation Details By Resource Element Service ==== | ====Annotation Details By Resource Element Service ==== | ||
− | Returns the set of all annotations details with a given resource element | + | Returns the set of all annotations details with a given resource element localElementId for given conceptId |
− | *GET Request Format : ''/details | + | *GET Request Format : '''/details/{elementDetails}/concept/{ontologyid}/resource/{resourceid}/{offset}/{limit}?conceptid={conceptid}&elementid={elementid}''' |
− | *Example : http://rest.bioontology.org/resource_index/details/concept/ | + | *Example : http://rest.bioontology.org/resource_index/details/true/concept/42838/resource/AE/0/10?conceptid=Melanoma&elementid=E-GEOD-18509&apikey=YourAPIKey |
+ | *Old Request Format* : | ||
+ | **/details/{elementDetails}/concept/{ontologyID}/resource/{resourceID}?conceptID={conceptID}&elementID={localElementID} | ||
+ | **/details/{elementDetails}/concept/{ontologyID}/{conceptID}/resource/{resourceID}/element/{localElementID} | ||
− | *Response Content : ObrAnnotationBean. | + | *Response Content : ''ObrAnnotationBean/ObrAnnotationBeanDetailed'' is a representation of one '''annotation/annotationDetailed'''. annotationDetailed if elementDetails is true otherwise annotation. |
====Annotation Details By Resource Element Service for BioPortal Virtual OntologyID==== | ====Annotation Details By Resource Element Service for BioPortal Virtual OntologyID==== | ||
− | Returns the set of all annotations details with a given resource element | + | Returns the set of all annotations details with a given resource element localElementId for given conceptId of BioPortal virtual ontologyId |
− | *GET Request Format : ''/details/virtual/concept/{ | + | *GET Request Format : '''/details/{elementDetails}/virtual/concept/{virtual_ontology_id}/resource/{resourceid}/{offset}/{limit}?conceptid={conceptid}&elementid={elementid}''' |
− | *Example : http://rest.bioontology.org/resource_index/details/virtual/concept/ | + | *Example : http://rest.bioontology.org/resource_index/details/true/virtual/concept/1032/resource/AE/0/10?conceptid=Melanoma&elementid=E-GEOD-18509&apikey=YourAPIKey |
+ | *Old Request Format* : | ||
+ | **/details/{elementDetails}/virtual/concept/{virtualOntologyID}/resource/{resourceID}?conceptID={conceptID}&elementID={localElementID} | ||
+ | **/details/{elementDetails}/virtual/concept/{virtualOntologyID}/{conceptID}/resource/{resourceID}/element/{localElementID} | ||
− | *Response Content : ObrAnnotationBean. | + | *Response Content : ''ObrAnnotationBean/ObrAnnotationBeanDetailed'' is a representation of one '''annotation/annotationDetailed'''. annotationDetailed if elementDetails is true otherwise annotation. |
====Resources Service ==== | ====Resources Service ==== | ||
Line 176: | Line 427: | ||
*GET Request Format : ''/resources'' | *GET Request Format : ''/resources'' | ||
− | *Example: http://rest.bioontology.org/resource_index/resources | + | *Example: http://rest.bioontology.org/resource_index/resources?apikey=YourAPIKey |
*Response Content : Resource is a representation of one resource | *Response Content : Resource is a representation of one resource | ||
Line 187: | Line 438: | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''resourceId''' |
|width="90%"| Identifier of the resource. | |width="90%"| Identifier of the resource. | ||
Line 218: | Line 469: | ||
{| border="2" style="background:#ABCDEF;"<!-- The nested table must be on a new line --> | {| border="2" style="background:#ABCDEF;"<!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''resourceId''' |
|width="90%"|resource identifier for Resource. | |width="90%"|resource identifier for Resource. | ||
Line 234: | Line 485: | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''ontoIds''' |
− | |width="90%"|map contain | + | |width="90%"|map contain ontology ids for each context (as String). |
|} | |} | ||
Line 241: | Line 492: | ||
====Resource Service ==== | ====Resource Service ==== | ||
− | Returns the resource in resource index for given | + | Returns the resource in resource index for given resource id and information related to it. |
+ | |||
+ | *GET Request Format : ''/resources/{resourceid}'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/resources/AE?apikey=YourAPIKey | ||
+ | *Old Request Format* : /resources/{resourceID} | ||
+ | *Response Content : ''Resource'' is a representation of one '''resource'''. | ||
+ | |||
+ | ====Resource Element Service ==== | ||
+ | Service returns elementURL for given localElementId and redirect it to get resource element on the web. | ||
+ | |||
+ | *GET Request Format : ''/element/{resourceid}?elementid={elementid}'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/element/AE?elementid=E-GEOD-9118&apikey=YourAPIKey | ||
+ | *Old Request Format* : /element/{resourceID}?element={localElementID} | ||
+ | *Response Content : Web page containing details of the element. | ||
+ | |||
+ | ====Element details service by elementid ==== | ||
+ | Returns detail for given element using resource id and element id | ||
− | *GET Request Format : ''/ | + | *GET Request Format : ''/elementDetails/{resourceid}?elementid={elementid}'' |
− | *Example: http://rest.bioontology.org/resource_index/ | + | *Example: http://rest.bioontology.org/resource_index/elementDetails/AE?elementid=E-GEOD-9118&apikey=YourAPIKey |
− | *Response Content : | + | *Response Content : element |
− | ==== | + | ====Elements detail service by chronology ==== |
− | + | Retruns elements details for given resource id cronologically | |
− | *GET Request Format : ''/ | + | *GET Request Format : ''/elements/{resourceid}?method={method}&offset={offset}&limit={limit}'' |
− | *Example: http://rest.bioontology.org/resource_index/ | + | *Example: http://rest.bioontology.org/resource_index/elements/AE?method=chronology&offset=0&limit=10&apikey=YourAPIKey |
− | *Response Content : | + | *Response Content : ''Element'' is a representation of one '''element'''. |
+ | |||
+ | ====Resources Service with ontologies used for indexing ==== | ||
+ | Returns the set of all resources available in resource index and list of onotolgies used for indexing them. | ||
+ | |||
+ | *GET Request Format : ''/resources?withontologies=true'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/resources?withontologies=true&apikey=YourAPIKey | ||
+ | *Old Request Format* : /resources?withOntologies=true | ||
+ | *Response Content : ObrResourceBean is a representation of one resource with ontologies | ||
+ | '''Response Content: ObrResourceBean''' | ||
− | + | Response ObrResourceBean contains all the contents of Resource. Those contents are described in section ''Response Content: Resource''. | |
− | + | Following are remaining contents for ObrResourceBean : | |
− | '''Response | + | {| border="2" <!-- The nested table must be on a new line --> |
− | {| border=" | + | |-valign="top" |
+ | |width="10%"|'''ontologiesUsed''' | ||
+ | |width="90%"| Presents list of ontologies used for indexing. Each ontology of type OntologyBean. | ||
+ | '''Response Content: OntologyBean''' | ||
+ | {| border="2" style="background:#ABCDEF;"<!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''localOntologyId''' |
− | |width="90%"| | + | |width="90%"|Local onotology id for Ontology. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''ontologyName''' |
− | |width="90%"| | + | |width="90%"|name of the resource. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''ontologyVersion''' |
− | |width="90%"| | + | |width="90%"|version number for resource. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''virtualOntologyId''' |
− | |width="90%"| | + | |width="90%"|virtual ontology id for ontology. |
+ | |} | ||
|} | |} | ||
− | ''' | + | ====Resource Service with ontologies used for indexing ==== |
+ | Returns the information about resources and list of onotolgies used for indexing it. | ||
+ | |||
+ | *GET Request Format : ''/resources/{resourceid}?withontologies=true'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/resources/AE?withOntologies=true&apikey=YourAPIKey | ||
+ | *Old Request Format : /resources/{resourceID}?withOntologies=true | ||
+ | *Response Content : '''resource''' is represented by ''ObrResourceBean''. | ||
− | + | ====Ontologies Service with resources indexed ==== | |
+ | Returns the set of all ontologies used in resource index with list of resources indexed by given ontology. | ||
− | + | *GET Request Format : ''/ontologies?withresources=true'' | |
+ | *Example: http://rest.bioontology.org/resource_index/ontologies?withresources=true&apikey=YourAPIKey | ||
− | + | *Response Content : Each '''ontology''' is represented by ''ObrOntologyBean''. | |
− | {| border | + | Response ObrOntologyBean contains all the contents of OntologyBean.Those contents are described in section Response Content: OntologyBean. |
+ | |||
+ | Following are remaining contents for ObrResourceBean : | ||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''resources''' |
− | |width="90%"| | + | |width="90%"| Represents list of resources. Response content for each '''resource''' is of type ''Resource''. |
+ | |} | ||
+ | |||
+ | ====Ontology Service with resources indexed ==== | ||
+ | Returns the information about given ontologies used in resource index with list of resources. | ||
+ | |||
+ | *GET Request Format : ''/ontologies/{ontologyid}'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/ontologies/42838?apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : '''ontology''' is represented by ''ObrOntologyBean''. | ||
+ | |||
+ | ====Virtual Ontology Service with resources indexed ==== | ||
+ | Returns the ontology versions in resource index with list of resources for given virtual_ontology_id. | ||
+ | |||
+ | *GET Request Format : ''/virtual/ontology/{virtual_ontology_id}?withresources={true|false}'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/virtual/ontology/1032?withresources=true&apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : List of '''ontology''' represented by ''ObrOntologyBean''. | ||
− | + | ====Concept Frequency Service==== | |
− | + | Returns the get most used concepts for given resource id. | |
− | |||
− | + | *GET Request Format : ''/most-used-concepts/{resourceid}?method={counts|score}&offset={offset}&limit={limit}'' | |
− | | | + | *Example: http://rest.bioontology.org/resource_index/most-used-concepts/AE?method=counts&offset=0&limit=10&apikey=YourAPIKey |
− | |||
− | + | *Response Content : '''conceptFrequency''' with format ''ObrConceptFrequencyBean''. | |
− | ''' | + | '''Response Content: ObrConceptFrequencyBean''' |
+ | Following are contents for ObrConceptFrequencyBean: | ||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''concept''' | ||
+ | |width="90%"|ConceptBean is a representation of concept | ||
− | |||
− | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''counts''' |
− | |width="90%"| | + | |width="90%"|Frequency counts for a concept . |
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''score''' |
− | |width="90%"| | + | |width="90%"|score for a concept . |
+ | |||
+ | |} | ||
+ | |||
+ | ====All Statistics Service==== | ||
+ | Returns the information about number of all the annotations done in resource index. | ||
+ | |||
+ | *GET Request Format : ''/statistics/all'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/statistics/all?apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : All '''statistics' represented by ''ObrStatisticsBean''. | ||
+ | |||
+ | '''Response Content: ObrStatisticsBean''' | ||
+ | Following are remaining contents for ObrStatisticsBean: | ||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''aggregatedAnnotations''' |
− | |width="90%"| | + | |width="90%"|Sum of the number of rows in all the indexing tables |
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''mgrepAnnotations''' |
− | |width="90%"| | + | |width="90%"|Number of mgrep annotations entries in direct annotation table. |
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''reportedAnnotations''' |
− | |width="90%"| | + | |width="90%"|Number of reported annotations entries in direct annotation table. |
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''isaAnnotations''' |
− | |width="90%"| | + | |width="90%"|Number of is-a annotations entries in extended annotation table. |
− | ''' | + | |-valign="top" |
+ | |width="10%"|'''mappingAnnotations''' | ||
+ | |width="90%"|Number of mapping annotations entries in extended annotation table. | ||
+ | |||
+ | |} | ||
− | + | ====Ontology Statistics Service==== | |
+ | Returns the total statistics for given ontology for All resources. | ||
− | + | *GET Request Format : ''/statistics/ontology/{ontologyid}'' | |
+ | *Example: http://rest.bioontology.org/resource_index/statistics/ontology/42838?apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : '''ontologyStatistics''' with format ''ObrOntologyStatisticsBean''. | ||
+ | '''Response Content: ObrOntologyStatisticsBean''' | ||
+ | Following are contents for ObrOntologyStatisticsBean: | ||
{| border="2" <!-- The nested table must be on a new line --> | {| border="2" <!-- The nested table must be on a new line --> | ||
+ | |-valign="top" | ||
+ | |width="10%"|'''resourceId''' | ||
+ | |width="90%"|Resource Id for resource. | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''statistics''' |
− | |width="90%"| | + | |width="90%"|ObrStatisticsBean is a representation of statistics |
− | + | ||
− | + | |} | |
+ | |||
+ | ====Ontology Statistics Service by resources==== | ||
+ | Returns the statistics for given ontology for each resource separately. | ||
− | '''Response Content: | + | *GET Request Format : ''/statistics/ontology/{onotlogyid}?byresource=true'' |
+ | *Example: http://rest.bioontology.org/resource_index/statistics/ontology/42838?byresource=true&apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : '''ontologyStatistics''' with format ''ObrOntologyStatisticsBean''. | ||
− | + | ====Resource Statistics Service==== | |
− | + | Returns the total statistics for given resource for All ontology. | |
− | |||
− | |||
− | + | *GET Request Format : ''/statistics/resource/{resourceid}'' | |
− | + | *Example: http://rest.bioontology.org/resource_index/statistics/resource/CANANO?apikey=YourAPIKey | |
− | + | ||
+ | *Response Content : '''resourceStatistics''' with format ''ObrResourceStatisticsBean''. | ||
+ | '''Response Content: ObrResourceStatisticsBean''' | ||
+ | Following are contents for ObrResourceStatisticsBean: | ||
+ | {| border="2" <!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''localOntologyId''' |
− | |width="90%"| | + | |width="90%"|local ontology id for given ontology. |
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''statistics''' |
− | |width="90%"| | + | |width="90%"|''ObrStatisticsBean'' is a representation of '''statistics'''. |
− | |||
− | |||
− | |||
|} | |} | ||
− | + | ====Resource Statistics Service by ontologies==== | |
+ | Returns the statistics for given resource for each ontology separately. | ||
+ | |||
+ | *GET Request Format : ''/statistics/resource/{resourceid}?byontology=true '' | ||
+ | *Example: http://rest.bioontology.org/resource_index/statistics/resource/AE?byontology=true&apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : '''resourceStatistics''' with format ''ObrResourceStatisticsBean''. | ||
− | + | ====All Executions Service==== | |
+ | Returns the information about all workflow executions done in resource index. | ||
+ | *GET Request Format : ''/executions'' | ||
+ | *Web Page Request Format : ''/executions/list/'' | ||
+ | *Examples: | ||
+ | **http://rest.bioontology.org/resource_index/executions?apikey=YourAPIKey | ||
+ | **http://rest.bioontology.org/resource_index/executions/list/?apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : List of all '''execution'' represented by ''ObrExecutionBean''. | ||
+ | |||
+ | '''Response Content: ObrExecutionBean''' | ||
+ | Following are remaining contents for ObrExecutionBean: | ||
{| border="2" <!-- The nested table must be on a new line --> | {| border="2" <!-- The nested table must be on a new line --> | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''resourceId''' |
− | |width="90%"| Identifier for | + | |width="90%"|Identifier of the resource. |
+ | |||
+ | |-valign="top" | ||
+ | |width="10%"|'''dictionaryId''' | ||
+ | |width="90%"|Identifier of the dictionary used for execution. | ||
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''withCompleteDictionary''' |
− | |width="90%"| | + | |width="90%"|Specifies if complete dictionary is used for execution or not (true/false). |
+ | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''elementCount''' |
− | |width="90%"| | + | |width="90%"|Number of elements updated/annotated in execution. |
− | + | ||
− | |||
− | |||
− | |||
− | |||
− | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''firstExecution''' |
− | |width="90%"| | + | |width="90%"|Boolean value specifies if execution is first execution. |
− | + | ||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''executionBeginning''' |
− | |width="90%"| | + | |width="90%"|Specifies Date/Time at which execution started. |
− | + | ||
− | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''executionEnd''' |
− | |width="90%"| | + | |width="90%"|Specifies Date/Time at which execution ended.. |
− | + | ||
− | |||
− | |||
|-valign="top" | |-valign="top" | ||
− | |width="10%"|''' | + | |width="10%"|'''executionTime''' |
− | |width="90%"| | + | |width="90%"|Time required (in HH:mm:ss format) to complete current execution. |
− | + | ||
− | |||
− | |||
|} | |} | ||
− | + | ====Resource Executions Service==== | |
− | + | Returns the information about workflow executions done for given resource in resource index. | |
− | + | ||
+ | *GET Request Format : ''/executions/{resourceid}'' | ||
+ | *Example: http://rest.bioontology.org/resource_index/executions/WP?apikey=YourAPIKey | ||
+ | |||
+ | *Response Content : '''execution'' represented by ''ObrExecutionBean''. | ||
+ | ---- | ||
+ | '''Note* :''' ''Old Request Format not working anymore.'' | ||
− | + | ---- |
Latest revision as of 15:43, 7 November 2014
version 2.0 (REST Web Services API) is obsolete NCBO BioPortal v4.0 REST services are documented at: http://data.bioontology.org/documentation
Introduction
The Resource Index API is available through a REST web services interface.
This documentation describes the current version of the API. Some changes may append in the future.
The Resource index API is based on the web service that returns annotations from the Resource Index (called via a REST post). Additionally some simplified REST get services returned simplified results.
Sample HTTP Client for the Resource Index REST Web Service
- Test HTML Page : http://rest.bioontology.org/resource_index/test
- Test HTML Page (element per concept(s)) : http://rest.bioontology.org/resource_index/test/search
List of Resource Index Resources
- Resources Page : http://rest.bioontology.org/resource_index/resources/list/
Service endpoints
- To retrieve "annotations" either per element or per concept(s) : http://rest.bioontology.org/resource_index/
- To retrieve "element" per concept(s) : http://rest.bioontology.org/resource_index/search
Resource Index Web service Validation
- Note: All NCBO REST Web services will be required to contain the parameter "apikey=YourApiKey" starting June 2011. The parameter will be added to all Web service calls for the April 27, 2011 release but will not be required until June 2011. To obtain an API key, login to BioPortal and go to "Account" where your API key will be displayed. The addition of the API key replaces the use of the email parameter.
- Note for Application Developers: Application developers will also need to include the apikey parameter on all NCBO Web service calls. This allows us to track usage of our system at the level of an application. To obtain an API key, login to BioPortal and go to "Account" where your API key will be displayed. The addition of the API key replaces the use of the email parameter.
POST calls
POST your requests at the service endpoints.
Parameters
The Resource Index web service offers a set of parameters that allows a user to customize the annotations returned according to his specific requirements. For example, the annotations returned can be limited to a specific set of ontology and a specific set of semantic types. Plus, the expanded annotations can be filtered.
Please see below for the list of parameters and the possible values.
Note** : Parameter apikey and applicationid applies to all POST and GET calls.
apikey** | {apikey} | default: null | User identification query parameter with the pattern of "apikey=YourAPIKey". This parameter replaces the email parameter. The parameter will be required in June 2011. |
applicationid** | {applicationid} | default: null | Identifies the application calling the REST service. To receive your "applicationid" please request one from Support. |
ontologiesToKeepInResult | {localOntology1,...,localOntologyN} | default: empty (i.e. all ontologies) | Specifies the list of ontologies you want to filter in the result from the annotation process. The list of ontologies that can be used is available in the sample HTML page. The values are separated with comma (without spaces)
|
semanticTypes | {semanticType1,...,semanticTypeN} | default: empty (i.e. all semanticTypes) | Specifies the list of UMLS semantic types to use in the annotation process. The list of semantic types that can be used is available at the /obs/semanticTypes URL. Note that the restriction to semantic types is also applied during the semantic expansion steps.
|
levelMax | {integer} | default: 0 | Specifies the maximum level a parent concept must have to be considered for the is_a semantic closure expansion step.
|
mappingTypes | {null,mappingType1,...,mappingTypeN} | default: empty (i.e. all mappingTypes) | Specifies the list of mapping types to use during the mapping expansion step. The list of rmapping types that can be used is available at the /obs/mappingTypes URL. The current list is described in section Mapping types.
|
filterNumber | {true, false} | default: true | Specifies whether the concept recognition step to filter numbers or not. |
minTermSize | {integer} | default: 0 | Specifies the minimum length of the term to be included in the annotations. |
withSynonyms | {true, false} | default: true | Specifies either or not the direct annotations are done with or without Synonyms. By default it includes all the synonyms and preferred name. If 'false' is selected, the direct annotations are done with only preferred name. |
additionalStopWords | {stopWord1,...,stopWordN} | default: empty (i.e. none) | Specifies the list of additional stop words to use. Already used stop words are available here: [[1]] |
isStopWordsCaseSenstive | {true, false} | default: false | Specifies whether stopwords are case-sensitive or not. |
conceptids | {conceptid1,...,conceptidn} | default: empty (i.e. all concepts) | Specifies the list of concept to use to query the Resource index (i.e., get the annotations done with this list). This parameter must be jointly specified with the mode parameter. If conceptids contains only one element then the mode parameter can be ignored. The values are separated with comma (without spaces).
|
isVirtualOntologyId | {true, false} | default: false | Specifies the if the list of ontologies are all BioPortal virtual ontology ids. This parameter applies to both conceptids and ontologiesToKeepInResult parameters. |
mode | {union, intersection} | default: union | Specifies the mode to use when querying the resource index with several concept (parameter conceptids ). The union mode returns the union of all the annotations (filtered eventually with other parameters) done with each specified conceptid. The intersection mode returns the intersection. |
elementid | default: all | Specifies the identifier of the resource element for which annotations are requested. The elementid is defined by the original resource e.g., PMID for PubMed, NCT for ClinicalTrials. The full list of the elementid type is defined in Section Local element ID used.
| |
resourceids | default: all | Specifies the resource to filter the annotations with. The resourceids identifies a resource in the Resource Index. They are defined in section Resource identifiers. The list of resourceids can be used is available at the /obs/resources URL.
| |
elementDetails | {true, false} | default: false | Specifies the if the returned resource elements to be detailed or not. |
withContext | {true, false} | default: true | Specifies whether the annotations context information to be available or not. If turn to false, the set of annotations returned will be simplified and will not detail the context information for an annotation. Only the score will be returned. |
offset and limit | {integer} | default: 0/10 respectively | Specifies an offset and limits the number of annotation results. |
format | {text, tabDelimited, owl, rdf, xml} | default: xml | Specifies the desired format of the response. RDF and OWL outputs are defined according to a RDFS schema and OWL ontology respectively available here: http://obs.bioontology.org/ontologies/BioPortalAnnotation.rdfs and http://obs.bioontology.org/ontologies/NCBO_OBS_ontology.owl |
Web Service Response
Response Format
text | Returns plain text representation of the ObrResultBean(Detailled). |
tabDelimited | Shorter version of "Text" format, returns not the full result content but the annotations only (no statistics, etc.). The format of the tab delimited file is: score \t conceptId \t preferredName \t synonyms (separated by ' /// ') \t semanticType (separated by ' /// ') \t contextName \t isDirect \t other context information (e.g., childConceptId, mappedConceptId, level, mappingType) (separated by ' /// '). |
xml | Returns XML representation of the ObrResultBean(Detailled). |
owl | Returns OWL representation of the ObrResultBean(Detailled). The elementsof the result (dictionary, parameters, annotations, etc) are described as instances in the following ontology: http://obs.bioontology.org/ontologies/NCBO_OBS_ontology.owl |
rdf | Returns RDF representation of the annotations in ObrResultBean(Detailled). The elements of the result are described as instances in the following ontology: http://obs.bioontology.org/ontologies/BioPortalAnnotation.rdfs |
Note : if request parameter withContext is true, then returns representation of the ObrResultBeanDetailed and if request parameter withContext is false, then returns representation of the ObrResultBean.
Response Content: ObrResultBeanDetailed
Response ObrResultBeanDetailed contains all the contents of ObrResultBean. Those contents are described in section Response Content: ObrResultBean.
Following are remaining contents for ObrResultBeanDetailed :
directAnnotations | One annotation is represented by ObrAnnotationBean. |
isaAnnotations | One annotation is represented by ObrAnnotationBean. |
mappingAnnotations | One annotation is represented by ObrAnnotationBean. |
Note : Response contents of the ObrAnnotationBean are described in section ObrResultBean annotations
Response Content: ObrResultBean
resultId | |||||||||||||||||||||||||||
dictionary | Dictionary contains the metadata (not the content) of the dictionary used for a result. dictionaryId, dictionaryName, and dictionaryDate identify the dictionary on the server side and give information about its content. Dictionary versioning is strongly linked to the evolution of the ontologies used. Each time ontologies change, the dictionary is updated. All the dictionary information may be useful for comparing results of the Annotator Restlet service on time. | ||||||||||||||||||||||||||
resultStatistics | Each statistics contains information on the number of annotations done for a given context. The contextName keyword identifies the type of context and annotationCount is the number of annotations of this type. | ||||||||||||||||||||||||||
parameters | Parameters summarizes all the parameters specified by the user when requesting the Annotator Restlet service. Those parameters are described in section Service parameters | ||||||||||||||||||||||||||
ontologies | To keep the model simple, we provide only the global ontology identifier, localOntologyId the name (ontologyName) and version (ontologyVersion). This information come from the original repositories (UMLS/BioPortal) and might help the user to select the right ontology to use. When an ontology is used in the annotation, a result has a set of OntologyUsed which specify 2 other properties: nbAnnotation, the number of annotation that have been made with concepts from this ontology. score, the sum of all the scores of the annotations done with concepts from this ontology (if parameter scored=true). Therefore, score represents the most accurate ontology to annotate the given text. | ||||||||||||||||||||||||||
annotations | ObrAnnotationBean/ObrAnnotationBeanDetailed is a representation of one annotation/annotationDetailed. If elementDetails parameter is true the service return response of type annotation, otherwise annotationDetailed. An annotation has a score which represents the accuracy of the annotation computed by the scoring algorithm (if the scored=true parameter was chosen, otherwise score=-1). An annotation is done with a concept in a context.
Response Content: ObrAnnotationBeanDetailled Response ObrAnnotationBeanDetailed contains all the contents of ObrAnnotationBean. Those contents are described in section Response Content: ObrAnnotationBean. Following are remaining contents for ObrAnnotationBeanDetailed :
Response Content: ObrAnnotationBean
| ||||||||||||||||||||||||||
localElementId localConceptIds mode withContext elementDetails counts offsetStart offsetMax | Parameters summarizes all the parameters specified by the user when requesting the Resource Index Restlet service. Those parameters are described in section Service parameters |
GET calls
Following section describes all other simplified GET services available in Resource_Index_API.
Annotation by Concept Service
Returns the set of annotations done with a given localConceptId.
- GET Request Format : /byconcept/{ontologyid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}
- Example : http://rest.bioontology.org/resource_index/byconcept/42838/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey
- Old Request Format* :
- /byconcept/{ontologyID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID}
- /byconcept/{ontologyID}/{conceptID}/{withContext}/{counts}/{from}/{number}
- Response Content : ObrResultBean/ObrResultBeanDetailed is a representation of result/resultDetailed. If request parameter withContext is true, then returns representation of the resultDetailed and if request parameter withContext is false, then returns representation of the result.
Annotation for BioPortal virtual ontology Concept Service
Returns the set of all annotations done with a given localConceptId using BioPortal virtual ontology id.
- GET Request Format : /byconcept/virtual/{virtual_ontology_id}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}
- Example : http://rest.bioontology.org/resource_index/byconcept/virtual/1032/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey
- Old Request Format* :
- /byconcept/virtual/{virtualOntologyID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID}
- /byconcept/virtual/{virtualOntologyID}/{conceptID}/{withContext}/{counts}/{from}/{number}
- Response Content : ObrResultBean/ObrResultBeanDetailed is a representation of result/resultDetailed.
Annotation By Concept And Resource Service
Returns the set of all annotations done with a given localConceptId for given resourceId.
- GET Request Format : /byconcept/{ontologyid}/{resourceid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}
- Example : http://rest.bioontology.org/resource_index/byconcept/42838/AE/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey
- Old Request Format* :
- /byconcept/{ontologyID}/{resourceID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID}
- /byconcept/{ontologyID}/{conceptID}/{resourceID}/{withContext}/{counts}/{from}/{number}/{from}/{number}
- Response Content : ObrResultBean/ObrResultBeanDetailed is a representation of result/resultDetailed.
Annotation for BioPortal virtual ontology Concept And Resource Service
Returns the set of all annotations done with a given localConceptId using BioPortal virtual ontology id and using particular resourceId.
- GET Request Format : /byconcept/virtual/{virtual_ontology_id}/{resourceid}/{withContext}/{counts}/{offset}/{limit}?conceptid={conceptid}
- Example : http://rest.bioontology.org/resource_index/byconcept/virtual/1032/AE/false/true/0/10?conceptid=Melanoma&apikey=YourAPIKey
- Old Request Format* :
- /byconcept/virtual/{virtualOntologyID}/{resourceID}/{withContext}/{counts}/{from}/{number}?conceptID={conceptID}
- /byconcept/virtual/{virtualOntologyID}/{conceptID}/{resourceID}/{withContext}/{counts}/{from}/{number}
- Response Content : ObrResultBean/ObrResultBeanDetailed is a representation of result/resultDetailed.
For Multiple resources using service at basis URL
- GET Request Format : /?conceptids={conceptids}&isVirtualOntologyId=true&resourceids={resourceids}&withContext={withContext}&counts={counts}&offset={offset}&limit={limit}&levelMax=2147483647&filterNumber=false
- Example : http://rest.bioontology.org/resource_index/?conceptids=1032/Melanoma&isVirtualOntologyId=true&resourceids=CT,DBK,OMIM,RXRD&withContext=true&counts=true&offset=0&limit=10&levelMax=2147483647&filterNumber=false&apikey=YourAPIKey
- Response Content : result/resultDetailed for each resource. ObrResultBean/ObrResultBeanDetailed is a representation of one result/resultDetailed
Annotation By Resource Element Service
Returns the set of all annotations done with a given resource element localElementId for all the concepts.
- GET Request Format : /byelement/{resourceid}/{elementDetails}{withContext}/{counts}/{offset}/{limit}?elementid={elementid}
- Example 1 : http://rest.bioontology.org/resource_index/byelement/AE/false/true/false/0/10?elementid=E-GEOD-18509&apikey=YourAPIKey
- Example 1 : http://rest.bioontology.org/resource_index/byelement/AE/true/true/false/0/10?elementid=E-GEOD-18509&apikey=YourAPIKey
- Old Request Format* :
- /byelement/{resourceID}/{withContext}/{counts}/{from}/{number}?elementID={localElementID}
- /byelement/{resourceID}/{localElementID}/{withContext}/{counts}/{from}/{number}
- Response Content : ObrResultBean/ObrResultBeanDetailed is a representation of result/resultDetailed.
Annotation Details By Resource Element Service
Returns the set of all annotations details with a given resource element localElementId for given conceptId
- GET Request Format : /details/{elementDetails}/concept/{ontologyid}/resource/{resourceid}/{offset}/{limit}?conceptid={conceptid}&elementid={elementid}
- Example : http://rest.bioontology.org/resource_index/details/true/concept/42838/resource/AE/0/10?conceptid=Melanoma&elementid=E-GEOD-18509&apikey=YourAPIKey
- Old Request Format* :
- /details/{elementDetails}/concept/{ontologyID}/resource/{resourceID}?conceptID={conceptID}&elementID={localElementID}
- /details/{elementDetails}/concept/{ontologyID}/{conceptID}/resource/{resourceID}/element/{localElementID}
- Response Content : ObrAnnotationBean/ObrAnnotationBeanDetailed is a representation of one annotation/annotationDetailed. annotationDetailed if elementDetails is true otherwise annotation.
Annotation Details By Resource Element Service for BioPortal Virtual OntologyID
Returns the set of all annotations details with a given resource element localElementId for given conceptId of BioPortal virtual ontologyId
- GET Request Format : /details/{elementDetails}/virtual/concept/{virtual_ontology_id}/resource/{resourceid}/{offset}/{limit}?conceptid={conceptid}&elementid={elementid}
- Example : http://rest.bioontology.org/resource_index/details/true/virtual/concept/1032/resource/AE/0/10?conceptid=Melanoma&elementid=E-GEOD-18509&apikey=YourAPIKey
- Old Request Format* :
- /details/{elementDetails}/virtual/concept/{virtualOntologyID}/resource/{resourceID}?conceptID={conceptID}&elementID={localElementID}
- /details/{elementDetails}/virtual/concept/{virtualOntologyID}/{conceptID}/resource/{resourceID}/element/{localElementID}
- Response Content : ObrAnnotationBean/ObrAnnotationBeanDetailed is a representation of one annotation/annotationDetailed. annotationDetailed if elementDetails is true otherwise annotation.
Resources Service
Returns the set of all resources available in resource index and information related to it.
- GET Request Format : /resources
- Example: http://rest.bioontology.org/resource_index/resources?apikey=YourAPIKey
- Response Content : Resource is a representation of one resource
Response Content: Resource
resourceName | Name of the particular resource. | ||||||||||
resourceId | Identifier of the resource. | ||||||||||
mainContext | Main context string for the resource. | ||||||||||
resourceURL | Website URL for the resource | ||||||||||
resourceElementURL | Base URL for getting elements for resource. | ||||||||||
resourceDescription | Description of the resource. | ||||||||||
resourceLogo | URL of logo image for the resource. | ||||||||||
resourceStructure | Represents Structure of an element for the resource.
Response Content: Structure
|
Resource Service
Returns the resource in resource index for given resource id and information related to it.
- GET Request Format : /resources/{resourceid}
- Example: http://rest.bioontology.org/resource_index/resources/AE?apikey=YourAPIKey
- Old Request Format* : /resources/{resourceID}
- Response Content : Resource is a representation of one resource.
Resource Element Service
Service returns elementURL for given localElementId and redirect it to get resource element on the web.
- GET Request Format : /element/{resourceid}?elementid={elementid}
- Example: http://rest.bioontology.org/resource_index/element/AE?elementid=E-GEOD-9118&apikey=YourAPIKey
- Old Request Format* : /element/{resourceID}?element={localElementID}
- Response Content : Web page containing details of the element.
Element details service by elementid
Returns detail for given element using resource id and element id
- GET Request Format : /elementDetails/{resourceid}?elementid={elementid}
- Example: http://rest.bioontology.org/resource_index/elementDetails/AE?elementid=E-GEOD-9118&apikey=YourAPIKey
- Response Content : element
Elements detail service by chronology
Retruns elements details for given resource id cronologically
- GET Request Format : /elements/{resourceid}?method={method}&offset={offset}&limit={limit}
- Example: http://rest.bioontology.org/resource_index/elements/AE?method=chronology&offset=0&limit=10&apikey=YourAPIKey
- Response Content : Element is a representation of one element.
Resources Service with ontologies used for indexing
Returns the set of all resources available in resource index and list of onotolgies used for indexing them.
- GET Request Format : /resources?withontologies=true
- Example: http://rest.bioontology.org/resource_index/resources?withontologies=true&apikey=YourAPIKey
- Old Request Format* : /resources?withOntologies=true
- Response Content : ObrResourceBean is a representation of one resource with ontologies
Response Content: ObrResourceBean
Response ObrResourceBean contains all the contents of Resource. Those contents are described in section Response Content: Resource.
Following are remaining contents for ObrResourceBean :
ontologiesUsed | Presents list of ontologies used for indexing. Each ontology of type OntologyBean.
Response Content: OntologyBean
|
Resource Service with ontologies used for indexing
Returns the information about resources and list of onotolgies used for indexing it.
- GET Request Format : /resources/{resourceid}?withontologies=true
- Example: http://rest.bioontology.org/resource_index/resources/AE?withOntologies=true&apikey=YourAPIKey
- Old Request Format : /resources/{resourceID}?withOntologies=true
- Response Content : resource is represented by ObrResourceBean.
Ontologies Service with resources indexed
Returns the set of all ontologies used in resource index with list of resources indexed by given ontology.
- GET Request Format : /ontologies?withresources=true
- Example: http://rest.bioontology.org/resource_index/ontologies?withresources=true&apikey=YourAPIKey
- Response Content : Each ontology is represented by ObrOntologyBean.
Response ObrOntologyBean contains all the contents of OntologyBean.Those contents are described in section Response Content: OntologyBean.
Following are remaining contents for ObrResourceBean :
resources | Represents list of resources. Response content for each resource is of type Resource. |
Ontology Service with resources indexed
Returns the information about given ontologies used in resource index with list of resources.
- GET Request Format : /ontologies/{ontologyid}
- Example: http://rest.bioontology.org/resource_index/ontologies/42838?apikey=YourAPIKey
- Response Content : ontology is represented by ObrOntologyBean.
Virtual Ontology Service with resources indexed
Returns the ontology versions in resource index with list of resources for given virtual_ontology_id.
- GET Request Format : /virtual/ontology/{virtual_ontology_id}?withresources={true|false}
- Example: http://rest.bioontology.org/resource_index/virtual/ontology/1032?withresources=true&apikey=YourAPIKey
- Response Content : List of ontology represented by ObrOntologyBean.
Concept Frequency Service
Returns the get most used concepts for given resource id.
- GET Request Format : /most-used-concepts/{resourceid}?method={counts|score}&offset={offset}&limit={limit}
- Example: http://rest.bioontology.org/resource_index/most-used-concepts/AE?method=counts&offset=0&limit=10&apikey=YourAPIKey
- Response Content : conceptFrequency with format ObrConceptFrequencyBean.
Response Content: ObrConceptFrequencyBean
Following are contents for ObrConceptFrequencyBean:
concept | ConceptBean is a representation of concept |
counts | Frequency counts for a concept . |
score | score for a concept . |
All Statistics Service
Returns the information about number of all the annotations done in resource index.
- GET Request Format : /statistics/all
- Example: http://rest.bioontology.org/resource_index/statistics/all?apikey=YourAPIKey
- Response Content : All statistics' represented by ObrStatisticsBean.
Response Content: ObrStatisticsBean Following are remaining contents for ObrStatisticsBean:
aggregatedAnnotations | Sum of the number of rows in all the indexing tables |
mgrepAnnotations | Number of mgrep annotations entries in direct annotation table. |
reportedAnnotations | Number of reported annotations entries in direct annotation table. |
isaAnnotations | Number of is-a annotations entries in extended annotation table. |
mappingAnnotations | Number of mapping annotations entries in extended annotation table. |
Ontology Statistics Service
Returns the total statistics for given ontology for All resources.
- GET Request Format : /statistics/ontology/{ontologyid}
- Example: http://rest.bioontology.org/resource_index/statistics/ontology/42838?apikey=YourAPIKey
- Response Content : ontologyStatistics with format ObrOntologyStatisticsBean.
Response Content: ObrOntologyStatisticsBean Following are contents for ObrOntologyStatisticsBean:
resourceId | Resource Id for resource. |
statistics | ObrStatisticsBean is a representation of statistics |
Ontology Statistics Service by resources
Returns the statistics for given ontology for each resource separately.
- GET Request Format : /statistics/ontology/{onotlogyid}?byresource=true
- Example: http://rest.bioontology.org/resource_index/statistics/ontology/42838?byresource=true&apikey=YourAPIKey
- Response Content : ontologyStatistics with format ObrOntologyStatisticsBean.
Resource Statistics Service
Returns the total statistics for given resource for All ontology.
- GET Request Format : /statistics/resource/{resourceid}
- Example: http://rest.bioontology.org/resource_index/statistics/resource/CANANO?apikey=YourAPIKey
- Response Content : resourceStatistics with format ObrResourceStatisticsBean.
Response Content: ObrResourceStatisticsBean Following are contents for ObrResourceStatisticsBean:
localOntologyId | local ontology id for given ontology. |
statistics | ObrStatisticsBean is a representation of statistics. |
Resource Statistics Service by ontologies
Returns the statistics for given resource for each ontology separately.
- GET Request Format : /statistics/resource/{resourceid}?byontology=true
- Example: http://rest.bioontology.org/resource_index/statistics/resource/AE?byontology=true&apikey=YourAPIKey
- Response Content : resourceStatistics with format ObrResourceStatisticsBean.
All Executions Service
Returns the information about all workflow executions done in resource index.
- GET Request Format : /executions
- Web Page Request Format : /executions/list/
- Examples:
- Response Content : List of all 'execution represented by ObrExecutionBean.
Response Content: ObrExecutionBean Following are remaining contents for ObrExecutionBean:
resourceId | Identifier of the resource. |
dictionaryId | Identifier of the dictionary used for execution. |
withCompleteDictionary | Specifies if complete dictionary is used for execution or not (true/false). |
elementCount | Number of elements updated/annotated in execution. |
firstExecution | Boolean value specifies if execution is first execution. |
executionBeginning | Specifies Date/Time at which execution started. |
executionEnd | Specifies Date/Time at which execution ended.. |
executionTime | Time required (in HH:mm:ss format) to complete current execution. |
Resource Executions Service
Returns the information about workflow executions done for given resource in resource index.
- GET Request Format : /executions/{resourceid}
- Example: http://rest.bioontology.org/resource_index/executions/WP?apikey=YourAPIKey
- Response Content : 'execution represented by ObrExecutionBean.
Note* : Old Request Format not working anymore.