NAV
shell

Introduction

The Kardia API is organized around REST. Our API has predictable resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

How it Works

Kardia Pro facilitates a connection between a clinician’s Kardia Pro account and their selected patients. Patients are provisioned with a unique code that connects their Kardia application specifically to their clinician or service and allows all ECG recordings captured via Kardia Mobile to be accessible to the clinician via the Kardia Pro API.

Authentication

curl https://api.kardia.com/v1/patients \
  -u YOUR-API-KEY:
# The colon prevents curl from asking for a password.

The Kardia API uses API keys to authenticate requests. APIs within the Kardia platform require the use of HTTP Basic Authentication, constructed from a valid API key as the username and empty password combination.

Example Requests

# Get your API Key
curl -X POST https://api.kardia.com/v1/apikey \
  -d email=YOUR_EMAIL \
  -d password=YOUR_PASSWORD

To access your API Key, send a POST request with your Kardia Pro email and password as url encoded form params to /v1/apikey.

# Generate a new API Key
curl -X POST https://api.kardia.com/v1/apikey/new \
  -u YOUR-API-KEY:

Example Response

{
    "apiKey": "3test974-cd11-48c3-a0dd-621test8test"
}

To generate a new API Key, send a POST request to /v1/apikey/new using your current API Key.

Base URL

Region Host
US https://api.kardia.com
EU https://eu-api.kardia.com

Patients

Patient Object

Name Type Description
id string The patient's unique random ID
mrn string The patient's medical record number
dob string The patient's date of birth
email string The patient's email address
firstname string The patient's first name
lastname string The patient's last name
sex int The patient's sex as ISO/IEC5218
status string Connection status for patient: "pending", "connected", "none"

Create Patient

Example Request

curl https://api.kardia.com/v1/patients \
  -u YOUR-API-KEY: \
  -d mrn=JS-20000721 \
  -d dob=2000-07-21 \
  -d email=joe@example.com \
  -d firstname=Joe \
  -d lastname=Smith \
  -d sex=1

Example Response

{
  "id": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
  "mrn": "JS-20000721",
  "dob": "1970-03-12",
  "email": "joe@example.com",
  "firstname": "Joe",
  "lastname": "Smith",
  "sex": 1
}

To create a patient, send a POST request to /v1/patients.

Arguments

Name Type Required Description
mrn string Yes The patient's medical record number
email string Yes The patient's email address
dob string Yes The patient's date of birth as YYYY-MM-DD
firstname string No The patient's first name
lastname string No The patient's last name
sex int No The patient's sex as ISO/IEC 5218

Get Patient

Example Request

curl https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i \
 -u YOUR-API-KEY:

Example Response

{
  "id": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
  "mrn": "JMJ-19810712",
  "dob": "1970-03-12",
  "email": "joe@example.com",
  "firstname": "Joe",
  "lastname": "Smith",
  "sex": 0, 
  "status": "pending"
}

Responds to GET requests to /v1/patients/:id and returns a single patient object.

Example Request with Custom Participant Fields

curl https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i?customField=true
  -u YOUR-API-KEY:

Example Response with Custom Participant Fields

{
  "id": "wNSEDeLOEPQE5rznkJmwbnjpx",
  "phone": "JMJ-19810712",
  "dob": "1970-03-12",
  "firstname": "Joe",
  "lastname": "Smith",
  "status": "pending",
  "participantCustomFields": [
      {
          "id": "hSlFAoIJEYbDPyH",
          "fieldName": "steps",
          "displayName": "steps",
          "fieldValue": "10",
      },
      {
          "id": "H82XSoIxV7S3UpyEu8Ahc",
          "fieldName": "emergencyContact",
          "displayName": "emergencyContact",
          "fieldValue": "test emergencyContact"
       }
    ]
}

Get Patient with Custom Fields

Querystring parameters

customField If true, returns the custom participant fields object along with the Patients and the page info Objects

Custom Participant Fields Object

Name Type
Id string
FieldName string
DisplayName string
FieldValue string

Delete Patient

Example Request

curl -X DELETE https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i \
 -u YOUR-API-KEY:

Responds to DELETE requests to /v1/patients/:id. Successful requests return an HTTP status 202 Accepted. Developers must request Data Controller access for this functionality.

Export Patient

Example Request

curl https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i/export \
 -u YOUR-API-KEY:

Responds to GET requests to /v1/patients/:id/export. Exports are queued and email sent to the API key owner once the export is ready for download. Returns an HTTP 202 Acceptedon success. Developers must request Data Controller access for this functionality.

Get Connection Templates

Example Request

curl https://api.kardia.com/v1/teamConnectionTemplate \
 -u YOUR-API-KEY:

Example Response

[
  {
      "teamID": "Fs0ZK1raZi5KidNtCyK9b4nyh6gkq4ah",
      "templateName": "KardiaMobile + 1 Year Connection ($120)",
      "templateId": "4qq0q0tSkSKziiUcyjOYbpi9whdo7403",
      "duration": 365,
      "price": 9.99
  }
]

Responds to GET requests to /v1/teamConnectionTemplate returns a template ids, template names, price, duration and team id.

Get Connection Code

Example Request

curl https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i/code?template_id=RnHOxYlu8l7zGboaWKhicma6qin4fjr7 \
 -u YOUR-API-KEY:

Example Response

{
  "code": "LQYP-MSAK-NPJR",
  "status": "connected"
}

Responds to GET requests to /v1/patients/:id/code and returns a valid connection code for the given patient and the status of the connection, either connected or pending.

Querystring parameters

Name Type Required Description
template_id string False Need to retrive specific codes based on templateId

Disconnect patient connection

Example Request

curl -X POST https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i/disconnect \
 -u YOUR-API-KEY:

Example Response

{}

Responds to POST requests to /v1/patients/:id/disconnect and terminates a patient's connection. Returns an empty response if successful.

Get Summary Report

Example Request

curl https://api.kardia.com/v1/patients/{:id}/summaryReport?startTime=2021-03-15T15:04:05Z&endTime=2021-04-07T15:04:05Z&dateFormat=us
 -u YOUR-API-KEY:

Example Response

Responds to GET requests to /patients/{id}/summaryReport returns a application/pdf. Defaults to last 30 days if start and endTime are not provided

Arguments

Name Type Required Description
id string Yes Unique id for patient
startTime date No RFC3339 formatted time to start report
endTime date No RFC3339 formatted time to end report
dateFormat string No 'us' or 'iso', used for formatting Dates in pdf response, defaults to us format

Get Patient Recordings

Example Request

curl https://api.kardia.com/v1/patients/wNSEDeLOEPQE5rznkJmwbnjpxfdst93i/recordings \
 -u YOUR-API-KEY:

Example Response

{
  "totalCount": 200,
  "recordings": [
    {
      "id": "3wde1eem9vy4y1a0rv3y98u2a",
      "patientID": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
      "duration": 30000,
      "heartRate": 65,  
      "note": "Drank coffee, having palpitations.",
      "recordedAt": "2008-09-15T15:53:00+05:00",
      "tags": ["Low sleep", "At doctors office"]
    }
  ],
  "pageInfo": {
    "startCursor": "c3RhcnRDdXJzb3I=",
    "endCursor": "ZW5kQ3Vyc29yc2Rh=",
    "hasNextPage": true
  }
}

Responds to GET requests to /v1/patients/:id/recordings and returns an array of ECG recordings for the given patient.

Querystring parameters

limit A limit on the number of objects to be returned. Limit can range between 1 and 500, and the default is 100.

start The cursor used to return recordings after the startCursor or endCursor cursor, and returning at most limit recordings.

Recordings Object

Name Type Description
totalCount int The total number of patients
recordings array An array of recording data
pageInfo object Pagination information

Page Info Object

Name Type Description
startCursor string The cursor for the first recording in the page
endCursor string the cursor for the last recording in the page
hasNextPage bool True if there is another page of data

Get All Patients

Example Request

curl https://api.kardia.com/v1/patients?limit=50&start=ZW5kQ3Vyc29yc2Rh= \
  -u YOUR-API-KEY:

Example Response

{
  "totalCount": 200,
    "patients": [{
      "id": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
      "mrn": "JS-19810712",
      "dob": "1970-03-12",
      "email": "joe@example.com",
      "firstname": "Joe",
      "lastname": "Smith",
      "sex": 0
      "status": "connected"
    }],
    "pageInfo": {
      "startCursor": "c3RhcnRDdXJzb3I=",
      "endCursor": "ZW5kQ3Vyc29yc2Rh=",
      "hasNextPage": true
    }
}

Example Request with Custom Participant Fields

curl https://api.kardia.com/v1/patients?limit=50&start=ZW5kQ3Vyc29yc2Rh&customField=true\
  -u YOUR-API-KEY:

Example Response with Custom Participant Fields

{
  "totalCount": 2,
    "patients": [{
      "id": "SkUDkZEAxSwiVF37fbgn116xs",
      "mrn": "JS-19810712",
      "dob": "1970-03-12",
      "email": "joe@example.com",
      "firstname": "Joe",
      "lastname": "Smith",
      "sex": 0
      "status": "connected",
      "participantCustomFields": [
      {
          "id": "R54a3jUTDfcfs22pvxp14c",
          "fieldName": "test_field",
          "displayName": "test_field",
          "fieldValue": "test_field_value"
      },
      {
          "id": "H82XSoIxV7S3UpyEu8Ahc",
          "fieldName": "Summary Report",
          "displayName": "Summary Report",
          "fieldValue": "test Summary Report"
       }
       ]}
  ],
  "pageInfo": {
  "startCursor": "c3RhcnRDdXJzb3I=",
  "endCursor": "ZW5kQ3Vyc29yc2Rh=",
  "hasNextPage": true
  }
}

Responds to GET requests to /v1/patients and returns a list of patients with the most recent created patient first.

Querystring parameters

limit A limit on the number of objects to be returned. Limit can range between 1 and 500, and the default is 100.

start The cursor used to return patients after the startCursor or endCursor cursor, and returning at most limit patients.

Patients Object

Name Type Description
totalCount int The total number of patients
patients array An array of Patient objects
pageInfo object Pagination information

Page Info Object

Name Type Description
startCursor string The cursor for the first patient in the page
endCursor string the cursor for the last patient in the page
hasNextPage bool True if there is another page of data

Get All Patients with Custom Fields

Querystring parameters

Along with the parameters mentioned above.

customField If true, returns the custom participant fields object along with the Patients and the page info Objects

Custom Participant Fields Object

Name Type
Id string
FieldName string
DisplayName string
FieldValue string

Teams

Get All Patients

Example Request

curl https://api.kardia.com/partner/v1/teams/01WXFqmerP9IhSJGkxZVcfxk3q/patient/fields\
-u YOUR-API-KEY:

Example Response

{
    "teams": [{
        "id": "abcdefg",
        "teamId": "FvmnXyl78L81loT0T3",
        "fieldName": "firstName",
        "displayName": "FIRST NAME",
        "isRequired": false,
        "isVisible": true,
        "isCustom": false,
        "isKeyIdentifier": false,
        "kardiaRXVisible": true,
        "createdAt": "2021-08-30T23:02:11.025158Z",
        "updatedAt": "2021-11-11T19:57:31.430292Z"
    }]
}

Responds to GET requests to /teams/:id/patient/fields and returns a list of patients with the most recent created patient first.

Name Type
id string
teamId string
fieldName string
displayName string
isRequired bool
isVisible bool
isCustom bool
isKeyIdentifier bool
kardiaRXVisible bool
createdAt string
updatedAt string

Add service Provider

Example Request

curl https://api.kardia.com/partner/v1/teams/OstYEHjsota5xj7m4QQdbhdxpttj4/serviceProviderTeams/8sP3SiaFigYoGRKoc4kaf692hmwi\
 -u YOUR-API-KEY:

To add a teams service provider send a POST requests to /teams/:id/serviceProviderTeams/:spid

HTTP Codes Description
200 Added service Provider successfully
500 Failed to add service provider

ECG Recordings

ECG Object

Name Type Description
id string The patient's unique random ID
patientID string The unique patient identifier
duration int The duration of the ECG recording in milliseconds
heartRate int The average heart rate
note string The patient supplied note associated with the ECG
algorithmDetermination string Represents the output of the AliveCor ECG algorithms, the allowable values are normal, afib, unclassified, bradycardia, tachycardia, too_short, too_long, unreadable, sinus_rhythm, sinus_rhythm,multiple_pacs, sinus_rhythm,multiple_pvcs, sinus_rhythm,wide_qrs and no_analysis

Apple Specific:

sinusRhythm, atrialFibrillation, inconclusiveLowHeartRate, inconclusiveHighHeartRate, inconclusivePoorReading, inconclusiveOther, unrecognized and notSet
data object The raw and enhanced filterred ECG data samples
recordedAt string The date time the ECG was recorded

ECG Data Object

Name Type Description
frequency int The frequency in hertz of the ECG recording, i.e. 300Hz
mainsFrequency int The mains frequency either 50 (e.g. Europe) or 60 (e.g. America) Hz.
amplitudeResolution int The number of nanovolts corresponding to each sample unit.
samples object The ECG data samples

ECG Samples Object

Name Type Description
leadI array The Lead 1 data samples at the specified sampling frequency, in ADC units. To convert to millivolts, divide these samples by (1e6 / amplitudeResolution).

Single ECG

Example Request

curl https://api.kardia.com/v1/recordings/3wde1eem9vy4y1a0rv3y98u2a \
  -u YOUR-API-KEY:

Example Response

{
  "id": "3wde1eem9vy4y1a0rv3y98u2a",
  "patientID": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
  "algorithmDetermination": "normal",
  "duration": 30000,
  "heartRate": 65,  
  "note": "Drank coffee, having palpitations.",
  "tags": ["Low sleep", "At doctors office"],
  "recordedAt": "2008-09-15T15:53:00+05:00",
  "data": {
    "raw": {
      "frequency": 300,
      "mains_freq": 60,
      "samples": {
        "leadI": [
          397,
          -262,
          -426,
          -284,
          286,
          391,
          -45,
          -249,
          -30,
          566,
          515,
          204,
          -138,
          -30,
          491,
          572,
          103,
          -187,
          -62,
          322,
          ...     
        ],
        "leadII": [...],
        "leadIII": [...],
        "AVR": [...],
        "AVL": [...],
        "AVF": [...]
      },
      "numLeads": 6
    },
    "enhanced": {
      "frequency": 300,
      "mains_freq": 60,
      "samples": {
        "lead_I": [
          397,
          -262,
          -426,
          -284,
          286,
          391,
          -45,
          -249,
          -30,
          566,
          515,
          204,
          -138,
          -30,
          491,
          572,
          103,
          -187,
          -62,
          322,
          ...     
        ],
        "leadII": [...],
        "leadIII": [...],
        "AVR": [...],
        "AVL": [...],
        "AVF": [...]
      },
      "numLeads": 6
    }
  }
}

To get a single ECG for a given patient send a GET request to /v1/recordings/:id

Single ECG PDF

Example Request

curl https://api.kardia.com/v1/recordings/3wde1eem9vy4y1a0rv3y98u2a.pdf \
  -u 7863674b-1919-432b-90d5-838fb8207d3f:

To get a single ECG PDF for a given patient send a GET request to /v1/recordings/:id.pdf

Get All Recordings

Example Request

curl https://api.kardia.com/v1/recordings \
 -u 7863674b-1919-432b-90d5-838fb8207d3f:

Example Response

{
  "totalCount": 200,
   "recordings": [{
      "id": "3wde1eem9vy4y1a0rv3y98u2a",
      "patientID": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
      "algorithmDetermination": "normal",
      "duration": 30000,
      "heartRate": 65,  
      "note": "Drank coffee, having palpitations.",
      "recordedAt": "2008-09-15T15:53:00+05:00",
      "tags": ["Low sleep", "At doctors office"]
  }],
  "pageInfo": {
    "startCursor": "c3RhcnRDdXJzb3I=",
    "endCursor": "ZW5kQ3Vyc29yc2Rh=",
    "hasNextPage": true
  }
}

Responds to GET requests to /v1/recordings and returns an array of ECG's across all patients taken in the Kardia Mobile App. This will not include screening station recordings.

Querystring parameters

limit A limit on the number of objects to be returned. Limit can range between 1 and 500, and the default is 100.

start The cursor used to return recordings after the startCursor or endCursor cursor, and returning at most limit recordings.

Get All Screening Station Recordings

Example Request

curl https://api.kardia.com/v1/screening/recordings \
 -u 7863674b-1919-432b-90d5-838fb8207d3f:

Example Response

{
  "totalCount": 200,
   "recordings": [{
      "id": "3wde1eem9vy4y1a0rv3y98u2a",
      "patientID": "wNSEDeLOEPQE5rznkJmwbnjpxfdst93i",
      "algorithmDetermination": "normal",
      "duration": 30000,
      "heartRate": 65,  
      "note": "Drank coffee, having palpitations.",
      "tags": ["Low sleep", "At doctors office"],
      "recordedAt": "2008-09-15T15:53:00+05:00"
  }],
  "pageInfo": {
    "startCursor": "c3RhcnRDdXJzb3I=",
    "endCursor": "ZW5kQ3Vyc29yc2Rh=",
    "hasNextPage": true
  }
}

Responds to GET requests to /v1/screening/recordings and returns an array of ECG's taken at Kardia Screening Stations.

Querystring parameters

limit A limit on the number of objects to be returned. Limit can range between 1 and 500, and the default is 100.

start The cursor used to return recordings after the startCursor or endCursor cursor, and returning at most limit recordings.

Set QT Analysis Measurements

Example Request

curl --request POST https://api.kardia.com/v1/recordings/3wde1eem9vy4y1a0rv3y98u2a/qt \
 -u 7863674b-1919-432b-90d5-838fb8207d3f: \
 --header 'Content-Type: application/json' \
 --data '{"qt": 1.45,"rr": 1.21,"qtcb": -5.12,"qtcf": 145, "error": "any error message", "errorType": "poorQuality"}'

Example Response

{
    "recordingID": "3wde1eem9vy4y1a0rv3y98u2a",
    "qt": 1.45,
    "rr": 1.21,
    "qtcb": -5.12,
    "qtcf": 145,
    "measurementID": "IOyFM8PTUW7DEw2UAircc1pfvsh2rxdd",
    "error": "any error message",
    "errorType": "poorQuality"    
}

Responds to POST requests to /v1/recordings/:recordingId/qt and returns the created qt measurement object. A qt measurement may contain an optional error message, which will require an errorType if an error message is specified. Valid error types are poorQuality, undeterminedRhythm, and other

Recordings Object

Name Type Description
totalCount int The total number of recordings
recordings array An array of recording data
pageInfo object Pagination information
startCursor string The cursor for the first recording in the page
endCursor string the cursor for the last recording in the page
hasNextPage bool True if there is another page of data

Get Recording Symptoms

Example Request

curl https://api.kardia.com/v1/recordings/7q8ZwxNLl2sXOQVkzBYncp95i3gpp804/symptoms \
 -u YOUR-API-KEY:

Example Response

{
    "symptoms": [
        {
            "recordingID": "7q8ZwxNLl2sXOQVkzBYncp95i3gpp804",
            "symptomId": "6de27744-4cca-47ea-b8dc-ad12ea09d1b6",
            "createdAt": "2022-12-23T11:24:02.124965Z",
            "symptomName": "Trouble breathing"
        },
        {
            "recordingID": "7q8ZwxNLl2sXOQVkzBYncp95i3gpp804",
            "symptomId": "8e5273dd-278c-4bdc-aebe-098fc2f1f286",
            "createdAt": "2022-12-23T11:24:02.124966Z",
            "symptomName": "Dizzy, light-headed"
        }
    ]
}

Responds to GET requests to /v1/recordings/:id/symptoms and returns an array of symptoms (and their detail) reported by a Patient right after taking an ECG. If the user did not explicitly report a symptom, you can expect a "None Specified" symptom to be returned

Get Recording Activity

Example Request

curl https://api.kardia.com/v1/recordings/7q8ZwxNLl2sXOQVkzBYncp95i3gpp804/activity \
 -u YOUR-API-KEY:

Example Response

{
    "activity": [
        {
            "recordingID": "7q8ZwxNLl2sXOQVkzBYncp95i3gpp804",
            "activityLevelID": "10e89226-0d89-494d-b115-8c1178af1f0f",
            "name": "At rest (sitting or lying down)"
            "createdAt": "2022-12-23T11:24:02.125347Z",
        }
    ]
}

Responds to GET requests to /v1/recordings/:id/activity and returns an array of activities (and their detail) reported by a Patient right after taking an ECG. If the user did not explicitly report an activity, you can expect a "None Specified" activity to be returned

Partners

Get associated teams

Example Request

curl https://api.kardia.com/partner/v1/teams\
 -u YOUR-API-KEY:

Example Response

{
    "teams": [{
        "id": "abcdefg",
        "name": "team name",
        "avatarUrl": "https://s3.amazonaws.com/public/images/partner-logos/fpo_avatar.png",
        "callbackUrl": "https://ptsv.com/t/qgies-callbackTest/post",
        "logoUrl": "https://s3.amazonaws.com/fpo_logo.png",
        "timezone": "America/Los_Angeles",
        "secretKey": "secret-key",
        "createdAt": "2016-06-02 19:41:59.01917 +0000 +0000",
        "updatedAt": "2020-12-14 07:17:59.564112 +0000 +0000"
    }]
}

Responds to GET requests to /partner/v1/teams and returns a list of teams associated with the partner.

Kardia Mobile Users

Create User

Example Request

curl https://api.kardia.com/v1/users \
  -u YOUR-API-KEY: \
  -d email=joe@example.com \
  -d password=5up3R53Cur3 \
  -d countryCode=us \
  -d patientId=wNSEDeLOEPQE5rznkJmwbnjpxfdst93i

Example Response

{
  "requestId": "q1ATFmh7OShS2Dmd1cVAb6boqkrp7gif",
}

The API allows developers to create Kardia Mobile users that will be automatically connected to the Kardia Pro account. To create a Kardia Mobile user, send a POST request to /v1/users.

Arguments

Name Type Required Description
email string Yes The Kardia Mobile user's email address.
password string Yes The Kardia Mobile user's password
countryCode string Yes The ISO 3166 Alpha-2 country code
patientId string Yes The patient's unique identifier.

Webhooks

Webhooks are a system of automated notifications indicating that an event has occurred for your team. Rather than requiring you to pull information via our API, webhooks push information to your destination when important events occur. Webhooks notify the following events.

The Kardia server will send a post to your set url with a json body:

New Recording

{
  "eventType":   "newRecording",
  "recordingId": "123recordingIDTest",
  "patientId":   "456patientID"
}

QT Analysis Request

{
  "eventType":   "qtAnalysis",
  "recordingId": "123recordingIDTest"
}

QT Result Notification

{
  "eventType":   "qtResultNotification",
  "recordingId": "123recordingIDTest",
  "patientId":   "456patientID"
}

Vendor Specific Interpretation

{
  "eventType":   "newVendorSpecificInterpretation",
  "recordingId": "123recordingIDTest",
  "patientId":   "456patientID",
  "remarks":     "notes here",
  "timestamp":   "1617927783",
}

Patient Connection/Disconnection

{
  "eventType":            "participantConnected", // OR "participantDisconnected"
  "patientId":            "456patientID",
  "customParticipantId":  "customPatientMRN"
}

Single Recording Updated

{
  "eventType":      "activityUpdate",
  "recordingId":    "123recordingIDTest",
  "fieldsUpdated":  ["note", "tags_data"] // only these 2 options currently supported in webhook
}

Symptoms Updated in KRx App

{
  "eventType":   "symptomsUpdate",
  "recordingId": "123recordingIDTest",
  "teamID":      "567testTeamIdForDevs",
  "teamName":    "Practice Name I23",

}

Activities Updated in KRx App

{
  "eventType":   "activityUpdate",
  "recordingId": "123recordingIDTest",
  "teamID":      "567testTeamIdForDevs",
  "teamName":    "Practice Name I23",

}

Recording Added to Inbox

{
  "eventType":  "recordingInboxUpdated",
  "memberId":   "doctorMemberId", // id of KardiaPro user who's inbox was updated
  "action":     "trigger"
}

Set callback URL

Example Request

curl -X PUT https://api.kardia.com/v1/callback \
  -u YOUR-API-KEY: \
  -d url=https://www.example.com/webhooks

Example Response

{
  "url": "https://www.example.com/webhooks",
}

Lets you assign a callback URL for POST notifications. Make sure to assign a publicly accessible URL for your callback service. Responds to PUT requests to /v1/callback.

Get callback URL

Example Request

curl https://api.kardia.com/v1/callback \
  -u YOUR-API-KEY:

Example Response

{
  "url": "https://www.example.com/webhooks",
}

Callback JSON examples

Participant connected to a team

{
    "eventType": "participantConnected",
    "customParticipantId": "mrn123",
    "patientId": "patientid123"
}

Participant disconnected from a team

{
    "eventType": "participantDisconnected",
    "customParticipantId": "mrn123",
    "patientId": "patientid123"
}

New recording made by patient

{
    "eventType":   "newRecording",
    "recordingId": "recordingid123",
    "patientId": "patientid123"
}

Stack updated based on an automatic "trigger" or "manual" action

{
    "eventType": "recordingInboxUpdated",
    "memberId": "memberid123",
    "action": "trigger"
}

This section provides examples of JSON request bodies that are sent to the callback URL from Alivecor backend when the described events take place

Set QT Analysis Callback URL

Example Request

curl -X PUT https://api.kardia.com/v1/qtCallback \
  -u YOUR-API-KEY: \
  -d url=https://www.example.com/webhooks

Example Response

{
  "url": "https://www.example.com/webhooks",
}

Lets you assign a callback URL for POST notifications. Make sure to assign a publicly accessible URL for your callback service. Responds to PUT requests to /v1/qtCallback.

Get QT Analysis Callback URL

Example Request

curl https://api.kardia.com/v1/qtCallback \
  -u YOUR-API-KEY:

Example Response

{
  "url": "https://www.example.com/webhooks",
}

QT callback JSON example

QT analysis complete

{
    "eventType": "qtAnalysis",
    "recordingId": "recordingID123",
}

This section provides examples of JSON request bodies that are sent to the QT callback URL from Alivecor backend when the described events take place

Get callback logs

Example Request

curl https://api.kardia.com/v1/logs \
  -u YOUR-API-KEY:

Example Response

{
    "totalCount": 2,
    "logs": [
        {
            "statusCode": "500",
            "eventType": "newRecording",
            "createdAt": "2019-05-13T00:00:01Z",
            "error": "Failed to send new recording to callback url"
        },
        {
            "statusCode": "200",
            "eventType": "newRecording",
            "createdAt": "2019-05-13T00:00:00Z"
        }
    ],
    "pageInfo": {
        "startCursor": "Y3Vyc29yMjAxOS0wNS0xM1QwMDowMDowMVo=",
        "endCursor": "Y3Vyc29yMjAxOS0wNS0xM1QwMDowMDowMFo=",
        "hasNextPage": false
    }
}

Returns a paged list of logs. Send a GET request to /v1/logs.

Querystring parameters

limit A limit on the number of objects to be returned. Limit can range between 1 and 500, and the default is 100.

start The cursor used to return logs after the startCursor or endCursor cursor, and returning at most limit logs..

Errors

Error objects provide additional information about problems encountered while performing an operation. Error objects are returned as an array keyed by errors in the top level of a JSON document.

An error object MAY have the following members:

Name Type Description
id string A unique identifier for this particular occurrence of the problem
status string The HTTP status code applicable to this problem, expressed as a string value.
code string An application-specific error code, expressed as a string value.
title string A short, human-readable summary of the problem.
detail string A human-readable explanation specific to this occurrence of the problem.
Error Code Meaning
400 Bad Request -- Your request is invalid.
401 Unauthorized -- Your API key is wrong.
404 Not Found -- The specified resource could not be found.
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.