Skip to main content

Fetch all the consent request details of a patient

GET/api/hiecm/consent/v3/request

By invoking this API, users can retrieve a comprehensive list of all consent requests associated with a patient’s health information. This functionality is essential for maintaining transparency and ensuring that users have access to complete and up-to-date consent information. The API supports efficient tracking and management of consent requests, facilitating secure and compliant health information exchange within the healthcare ecosystem.

Authorizations

Authorizationbearer tokenRequired

The access token from POST /api/hiecm/gateway/v3/sessions, sent with a Bearer prefix.

Query parameters

limitintegerRequired

The number of items to be returned at a time

offsetinteger

The number of items to be skipped before starting to collect data

statusstring

Status of the consent

Headers

REQUEST-IDstringRequired

Unique UUID for track the end to end request transaction

TIMESTAMPstringRequired

Actual time of the request was initiated, ISO 8601 represents date and time by starting with the year, followed by the month, the day, the hour, the minutes, seconds and milliseconds

X-CM-IDstringRequired

Suffix of the consent manager to which the request was intended

X-AUTH-TOKENstringRequired

The user token the PHR service issued when the patient logged in.

Responses

200

OK

sizeinteger
limitinteger
offsetinteger
requestsobject[]
requests.requestIdstring
requests.purposeobject
requests.purpose.textstringRequired

One of Care ManagementBreak the GlassPublic HealthHealthcare PaymentDisease Specific Healthcare ResearchSelf Requested

requests.purpose.codestringRequired

One of CAREMGTBTGPUBHLTHHPAYMTDSRCHPATRQT

requests.purpose.refUristringRequired

The reference URL. Should be a valid URL

requests.patientobject
requests.patient.idstringRequired

The abha address of the patient

requests.hipobject

Identifier and name of the health information provider.

requests.hip.idstringRequired

The service ID of the health information provider. Allows alpha numeric character and special characters like [A-Z a-z 0-9]+[A-Z a-z 0-9 //_//-]*[A-Z a-z 0-9]$

requests.hip.namestringRequired

The name of the health information provider. Allows alpha numeric and special characters like _\-@,():/

requests.hip.typestring

The type of the health information provider. Allows alpha numeric and special characters like _\-@,. ":/

requests.hiuobject
requests.hiu.idstringRequired

The service ID of the health information user. Allows alpha numeric character and special characters like [A-Z a-z 0-9]+[A-Z a-z 0-9 //_//-]*[A-Z a-z 0-9]$

requests.hiu.namestringRequired

The name of the health information user. Allows alpha numeric and special characters like _\-@,():/

requests.hiu.typestring

The type of the health information user. Allows alpha numeric and special characters like _\-@,. ":/

requests.careContextsobject[]

List of care contexts linked at the HIP end for the identified patient.

requests.careContexts.patientReferencestringRequired

A patient identifier with which patient is registered in the facility/hospital

requests.careContexts.careContextReferencestringRequired

An identifier of patient's care context created in HIP. A care context is a group of patient's health data (Not the actual health data)

requests.requesterobject
requests.requester.namestringRequired

The name of the requester

requests.requester.identifierobjectRequired
requests.requester.identifier.valuestringRequired

The type of the identification. Allows alpha numeric character and special characters like _\-@,. ":/

requests.requester.identifier.typestringRequired

The identification value. Allows alpha numeric character and special characters like _\-@,. ":/

requests.requester.identifier.systemstringRequired

Allows alpha numeric character and special characters like _\-@,. ":/

requests.statusstring

One of REQUESTEDEXPIREDDENIEDGRANTEDREVOKED

requests.createdAtstring
requests.lastUpdatedstring
requests.hiTypestring[]
requests.permissionobject
requests.permission.accessModestringRequired

One of VIEWSTORESTREAMQUERY

requests.permission.dateRangeobjectRequired
requests.permission.dateRange.fromstringRequired

Should be UTC date time in ISO format

requests.permission.dateRange.tostringRequired

Should be UTC date time in ISO format

requests.permission.dataEraseAtstringRequired

The date at which the consent expire. Should be UTC date time in ISO format

requests.permission.frequencyobjectRequired
requests.permission.frequency.unitstringRequired

One of HOURDAYWEEKMONTHYEAR

requests.permission.frequency.valuenumberRequired

The frequency unit value. Should be be a integer

requests.permission.frequency.repeatsnumberRequired

Should be be a integer

400

Bad Request. The request could not be processed because it was malformed or failed validation - a missing mandatory field, a value in the wrong format, or a header that did not match the body.

Error codes for this module

errorobject

The error code and message, if any occurred.

error.codestringRequired

ABDM-1006 - Bad Request, invalid request Body. May be returned either bare or with a trailing ": " separator; match on the code itself and tolerate the separator.

error.messagestringRequired

Short description of the failure.

401

Unauthorized

Everything returns 401

codestring

900901 - Unauthorized. May be returned either bare or with a trailing ": " separator; match on the code itself and tolerate the separator.

messagestring
descriptionstring
404

Not Found

Error codes for this module

errorobject

The error code and message, if any occurred.

error.codestringRequired

ABDM-1001 - No data found. May be returned either bare (ABDM-1001) or with a trailing ": " separator (ABDM-1001: ); match on the code itself and tolerate the separator.

error.messagestringRequired
500

Internal Server Error

Error codes for this module

codestring

900900 - Unclassified Authentication Failure. May be returned either bare or with a trailing ": " separator; match on the code itself and tolerate the separator.

messagestring
descriptionstring
503

Service Unavailable

Error codes for this module

codestringRequired

ABDM-1024 - Dependent service unavailable. May be returned either bare (ABDM-1024) or with a trailing ": " separator (ABDM-1024: ); match on the code itself and tolerate the separator.

messagestringRequired