This repository contains the logic for implementing the mediation service used within the MamaToto HIE stack for completing the relevant workflows.
To create a standalone instance of the service, you will need to run the below commands.
Note: This service has external dependecies which need to be up and running.
Create the env file and populate the relevant variables
cp .env.example .env
Run the instance in development mode:
yarn dev
The service should now be accessible on http://localhost:3000
The Platform instance will scaffold a project architecture which contains a couple of dependant services which are required for the entire workflow to be tested.
- Docker
- An Active Docker Swarm
- Check that you have an active docker swarm running on the respective environment.
docker info | grep Swarm
- If no swarm is running, you can start a swarm with
docker swarm init
. - Run
./get-cli.sh
to download the latest release of the CLI. You can download only the specific CLI for your operating system by providing it as a parameter. (e.g../get-cli.sh linux
) - Create the env file and populate the relevant variables (e.g.
cp .env.example .env
) - NB! The custom images used within the project will need to be built before running the deployment to ensure the Docker images are available for use. Run the below command to build the custom images:
./build-custom-images.sh
- Run the relevant deploy script. (e.g.
./instant-linux package init -p local --concurrency=1
)
- OpenHIM
- Console: http://localhost:9000/
[email protected]:instant101
- Core API: https://localhost:8080
- Core Transaction: http://localhost:5001/ or https://localhost:5000/
- Request Header:
Authorization: Custom test
- Request Header:
- Console: http://localhost:9000/
- Hapi FHIR
Send a test request to the OpenHIM to process the FHIR Bundle be executing the below cURL command
curl --location 'http://localhost:5001/fhir' \
--header 'Authorization: Custom test' \
--header 'Content-Type: application/json' \
--data @resources/SHR-Bundle-BMI-Observation.json