Skip to main content

App Walkthrough (Clinician)

This guide will walk you through how to make a Clinician-facing Plasma app that connects with Epic.

Sign Up for Plasma

The first step is to get your Plasma credentials.
The demo instance of Plasma is hosted at https://plasma.smart-on-fhir.com.
Although an isolated instance of Plasma can be deployed for your team, it's usually a good idea to start here for testing.

Please Contact Us to have an account set up for you.

Once you have signed up for Plasma, you will need the following information:

  • Plasma username/password
  • Plasma API Key (login to Plasma and go to Settings)

Register with Epic

Since our app will be connecting with Epic, we'll need to register our app with Epic. Once the app is registered, it can be managed by Plasma.

For help registering your app, please see our EHR Guide. A few things to note:

  • Please select Clinicians or Administrative Users
  • For Incoming APIs, we recommend selecting the following:
    • Patient.Read (R4)
    • Patient.Search (R4)
    • Observation.Read (R4) (all types)
    • Observation.Search (R4) (all types)
  • For your Redirect URL, please enter:
    • https://plasma.smart-on-fhir.com/api/plasma/sof/oauth
    • If you are using a different deployment of Plasma, you should specify that deployment instead
  • Please select R4 for the FHIR Version

Once you have created the app, make a note of your Non-Production Client Id

Use create-plasma-app

The create-plasma-app is a tool that can instantly create a demo app for you.

  1. Install or update the tool by running npm install -g create-plasma-app
  2. Run the tool by running npx create-plasma-app ./my-app {plasma-api-key}
    • Replace {plasma-api-key} with the API key you can find by logging into Plasma and going to Settings
  3. When prompted, select that you are creating a Clinician app for Web
  4. Select the nextjs-diabetes-risk-score-example template. This is a demo app that computes a patient's risk for diabetes.
  5. When prompted, select that you want to use Epic
  6. When prompted, enter the Non-Production Client Id you got when you registered your app with Epic

After running the tool, a sample app will be generated for you! It will have also created a project for you inside of Plasma. You will see if if you login to Plasma and navigate to your Projects view.

Test and Customize your App

Switch into the directory where the app was created (/my-app).
You can run the app by running npm run dev.

You can now examine the source code of the app and customize it as necessary. This app can be embedded in an EHR or used as a standalone app.

Have fun!