UNPKG

openapi-directory

Version:

Building & bundling https://github.com/APIs-guru/openapi-directory for easy use from JS

1 lines 118 kB
{"openapi":"3.0.0","servers":[{"description":"Sandbox","url":"https://dev.ndhm.gov.in/gateway"}],"info":{"contact":{"name":"National Health Authority","url":"https://ndhm.gov.in/"},"description":"Gateway is the hub that routes/orchestrates the interaction between consent managers and API bridges. There are 5 categories of APIs; discovery, link, consent flow, data flow and monitoring. To reflect the consumers of APIs, the above apis are also categorized under cm facing, hiu facing and hip facing \n","title":"Gateway","version":"0.5","x-apisguru-categories":["open_data"],"x-origin":[{"format":"openapi","url":"https://apisetu.gov.in/api_specification_v8/ndhm-gateway.yaml","version":"3.0"}],"x-providerName":"ndhm.gov.in","x-serviceName":"ndhm-gateway"},"tags":[{"name":"user auth"},{"name":"profile"},{"name":"discovery"},{"name":"link"},{"name":"consent flow"},{"name":"data flow"},{"name":"identification"},{"name":"monitoring"},{"name":"sessions"},{"name":"subscriptions"},{"name":"services"},{"name":"cm facing"},{"name":"hiu facing"},{"name":"hip facing"}],"paths":{"/v0.5/.well-known/openid-configuration":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenIdConfiguration"}},"application/xml":{"schema":{"$ref":"#/components/schemas/OpenIdConfiguration"}}},"description":"OK"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid consent request id\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get openid configuration","tags":["sessions"]}},"/v0.5/care-contexts/discover":{"post":{"description":"Request for patient care context discover, made by CM for a specific HIP. It is expected that HIP will subsequently return either zero or one patient record with (potentially masked) associated care contexts\n 1. **At least one of the verified identifier matches**\n 2. **Name (fuzzy), gender matches**\n 3. **If YoB was given, age band(+-2) matches**\n 4. **If unverified identifiers were given, one of them matches**\n 5. **If more than one patient records would be found after aforementioned steps, then patient who matches most verified and unverified identifiers would be returned.**\n 6. **If there would be still more than one patients (after ranking) error would be returned**\n 7. **Intended HIP should be able to resolve and identify results returned in the subsequent link confirmation request via the specified transactionId**\n 8. **Intended HIP should store the discovery results with transactionId and care contexts discovered for subsequent link initiation**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientDiscoveryRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientDiscoveryRequest"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Empty verified identifiers.\n * Format mismatch of any of attributes.\n | type | Format/Allowed Values|\n | ------- | ---------------- |\n | gender | M/F/O/U |\n | MOBILE | valid mobile number with proper country code |\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Discover patient's accounts","tags":["discovery","cm facing"]}},"/v0.5/care-contexts/on-discover":{"post":{"description":"Result of patient care-context discovery request at HIP end. If a matching patient found with zero or more care contexts associated, it is specified as result attribute. If the prior discovery request, resulted in errors then it is specified in the error attribute. Reasons of errors can be \n 1. **more than one definitive match for the given request** \n 2. **no verified identifer was specified**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientDiscoveryResult"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientDiscoveryResult"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Format mismatch of any of attributes.\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Response to patient's account discovery request","tags":["discovery","cm facing"]}},"/v0.5/certs":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Certs"}},"application/xml":{"schema":{"$ref":"#/components/schemas/Certs"}}},"description":"OK"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid consent request id\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get certs for JWT verification","tags":["sessions"]}},"/v0.5/consent-requests/init":{"post":{"description":"Creates a consent request to get data about a patient by HIU user.","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ConsentRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent \n * Required attributes not mentioned\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Create consent request","tags":["consent flow","hiu facing"]}},"/v0.5/consent-requests/on-init":{"post":{"description":"Result of consent request creation for a patient. **consentRequest.id** represents the consentrequest id created by CM. The result must contain either **consentRequest** or the **error** caused. <br/>\n Reasons for error may be\n * Invalid references (e.g patient id, hiu id), purpose, hiTypes, ranges, persmission\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIU-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentRequestInitResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ConsentRequestInitResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Response to consent request","tags":["consent flow","cm facing"]}},"/v0.5/consent-requests/on-status":{"post":{"description":"Result of consent request done previously. Status of request can be GRANTED, DENIED, EXPIRED. If the request was GRANTED, then \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIU-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIUConsentRequestStatus"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIUConsentRequestStatus"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Result of consent request status","tags":["consent flow","cm facing"]}},"/v0.5/consent-requests/status":{"post":{"description":"Get status of consent request done previously","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentRequestStatusRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ConsentRequestStatusRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get consent request status","tags":["consent flow","hiu facing"]}},"/v0.5/consents/fetch":{"post":{"parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentFetchRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get consent artefact","tags":["consent flow","hiu facing"]}},"/v0.5/consents/hip/notify":{"post":{"description":"Notification of consents to health information providers consent request granted, consent revoked, consent expired. Only the GRANTED, REVOKED and EXPIRED status notifications will be sent to HIP.\n 1. If consent is granted, status=GRANTED, then consentDetail contains the consent artefact details and signature is available. \n 2. If consent is revoked, then status=REVOKED, and consentId specifes which consent artefact is revoked. \n 3. If the consent has expired, then status=EXPIRED, and consentId specifies which consent artefact has expired. Note, this is also responsibility of the HIP to keep track of consent expiry. Any data request on expired consent artefact must not be done. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIPConsentNotification"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIPConsentNotification"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid/Expired/Empty token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream services are down\n"}},"summary":"Consent notification","tags":["consent flow","cm facing"]}},"/v0.5/consents/hip/on-notify":{"post":{"description":"This API is called by HIP as acknowledgement to notification of consents, in cases of consent revocation and expiration. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIPConsentNotificationResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIPConsentNotificationResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid/Expired/Empty token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream services are down\n"}},"summary":"Consent notification","tags":["consent flow","hip facing"]}},"/v0.5/consents/hiu/notify":{"post":{"description":"Health information user will get notified about the consent request granted or denied, consent revoked, consent expired. \n1. For consent request grant, status=GRANTED, consentRequestId=<consent-request-id>, and consentArtefacts is an array of generated consent artefact Ids.\n2. For consent request expiry, status=EXPIRED, consentRequestId=<consent-request-id>\n3. For consent request denied, status=DENIED, consentRequestId=<consent-request-id>\n4. For consent revocation, status=REVOKED, consentArtefacts is an array of revoked consent artefact ids\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIU-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIUConsentNotificationEvent"}}},"required":true},"responses":{"202":{"description":"Request Accepted."},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid/Expired/Empty token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream services are down\n"}},"summary":"Consent notification","tags":["consent flow","cm facing"]}},"/v0.5/consents/hiu/on-notify":{"post":{"description":"This API is called by HIU as acknowledgement to consent notifications, specifically for cases when consent is REVOKED or EXPIRED.\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIUConsentNotificationResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted."},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid/Expired/Empty token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream services are down\n"}},"summary":"Consent notification","tags":["consent flow","hiu facing"]}},"/v0.5/consents/on-fetch":{"post":{"description":"Must contain either consentDetail or error. Possible reason of errors are \n1. consentId passed through /fetch is invalid\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIU-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentArtefactResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ConsentArtefactResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid data sent\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Result of fetch request for a consent artefact","tags":["consent flow","cm facing"]}},"/v0.5/health-information/cm/on-request":{"post":{"description":"Callback API for acknowledgement of Health information request of HIU. CM calls this API when it has validated the Health Information request given the consent id. Either the **hiRequest** or **error** would need to be specified. If the health info request was valid, then the ***hiRequest.transactionId*** specifies the transaction context against which HIP would send over the data. Possible cases of errors are\n 1. **Invalid consent artefact id**\n 2. **Consent has expired**\n 3. **Date ranges are invalid**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIU-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIUHealthInformationRequestResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIUHealthInformationRequestResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Bad request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Token is invalid or Link has expired\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Health information data request","tags":["data flow","cm facing"]}},"/v0.5/health-information/cm/request":{"post":{"description":"Request for Health information against a consent id. CM would generate a transactionId against each consent and pass it as trnasaction context / correlation id to the HIP and also return the same to HIU via /on-request. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Bad request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Token is invalid or Link has expired\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Health information data request","tags":["data flow","hiu facing"]}},"/v0.5/health-information/hip/on-request":{"post":{"description":"API called by HIP to acknowledge Health information request receipt. Either the **hiRequest** or **error** must be specified. **hiRequest** element returns the same transactionId as before with a status indicating that the request is acknowledged. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIPHealthInformationRequestAcknowledgement"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIPHealthInformationRequestAcknowledgement"}}},"required":true},"responses":{"202":{"description":"Request accepted."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Bad request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Token is invalid or Link has expired\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Health information data request","tags":["data flow","hip facing"]}},"/v0.5/health-information/hip/request":{"post":{"description":"API called by CM to request Health information from HIP against a validated consent artefact. The transactionId is the correlation id that HIP should use use when pushing data to the **dataPushUrl**. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HIPHIRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HIPHIRequest"}}},"required":true},"responses":{"202":{"description":"Request accepted."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Bad request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Token is invalid or Link has expired\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Health information data request","tags":["data flow","cm facing"]}},"/v0.5/health-information/notify":{"post":{"description":"API called by HIU and HIP during data-transfer. \n1. HIP on transfer of data would send **sessionStatus** - one of [TRANSFERRED, FAILED]\n2. HIP would also send **hiStatus** for each *careContextReference* - on of [DELIVERED, ERRORED]\n3. HIU on receipt of data would send **sessionStatus** - one of [TRANSFERRED, FAILED]. For example, FAILED when if data was not sent or if invalid data was sent\n4. HIU would also send **hiStatus** for each *careContextReference* - one of [OK, ERRORED] \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthInformationNotification"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HealthInformationNotification"}}},"required":true},"responses":{"204":{"description":"Notification is Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid Request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Expired/Invalid token.\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Notifications corresponding to events during data flow","tags":["data flow","hip facing","hiu facing"]}},"/v0.5/heartbeat":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HeartbeatResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/HeartbeatResponse"}}},"description":"OK"}},"summary":"Get consent request status","tags":["monitoring"]}},"/v0.5/hi-services/{service-id}":{"get":{"description":"This API is meant for displaying the bridge service details by the serviceId provided .\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/service-id"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceProfileResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ServiceProfileResponse"}}},"description":"service details fetched successfully"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Service doesn't exist."},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get bridge service details/profile by the serviceId provided.","tags":["services"]}},"/v0.5/links/link/add-contexts":{"post":{"description":"API to submit care-context to CM for HIP initiated linking. The API must accompany the \"accessToken\" fetched in the users/auth process. \n 1. subsequent usage for accessToken may be invalid if it was meant for one-time usage or if it expired\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientCareContextLinkRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientCareContextLinkRequest"}}},"required":true},"responses":{"202":{"description":"accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * required information not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"API for HIP initiated care-context linking for patient","tags":["link","hip facing"]}},"/v0.5/links/link/confirm":{"post":{"description":"API to submit the token that was sent by HIP during the link request. \n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkConfirmationRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/LinkConfirmationRequest"}}},"required":true},"responses":{"202":{"description":"accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Token is not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Token submission by Consent Manager for link confirmation","tags":["link","cm facing"]}},"/v0.5/links/link/init":{"post":{"description":"Request from CM to links care contexts associated with only one patient\n 1. **Validate account reference number and care context reference number**\n 2. **Validate transactionId in the request with discovery request entry to check whether there was a discovery\n and were these care contexts discovered or not for a given patient**\n 3. **Before eventual link confirmation, HIP needs to authenticate the request with the patient(eg: OTP verification)**\n 4. **HIP should communicate the mode of authentication of a successful request to Consent Manager**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientLinkReferenceRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientLinkReferenceRequest"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Consent manager user id is not provided\n * Patient reference number is not provided\n * Care context references are not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Link patient's care contexts","tags":["link","cm facing"]}},"/v0.5/links/link/on-add-contexts":{"post":{"description":"If the accessToken is valid for purpose of linking, and specified details provided, CM will send \"acknoweldgement.status\" as SUCCESS. If any error occcurred, for example invalid token, or other required patient or care-context information not provided, then \"error\" attribute conveys so. \n 1. **accessToken must be valid and must be for the purpose of linking**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientCareContextLinkResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientCareContextLinkResponse"}}},"required":true},"responses":{"202":{"description":"accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * resp not specified\n * atleast acknowledgement or error should be specified\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"callback API for HIP initiated patient linking /link/add-context","tags":["link","cm facing"]}},"/v0.5/links/link/on-confirm":{"post":{"description":"Returns a list of linked care contexts with patient reference number.\n 1. **Validated and linked account reference number**\n 2. **Validated that the token sent from Consent Manager is same as the one generated by HIP**\n 3. **Verified that same Consent Manager which made the link request is sending the token**\n 4. **Results of unmasked linked care contexts with patient reference number**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientLinkResult"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientLinkResult"}}},"required":true},"responses":{"202":{"description":"accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * resp not specified\n * atleast patient or error should be specified\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Token authenticated by HIP, indicating completion of linkage of care-contexts","tags":["link","hip facing"]}},"/v0.5/links/link/on-init":{"post":{"description":"Result of patient care-context link request from HIP end. This happens in context of previous discovery of patient found at HIP end, therefore the link requests ought to be in reference to the patient reference and care-context references previously returned by the HIP. The correlation of discovery and link request is maintained through the transactionId. HIP should have\n 1. **Validated transactionId in the request to check whether there was a discovery done previously, and the link request corresponds to returned patient care care context references**\n 2. **Before returning the response, HIP should have sent an authentication request to the patient(eg: OTP verification)**\n 3. **HIP should communicate the mode of authentication of a successful request**\n 4. **HIP subsequently should expect the token passed via /link/confirm against the link.referenceNumber passed in this call**\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n \nThe error section in the body, represents the potential errors that may have occurred. Possible reasons:\n 1. **Patient reference number is invalid**\n 2. **Care context reference numbers are invalid**\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientLinkReferenceResult"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientLinkReferenceResult"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Format mismatch of any of attributes.\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Response to patient's care context link request","tags":["link","hip facing"]}},"/v0.5/patients/find":{"post":{"description":"This API is meant for identify to patient given her consent-manager-user-id\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientIdentificationRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientIdentificationRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request, required attributes not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Identify a patient by her consent-manager user-id","tags":["identification","hiu facing"]}},"/v0.5/patients/on-find":{"post":{"description":"If a patient is found then patient.name contains the patients name. \nOtherwise, patient is not provided, and possibly error is raised for invalid requests\nNote in addition to the \"Authorization\" header, one of the following headers must be specified\n1. specify **X-HIU-ID** if the requester is HIU (identified from /find requester.id)\n2. specify **X-HIP-ID** if the requester is HIP (identified from /find requester.id)\n","parameters":[{"$ref":"#/components/parameters/authorization"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientIdentificationResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientIdentificationResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request, required attributes not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Identification result for a consent-manager user-id","tags":["identification","cm facing"]}},"/v0.5/patients/profile/on-share":{"post":{"description":"Result of patient share profile request at HIP end.\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShareProfileResult"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ShareProfileResult"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Format mismatch of any of attributes.\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Response to patient's share profile request","tags":["profile"]}},"/v0.5/patients/profile/share":{"post":{"description":"Request for sharing patient's profile details to HIP\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShareProfileRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ShareProfileRequest"}}},"required":true},"responses":{"202":{"description":"Request accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid Request\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Share patient profile details","tags":["profile","cm facing"]},"servers":[{"url":"https://your-hrp-server.com"}]},"/v0.5/patients/sms/notify":{"post":{"description":"API to send SMS notifications to patient with custom deeplink.\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientSMSNotifcationRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientSMSNotifcationRequest"}}},"required":true},"responses":{"202":{"description":"accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * required information not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"API for HIP to send SMS notifications to patients","tags":["hip facing","patient notification"]}},"/v0.5/patients/sms/on-notify":{"post":{"description":"If the SMS notification is successfully sent to patient then \"status\" will be \"ACKNOWLEDGED\" with no error.\nIf the SMS notification is failed then \"status\" will be \"ERRORED\" with error.\n","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-HIP-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientSMSNotifcationResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/PatientSMSNotifcationResponse"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request, required attributes not provided\n"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Unauthorized request\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Acknowledgment response for SMS notification sent to patient by HIP","tags":["cm facing","patient notification"]}},"/v0.5/sessions":{"post":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/SessionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/SessionResponse"}}},"description":"OK"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid client Id or secret.\n"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Invalid consent request id\n"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Causes:**\n * Downstream system(s) is down.\n * Unhandled exceptions.\n"}},"summary":"Get access token","tags":["sessions"]}},"/v0.5/subscription-requests/cm/init":{"post":{"description":"creates a request for subscription. The subscription categories can be for care-contexts linkages or availability of data against existing care-contexts. Note that the requester must have HIU role","parameters":[{"$ref":"#/components/parameters/authorization"},{"$ref":"#/components/parameters/X-CM-ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequest"}},"application/xml":{"schema":{"$ref":"#/components/schemas/SubscriptionRequest"}}},"required":true},"responses":{"202":{"description":"Request Accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}},"application/xml":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"**Cause