Skip to content

Sthanke/de2Miabis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

de2Miabis – BBMRI.de → MIABIS on FHIR Transformer

A Python command-line tool that transforms FHIR resources and collection bundles conforming to the BBMRI.de/GBA Implementation Guide into resources conforming to the MIABIS on FHIR Implementation Guide.

Developed as part of BBMRI-ERIC interoperability work.


Supported Transformations

BBMRI.de Resource MIABIS on FHIR Profile
Specimen miabis-sample
Patient miabis-sample-donor
Condition miabis-condition
Biobank (Organization) miabis-biobank
Collection (Organization) miabis-collection-organization
Observations (BMI, BodyHeight, BodyWeight, TobaccoUse, CauseOfDeath) miabis-observation

Code mappings handled:

  • Material type – BBMRI.de SampleMaterialType → MIABIS miabis-material-type-CS
  • Storage temperature – BBMRI.de StorageTemperature → MIABIS miabis-storage-temperature-cs
  • Sample diagnosis – BBMRI.de OtherSampleDiagnosis → MIABIS miabis-sample-diagnosis-cs
  • Profile URLs – all BBMRI.de StructureDefinition references remapped to MIABIS equivalents
  • Extension URLs – StorageTemperature, SampleDiagnosis, and Custodian extensions remapped

Requirements

  • Python 3.8+
  • No external dependencies (standard library only)

Usage

# Transform a single FHIR JSON file
python bbmri_de_to_miabis.py input.json output.json

# Transform all JSON files in a directory
python bbmri_de_to_miabis.py input_dir/ output_dir/

# Print a mapping summary
python bbmri_de_to_miabis.py --summary

# Verbose / debug output
python bbmri_de_to_miabis.py input.json output.json --verbose

If no output path is given for a single file, the result is written to <input_basename>_miabis.json.
If no output directory is given for a directory, results go to <input_dir>_miabis/.


Project Structure

de2Miabis/
├── bbmri_de_to_miabis.py       # Main transformer script
├── test_bbmri_de_bundle.json   # Example BBMRI.de input bundle
├── test_miabis_output.json     # Example MIABIS on FHIR output bundle
└── README.md

Links


License

This project is developed within BBMRI-ERIC. Please check with the project maintainers for licensing details.

About

Transforms FHIR resources and collection bundles conforming to the BBMRI.de/GBA Implementation Guide (https://fhir.bbmri.de) into resources conforming to the MIABIS on FHIR Implementation Guide (https://fhir.bbmri-eric.eu).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages