Skip to main content

Prerequisites

Requiredโ€‹

Java 21โ€‹

The app requires Java 21 or later. Spring Boot 3.x requires Java 17 as a minimum; Java 21 is recommended as it is the current LTS release and enables Java records, pattern matching, and virtual threads used throughout the codebase.

Check versionโ€‹

    java -version
# java version "21.0.x" ...

Install โ€” macOS (Homebrew)โ€‹

    brew install openjdk@21
echo 'export PATH="/opt/homebrew/opt/openjdk@21/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc

Install โ€” Ubuntu/Debianโ€‹

    sudo apt update
sudo apt install openjdk-21-jdk

Install โ€” Windows (winget)โ€‹

    winget install Microsoft.OpenJDK.21

Install โ€” SDKMAN (cross-platform)โ€‹

    sdk install java 21.0.5-tem
sdk use java 21.0.5-tem

Maven 3.9+โ€‹

Maven is the build tool. Spring Boot 3.3.x requires Maven 3.6.3 or later; Maven 3.9+ is recommended.

Check versionโ€‹

    mvn -version
# Apache Maven 3.9.x ...

Install โ€” macOSโ€‹

    brew install maven

Install โ€” Ubuntu/Debianโ€‹

    sudo apt install maven

Install โ€” Windowsโ€‹

Download from maven.apache.org and add bin/ to your PATH.

Maven wrapper

The project includes mvnw / mvnw.cmd โ€” Maven wrapper scripts that download the correct Maven version automatically. You can use ./mvnw instead of mvn if you prefer not to install Maven globally.


Gitโ€‹

git --version
# git version 2.x.x

Install via your OS package manager, git-scm.com, or GitHub Desktop.


An IDEโ€‹

Any modern Java IDE works. The two most popular:

IntelliJ IDEAโ€‹

The recommended IDE for Spring Boot development.

  • Download: jetbrains.com/idea
  • Community Edition is free and sufficient
  • Install the Spring Boot and Thymeleaf plugins for full support
  • Open the project by selecting pom.xml

VS Codeโ€‹

Lightweight alternative with good Java support via extensions.

  • Install the Extension Pack for Java from Microsoft
  • Install the Spring Boot Extension Pack
  • Open the project folder

Docker (for Redis session clustering)โ€‹

Required only for production clustering with Redis-backed sessions. Not needed for development or sandbox testing.

docker --version
# Docker version 24.x.x

For Epic sandbox testingโ€‹

A web browserโ€‹

The SMART EHR launch flow redirects your browser through Epic's authorisation page. Any modern browser works โ€” Chrome, Firefox, Safari, Edge.

An Epic developer account (free)โ€‹

Required only for testing against Epic's non-production sandbox (the -Pepic profile). Not required for the SMART Health IT sandbox tests which run without any account.

See Epic Registration โ†’ for the full setup guide.

The account is free and takes about 10 minutes to set up at fhir.epic.com.


Network requirementsโ€‹

The app makes outbound HTTPS requests to:

EndpointPurposeWhen
launch.smarthealthit.orgSMART Health IT sandbox discovery + auth-Psmartprofile
fhir.epic.comEpic sandbox discovery, auth + FHIR API-Pepic profile
Any hospital's Epic FHIR URLProduction FHIR callsProduction only

If you are behind a corporate proxy or firewall, ensure outbound HTTPS (port 443) to these hosts is permitted.


Dependency overviewโ€‹

The following are pulled in automatically by Maven โ€” you do not need to install them separately:

DependencyVersionPurpose
Spring Boot3.3.5Application framework
Spring Security6.xSecurity filter chain, CSRF
Spring Boot OAuth2 Client6.xPKCE helpers, token client
HAPI FHIR Client7.4.5FHIR R4 API calls
HAPI FHIR Structures R47.4.5Patient, Condition, MedicationRequest models
Thymeleaf3.xServer-side HTML templates
WireMock3.6.0HTTP mocking in tests
Jackson2.xJSON parsing (token responses, discovery docs)

Checklistโ€‹

Before moving to the Quick Start:

  • java -version shows Java 21+
  • mvn -version shows Maven 3.6.3+
  • git --version works
  • Outbound HTTPS to launch.smarthealthit.org is accessible (for SMART sandbox)
  • Browser available for the OAuth2 redirect

Quick Start โ†’