The Validation Service is responsible for validating FHIR resources according to the HL7 FHIR specification, based on predefined FHIR profiles, provided from RKI (Robert Koch Institute). These profiles are loaded from the file system during the service startup phase. Please note that the profiles are not part of this repository. In a Kubernetes environment, the FHIR profiles are mounted to the service's file system from a dedicated OCI container image.
This service is a Spring Boot-based application that processes HTTP requests and leverages appropriate HAPI FHIR library methods to perform the following tasks:
See ReleaseNotes for all information regarding the (newest) releases.
The application requires the DEMIS FHIR Profiles. This image is maintained in DockerHub: demis-profile-snapshots.
The profiles are require to execute the integration profile tests included in this repository. With -PskipProfileTests
you can skip these tests if you don't have profiles locally.
At runtime execution the profile files must be available in a folder and this folder must be specified through the
environment variable FHIR_PROFILES_BASEPATH.
mvn clean verify
The Project can be built with the following command:
mvn -e clean install -DskipTests=true
build with docker image:
docker build -t validation-service:latest .
The Docker Image associated to the service can be built alternatively with the extra profile docker:
mvn -e clean install -Pdocker
or if you don't have the profiles
mvn -e clean install -PskipProfileTests -Pdocker
The application can be started as Docker container with the following commands assuming that the profile snapshots are located in directory /profiles/5.2.0/Fhir
docker run --rm --name validation-service \
-v $(pwd)/profiles:/profiles \
-p 8080:8080 \
-e FHIR_PROFILES_BASEPATH=/profiles \
-e PACKAGE_VERSIONS=5.2.0 \
validation-service:latest
aus IntelliJ als SpringBoot Application starten

Start the spring boot server with: mvn clean spring-boot:run
Check the server with: curl -v localhost:8080/actuator/health
aus IntelliJ als SpringBoot Application starten
| Property | Default Value | Environment Variable | Environment Variable Description |
|---|---|---|---|
| demis.validation-service.profiles.basepath | FHIR_PROFILES_BASEPATH | Path to base directory with all profiles versions | |
| demis.validation-service.profiles.fhirpath | Fhir | Path inside of a profiles versions directory to the resources. | |
| demis.validation-service.profiles.versions | PACKAGE_VERSIONS | List of versions. Must match the directory names under the base path. | |
| demis.validation-service.locale | en_US | Locale for the HAPI-FHIR context and validator. The language of diagnostics of the outcome is dependent on this locale. | |
| demis.validation-service.minSeverityOutcome | information | Minimal severity that will not be filtered out in the Outcome. Possible values:information, warning, error, fatal. | |
| demis.validation-service.common-code-system-terminology-enabled | false | CONFIG_OPTION_COMMON_CODE_SYSTEM_TERMINOLOGY_ENABLED | adds terminology support to validator |
| demis.validation-service.custom-regex-validator-enabled | false | CONFIG_OPTION_CUSTOM_REGEX_VALIDATOR_ENABLED | enables custom regex validator |
| demis.validation-service.custom-quantity-validator-enabled | false | CONFIG_OPTION_CUSTOM_QUANTITY_VALIDATOR_ENABLED | enables custom quantity validator |
| Feature Flag | Description |
|---|---|
| feature.flag.format.validation.enabled | allow json only as valid format |
| feature.flag.filtered.errors.as.warnings.disabled | changes error validation results to warnings. |
Start the spring boot server with: mvn clean spring-boot:run
Check the server with: curl -v localhost:8080/actuator/health
| Endpoint | Description |
|---|---|
/status | GET endpoint for status notifications. Currently minimally implemented. |
/$validate | POST endpoint for validating messages. Returns validation results from the HAPI Validator. |
/actuator/health/ | Standard endpoint from Actuator. |
/actuator/health/liveness | Standard endpoint from Actuator. |
/actuator/health/readiness | Standard endpoint from Actuator. |
If you want to see the security policy, please check our SECURITY.md.
If you want to contribute, please check our CONTRIBUTING.md.
Copyright 2022-2025 gematik GmbH
EUROPEAN UNION PUBLIC LICENCE v. 1.2
EUPL © the European Union 2007, 2016
See the LICENSE for the specific language governing permissions and limitations under the License
E-Mail to DEMIS Entwicklung
Content type
Image
Digest
sha256:36337c2f6…
Size
4.1 MB
Last updated
10 days ago
docker pull gematik1/demis-validation-service:sha256-fa311fc8af2ec1c323c1653a58cde19becc06c90cda98b033453b33cf1266f08.att