Skip to main content

Receive a patient's share request, as the HIU

Hosted by the HIU, not by ABDM. The HIE-CM calls this endpoint at the callback URL registered for your bridge, so the path below is relative to that URL.

POST/api/v3/patient-record/share

This is a callback API for the HIU. The HIE-CM provides the record share request the PHR app raised: the patient's profile, the number of records and the care contexts to share, and a transactionId for the transfer. Reply by calling POST /api/hiecm/patient-record/v3/on-share with the data push URL and the encryption key, carrying this transactionId and this request's REQUEST-ID.

Authorizations

Authorizationbearer tokenRequired

JWT access token issued by the ABDM session API after successful validation of client id and secret.

Headers

request-idstringRequired

Random UUID, a v4 style guid, unique per callback.

timestampstringRequired

ISO 8601 timestamp of when the callback was sent.

x-hiu-idstringRequired

Identifier of the health information user to which the request was intended.

Body

metaDataobjectRequired

The HIU and the counter the QR code named.

metaData.hiuIdstringRequired

The HIU's identifier, read from the QR code.

metaData.counterIdstringRequired

The counter at the HIU, read from the QR code.

transactionIdstringRequired

The transfer's identifier, assigned by the HIE-CM. Carry it in on-share and in notify.

profileobjectRequired

The essential patient details, including ABHA number, ABHA address and the patient's contact address, used for initiating the record share process.

profile.patientobjectRequired
profile.patient.abhaNumberstringnull

The 14 digit ABHA number, or null when the patient has an address only.

profile.patient.abhaAddressstringRequired

The patient's ABHA address.

profile.patient.namestringRequired
profile.patient.genderstringRequired

M, F or O.

profile.patient.dayOfBirthstring
profile.patient.monthOfBirthstring
profile.patient.yearOfBirthstringRequired
profile.patient.addressobjectRequired
profile.patient.address.linestring
profile.patient.address.districtstring
profile.patient.address.statestring
profile.patient.address.pincodestring
profile.patient.phoneNumberstringRequired
sharedRecordCountintegerRequired

Number of records that are to be shared to the HIU.

consentobjectRequired

The care contexts to share, the permission specifying how the records can be accessed, and the dataEraseAt date until which the data remains accessible.

consent.careContextsobject[]Required
consent.careContexts.patientReferencestringRequired

The patient reference the care context was linked under.

consent.careContexts.careContextReferencestringRequired
consent.permissionobjectRequired
consent.permission.accessModestringRequired

How the HIU may use the records.

One of VIEW

consent.dataEraseAtstringRequired

Until when the data remains accessible to the HIU.

Responses

202

Accepted. Answer with the on-share call.

The callback never arrives

Where this fits​

You produce this callback by calling Share a patient's records with the HIU whose QR code was scanned..