66from flask import jsonify
77from semantic_version import Version
88
9- from .cohd_trapi_13 import CohdTrapi130
109from .cohd_trapi_14 import CohdTrapi140
10+ from .cohd_trapi_15 import CohdTrapi150
1111from .biolink_mapper import BiolinkConceptMapper , SriNodeNormalizer , map_omop_domain_to_blm_class
1212from .query_cohd_mysql import omop_concept_definitions
1313
@@ -160,7 +160,7 @@ def translator_meta_knowledge_graph():
160160 })
161161
162162
163- def translator_query (request , version = '1.4 .0' ):
163+ def translator_query (request , version = '1.5 .0' ):
164164 """ Implementation of query endpoint for TRAPI
165165
166166 Calls the requested version of the TRAPI message
@@ -176,19 +176,19 @@ def translator_query(request, version='1.4.0'):
176176 requested version
177177 """
178178 if version is None :
179- version = '1.4 .0'
179+ version = '1.5 .0'
180180
181181 try :
182182 version = Version (version )
183183 except ValueError :
184- return f'TRAPI version { version } not supported. Please use semantic version specifier, e.g., 1.2 .0' , 400
184+ return f'TRAPI version { version } not supported. Please use semantic version specifier, e.g., 1.5 .0' , 400
185185
186- if Version ('1.3.0-alpha' ) <= version < Version ('1.4.0-alpha' ):
187- trapi = CohdTrapi130 (request )
188- return trapi .operate ()
189- elif Version ('1.4.0-alpha' ) <= version < Version ('1.5.0-alpha' ):
186+ if Version ('1.4.0-alpha' ) <= version < Version ('1.5.0-alpha' ):
190187 trapi = CohdTrapi140 (request )
191188 return trapi .operate ()
189+ elif Version ('1.5.0-alpha' ) <= version < Version ('1.6.0-alpha' ):
190+ trapi = CohdTrapi150 (request )
191+ return trapi .operate ()
192192 else :
193193 return f'TRAPI version { version } not supported' , 501
194194
0 commit comments