🫀Measurements
Last updated
Last updated
A FibriCheck measurement is performed in 3 steps:
Take the measurement: the Camera SDK uses the smartphone's camera to take an on-device PPG-signal.
Process the measurement: the measurement data is sent to the FibriCheck cloud where our AI algorithm will process the measurement and make a diagnosis. In some cases the measurement will be reviewed by a medical expert.
Visualise the measurement: the measurement can be visualised in your application or through a generated PDF.
A measurement can have multiple statuses, depending in which phase of the review process it is in:
Status | Description |
---|---|
This value represents the indicator that the FibriCheck algorithm has given to the measurement. When the status
is reviewed
, it means this indicator is validated by a medical professional. Possible values are 'normal' | 'quality' | 'urgent' | 'warning'
After a measurement is analyzed the mostSevereLabel
object will become available. This object will return the current diagnosis and takes into account whether it's a measurement that will be reviewed (premium) or not (essential) `. To get the diagnosis, you can check the mostSevereLabel
property from the measurement object:
The mostSevereLabel
is added and updated asynchronously after a measurement has been analyzed or reviewed respectively. It can take a couple of seconds before it's added or updated to the measurement result.
Possible values of mostSevereLabel.key
are:
Possible values of mostSevereLabel.color
are:
The colors give a visual indication of the meaning of the label. Green, orange and red indicate the severity of the diagnosis. Blue indicates a issue with the quality of the measurement, and grey means that a result is not (yet) available.
In older versions of the Cloud SDK, this property may not be visible yet. If so, you can always use the getMostSevereLabel()
function.
The algorithm returns the calculated heart rate in the heartrate
property. This calculated value can differ from the real-time heart rate value that you can see while performing a measurement.
The reason for the difference is because the heartrate
property is provided by the FibriCheck Cloud AI algorithm, which provides a more accurate value than the lighter on-device algorithm.
The date and time of the measurement is given in epoch format under the measurement_timestamp
property.
When a measurement has been performed, context can be added. The context can contain one activity and multiple symptoms.
The context can be added directly to a measurement or can be updated at a later stage through the updateMeasurementContext
method. This can be beneficial to the user experience. If you send the raw measurement data first, the processing of the measurement can already start in the FibriCheck Cloud. When the user has selected their symptoms, it can be added to the already processed measurement.
See below how to update the measurement context afterwards.
The symptom severity score follows the modified EHRA classification for symptom severity. The symptom severity score is a single score given across the symptoms a patient is experiencing.
When a measurement done by the Camera SDK is finished, it needs to be uploaded to the FibriCheck cloud for processing and analysis.
Take a look at the Camera SDK documentation for a full code example on how to perform and post a FibriCheck measurement.
Measurements will only be analyzed by the algorithm when the authenticated user has an active prescription. See the prescriptions documentation for more information on how to create and manage prescriptions.
The Cloud SDK is aware of the data structure of the Camera SDK. Posting a measurement is nothing more than executing the postMeasurement
function with the data object from the Camera SDK.
The SDK will automatically augment the measurement data with some meta-data like the device details and the application version.
After a successful measurement, the platform-specific FibriCheck Camera SDK will output a structure that, converted to JSON, can be uploaded as-is to the FibriCheck cloud via the following POST
call:
POST
https://api.fibricheck.com/data/v1/documents/fibricheck-measurements/
Typically you want to add some meta-data to the measurement. This can be done by augmenting the measurement
object from the Camera SDK in the following way:
Always include the device information. The algorithm requires this information to know which parameters to include in the analysis!
The tags
parameter can be used to categorise sets of measurements for easier filtering later on.
Take a look at the documentation of your app development platform to find out how to retrieve metadata parameters like OS version, build number,... in your application
To update the measurement context through the API, you have to execute the API call below with the following body:
PUT
https://api.fibricheck.com/data/v1/fibricheck-measurements/documents/{measurementId}
Use the getMeasurement
method to get a single measurement based on an id
. The SDK only allows to request measurements for the currently authenticated user.
To fetch multiple measurements, you can use thegetMeasurements
method. This will return a paginated result with all measurements for the currently authenticated user. You can find the measurements under the data
property. You can also use the next
and previous
functions, present on the result, to navigate through the user's measurements.
GET
https://api.fibricheck.com/data/v1/fibricheck-measurements/documents
The following JSON result is an example response when a single measurement is requested from the API.
This endpoint uses RQL as a query language and always returns a list of documents.
In a single call, by default 20 items are returned, the maximum number of items that can be fetched in a single API call is 50. You can customise the number of returned items using the limit()
operator.
If there are more than 50 measurements in your query, you have to use an offset to fetch more than the first. For example limit(10,50)
will return 10 results, with an offset of 50.
By default the API returns the results in ascending order, the oldest measurement is returned first. Use the sort(-creationTimestamp)
operator to return results in descending order.
The following example queries give an overview of how to use this endpoint. For brevity, the full URL is omitted.
Fetch the latest measurement
/documents?limit(1)&sort(-creationTimestamp)
Fetch the latest 50 measurements
/documents?limit(50)&sort(-creationTimestamp)
Fetch the next 50 measurements
/documents?limit(50,50)&sort(-creationTimestamp)
Fetch measurements where the analysis failed
/documents?eq(status,analysis_failed)
App Development Best Practice
By default, a registered user with no additional permissions will be able to only fetch his own measurements through the API. However, if at some point the user receives additional permissions, for example when the user is a doctor or nurse, that might change.
Therefore it's strongly advised to always filter on creatorId
using the following RQL query:/documents?eq(creatorId,{userId})
It is also possible to remove measurements that you are entitled to. To do this, you need to be a staff member of at least one group of the recorded measurement.
DELETE
https://api.fibricheck.com/data/v1/fibricheck-measurements/documents/{measurementId}
The Camera SDK is the workhorse for generating the measurement data. After a PPG measurement has been completed, the Camera SDK will emit an onMeasurementProcessed
event with a CameraData
object that contains all data to process the the measurement.
The complete structure is exported as a Measurement
type in the SDK. The CameraData
object is explained here for informational purposes, the Camera SDK will populate all the fields.
This structure can be used for creating MeasurementCreationData,
which can be posted to our backend via the postMeasurement
method
Property | Possible Values | Description |
---|---|---|
mEHRA score | Symptoms | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
measured
The measurement is received. The status should change to preprocessing_selection
immediately.
preprocessing_selection
The correct preprocessing algo is being determined. The status should change to analysis_selection
immediately.
analysis_selection
The correct analysis algo is being determined. The status should change to pending_analysis
immediately.
pending_analysis
The measurement is waiting for the algorithm to analyze it. The status should change to under_analysis
when the algorithm is ready to analyze
under_analysis
The measurement is being analyzed by the algo. The status will be transitioned to analysis_failed
or processing_results
depending on the response of the algorithm.
analysis_failed
The algorithm was not able to analyze this measurement. The measurement will stay in this status until manually transitioned back to pending_analysis
.
processing_results
The result of the analysis is being processed. The status should change to analyzed
when ready.
analyzed
The measurement was successfully analyzed
. Depending on the subscription, the measurement will immediately transition to pending_review
or stay in this status. Upon request, the measurement can also be manually transitioned topending_review
.
pending_review
The measurement is awaiting revision by a human medical expert. The human revision is currently meant to be completed within 48 hours and will transition the status to reviewed
.
reviewed
The measurement is reviewed by a human medical expert. The measurement will stay in this status until manually transitioned back to pending_review
.
activity
resting
, sleeping
, sitting
, walking
working
, exercising
other
, standing
Describes what the user was doing just before taking the measurement. A single value can be selected.
symptoms
no_symptoms
, lightheaded
, confused
, fatigue
, other
, palpitations
, chest_pains
, shortness_of_breath
, dizziness
, feeling_of_fainting
, racing_heart
Symptoms that the user was experiencing at the time of the measurement. One or more values can be selected.
symptomSeverity
2a
, 2b
, 3
, 4
A single severity score across the different symptoms a user is experiencing.
2a
Mild
Normal daily activity not affected, symptoms not troublesome to patient
2b
Moderate
Normal daily activity not affected but patient troubled by symptoms
3
Severe
Normal daily activity affected
4
Disabling
Normal daily activity discontinued
String
measurementId*
String