UKRDC API (5.5.0)

Download OpenAPI specification:Download

Early test version of an updated, simpler UKRDC API

Admin

Datahealth Multiple Ukrdcids

Retreive list of patients with multiple UKRDC IDs

Authorizations:
OktaJWTBearer
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Datahealth Multiple Ukrdcids Last Run

Retreive the datetime the multiple_ukrdcid table was fully refreshed

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "lastRunTime": "2019-08-24T14:15:22Z"
}

Record Workitem Counts

Retreive a list of all master records with open work items, and the number of work items on each. Most useful when sorted by descending work item count, to identify records most in need of work item resolution.

Authorizations:
OktaJWTBearer
query Parameters
sort_by
any (WorkItemGroupSorterEnum)
Enum: "work_item_count" "master_record.id" "master_record.last_updated"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Full Workitem History

Retreive basic statistics about recent records

Authorizations:
OktaJWTBearer
query Parameters
since
string <date> (Since)
until
string <date> (Until)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Full Errors History

Retreive basic statistics about recent records

Authorizations:
OktaJWTBearer
query Parameters
since
string <date> (Since)
until
string <date> (Until)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Admin Counts

Retreive basic counts across the UKRDC

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "openWorkitems": 0,
  • "distinctPatients": 0,
  • "patientsReceivingErrors": 0
}

Admin/Data Health

Datahealth Multiple Ukrdcids

Retreive list of patients with multiple UKRDC IDs

Authorizations:
OktaJWTBearer
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Datahealth Multiple Ukrdcids Last Run

Retreive the datetime the multiple_ukrdcid table was fully refreshed

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "lastRunTime": "2019-08-24T14:15:22Z"
}

Record Workitem Counts

Retreive a list of all master records with open work items, and the number of work items on each. Most useful when sorted by descending work item count, to identify records most in need of work item resolution.

Authorizations:
OktaJWTBearer
query Parameters
sort_by
any (WorkItemGroupSorterEnum)
Enum: "work_item_count" "master_record.id" "master_record.last_updated"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Dashboard

Dashboard

Retreive basic statistics about recent records

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "messages": [
    ],
  • "warnings": [
    ]
}

System Info

System Info

Retreive basic system info

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "githubSha": "bfcb72756c116fda615e01650e2cd4f7bbb9b323",
  • "githubRef": "refs/tags/v5.5.0",
  • "deploymentEnv": "development",
  • "version": "5.5.0"
}

System User

Retreive basic user info

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "permissions": [
    ],
  • "email": "string"
}

System User Preferences

Retreive user preferences

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
{
  • "placeholder": false
}

Update System User Preferences

Update user preferences

Authorizations:
OktaJWTBearer
Request Body schema: application/json
placeholder
boolean (Placeholder)

Placeholder preference, does not do anything

Responses

Request samples

Content type
application/json
{
  • "placeholder": true
}

Response samples

Content type
application/json
{
  • "placeholder": false
}

Patient Index Operations

Empi Merge

Merge a pair of MasterRecords

Authorizations:
OktaJWTBearer
Request Body schema: application/json
superseding
required
integer (Superseding master-record ID)
superseded
required
integer (Superseded master-record ID)

Responses

Request samples

Content type
application/json
{
  • "superseding": 0,
  • "superseded": 0
}

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Mirth

Mirth Channel Map

Retrieve a basic channel ID-name map, available to all user permission levels. Used for things like message filtering.

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Mirth Channels

Retrieve a list of Mirth channels

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Mirth Groups

Retrieve a list of Mirth channel groups

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Mirth Channel

Get details and statistics about a specific Mirth channel

Authorizations:
OktaJWTBearer
path Parameters
channel_id
required
string (Channel Id)

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "name": "string",
  • "description": "string",
  • "revision": "string",
  • "statistics": {
    }
}

Mirth Channel Messages

Retreive a list a messages from a specific Mirth channel

Authorizations:
OktaJWTBearer
path Parameters
channel_id
required
string (Channel Id)
query Parameters
page
integer (Page)
Default: 0
size
integer (Size)
Default: 20

Responses

Response samples

Content type
application/json
{
  • "page": 0,
  • "size": 0,
  • "items": [
    ]
}

Mirth Channel Message

Retreive a specific message from a specific Mirth channel

Authorizations:
OktaJWTBearer
path Parameters
channel_id
required
string (Channel Id)
message_id
required
string (Message Id)

Responses

Response samples

Content type
application/json
{
  • "messageId": 0,
  • "serverId": "10d2345a-e43d-463d-830e-4f5b19b60d41",
  • "channelId": "5f6d08bc-455a-4532-98b8-19e2cee51160",
  • "processed": true,
  • "receivedDate": "2019-08-24T14:15:22Z",
  • "connectorMessages": {
    }
}

Search

Search Masterrecords Deprecated

Search the EMPI for a particular master record

Authorizations:
OktaJWTBearer
query Parameters
pid
Array of strings (Pid)
Default: []

Patient PID

mrn_number
Array of strings (Mrn Number)
Default: []

Patient MRN number, e.g. NHS, CHI or HSC number

ukrdc_number
Array of strings (Ukrdc Number)
Default: []

UKRDC record number

full_name
Array of strings (Full Name)
Default: []

Patient full name

dob
Array of strings (Dob)
Default: []

Patient date of birth

facility
Array of strings (Facility)
Default: []

Facility code

search
Array of strings (Search)
Default: []

Free-text search query

number_type
Array of strings (Number Type)
Default: []

Number types to return, e.g. UKRDC, NHS, CHI, HSC

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Search Records

Search the UKRDC for a particular patient record

Authorizations:
OktaJWTBearer
query Parameters
pid
Array of strings (Pid)
Default: []

Patient PID

mrn_number
Array of strings (Mrn Number)
Default: []

Patient MRN number, e.g. NHS, CHI or HSC number

ukrdc_number
Array of strings (Ukrdc Number)
Default: []

UKRDC record number

full_name
Array of strings (Full Name)
Default: []

Patient full name

dob
Array of strings (Dob)
Default: []

Patient date of birth

facility
Array of strings (Facility)
Default: []

Facility code

extract
Array of strings (Extract)
Default: []

Extract code

search
Array of strings (Search)
Default: []

Free-text search query

include_migrated
boolean (Include Migrated)
Default: false

Include migrated records in search results

include_memberships
boolean (Include Memberships)
Default: false

Include membership-only records in search results

include_informational
boolean (Include Informational)
Default: false

Include informational-only records in search results

include_survey
boolean (Include Survey)
Default: false

Include survey-only records in search results

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Records

Patient Export Pv

Export a specific patient's data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pv Tests

Export a specific patient's test data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pv Docs

Export a specific patient's documents data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Radar

Export a specific patient's data to RaDaR

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pkb

Export a specific patient's data to PKB.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Mrc

Export a specific patient's data to PKB.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Update Demographics

Update the demographic data of a given patient record

Args: demographics (DemographicUpdateSchema): [description] patient_record (PatientRecord, optional): [description]. Defaults to Depends(_get_patientrecord). mirth (MirthAPI, optional): [description]. Defaults to Depends(get_mirth). redis (Redis, optional): [description]. Defaults to Depends(get_redis). audit (Auditer, optional): [description]. Defaults to Depends(get_auditer).

Returns: [type]: [description]

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
Request Body schema: application/json
object (NameSchema)

Patient name

birthTime
string <date-time> (Birthtime)
gender
string (Gender)
Enum: "1" "2" "9"
object (AddressSchema)

Patient address

Responses

Request samples

Content type
application/json
{
  • "name": {
    },
  • "birthTime": "2019-08-24T14:15:22Z",
  • "gender": "1",
  • "address": {
    }
}

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Patient Results

Retreive a specific patient's lab orders

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
service_id
Array of strings (Service Id)
Default: []
order_id
Array of strings (Order Id)
Default: []
since
string <date-time> (Since)
until
string <date-time> (Until)
sort_by
any (ResultItemEnum)
Enum: "observation_time" "entered_on"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Result

Retreive a particular lab result

Authorizations:
OktaJWTBearer
path Parameters
resultitem_id
required
string (Resultitem Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "pid": "string",
  • "orderId": "string",
  • "serviceId": "string",
  • "serviceIdDescription": "string",
  • "value": "string",
  • "valueUnits": "string",
  • "resultType": "string",
  • "prePost": "string",
  • "observationTime": "2019-08-24T14:15:22Z"
}

Patient Result Delete

Mark a particular lab result for deletion

Authorizations:
OktaJWTBearer
path Parameters
resultitem_id
required
string (Resultitem Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
null

Patient Laborders

Retreive a specific patient's lab orders

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Laborder

Retreive a particular lab order

Authorizations:
OktaJWTBearer
path Parameters
order_id
required
string (Order Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "pid": "string",
  • "enteredAtDescription": "string",
  • "enteredAt": "string",
  • "specimenCollectedTime": "2019-08-24T14:15:22Z",
  • "resultItems": [
    ]
}

Patient Laborder Delete

Mark a particular lab order for deletion

Authorizations:
OktaJWTBearer
path Parameters
order_id
required
string (Order Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
null

Patient Documents

Retreive a specific patient's documents

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (DocumentEnum)
Enum: "documenttime" "updatedon"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Document

Retreive a specific patient's document information

Authorizations:
OktaJWTBearer
path Parameters
document_id
required
string (Document Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "pid": "string",
  • "documenttime": "2019-08-24T14:15:22Z",
  • "documentname": "string",
  • "filetype": "string",
  • "filename": "string",
  • "enteredbydesc": "string",
  • "enteredatcode": "string",
  • "idx": 0,
  • "notetext": "string",
  • "documenttypecode": "string",
  • "documenttypecodestd": "string",
  • "documenttypedesc": "string",
  • "cliniciancode": "string",
  • "cliniciancodestd": "string",
  • "cliniciandesc": "string",
  • "statuscode": "string",
  • "statuscodestd": "string",
  • "statusdesc": "string",
  • "enteredbycode": "string",
  • "enteredbycodestd": "string",
  • "enteredatcodestd": "string",
  • "enteredatdesc": "string",
  • "documenturl": "string",
  • "updatedon": "2019-08-24T14:15:22Z",
  • "actioncode": "string",
  • "externalid": "string",
  • "updateDate": "2019-08-24T14:15:22Z",
  • "creationDate": "2019-08-24T14:15:22Z",
  • "repositoryUpdateDate": "2019-08-24T14:15:22Z"
}

Patient Document Download

Retreive a specific patient's document file

Authorizations:
OktaJWTBearer
path Parameters
document_id
required
string (Document Id)
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
null

Patient Diagnosis

Retreive a specific patient's diagnoses

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Renal Diagnosis

Retreive a specific patient's renal diagnoses

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Cause Of Death

Retreive a specific patient's cause of death

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient

Retreive a specific patient record

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "pid": "string",
  • "sendingfacility": "string",
  • "sendingextract": "PV",
  • "localpatientid": "string",
  • "ukrdcid": "string",
  • "pvdata": {
    },
  • "programMemberships": [ ],
  • "patient": {
    },
  • "repositoryCreationDate": "2019-08-24T14:15:22Z",
  • "repositoryUpdateDate": "2019-08-24T14:15:22Z",
  • "masterId": 0
}

Patient Audit

Retreive a page of audit events related to a particular master record.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
resource
any (Resource)
Enum: "PATIENT_RECORD" "UKRDCID" "MEDICATIONS" "TREATMENTS" "SURVEYS" "DOCUMENTS" "DOCUMENT" "OBSERVATIONS" "DIALYSISSESSIONS" "LABORDERS" "LABORDER" "RESULTITEMS" "RESULTITEM" "TRANSPLANTS" "DIAGNOSES" "RENALDIAGNOSES" "CAUSEOFDEATH" "MASTER_RECORD" "MESSAGES" "STATISTICS" "MEMBERSHIP" "PERSON" "MESSAGE" "WORKITEM" "FACILITY"

An enumeration.

operation
any (AuditOperation)
Enum: "CREATE" "UPDATE" "DELETE" "READ" "EXPORT_PV" "EXPORT_PV_TESTS" "EXPORT_PV_DOCS" "EXPORT_RADAR" "EXPORT_PKB" "EXPORT_MRC" "READ_SOURCE"

An enumeration.

since
string <date-time> (Since)
until
string <date-time> (Until)
sort_by
any (AccessEventAuditEventEnum)
Enum: "id" "time"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Messages

Retreive a list of messages related to a particular patient record. By default returns message created within the last 365 days.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
since
string <date-time> (Since)
until
string <date-time> (Until)
status
Array of strings (Status)
channel
Array of strings (Channel)
sort_by
any (MessageEnum)
Enum: "id" "received" "ni"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Record Latest Message

Retreive a minimal representation of the latest file received for the patient, if received within the last year.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "received": "2019-08-24T14:15:22Z",
  • "msgStatus": "string",
  • "ni": "string",
  • "filename": "string",
  • "facility": "string"
}

Patient Delete

Delete a specific patient record and all its associated data

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
Request Body schema: application/json
hash
string (Hash)

Hash of the record to delete

Responses

Request samples

Content type
application/json
{
  • "hash": "string"
}

Response samples

Content type
application/json
null

Patient Medications

Retreive a specific patient's medications

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (MedicationEnum)
Enum: "fromtime" "totime"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Treatments

Retreive a specific patient's treatments

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (TreatmentEnum)
Enum: "fromtime" "totime"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Transplants

Retreive a specific patient's transplant procedures

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (TransplantEnum)
Enum: "proceduretime" "creation_date"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Surveys

Retreive a specific patient's surveys

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (SurveyEnum)
Enum: "surveytime" "updatedon"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Observations

Retreive a specific patient's lab orders

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
code
Array of strings (Code)
Default: []
sort_by
any (ObservationEnum)
Enum: "observation_time" "updated_on"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Dialysis Sessions

Retreive a specific patient's lab orders

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
query Parameters
sort_by
any (DialysisSessionEnum)
Enum: "proceduretime" "creation_date"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Patient Observation Codes

Retreive a list of observation codes available for a specific patient

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
[
  • "string"
]

Patient Result Services

Retreive a list of resultitem services available for a specific patient

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Patient Records/Export

Patient Export Pv

Export a specific patient's data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pv Tests

Export a specific patient's test data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pv Docs

Export a specific patient's documents data to PV

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Radar

Export a specific patient's data to RaDaR

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Pkb

Export a specific patient's data to PKB.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Export Mrc

Export a specific patient's data to PKB.

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "numberOfMessages": 0
}

Patient Records/Update

Patient Update Demographics

Update the demographic data of a given patient record

Args: demographics (DemographicUpdateSchema): [description] patient_record (PatientRecord, optional): [description]. Defaults to Depends(_get_patientrecord). mirth (MirthAPI, optional): [description]. Defaults to Depends(get_mirth). redis (Redis, optional): [description]. Defaults to Depends(get_redis). audit (Auditer, optional): [description]. Defaults to Depends(get_auditer).

Returns: [type]: [description]

Authorizations:
OktaJWTBearer
path Parameters
pid
required
string (Pid)
Request Body schema: application/json
object (NameSchema)

Patient name

birthTime
string <date-time> (Birthtime)
gender
string (Gender)
Enum: "1" "2" "9"
object (AddressSchema)

Patient address

Responses

Request samples

Content type
application/json
{
  • "name": {
    },
  • "birthTime": "2019-08-24T14:15:22Z",
  • "gender": "1",
  • "address": {
    }
}

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

UKRDC Record Group

Ukrdcid Records

Retreive patient records related to a specific patient record

Authorizations:
OktaJWTBearer
path Parameters
ukrdcid
required
string (Ukrdcid)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Ukrdcid Memberships Create Pkb

Create a new membership for a master record.

Authorizations:
OktaJWTBearer
path Parameters
ukrdcid
required
string (Ukrdcid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Ukrdcid Memberships Create Mrc

Authorizations:
OktaJWTBearer
path Parameters
ukrdcid
required
string (Ukrdcid)

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Facilities

Facility Stats Demographics

Retreive demographic statistics for a given facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "gender": {
    },
  • "ethnicGroup": {
    },
  • "age": {
    },
  • "metadata": {
    }
}

Facility Stats Krt

Retreive KRT statistics for a given facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "all": {
    },
  • "units": {
    }
}

Facility Reports Cc001

Custom Cohort Report 001: No treatment or programme membership to explain presence of record in the UKRDC. Excludes patients with a known date of death prior to 5 years ago from the time of query.

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Facility Reports Pm001

Program Membership Report 001: Patients with no active PKB membership record

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Facility List

Retreive a list of on-record facilities

Authorizations:
OktaJWTBearer
query Parameters
include_inactive
boolean (Include Inactive)
Default: false
include_empty
boolean (Include Empty)
Default: false
sort_by
any (FacilitySorterEnum)
Enum: "id" "statistics.total_patients" "statistics.patients_receiving_message_error" "data_flow.pkb_out" "last_message_received_at"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Facility

Retreive information and current status of a particular facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "description": "string",
  • "lastMessageReceivedAt": "2019-08-24T14:15:22Z",
  • "statistics": {
    },
  • "dataFlow": {
    }
}

Facility Patients Latest Errors

Retreive time-series new error counts for the last year for a particular facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
channel
Array of strings (Channel)
sort_by
any (MessageEnum)
Enum: "id" "received" "ni"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Facility Errrors History

Retreive time-series new error counts for the last year for a particular facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
since
string <date> (Since)
until
string <date> (Until)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Facility Extracts

Retreive extract counts for a particular facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "ukrdc": 0,
  • "pv": 0,
  • "radar": 0,
  • "survey": 0,
  • "pvmig": 0,
  • "hsmig": 0,
  • "ukrr": 0
}

Facilities/Stats

Facility Stats Demographics

Retreive demographic statistics for a given facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "gender": {
    },
  • "ethnicGroup": {
    },
  • "age": {
    },
  • "metadata": {
    }
}

Facility Stats Krt

Retreive KRT statistics for a given facility

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "all": {
    },
  • "units": {
    }
}

Facilities/Reports

Facility Reports Cc001

Custom Cohort Report 001: No treatment or programme membership to explain presence of record in the UKRDC. Excludes patients with a known date of death prior to 5 years ago from the time of query.

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Facility Reports Pm001

Program Membership Report 001: Patients with no active PKB membership record

Authorizations:
OktaJWTBearer
path Parameters
code
required
string (Code)
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Codes

Code List

Retreive a list of internal codes

Authorizations:
OktaJWTBearer
query Parameters
coding_standard
Array of strings (Coding Standard)
search
string (Search)
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Code Details

Retreive a list of internal codes

Authorizations:
OktaJWTBearer
path Parameters
coding_standard
required
string (Coding Standard)
code
required
string (Code)

Responses

Response samples

Content type
application/json
{
  • "codingStandard": "string",
  • "code": "string",
  • "description": "string",
  • "objectType": "string",
  • "creationDate": "2019-08-24T14:15:22Z",
  • "updateDate": "2019-08-24T14:15:22Z",
  • "units": "string",
  • "pkbReferenceRange": "string",
  • "pkbComment": "string",
  • "mapsTo": [
    ],
  • "mappedBy": [
    ]
}

Code Maps

Retreive a list of internal code maps

Authorizations:
OktaJWTBearer
query Parameters
source_coding_standard
Array of strings (Source Coding Standard)
destination_coding_standard
Array of strings (Destination Coding Standard)
source_code
string (Source Code)
destination_code
string (Destination Code)
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Code Exclusions

Retreive a list of internal code maps

Authorizations:
OktaJWTBearer
query Parameters
coding_standard
Array of strings (Coding Standard)
code
Array of strings (Code)
system
Array of strings (System)
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Coding Standards List

Retreive a list of internal codeing standards

Authorizations:
OktaJWTBearer

Responses

Response samples

Content type
application/json
[
  • "string"
]

Code List Export

Export a CSV of a list of internal codes

Authorizations:
OktaJWTBearer
query Parameters
coding_standard
Array of strings (Coding Standard)
search
string (Search)

Responses

Response samples

Content type
application/json
{
  • "detail": [
    ]
}

Code Maps Export

Export a CSV of a list of internal codes

Authorizations:
OktaJWTBearer
query Parameters
source_coding_standard
Array of strings (Source Coding Standard)
destination_coding_standard
Array of strings (Destination Coding Standard)
source_code
string (Source Code)
destination_code
string (Destination Code)

Responses

Response samples

Content type
application/json
{
  • "detail": [
    ]
}

Code Exclusions Export

Export a CSV of a list of internal codes

Authorizations:
OktaJWTBearer
query Parameters
coding_standard
Array of strings (Coding Standard)
code
Array of strings (Code)
system
Array of strings (System)

Responses

Response samples

Content type
application/json
{
  • "detail": [
    ]
}

Work Items

Workitem

Retreive a particular work item from the EMPI

Authorizations:
OktaJWTBearer
path Parameters
workitem_id
required
integer (Workitem Id)

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "type": 0,
  • "description": "string",
  • "status": 0,
  • "creationDate": "2019-08-24T14:15:22Z",
  • "lastUpdated": "2019-08-24T14:15:22Z",
  • "updatedBy": "string",
  • "attributes": {
    },
  • "updateDescription": "string",
  • "person": {
    },
  • "masterRecord": {
    },
  • "incoming": {
    },
  • "destination": {
    }
}

Workitem Update

Update a particular work item in the EMPI

Authorizations:
OktaJWTBearer
path Parameters
workitem_id
required
integer (Workitem Id)
Request Body schema: application/json
status
integer (Status)
comment
string (Comment) <= 100 characters

Responses

Request samples

Content type
application/json
{
  • "status": 0,
  • "comment": "string"
}

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Workitem Close

Update and close a particular work item

Authorizations:
OktaJWTBearer
path Parameters
workitem_id
required
integer (Workitem Id)
Request Body schema: application/json
comment
string (Comment) <= 100 characters

Responses

Request samples

Content type
application/json
{
  • "comment": "string"
}

Response samples

Content type
application/json
{
  • "status": "string",
  • "message": "string"
}

Workitem Collection

Retreive a list of other work items related to a particular work item

Authorizations:
OktaJWTBearer
path Parameters
workitem_id
required
integer (Workitem Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Workitem Messages

Retreive a list of other work items related to a particular work item

Authorizations:
OktaJWTBearer
path Parameters
workitem_id
required
integer (Workitem Id)
query Parameters
facility
string (Facility)
since
string <date-time> (Since)
until
string <date-time> (Until)
status
Array of strings (Status)
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Workitems

Retreive a list of open work items from the EMPI

Authorizations:
OktaJWTBearer
query Parameters
since
string <date-time> (Since)
until
string <date-time> (Until)
status
Array of integers (Status)
Default: [1]
facility
string (Facility)
sort_by
any (WorkItemEnum)
Enum: "id" "last_updated" "master_id" "person_id"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Master Records

Master Record

Retreive a particular master record from the EMPI

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "nationalid": "string",
  • "nationalidType": "string",
  • "lastUpdated": "2019-08-24T14:15:22Z",
  • "dateOfBirth": "2019-08-24",
  • "gender": "string",
  • "givenname": "string",
  • "surname": "string",
  • "status": 0,
  • "effectiveDate": "2019-08-24T14:15:22Z"
}

Master Record Latest Message

Retreive a minimal representation of the latest file received for the patient, if received within the last year.

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "received": "2019-08-24T14:15:22Z",
  • "msgStatus": "string",
  • "ni": "string",
  • "filename": "string",
  • "facility": "string"
}

Master Record Statistics

Retreive a particular master record from the EMPI

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
{
  • "workitems": 0,
  • "errors": 0,
  • "ukrdcids": 0
}

Master Record Linkrecords

Retreive a list of link records related to a particular master record

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Master Record Messages

Retreive a list of errors related to a particular master record. By default returns message created within the last 365 days.

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)
query Parameters
facility
string (Facility)
since
string <date-time> (Since)
until
string <date-time> (Until)
status
Array of strings (Status)
channel
Array of strings (Channel)
sort_by
any (MessageEnum)
Enum: "id" "received" "ni"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Master Record Workitems

Retreive a list of work items related to a particular master record.

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)
query Parameters
status
Array of integers (Status)
Default: [1]

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Master Record Persons

Retreive a list of person records related to a particular master record.

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Master Record Patientrecords

Retreive a list of patient records related to a particular master record.

Authorizations:
OktaJWTBearer
path Parameters
record_id
required
integer (Record Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Messages

Messages

Retreive a list of error messages, optionally filtered by NI, facility, or date. By default returns message created within the last 365 days.

Authorizations:
OktaJWTBearer
query Parameters
facility
string (Facility)
since
string <date-time> (Since)
until
string <date-time> (Until)
status
Array of strings (Status)
channel
Array of strings (Channel)
ni
Array of strings (Ni)
Default: []
sort_by
any (MessageEnum)
Enum: "id" "received" "ni"

An enumeration.

order_by
string (OrderBy)
Enum: "asc" "desc"

An enumeration.

page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Message

Retreive detailed information about a specific error message

Authorizations:
OktaJWTBearer
path Parameters
message_id
required
integer (Message Id)

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "received": "2019-08-24T14:15:22Z",
  • "msgStatus": "string",
  • "ni": "string",
  • "filename": "string",
  • "facility": "string",
  • "error": "string",
  • "status": "string",
  • "mirthMessageId": "string",
  • "mirthChannelId": "string",
  • "mirthChannel": "string"
}

Message Source

Retreive detailed information about a specific error message

Authorizations:
OktaJWTBearer
path Parameters
message_id
required
integer (Message Id)

Responses

Response samples

Content type
application/json
{
  • "content": "string",
  • "contentType": "string"
}

Message Workitems

Retreive WorkItems associated with a specific error message

Authorizations:
OktaJWTBearer
path Parameters
message_id
required
integer (Message Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Message Patientrecords

Retreive patient records associated with a specific error message

Authorizations:
OktaJWTBearer
path Parameters
message_id
required
integer (Message Id)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Background Tasks

Tasks

Return a list of all non-expired background tasks

Authorizations:
OktaJWTBearer
query Parameters
page
integer (Page) >= 1
Default: 1
size
integer (Size) ( 0 .. 50 ]
Default: 20

Responses

Response samples

Content type
application/json
{
  • "items": [
    ],
  • "total": 0,
  • "page": 1,
  • "size": 1,
  • "pages": 0
}

Task

Return a specific background task

Authorizations:
OktaJWTBearer
path Parameters
task_id
required
string <uuid> (Task Id)

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "name": "string",
  • "visibility": "public",
  • "owner": "string",
  • "status": "pending",
  • "error": "string",
  • "created": "2019-08-24T14:15:22Z",
  • "started": "2019-08-24T14:15:22Z",
  • "finished": "2019-08-24T14:15:22Z"
}