Our solution serves as a decentralized marketplace to enable direct peer-to-peer transaction of medical data between third party organizations and owners of said data. With the use of blockchain and smart contracts, various issues in the current health data marketplace can be tackled accordingly to promote a healthy and sustainable marketplace.
We have 5 core smart contracts that support the business needs of our solution, namely Marketplace, Organization, Patient, MedicalRecord and Token. In this section, we provide an overview of the functions of each smart contract in our system.
The Marketplace contract serves the role of a conventional data broker:
- Verified patients can list and unlist their specific medical records for sale.
- Verified organizations can act as buyers to purchase listed medical records.
- Token related operations, such as transfer of token during purchase, token exchange and token withdrawal.
- Facilitate purchase process.
- Track purchase history of each buyer.
The Organization contract is used to support organization related operations, with all users representing an organization stored inside a single Organization contract instance. In summary, the Organization contract supports the following operations:
- Allowing existing verified organizations to verify and add a new user as a verified Organization.
- Remove verified organizations if verifiers find new organizations malicious.
- Retrieving the profile of verified organizations.
- Check whether a user is a verified organization or not.
The Patient contract is used to support patient related operations, with all users representing a patient stored inside a single Patient contract instance. In summary, the Patient contract supports the following operations:
- Allowing verified organizations to add new users as patients.
- Remove verified patients if the verifier finds new patients malicious.
- Uploading of new medical records by verified organizations or patients.
- Check whether a user is a verified patient or not.
- Manage uploaded medical records, and verified patients have total control and knowledge of who, when and which organizations are accessing which medical record that they upload.
The MedicalRecord contract represents a patient’s medical record, with a single instance representing a specific uploaded medical record. When new medical records are created by verified patients or organizations, the associated patient will be the data owner, and they can choose to list their records for sale on the Marketplace contract. A MedicalRecord contains various metadata such as the type of record (e.g. test result, prescription) as well as the URI to access the file associated with the record. It supports operations such as:
- Retrieving the metadata of the medical record.
- For verified organizations to toggle the validity of the smart contract.
- Emergency stop for data owner to control when to stop access to the metadata of the medical record.
The MedToken contract represents a standard ERC20 token, and is used to transact on the Marketplace. It supports fundamental operations such as: Minting of token.
- Transfer of token.
- Burning of token.
- Checking of token.