This is an open-access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/2.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work, first published in JMIR Diabetes, is properly cited. The complete bibliographic information, a link to the original publication on http://diabetes.jmir.org/, as well as this copyright and license information must be included.
Optimal management of chronic diseases, such as type 2 diabetes (T2D) and obesity, requires patient-provider communication and proactive self-management from the patient. Mobile apps could be an effective strategy for improving patient-provider communication and provide resources for self-management to patients themselves.
The objective of this paper is to describe the development of a mobile tool for patients with T2D and obesity that utilizes an integrative approach to facilitate patient-centered app development, with patient and physician interfaces. Our implementation strategy focused on the building of a multidisciplinary team to create a user-friendly and evidence-based app, to be used by patients in a home setting or at the point-of-care.
We present the iterative design, development, and testing of DiaFit, an app designed to improve the self-management of T2D and obesity, using an adapted Agile approach to software implementation. The production team consisted of experts in mobile health, nutrition sciences, and obesity; software engineers; and clinicians. Additionally, the team included citizen scientists and clinicians who acted as the de facto software clients for DiaFit and therefore interacted with the production team throughout the entire app creation, from design to testing.
DiaFit (version 1.0) is an open-source, inclusive iOS app that incorporates nutrition data, physical activity data, and medication and glucose values, as well as patient-reported outcomes. DiaFit supports the uploading of data from sensory devices via Bluetooth for physical activity (iOS step counts, FitBit, Apple watch) and glucose monitoring (iHealth glucose meter). The app provides summary statistics and graphics for step counts, dietary information, and glucose values that can be used by patients and their providers to make informed health decisions. The DiaFit iOS app was developed in Swift (version 2.2) with a Web back-end deployed on the Health Insurance Portability and Accountability Act compliant-ready Amazon Web Services cloud computing platform. DiaFit is publicly available on GitHub to the diabetes community at large, under the GNU General Public License agreement.
Given the proliferation of health-related apps available to health consumers, it is essential to ensure that apps are evidence-based and user-oriented, with specific health conditions in mind. To this end, we have used a software development approach focusing on community and clinical engagement to create DiaFit, an app that assists patients with T2D and obesity to better manage their health through active communication with their providers and proactive self-management of their diseases.
Between 1980 and 2014, the number of Americans diagnosed with diabetes increased fourfold [
Poor nutrition, low levels of physical activity, and sedentary lifestyles contribute greatly to T2D and obesity [
The ubiquitous nature of the Internet and mobile technologies makes them potential cost-effective and sustainable tools to improve health knowledge and outcomes for chronic diseases, such as T2D and obesity. According to the PEW Research Center, 70% of Americans have access to high-speed Internet at home [
The primary goal of this paper is to present DiaFit, a T2D and obesity-focused iOS app, and its implementation process, involving its potential end users. The app was developed to help patients self-manage T2D and obesity, and allow physicians to keep track of their patients’ progress. The majority of iOS apps targeting diabetes lack evidence-based support, functionalities, and interfacing with devices that support standard wireless communication protocols (eg, Bluetooth, Bluetooth Low Energy [BLE], or ANT+) [
For the purposes of this paper, the terms
We aimed to develop a fully integrative app that could be used to help patients manage their T2D and obesity, in a primary care setting and under the supervision of a primary care provider. We assembled a key stakeholder team comprised of citizen scientists (RB, CM, CRD), an internal medicine physician (ER), researchers in biomedical informatics, nutrition, and obesity science (FM, MC), and a software development team (TM, ZL). The citizen scientists were paid volunteers from the University of Florida Clinical and Translational Science Institute citizen scientist program. All citizen scientists had a chronic disease; either obesity and/or diabetes. The citizen scientists acted as de facto customers for the DiaFit software, whereas the clinician had both a customer and consultant role in the project.
We followed an Agile software development methodology [
1. Continuous and regular delivery of software components to allow the users to provide feedback early in the process, and to engage the intended users.
2. A project involving highly motivated individuals.
3. Regular face-to-face meetings.
4. Frequent and close cooperation between the stakeholders and continuous refinement of the design.
5. Functional software as main metric for progress.
6. Simplicity (ie, make the software as simple as possible, in collaboration with the stakeholders).
7. Pair-programming, whereby two programmers work together on a part of the code, with one programmer writing the code (the driver) and the other programmer assessing for correctness (the observer).
During the initial phase of the project we reviewed the limitations of existing apps (see
Basic requirements.
Requirement | Functional Requirement |
The patient-user should be able to use application on an iPhone | DiaFit runs on the following devices running iOS 9.2 or newer: iPhone 5 to iPhone 6s Plus |
The patient-user should have secure access to their account | DiaFit requires username and password for access. Passwords are saved via the keyed-hashed message authentication code - secure hash algorithm 1 random |
The patient-user should be able to track their eating habits | DiaFit provides user with access to a large nutrition database for logging dietary intake |
The patient-user should be able to measure calorie intake | DiaFit calculates the calorie intake of the user, utilizing the food consumption that is input by the user, and the nutritional database |
The patient-user should be able to measure carbohydrates, proteins and fats | DiaFit provides a graphical breakdown of the macronutrients consumed by the user, based on food consumption that is input by the user, and the database information |
The patient-user should be able to measure calorie expenditure | DiaFit supports Fitbit devices, Apple watch, or the iPhone on which the DiaFit app is installed, and provides the following calorie expenditure: (1) energy requirement estimate [ |
The patient-user should be able to track blood glucose | DiaFit allows the user to track their glucose by inputting their current glucose value, utilizing any type of glucometer |
The patient-user should be able to keep track of their medication | DiaFit provides data entry for the user to manually enter any medication and, if desired, create a reminder based on the time that medicine is taken |
DiaFit was implemented using iOS, so the software engineering team chose Apple’s Swift 2 programming language. This approach allowed for a tight integration with the current (and future) functionalities of Apple Healthkit (a platform for collecting data from various health and fitness apps in iOS). We used a serverless back-end developed with Amazon Web Services (AWS) Lambda and AWS DynamoDB database. The use of AWS Lambda allowed the app to have high availability and scalability without provisioning or managing servers. AWS also provided Health Insurance Portability and Accountability Act compliance, as well as Family Education Rights and Privacy Act and Federal Information Security Management Act compliance, if needed. We used the United States Department of Agriculture National Nutrient Database Application Program Interface (API) [
Additionally, we are in the process of incorporating the RxNorm API [
Additional requirements were identified in subsequent meetings, referred to as
Conceptually, the interactive process between the research team, software team, and the
Additional partial requirements.
Requirement | Functional Requirement |
The patient-user should be able to monitor their well-being | DiaFit prompts the user weekly for Short Form (9 questions) Diabetes-Specific Patient-Reported Outcomes Quality of Life (National Institutes of Health [NIH] Patient-Reported Outcomes Measurement Information Systems [PROMIS]) [ |
The patient-user should be able to track physical activity with a variety of wearables | DiaFit allows user to synchronize with iPhone Apple step counter, iWatch, and FitBit devices, and stores steps in a database |
The patient-user should be able to track blood glucose | DiaFit allows the user to track their glucose by automatically detecting if glucose data has been saved to Apple Health by a Bluetooth glucometer (ie, the wireless smart glucose-monitoring system from iHealth) |
The patient-user should be able to receive feedback from their physicians | DiaFit allows patient-user to give access data logs to physician-user |
The physician-user should be able to see summary statistics of their patients | DiaFit provides physician view |
The physician-user should be able to send encouragement messages to patient-user | DiaFit provides secure messaging interface |
The patient-user should be able to read physician-user messages | DiaFit provides secure access to messages |
Architecture of DiaFit. API: Application Program Interface; DB: database; USDA: United States Department of Agriculture.
Agile methodology for DiaFit development.
DiaFit incorporates account information and the following dimensions: nutrition, physical activity, blood glucose, medication, and Diabetes-Specific Patient-Reported Outcomes Quality of Life [
DiaFit’s icon was developed with the larger group of citizen scientists (
DiaFit icon.
Login/sign-in.
Account information.
The key functionalities of DiaFit were the following:
1. Access to a large nutrition database, which includes food items, calories, and breakdown in macronutrients, sodium, and fiber (
2. Physical activity tracking and seamless data entry. For the first version of the DiaFit app, the software team focused on integration with iPhone activity data, Apple watch, and Fitbit devices (
3. Glucose monitoring, either through manual input or Bluetooth seamless upload with iHealth glucose monitors. Another feature of glucose entry is the possibility to differentiate fasting glucose versus nonfasting glucose, which can be specified by the user (
4. Medication use via manual data entry, although DiaFit is being improved with an RxNorm API (
5. PROs (
6. Simplicity was also identified as a key, albeit nonfunctional, requirement of DiaFit. Indeed, with an aging population with T2D and obesity, it is critical to make the app as simple as possible [
Additionally, simple graphic capabilities were added to allow the user to track changes and see improvement over time. To continue our development process, our citizen scientists are undergoing software testing of the app and reporting bugs, frequency of bugs, and needed user interface changes through a Web-link.
Finally, DiaFit offers a physician view, which allows the monitoring of patient improvements remotely and asynchronously (
Slider menu.
Nutrition tracking.
Physical activity log.
Glucose log.
New medication entry.
Patient-reported outcomes survey.
Physician view of DiaFit.
The 2 main objectives of the DiaFit project were to (1) develop an evidence-based app that allows patients with T2D and obesity to manage their chronic conditions, and (2) ensure that the app is developed with the end-user in mind by involving them in the entire development of the product, rather than only in the testing phase (as is commonly done). To achieve this, we assembled a team of highly motivated individuals comprised of biomedical informaticians, nutrition and obesity science researchers, software engineers engaged in app development, a primary care physician, and citizen scientists with a strong interest in mHealth as a tool to address chronic conditions. To the best of our knowledge, this is the first attempt at assembling such a diverse team that included all stakeholders in the development of an app for the management of chronic conditions. It is important to note that our approach differed from that of focus groups, and that all team members acted as de facto collaborators on this project, bringing in a diverse range of expertise and perspectives. Although we included evidence-based components in the development of DiaFit, we cannot yet state that we have successfully created an evidence-based app because the effectiveness of the app has not yet been tested. Thus, whether we have succeeded in making the app evidence-based will need to be tested in future studies, and currently remains outside the scope of this paper.
The initial meeting with all DiaFit constituents occurred in late January 2016. The design and implementation phase started in late March 2016 due to the difficulty of recruiting motivated iOS developers. Finally, the deployment of the current version of DiaFit occurred mid-August 2016. The main barrier to accelerating the development process proved to be scheduling. Coordinating meetings with several citizen scientists who work full time, and a physician with long clinical hours, resulted in the research and development teams deciding to have partial team meetings to elicit feedback for improvement. However, the high motivation of all involved parties ensured that deadlines were met, and deliverables were presented on time to DiaFit stakeholders.
The development of DiaFit presented several challenges. Primary care physicians are significantly time-constrained. Therefore, careful planning is necessary to schedule Agile sprints early at the beginning of the project. We had not accounted for planning issues adequately at the beginning of this project, and subsequently lost a significant amount of time in early stages. Given the necessity for short time periods between meetings (ie, short Agile sprints), the development process should clearly lay out bimonthly meetings from the initial phase of the project, rather than letting development drive meeting times. However, our initial delays were mitigated by very strong clinical support for DiaFit. Having a clinician championing such a project is essential, not only to ensure sufficient feedback, but also to increase chances of adoption at later time points. Based on the expertise of our team, we decided to focus our efforts on iOS development and ignored the large Android market. With a growing segment of the population speaking Spanish, we also need to make the app available in Spanish. We are currently in version 1 of the app, and have not yet moved on to the staging that incorporates automated messaging, which would help the patients handle interactions related to diet, physical activity, and their glucose responses, which would be beneficial for self-management of T2D or obesity. Finally, DiaFit has not yet been tested as part of a pragmatic trial in a primary care setting with patients and physicians. However, prior work on mHealth strategies for diabetes management suggests that DiaFit could have a significant positive impact on patients’ lives [
Most apps developed for managing T2D and obesity do not include all variables that need to be addressed for these chronic conditions. Such apps typically address one dimension only, such as glucose monitoring or nutrition tracking, and often omit key functionalities that facilitate data entry and adherence, such as Bluetooth compatibility [
Despite the presence of >100,000 health and fitness-related apps in the Apple store alone, apps tend to be of poor quality with regards to clinical evidence. Very little effort has been placed in developing apps while including the potential end-users (eg, patients and physicians or health care professionals) in the process. In this paper, we presented the iterative process and design of the DiaFit process development, an app created to help patients with T2D and obesity manage their conditions more effectively. The process was based on the creation of a team representing all constituents of the DiaFit project, and we involved them as clients in an Agile software development project. We believe that this approach will allow academicians interested in mHealth strategies to close the gap between
application program interface
Amazon Web Services
Bluetooth Low Energy
mobile health
National Institutes of Health
patient-reported outcome
Patient-Reported Outcomes Measurement Information Systems
type 2 diabetes
FM was the lead author and was responsible for leading the app development and writing and editing of the manuscript. MC and ER were responsible for the expert content of the app and the writing and editing of the manuscript. JB was responsible for the writing and editing of the manuscript. TM was responsible for leading the app development. RB and CM were responsible for expert content and testing of the app. CR-D was responsible for expert content of the app. This research was supported by grant NIH/NCATS UL1TR001427.
None declared.