ΠΠ‘ΠΠ - ΠΏΡΠ±Π»ΡΡΠ½Π° Π΄ΠΎΠΊΡΠΌΠ΅Π½ΡΠ°ΡΡΡ
RC_REHAB_Verify approval+
Purpose
This WSΒ is designed to verify approval on entity, which aggregate other entities (episode_of_care, diagnostic_report, care_plan), OR forbidden group OR diagnoses group, OR on service_request including itβs permitted_resources OR on cancel for encounter and procedure OR patient.
Specification
Link | https://ehealthmedicaleventsapi.docs.apiary.io/#reference/approvals/verify-approval/verify-approval |
Resource | /api/patients/{{patiend_id}}/approvals/{{id}} |
Scope | approval:create |
Components | Approvals |
Microservices | API paragraph not found |
Protocol type | REST |
Request type | PATCH |
Sync/Async | Async |
Public/Private/Internal | Public |
Input parameters
Input parameter | Values | Type | Description | Example |
---|---|---|---|---|
patiend_id | String | mpi_id. Required | aff00bf6-68bf-4b49-b66d-f031d48922b3 | |
id | String | approval_id. Required | aff00bf6-68bf-4b49-b66d-f031d48922b3 |
Β
Logic
If approval has resource != (care_plan & terms_of_service = βINPATIENTβ for care_plan & granted_to.employees.legal_entity_id = care_plans.managing_organization):
If authentication_method_current.type = OTP
system checks verification code via otp_verification service PATCH /verifications/:phone_number/actions/complete
if verification code matches - change status to active
If not - return error
If authentication_method_current.type = offline or null OR approval with resource = care_plan where terms_of_service = βINPATIENTβ for care_plan & granted_to.employees.legal_entity_id = care_plans.managing_organization:
change status to active
Request structure
See on Apiary
Example:
Β
Authorize
Verify the validity of access token
Check user scope approval:create in order to perform this action
Β
Headers
ΠΠ°ΠΏΡΠΈΠΊΠ»Π°Π΄:
Content-Type:application/json
Authorization:Bearer d368a4b0-4a0e-457a-b267-32359fa6288f
HTTP status codes
HTTP status code | Message | What caused the error |
---|---|---|
Β 200 | Β Response |
ΠΠ‘ΠΠ - ΠΏΡΠ±Π»ΡΡΠ½Π° Π΄ΠΎΠΊΡΠΌΠ΅Π½ΡΠ°ΡΡΡ