Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents
maxLevel3
minLevel1

...

Specification

Page Properties


Link

https://medicaleventsmisapiehealthmedicaleventsapi.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 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

  1. If approval has resource != (care_plan & terms_of_service = ‘INPATIENT’ for care_plan & granted_to.employees.legal_entity_id = care_plans.managing_organization):

    1. If authentication_method_current.type = OTP

    2. system checks verification code via otp_verification service PATCH /verifications/:phone_number/actions/complete

    3. if verification code matches - change status to active

    4. If not - return error

  2. 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:

    1. change status to active

Request structure

See on Apiary

Example:

Expand
titleRequest example


Code Block
{
  "code": 3782
}


...

  1. Verify the validity of access token

  2. Check user scope approval:create in order to perform this action

Headers

Наприклад:

  • Content-Type:application/json

  • Authorization:Bearer d368a4b0-4a0e-457a-b267-32359fa6288f

...