Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Digital Square E0 proposal: openIMIS Shelf Readiness

Teams:

...

The goal of this project is to improve the open-source Insurance Management Information System (openIMIS) interoperability layer for easier and more efficient integration with other health-related systems within OpenHIE (Open Health Information Exchange) architecture, and to allow an efficient installation procedure through enhanced packaging and documentation, and thus, to align the solution with the Instant OpenHIE project and initiative. 

...

FHIR release four (R4) integration

Expand
titleopenIMIS Policies mobile app: Enrol Family payload
Code Block
languagejson
{
    "family": [{
        "FamilyId": "1",
        "InsureeId": "1",
        "LocationId": "61",
        "HOFCHFID": "131",
        "Poverty": "0",
        "FamilyType": "H",
        "FamilyAddress": "PermAdress1",
        "Ethnicity": "0",
        "ConfirmationNo": "Confirm1",
        "ConfirmationType": "C",
        "isOffline": "1",
        "FamilySMS": {
            "FamilyID": "1",
            "ApprovalOfSMS": true,
            "LanguageOfSMS": "fr"
        },
        "insurees": [{
            "InsureeId": "1",
            "FamilyId": "1",
            "CHFID": "131",
            "LastName": "NewTestInsureeLast",
            "OtherNames": "NewTestInsureeOther",
            "DOB": "2021-06-09",
            "Gender": "F",
            "Marital": "M",
            "isHead": "1",
            "IdentificationNumber": "NationaID1",
            "Phone": "123123123",
            "PhotoPath": "131_E00002_20210609124332_0_0.jpg",
            "CardIssued": "1",
            "Relationship": "0",
            "Profession": "1",
            "Education": "4",
            "Email": "insuree@mail.com",
            "TypeOfId": "N",
            "HFID": "4",
            "CurrentAddress": "CurrentInsureeAdress",
            "GeoLocation": "",
            "CurVillage": "62",
            "isOffline": "1"
        }],
        "policies": [{
            "PolicyId": "1",
            "FamilyId": "1",
            "EnrollDate": "2021-06-09",
            "StartDate": "2021-11-01",
            "EffectiveDate": "2021-11-01",
            "ExpiryDate": "2022-10-31",
            "PolicyStatus": "2",
            "PolicyValue": "6000",
            "ProdId": "10",
            "OfficerId": "6",
            "PolicyStage": "N",
            "isOffline": "1",
            "premium": {
                "PremiumId": "1",
                "PolicyId": "1",
                "PayerId": "0",
                "Amount": "6000",
                "Receipt": "REC0001",
                "PayDate": "2021-06-09",
                "PayType": "B",
                "isPhotoFee": "false",
                "isOffline": "1"
            }
        }],
        "insureePolicy": [{
            "InsureeId": "1",
            "PolicyId": "1",
            "EffectiveDate": "2021-11-01"
        }]
    }]
}

Expand
titleopenIMIS Policies mobile app: Modify Family payload
Code Block
languagejson
{
    "family": [{
        "FamilyId": "-31",
        "InsureeId": "-145",
        "LocationId": "60",
        "HOFCHFID": "121",
        "Poverty": "0",
        "FamilyType": "P",
        "FamilyAddress": "PermAdress1234",
        "Ethnicity": "0",
        "ConfirmationNo": "CONF002",
        "ConfirmationType": "C",
        "isOffline": 0,
        "FamilySMS": {
            "FamilyID": "-31",
            "ApprovalOfSMS": false,
            "LanguageOfSMS": "fr"
        },
        "insurees": [{
            "InsureeId": "-145",
            "FamilyId": "-31",
            "CHFID": "121",
            "LastName": "Test1@",
            "OtherNames": "Test1@",
            "DOB": "2021-06-09",
            "Gender": "M",
            "Marital": "D",
            "isHead": "true",
            "IdentificationNumber": "",
            "Phone": "",
            "PhotoPath": "121_E00002_20210609121931_0_0.jpg",
            "CardIssued": "true",
            "Relationship": "0",
            "Profession": "0",
            "Education": "0",
            "Email": "",
            "TypeOfId": "",
            "HFID": "0",
            "CurrentAddress": "",
            "GeoLocation": "",
            "CurVillage": "45",
            "isOffline": "0",
            "picture": {
                "ImageName": "",
                "ImageContent": ""
            }
        }, {
            "InsureeId": "-147",
            "FamilyId": "-31",
            "CHFID": "1221",
            "LastName": "TestR1",
            "OtherNames": "TestR1",
            "DOB": "2021-06-09",
            "Gender": "M",
            "Marital": "N",
            "isHead": "false",
            "IdentificationNumber": "",
            "Phone": "",
            "PhotoPath": "1221_E00002_20210609122012_0_0.jpg",
            "CardIssued": "false",
            "Relationship": "1",
            "Profession": "0",
            "Education": "0",
            "Email": "",
            "TypeOfId": "",
            "HFID": "0",
            "CurrentAddress": "",
            "GeoLocation": "",
            "CurVillage": "0",
            "isOffline": "0",
            "picture": {
                "ImageName": "",
                "ImageContent": ""
            }
        }, {
            "InsureeId": "-148",
            "FamilyId": "-31",
            "CHFID": "12221",
            "LastName": "AddedToExistingLast",
            "OtherNames": "AddedToExistingOther",
            "DOB": "2021-06-09",
            "Gender": "F",
            "Marital": "D",
            "isHead": "0",
            "IdentificationNumber": "PassportID",
            "Phone": "9018231022",
            "PhotoPath": "12221_E00002_20210609124855_0_0.jpg",
            "CardIssued": "1",
            "Relationship": "0",
            "Profession": "2",
            "Education": "5",
            "Email": "newinsureemail@mail.com",
            "TypeOfId": "P",
            "HFID": "1",
            "CurrentAddress": "CurrentAdresss011",
            "GeoLocation": "",
            "CurVillage": "62",
            "isOffline": "1"
        }],
        "policies": [{
            "PolicyId": "1",
            "FamilyId": "-31",
            "EnrollDate": "2021-06-09",
            "StartDate": "2021-06-09",
            "EffectiveDate": "2021-06-09",
            "ExpiryDate": "2022-06-08",
            "PolicyStatus": "2",
            "PolicyValue": "10000",
            "ProdId": "4",
            "OfficerId": "6",
            "PolicyStage": "N",
            "isOffline": "1",
            "premium": {
                "PremiumId": "1",
                "PolicyId": "1",
                "PayerId": "0",
                "Amount": "10000",
                "Receipt": "REC0002",
                "PayDate": "2021-06-09",
                "PayType": "C",
                "isPhotoFee": "false",
                "isOffline": "1"
            }
        }],
        "insureePolicy": [{
            "InsureeId": "-147",
            "PolicyId": "1",
            "EffectiveDate": "2021-06-09"
        }, {
            "InsureeId": "-145",
            "PolicyId": "1",
            "EffectiveDate": "2021-06-09"
        }, {
            "InsureeId": "148",
            "PolicyId": "1",
            "EffectiveDate": "2021-06-09"
        }]
    }]
}

FHIR R4 extensions development

...

Plantumlcloud
filenameSD_AdjudicateClaimsAI.png
datalVTbTsMwDP2aPiKFdvuAdnSiSHsBBI9T1po1Ik2qXCbg63GSbmtpNkCKNtuxjjVTbbsIwDP2aSuNhUkbLB7QMNCbxsk3bIwqNB9HSpMqFXb5+1jp8mCaEOVsR1PSI6nR4XVrKfCJClZcQZeCJc7TlJKu3aAFIHt2Mf2sdMkI8ZSbV0lEpLjqVHhJa+eHkNJU9iGpTPaFWCQQQNaDV32Wc7Vuz4xZmaOiyvq8eUdrIxvIhhGr88faIptMmUzAWHIMTLrfry8nSqapCr9eoZtZVEAFkCWsNdKvhub7fCwQANXZYPqyeU1oo50YRQgz/0oqdCPdT39vjBPuI/gXVjMBWsdiihIjQDQoukZ8R9QaKWy3AzXotWEHauDcO8mDcJNkpa8yy32qNe3Z9q1laqsWqHG5Z2IKMPTkjNyV90I5c8lrBQ0CMsq1u3Zg3tdl8H35DCBq2TiYh9fnk9u4vMBAsDtlWqCLCmPzDg1cCj1lDu364JSQMwpyxjX4SR8iHYySxKAW5DaGEOhKSU8VxrdSPXXP9hH/uaTNLxBkGJwn80AtnuARjxmKKBUaAZCj6RkJH1FklXbUF3eil5Qdq4dQ7yaNwm6SLUGWah1RLWvPN+57rjc5QE2rHJV7cOANa0goR5qjW1JhPpdmkj920643CV/jSLKVAi2twsXMSuexLAIluTWtVOyLGiZFsrxDxDn5DUzIv8TdbLRGvoO4MhWrQQnawT5KBfd1lRoY5uJUGH/mglvrQ2vKOf4hwIHVoGMr4Rc8WItymhjJsNzE047Cri7DidAR3GywgYHRUsxJAKWkOpLMxN5FtTBj78o2HVcBz6ST4cVNST0t8wRfnzy0HJKDLBXzMI9vL92Ukzam20ZkKtq90m8kQrQODP4LbcuItITgKSEnFORWGAgbcRhpp5NkDCojd2MIR1pr+Y3cWi0UZRcgSDPgwOxVY0vSuQajnMYFThfeY1ZESnJn90rzH2q5ksnsHhGHk2DQmUR/e7rcDeZs1QfIM1Npl+Kwa/NZ9Aw=j6ueB2h9CSCoF/CHDgJZiL+xFeRbQWi34VyIwTdryGTtjZzWjZ7cANphzp6GzIkBHQWukj41zufNQeBlSeWa3jXuDpddK8xT7Dx7fvT4YPjuEH8hc=
width
compressedtrue
revision13

FHIR REST API Login endpoint

The /login endpoint has been added to the FHIR R4 module to allow the generation of the JWT token through the FHIR R4 module’s REST API.

Code Block
languagetext
POST /api_fhir_r4/login 

Request body: 
  {
    "username": [username],
    "password": [password]
  }

HTTP 200 Response body: 
  {
    "token": [token]
    "exp": [expire_date]
  }

HTTP 401 Response if credentials are not valid  

...

Code Block
languagetext
Authorization: Bearer [token]

HTTP 200 Response when token validated (the actual resource payload is returned)

HTTP 401 Response when:
  if Authorization header is missing 
  if Bearer prefix is missing
  if error on decoding Authorization header  
  if token is expired

FHIR Authorisation

Related pages:

In openIMIS, authorisation is based on User’s role and location. A role is a group of authorities or permissions which are well defined and constant (see openIMIS Authorities for an up-to-date list of authorities). During the migrations, some of authorities were not added in the new created modules. Moreover, the query set used to obtain the data related to a resource was fetching all the objects from the DB.

Based on the openIMIS Authorities, used in the legacy openIMIS, we have added the missing permission to the modular openIMIS. Also, we have updated the query sets and retrieved them from the business module (e.g. Claim module) which limits the access based on the Users The following modules have been updated:

openIMIS FHIR module documentation

openIMIS FHIR Quality Assurance

Docker package improvement

For better distribution, docker can be used to facilitate the installation of openIMIS. The repository https://github.com/openimis/openimis-dist_dkr/tree/develop was updated to let users provide their configuration using local files. Here the user has to provide the normally called “openimis.json” locally using the appropriate environmental variable, two can be provided for the backend and frontend configuration (from the README.MD):

Code Block
BE_CONF_PATH=<the path to your config file, has to be local>
FE_CONF_PATH=<the path to your config file, has to be local>

Additionally if the user wants to provide development settings, there is a variable for the path where this configuration file would be located:

DEV_PATH=<the path to your developer config, optional>

For even easier installation, the different repositories will be built on the fly directly from GitHub (repository previously provided), the user might change the branch if need using the variables:

Code Block
 BE_BRANCH=<branch of the backend repository to be used>
 FE_BRANCH=<branch of the frontend repository to be used>
 DB_BRANCH=<branch of the database repository to be used>
 GW_BRANCH=<branch of the gateway repository to be used>

Developer initialisation script

A package to include not only openIMIS, but also services that could be required by an user, as a mediator (OpenHIM) or a FHIR server (Hapi) was developed. For this purpose, we extend the work of the OpenHIE, so called instant OpenHIE (https://github.com/openhie/instant ) to include openIMIS as a service(https://github.com/openimis/openimis-dist_instant_openhie/tree/develop).

There were some alterations of the in the previous section mentioned repository to achieve this. The manual steps for the installation of the database were eliminated, so that the only command the user would be required to use is:

./deploy.sh init core openimis-db_dkr openimis-dist_dkr -c="./openimis-db_dkr" -c="./openimis-dist_dkr"

To clean up the project you'd use destroy instead of init. The commands up and down known from docker-compose are also allowed.
This is extendable by any service the user may want, given that the service is in a directory that follows instant OpenHIE structure, and adding the package ID then to the previous command with the corresponding path.

The variables for both services are now in the docker/compose.sh files of each service as opposed of the .env file as in the previous repository.

Packaging and Installation