FHIR R4 - Patient
Description
The openIMIS Insuree object (from the openimis-be-insuree_py module) was mapped to the FHIR R4 Patient resource.
Notes / Assumptions
The current version of mapping will be focused on aspects of claiming.
In the current version of the openimis-be-insuree_py missing services layer which can be used to perform operations (CRUD - Create, Read, Update, Delete) on entities. That's why the current version of API use directly database layer manager for managing the Insuree objects. This leads to differences between operation between legacy and new openIMIS, for instance, the update operation doesn't create the database row with a history of the object and the delete operation permanently remove the object from the database.
familyId - missing in the current version of the Insuree model (from the openimis-be-insuree_py module). That's why the current version of API doesn't cover that field. Attribute needs to be nullable type in the Database Schema.
photoId - missing in the current version of the Insuree model (from the openimis-be-insuree_py module). That's why the current version of API doesn't cover that field. Attribute need to be nullable type in the Database Schema.
typeofid - missing in the current version of the Insuree model (from the openimis-be-insuree_py module). That's why the current version of API doesn't cover that field. Attribute need to be nullable type in the Database Schema.
Mapping
FHIR R4 Resource - Patient
openIMIS table - tblInsurees, tblFamilies
FHIR R4 field | openIMIS field | Notes | Mapping status |
---|---|---|---|
identifier | InsureeID / CHFID / passport / TypeOfId / InsureeUUID | there is a 0..* relation on identifier | InsureeID / CHFID / passport / InsureeUUID is mapped |
LastName / OtherNames | name field contains values that are being mapped for both LastName and OtherNames fields | mapped | |
DOB |
| mapped | |
Gender | Link to | mapped | |
Marital | maritalStatus.text in [Married, Single, Divorced, Widowed, Not specified] | mapped | |
Phone / Email | telecom field contains values that are being mapped for both Phone and Email fields | mapped | |
tblInsuree.PhotoID → tblPhotos.PhotoFolder + PhotoFileName | Should include the base URL | mapped | |
tblInsuree.PhotoID → tblPhotos.PhotoDate |
| mapped | |
HFID | reference/HeathcareService | mapped | |
CurrentAddress / GeoLocation | The patient can contain multiple addresses | mapped | |
link to tblInsuree.FamilyId → tblFamilies.InsureeId → tblInsurees.InsureeUUID | reference Patient/UUID | mapped | |
tblInsuree.relationship → tblRelations.Relation OR tblRelations.RelationId | Based on module configuration. tblRelations.Relation by default. | mapped | |
extension.isHead | tblInsuree.IsHead | url: isHead | mapped |
extension.registrationDate | tblInsuree.ValidityFrom | url: registrationDate | mapped |
extension.locationCode | link to tblInsuree.FamilyId → tblFamilies.LocationId→ tblLocations.LocationUUID | url: locationCode | mapped |
extension.educationCode.valueCoding.code | tblInsuree.Education → tblEducations.EducationId | utl: educationCode | mapped |
extension.professionCode.valueCoding.code | tblInsuree.Profession → tblProfessions.ProfessionId | utl: professionCode | mapped |
extension.povertyStatus | tblInsuree → tblFamilies → Poverty | url: povertyStatus | mapped |
extension.group | link to tblInsuree.FamilyId → tblFamilies.FamilyUUID | reference/Group/UUID | not mapped |
Endpoint specification
Example of endpoint URL
http://localhost:8000/api_fhir_r4/Patient/
Supported HTTP operation
CREATE - POST HTTP method
Used to create new FHIR Patient (Insuree). List of supported fields can be found in the table which shows the mapping between openIMIS and FHIR. Should be used the POST HTTP method and the body as JSON representation (example can be found below).