Skip to content
This repository has been archived by the owner on Oct 30, 2022. It is now read-only.

Latest commit

 

History

History
 
 

Android

Overview

This directory contains all the code necessary to build the FDA MyStudies Android application for study participants. Customization of the build.gradle, api.properties and strings.xml files will enable your Android application to interact with the other components of your FDA MyStudies deployment. Further customization of app branding can be accomplished by replacing the default application images with your own. All configuration related to the creation and operation of studies is done using the Study builder without need for code changes or redeployment of the mobile application.

Example screens

Requirements

The FDA MyStudies Android application requires Android Studio and can be run on Android versions starting from Kitkat.

Platform integration

The FDA MyStudies mobile application fetches all study, schedule, activity, eligibility, consent and notification information from the Study datastore and posts pseudonymized participant response data to the Response datastore. Consent forms and any other identifiable data is posted to the Participant datastore. Email and password authentication is handled by the MyStudies Auth server using OAuth 2.0 and Hydra.

Configuration instructions

  1. Set the applicationId in Android/app/build.gradle to your Application ID
  2. Modify Android/api.properties to match the configuration of your backend services
  3. Update the following in the Android/app/src/fda/res/values/strings.xml file:
    • Set deeplink_host to redirect to the app from the Hydra auth server (for example, app://mystudies.<your-domain>/mystudies - more information about deep links within Android applications is located here)
    • Set google_maps_key to the API key obtained following the instructions located here
    • Set package_name and app_name to correspond to a value you define for applicationId in Android/app/build.gradle (details)
    • Customize user-facing text strings as necessary
  4. Configure push notifications
  5. Configure your Participant datastore instance to interface with your mobile application
  6. Optional. Customize images and text
  7. Open the Android/ directory that contains your modifications as an existing project in Android Studio
  8. If necessary, install the Android 10 SDK using Tools → SDK Manager, then File → Sync Project with Gradle Files (do not update Gradle plugin)

Building and deploying

To build and run your FDA MyStudies application, follow the instructions here.

To distribute your application to users, review the options here.


Copyright 2020 Google LLC