FHIR Chat · Codeable Concept Validator · hapi

Stream: hapi

Topic: Codeable Concept Validator


view this post on Zulip Joshua Bell (Aug 31 2017 at 18:13):

I'd like to have my HAPI server validate the codeable concepts coming in. I noticed that even with the StrictErrorHandler (which handles everything I wanted but this) that Codeable concepts can have any free text submitted in the system/code fields. I'd like to validate that the incomming system and code exists, including NCI/SNOMED/ICD9&10/LNC/and some others. I noticed a class called FhirResourceDaoValueSetDstu3 that looks like it contains code similar to what I'd want, but I have not figured out how to use it exactly.

Do I need to write my own validator for hapi that checks the system/code combos, or is there one already built somewhere?

view this post on Zulip Igor Sirkovich (Aug 31 2017 at 19:50):

@Joshua Bell, did you look at http://hapifhir.io/doc_validation.html ?

view this post on Zulip Joshua Bell (Nov 02 2017 at 15:59):

Just now getting time to revisit this @Igor Sirkovich - I have read the validation docs there pretty thoroughly. At this point from what I can tell all the resource validation is within the scope of the validator, and I haven't been able to figure out how to make it global to all actions.
The parser validator does what I expect it to do: I can set it to the global context and on all posts etc it will run the StrictErrorHandler.
But all of the resource validation examples simply create a validator and then run it on a single/batch of resources known in the scope of that code. I haven't been able to figure out how to set it up to work across all resources.

Maybe I am getting some validation but not the validation I am looking for, not completely sure. I expect that if I have a Coding with a system and code, that if the code is invalid (like I put some random characters in it) - I want it to fail the posting of that resource. I'd like this set up with all the main code systems like SNOMED, NCI, etc...


Last updated: Apr 12 2022 at 19:14 UTC