Flexpa Scan
A health insurance card serves as an essential instrument in administering healthcare services. Quickly getting crucial data like insurer, member, prescription, and group number in structured JSON format can accelerate patient registration, financial coverage, direct payments, or processing insurance claims.
Flexpa Scan lets your app collect this data with a mobile phone camera. You can use Flexpa Scan to complement the more detailed information available via Flexpa Link and API.
To use Flexpa Scan you need:
- A frontend app to start the authentication flow with a user. Flexpa Scan runs in an
<iframe>
and can be added to your frontend with a <script>
tag.
- A backend web server to complete the authentication flow (see below).
- A Flexpa Scan publishable key. Today this is available only by request and manual provisioning by a Flexpa admin.
#Authentication flow
The diagram below shows how Flexpa Scan is used to obtain insurance card details from a user.
The flow starts when your user wants to complete a workflow that requires scanning their insurance card.
Your frontend application opens Flexpa Scan with your publishable_key
using the create()
and open()
functions in the install step below.
The patient then uses a webcam or phone camera to scan their insurance card.
They can then verify the scanned details in Flexpa Scan.
In the onSuccess
callback you will receive the verified insurance card information parsed from the scanned card in FHIR format.
#Install
You can add Flexpa Scan to your application within a couple of minutes.
Inside an HTML document add the Flexpa Scan script to create a global FlexpaLink
object in your application:
Add script tag
<head>
...
<script src="https://js.flexpa.com/v1/"></script>
</head>
#Create
Next, initialize FlexpaLink
by calling create()
. Contact us to receive a Flexpa Scan publishable_key_test
or publishable_key_live
key you can use to initialize:
Initialize FlexpaLink
FlexpaLink.create({
// Replace with your Flexpa Scan key
publishableKey: '...',
mode: 'scan',
onSuccess: (result: ScanResult) => {
console.log(result)
};
});
Parameters
- publishableKeystringRequired
The unique Flexpa Link key to identify your app with Scan enabled. This is provided to you by Flexpa support.
- onSuccess(response: object) => voidRequired
This callback is executed when a patient successfully scans and validates their card information. The full set of callback parameters is described below.
- onLoad() => void
This callback is executed when Flexpa Scan has finished loading after calling open
.
- onExit() => void
This callback is executed whenever a patient exits the Flexpa Scan flow without successfully authorizing access to their health plan.
#Open
To start the flow where your users scan their health card, use the open()
function on the FlexpaLink
object. For example, opening on a button click:
<button onclick="FlexpaLink.open()">Scan your insurance card</button>
That's it! You now have the core information from the patient's insurance card.→
When a user successfully links a health data source, FlexpaLink
calls the onSuccess
callback defined in the Create step. This callback includes the information related to the scanned insurance card:
- patientobject
A FHIR Patient resource containing the key demographic information present on the card, such as name and date of birth.
- coverageobject
A FHIR Coverage resource containing the insurance coverage information present on the card, such as member ID, group number, RxBin, RxGroup, RxPCN,
- endpointstring
An optional UUID string for the Endpoint corresponding to the insurance card.
This can be used in combination with the Flexpa Link and API flow, as providing this value skips the search-and-select health plan step in the authorization flow.
Patients will still need to authorize with their user name and password.
#Next steps
Contact us if you are interested and would like to get started. We will provide you with a Flexpa Scan publishable key to initialize Flexpa Scan in your application.