Published on in Vol 7 (2023)

Preprints (earlier versions) of this paper are available at, first published .
A Digital Platform and Smartphone App to Increase Physical Activity in Patients With Type 2 Diabetes: Overview Of a Technical Solution

A Digital Platform and Smartphone App to Increase Physical Activity in Patients With Type 2 Diabetes: Overview Of a Technical Solution

A Digital Platform and Smartphone App to Increase Physical Activity in Patients With Type 2 Diabetes: Overview Of a Technical Solution


1Clinical Epidemiology Division, Department of Medicine Solna, Karolinska Institutet, Stockholm, Sweden

2Department of Biosciences and Nutrition, Karolinska Institutet, Stockholm, Sweden

3Division of Society and Health, Department of Health, Medicine and Caring Sciences, Linköping University, Linköping, Sweden

4Obesity Specialist Center, Academic Specialist Center, Stockholm Health Services, Stockholm, Sweden

Corresponding Author:

Stephanie E Bonn, MSc, PhD

Clinical Epidemiology Division

Department of Medicine Solna

Karolinska Institutet

Maria Aspmans gata 16

Stockholm, 171 76


Phone: 46 8 517 791 83


Mobile Health (mHealth) solutions can be used to increase patients’ engagement in self-care. Descriptions of the technical solutions behind mHealth smartphone apps may guide the development of future apps. Here, we aim to describe the technical background and visual display of the DiaCert system, which was developed to support daily walking among patients with type 2 diabetes. The DiaCert system publishes one application program interface developed for patient devices (ie, smartphone apps running on iOS or Android) and another for web-based health care provider components (ie, administrative components). An individual care plan is created for each patient on the caregiver platform, and data on physical activity (ie, steps), blood samples, and questionnaires are shared between patient and caregiver in the DiaCert system. Technical solutions such as this enable us to reach more individuals at a lower cost compared to traditional health care. An advantage to the DiaCert technical solution is that it is built on a simple architecture and therefore is easily scalable. However, as it is a separate solution, it means adding yet another process for health care personnel to integrate into their work, which must be acknowledged. We hope that the technical description and visual display of the DiaCert system herein can guide researchers in the design and building of new and effective mHealth solutions.

International Registered Report Identifier (IRRID): RR2-10.1186/s12889-018-5026-4

JMIR Form Res 2023;7:e40285



New technology offers new opportunities for health care providers to connect, support, and monitor their patients. Traditional health care has often been organized as (1) reactive (ie, acting when there is an acute need) and (2) episodic (eg, annual checkups). However, today’s technology enables the landscape of health care to become (1) preventive and (2) continuous, that is, continuously following the health of patients and thereby enabling prevention of disease progression and complications from disease.

Type 2 diabetes is a chronic disease whose prevalence is rising rapidly [1]. Given the shortage of diabetes health professionals, especially in low- and middle-income countries, where the prevalence is rising most rapidly [2], use of new technology can be part of the solution. In addition to medication, a healthy lifestyle, including weight management, healthy eating habits, and physical activity, is key to controlling diabetes. Mobile health (mHealth) could potentially transform traditional health care toward becoming more preventive and continuous. This can increase patients’ engagement through the use of self-monitoring between routine care visits [3].

Smartphone app interventions targeting physical activity have proven effective [4]. Different apps include different features, such as monitoring, goal setting, and feedback [5]. Although detailed descriptions of app features and interventions are available, it is uncommon for researchers to publish any details about the technical solutions behind their apps, even though such information could be useful and improve the development of future apps.

The aim of this paper is to describe the technical background and provide a visual display of a smartphone app developed to support persons with type 2 diabetes and help them increase their daily physical activity. The smartphone app, in which patients register their daily steps, has been evaluated in a randomized controlled trial described in detail elsewhere [6]. We believe that the information given in this viewpoint can be used to guide and inspire future health app development.

Technical Solution

DiaCert comprises several systems that together create one solution to collect health data from patients. The DiaCert system publishes one application programming interface (API) developed for patient devices (ie, smartphone apps running on iOS or Android) and another for web-based health care provider components (eg, administrative components). The latter API also provides back-office functionality to include new health care providers and patients in the system. The DiaCert system uses 2 persistent databases: the MySQL MariaDB database (MariaDB Foundation) and the NoSQL Cassandra database (Apache Software Foundation). The MariaDB database is used to store information regarding users (ie, health care providers and patients) and the Cassandra database is used to store collected data (ie, steps and results from blood samples). The server applications are run in Docker containers on the application servers. The containers are run on the OpenShift container platform. Load balancers are used in order to distribute the load from the client to the server applications. Components of the DiaCert system are shown in Textbox 1 and Figure 1.

Components and hierarchy of the DiaCert system and division of front and back ends.

Front end

  • Patient component
    • The DiaCert iOS app
    • The DiaCert Android app
  • Health care provider components and administrative components (web based)

Back end

  • Web application program interface (DiaCare-web-api)
  • Device application program interface (DiaCare-device-api)
  • MariaDB database
  • Cassandra database
Textbox 1. Components and hierarchy of the DiaCert system and division of front and back ends.
Figure 1. Schematic of the DiaCert system. API: application programming interface.

Health Care Provider Component

An individual care plan is created for each patient entered into the caregiver platform using their unique national registration number [7]. Each caregiver has his or her own list of registered patients. A random code of 6 digits or letters and a QR code are created by the caregiver in the platform and used to connect the caregiver platform to the patient app. To ensure security, the code is only valid for 5 minutes. In the individual care plan, the patient and the caregiver set a daily step goal together. The goal is personalized, and no predefined recommendations on how to reach a set goal are used. The goal can be revised by the caregiver in dialogue with the patient. Steps are uploaded directly to the caregiver platform from the patient’s smartphone. The care plan also includes dates for laboratory testing and lifestyle questionnaires.

Patient Component: Smartphone App

Figure 2 shows the patient smartphone app, screen by screen.

The patient app is connected to the health care platform using a unique code received from the caregiver (Figure 2A). The patient only needs to connect using the code once.

The home screen (Figure 2B) shows a summary of activities in the individual care plan and presents an overview of steps taken that day and the last 7 days and dates for laboratory tests and questionnaires. The individual step goal is displayed, and that day’s current number of steps is shown as a percentage of the daily goal. Circles at the top of the screen illustrate goal fulfillment during the last 7 days; below, a larger circle represents that day’s steps. The circle is gradually filled as the patient walks toward the goal. When the goal is reached, the circle is completely filled and marked with a checkmark. Below that, 3 symbols (a shoe, a clipboard, and a drop of blood) lead to detailed information on steps, questionnaires, and results from blood samples (Figure 2C-E).

Steps (Figure 2C) are displayed as a bar chart and can be shown either as an average per month or steps per day. Green bars indicate days when the step goal was reached, and red bars indicate days the goal was not reached. The next screen (Figure 2D) shows questionnaires to fill out and responses from previous questionnaires. The final screen (Figure 2E), indicated by the drop of blood, shows results from laboratory tests. The example in Figure 2E shows data on hemoglobin A1C levels at 3 time points.

Eleven persons aged 19 to 49 years pilot-tested the first version of the DiaCert app for 3 weeks. Only 4 of 11 (36%) felt inspired to increase their physical activity during the test, and testers primarily requested an improved layout and better overview of their physical activity. In the next version of the app, we added the circles showing the continuous addition of steps to reach 100% of the daily goal and bar charts displaying goal fulfillment over time.

Figure 2. The patient smartphone app with each screen (A-E).


Technical solutions such as the DiaCert system enable us to reach more individuals at a lower cost than with traditional health care. The popularity of mHealth apps has led to a vast number of apps being freely available on the market that target health management in chronic conditions [8,9]. Only a fraction of all available apps have published technical descriptions.

A strength of the DiaCert technical solution is that it is built on a simple architecture and is thus easily scalable. A connection with other platforms would have increased complexity and costs. Nonetheless, the lack of integration with existing information systems, such as those that document continuous glucose data and make the data available for treating nurses or physicians, is a limitation. Furthermore, as DiaCert is a separate solution, using it means adding yet another process for health care personnel to integrate into their busy schedules. Another limitation is that the front end was only developed for health care personnel and not for private carers, such as carers of patients with cognitive impairment.

Behavior change techniques that impact the effectiveness of interventions have been summarized previously by Sporrel et al [5]. The DiaCert system comprises several techniques described by Sporrel et al, including monitoring, sharing, goal setting, and positive feedback. Passive monitoring, such as automatically recording step count in a participant’s phone, limits the time and effort of the user. In DiaCert, patients share their data with the caregiver. Sharing may increase effectiveness, according to Sporrel et al, but little is known about how sharing of physical activity information between patient and caregiver impacts the activity levels of the patient. Nevertheless, many patients show willingness to share personal digital data with their health care providers [10]. Two-way communication between persons with diabetes and health care providers has been determined to be a key component in technology-based self-care interventions that successfully reduce long-term blood sugar levels [11].

Another advantage of DiaCert is that a personalized goal is set with the caregiver. Assigning a goal to users, rather than letting them set their own goal or using a static, generic goal, was shown to be advantageous in the scoping review by Sporrel at al. Rewards for goal achievement, which are included in DiaCert, were also shown to be effective. Further, the DiaCert app is visual, and the number of daily steps is easy to follow regardless of language or literacy. Thus, use of the app is independent of language. This is valuable, as type 2 diabetes is common in immigrants [12].


We hope that our technical description and visual display of the DiaCert system can inspire development of future health apps and guide researchers in the design and building of new and effective mHealth solutions. Digital solutions have the potential to empower patients to manage their own health data and monitor their lifestyle to improve health.


We thank Dan Lind for his dedicated work in the development of the DiaCert app and his useful comments on the paragraph about the technical solution. This work was supported by the Stockholm County Council and Karolinska Institutet (4D; YTL), as well as through grants from the Swedish Research Council for Health, Working Life, and Welfare (Dnr: 2016–00985; YTL). The study was also financed by grants from the Swedish state under the agreement between the Swedish government and the county councils (Dnr: 20170784; YTL), the Strategic Research Area in Care Sciences (SFO-V; SEB), and the Stockholm County Council clinical research appointment (YTL). The funders had no role in the design, analysis, or writing of this article.

Authors' Contributions

YTL designed and is responsible for the study. SEB and CA performed the data collection. SEB performed the analyses and prepared the initial draft of the manuscript together with YTL. All authors have critically reviewed and edited the manuscript and approved the final version of the manuscript.

Conflicts of Interest

None declared.

  1. Diabetes: Key facts. World Health Organisation. 2021.   URL: [accessed 2023-03-06]
  2. Darzi A, Evans T. The global shortage of health workers-an opportunity to transform care. Lancet 2016 Nov 26;388(10060):2576-2577 [FREE Full text] [CrossRef] [Medline]
  3. Karduck J, Chapman-Novakofski K. Results of the Clinician Apps Survey, how clinicians working with patients with diabetes and obesity use mobile health apps. J Nutr Educ Behav 2018 Jan;50(1):62-69.e1. [CrossRef] [Medline]
  4. Feter N, Dos Santos TS, Caputo EL, da Silva MC. What is the role of smartphones on physical activity promotion? A systematic review and meta-analysis. Int J Public Health 2019 Jun;64(5):679-690. [CrossRef] [Medline]
  5. Sporrel K, Nibbeling N, Wang S, Ettema D, Simons M. Unraveling mobile health exercise interventions for adults: Scoping review on the implementations and designs of persuasive strategies. JMIR Mhealth Uhealth 2021 Jan 18;9(1):e16282 [FREE Full text] [CrossRef] [Medline]
  6. Bonn SE, Alexandrou C, Hjörleifsdottir Steiner K, Wiklander K, Östenson CG, Löf M, et al. App-technology to increase physical activity among patients with diabetes type 2 - the DiaCert-study, a randomized controlled trial. BMC Public Health 2018 Jan 10;18(1):119 [FREE Full text] [CrossRef] [Medline]
  7. Ludvigsson JF, Otterblad-Olausson P, Pettersson BU, Ekbom A. The Swedish personal identity number: possibilities and pitfalls in healthcare and medical research. Eur J Epidemiol 2009;24(11):659-667 [FREE Full text] [CrossRef] [Medline]
  8. Sneha S, Thalla S, Rischie I, Shahriar H. Health internet technology for chronic conditions: Review of diabetes management apps. JMIR Diabetes 2021 Aug 31;6(3):e17431 [FREE Full text] [CrossRef] [Medline]
  9. Jimenez G, Lum E, Car J. Examining diabetes management apps recommended from a Google search: Content analysis. JMIR Mhealth Uhealth 2019 Jan 16;7(1):e11848 [FREE Full text] [CrossRef] [Medline]
  10. Seltzer E, Goldshear J, Guntuku SC, Grande D, Asch DA, Klinger EV, et al. Patients' willingness to share digital health and non-health data for research: A cross-sectional study. BMC Med Inform Decis Mak 2019 Aug 08;19(1):157 [FREE Full text] [CrossRef] [Medline]
  11. Greenwood DA, Gee PM, Fatkin KJ, Peeples M. A systematic review of reviews evaluating technology-enabled diabetes self-management education and support. J Diabetes Sci Technol 2017 Sep;11(5):1015-1027 [FREE Full text] [CrossRef] [Medline]
  12. Buja A, Gini R, Visca M, Damiani G, Federico B, Francesconi P, Valore Project. Prevalence of chronic diseases by immigrant status and disparities in chronic disease management in immigrants: a population-based cohort study, Valore Project. BMC Public Health 2013 May 24;13(1):504 [FREE Full text] [CrossRef] [Medline]

API: application programming interface
mHealth: mobile health

Edited by A Mavragani; submitted 14.06.22; peer-reviewed by H Namba, M Blanker, J Job, D Reifegerste; comments to author 09.11.22; revised version received 17.11.22; accepted 28.02.23; published 14.03.23


©Stephanie E Bonn, Christina Alexandrou, Ylva Trolle Lagerros. Originally published in JMIR Formative Research (, 14.03.2023.

This is an open-access article distributed under the terms of the Creative Commons Attribution License (, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work, first published in JMIR Formative Research, is properly cited. The complete bibliographic information, a link to the original publication on, as well as this copyright and license information must be included.