In January 2019, the National Institute of Drug Abuse (NIDA) reported that more than 130 adult Americans die after overdosing on opioids everyday. One of the weaknesses in handling opioids in our current healthcare system is the transaction between patient and the pharmacist. Prescriptions are usually paper-written and held by the patients. It becomes an easy way to forge a fake description or patient identification in order to get more opioids.

What it does

BlockMD provides security and efficiency for authenticating patient identification and prescription validity. Our solution prevents patients from modifying their own prescription, while providing transparent transactions between doctor-patient-pharmacist.

Main steps of application: Each block contains patient information, or prescription information. We keep track of patient drug received/ not received state inside the prescription.

  1. Pharmacist authenticate MetaMask account on BlockDM
  2. Pharmacist enters the patient's health card number ('Submit')
  3. BlockDM validates if patient information exists
  4. Pharmacist confirms the transaction ('View Bill'), BlockDM checks for patient's eligibility: valid (patient data confirms eligibility) or invalid (patient is cheating and trying to get the drug again)
  5. In case of valid, the screen displays patient's prescription. 'Pay' will instruct the bill to be forwarded to insurance company. A new block with updated drug-received state is added. Contract is satisfied.
  6. In case of invalid, the screen will display error message and no further action is taken.

We also integrated the ability to forward the bill to the prospective insurance institution, given the agreement between involved parties.

How we built it

Using Truffle framework, our back-end developers wrote contracts in ERC20 Solidity as well as Javascripts code. Our front-end developers coded the UI in html and css. We used Ganache to generate fake accounts with public and private keys as well as 100 Ether. MetaMask wallet was utilized to connect our front-end to Ganache and update the blockchain per transaction.

Challenges we ran into

Our team had no foundation knowledge in blockchain, smart contracts as well as experience programming using Truffle framework. Our members also had limited experience developing a whole app from scratch. However, we were very anticipated to learn about such new and ubiquitous technology. Understanding how each component interacts with each other in the whole blockchain network was also a challenge for our teamwork.
Moreover, a lot of domain and ideas have already been exploited in the recent years given the current ability of Ethereum.

Accomplishments that we're proud of

It was a great achievement for us to finish a Dapp from scratch within the 24-hour timeframe. The team cooperation was also an amazing experience despite of different in career field, Thanks to the great mentors and volunteers, we were able to untangle all the issues and consistently making progress throughout the hackathon.

What we learned

From researching and developing experience, we have gained deeper understanding in the concept of smart contract, transaction, gas and so on. We also explored more potentials as well as limitations of blockchain. We are excited to test ourselves to create an application that helps the pharmaceutical industry as well as opening new possibilities for other drug prescriptions.

What's next for BlockMD

There's a potential of developing interface for doctor's and patient's end. We acknowledge the possibility of disclosing confidential information on public network. One solution could be to use Quorum protocol instead of basic Ethereum to provide more contract and transaction privacy. One more possibility is to improve the connection with insurance companies and develop a seamless direct transaction for billing.

Built With

  • solidity-html-css-javascript
Share this project: