Wiki Spaces


Get Help from Others

Q&A: Ask OpenMRS
Discussion: OpenMRS Talk
Real-Time: IRC Chat | Slack


Page tree

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.
title2015 GSoC Project Idea

This project is being considered as a potential project for Google Summer of Code 2015. If you are a potential intern and are interested in working on this project, please discuss it in detail with the mentor(s) listed here before submitting your internship proposal.

Primary mentor
Suranga Kasthurirathne or
Harsha Kumara
Backup mentor
Suranga Kasthurirathne
GSoC student
Mayank Sharma


The purpose of this project is to enhance the OpenMRS FHIR module by improving its usability, security and error management features.implement the OAuth2 support for the OpenMRS Webservices APIs. OAuth2 is welknown and popular standard in securing the webserives APIs where user can invoke services through access token without exposing their credentials. OpenMRS has two main web services projects  which are OpenMRS restful web services module[5] and OpenMRS FHIR module[1]. So the main target is to  implement the OAuth support for platform where OpenMRS act as a OAuth provider. 

This requirement is mainly coming from OpenMRS FHIR module which OpenMRS has recently undertaken a commitment to implement FHIR in order to ensure better interoperability between healthcare systems. The OpenMRS FHIR module was developed as part of these efforts. Currently, there is need to develop support the following features OAuth2 for the FHIR module:

  • Add Oauth based security for the module to communicate with third party systems
  • Demonstrate the success of an Oauth implementation by demonstrating its use against SMART platform apps
  • Add web based interfaces (akin to those implemented by the OpenMRS web services module) for users to be able to test / explore their sample messages
  • Add an error management console for interacting with failed requests


Specification :


  • Good Java skills
  • Familiarity with J2EE web programming (e.g., JSPs)
  • Ability to learn and work with FHIR and the HAPIOpenMRS REST APIs and FHIR Module with HAPI 
  • Familiarity / willing to learn OauthOAuth
  • Soft skills to interact with the HAPI and FHIR community and OpenMRS community in order to gather requirements and technical feedback

Project champions


  • Go through the OAuth specification and understand OAuth2 and it's grant typesDevelop Oauth
  • Go through the available samples in web to understand the implementation(6). 
  • Develop OAuth based security module for the OpenMRS FHIR module
  • Develop front end configuration and test screens akin to the OpenMRS Web Services module
  • Develop an error console to view and manage failed FHIR requests

Extra credit

  • TBDOpenMRS 
  • Come up with set of UI mockups for application creation and authorization
  • Create a new module following Creating Modules (improve the documentation if needed)
  • Apply for a repository at and a JIRA project
  • Create tickets in JIRA for tasks to be completed during GSoC
  • Design and implement the module API layer
    • API layer need to have a validateToken method which takes incoming token to check whether it's valid or not. The service will be a spring service where FHIR Module and Web Service module call to validate the incoming token. 
  • Design and implement the module OMOD layer
  • OMOD layer should support for following endpoints (Twitter API tutorial will helpful in understanding below endpoints During the implementation we may simplify the endpoints

How FHIR and REST Module Interact

Image Added

Extra credit

  • Developing a client and demonstrating how different OAuth grant types can be support from the OAuth module



  1. Work already completed under phase 01 of the FHIR module
  2. HL7 FHIR wiki
  3. OpenMRS FHIR GitHub Repo
  4. SMART enabled oauth


  1. OpenMRS REST Module
  3. Jira