Versions Compared

Key

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

...

Page Properties
idAPI_Specification

Link

API paragraph not found

Посилання на Apiary або Swagger

Resource

API paragraph not found

Посилання на ресурс, наприклад: /api/persons/create

Scope

person:verify

Scope для доступу

Components

API paragraph not found

Зазначається перелік бізнес компонентів, які використовують цей метод, наприклад: ePrescription

Microservices

API paragraph not found

Перелік мікросервісів, які використовує метод API, наприклад: Auth, ABAC

Protocol type

API paragraph not found

Тип протоколу, який використовується запитом, наприклад: SOAP | REST

Request type

API paragraph not found

Тип запиту API, наприклад: GET, POST, PATCH…

Sync/Async

API paragraph not found

Метод є синхронним чи асинхронним?

Public/Private/Internal

Private

Потрібно зазначити тип методу за ступенем доступності

Expand
titleindex.graphql
Code Block
languagegraphql
  "Updates verification status for a single `Person` by NHS using its globally unique ID."
  updatePersonVerificationStatus(
    input: UpdatePersonVerificationStatusInput!
  ): UpdatePersonVerificationStatusPayload

...

  1. Set fields in persons table (mpi database):

    1. verification_status = $.verification_status

    2. verification_comment = $.verification_comment, in case of NOT_VERIFIED. And verification_comment = NULL, in case of VERIFIED

    3. verification_reason = MANUAL

    4. updated_by = user_id (from token)

    5. updated_at = current timestamp

  2. Create StateChangeEvent in event manager with verification_status

  3. Add record to audit_log with changed fields

Request structure

...

API paragraph not found

Authorize

  • Verify the validity of access token

    • in case of error - return 401 (“Invalid access token”) in case of validation fails

  • Verify that token is not expired

    • in case of error - return 401 (“Invalid access token”)

  • Check user scopes in order to perform this action (scope = 'person:verify')

    • return 403 (“Your scope does not allow to access this resource. Missing allowances: person:verify”) in case of invalid scope(s)

Headers

API paragraph not found

Request data validation

Validate legal entity

...

  • if verification_status = NOT_VERIFIED

    • in case of error - return 409 ('verification status comment is required')

Processing

API paragraph not found

Response structure

See on ApiaryAPI paragraph not found

Post-processing processes

API paragraph not found

HTTP status codes

API paragraph not found