Table of Contents | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Purpose
This WS is designed to allow NHS employee with assigned appropriate scopes to get related information about person’s unzr from eHealth (MIMIR db), that in turn was received from EIS MVS register by a job.
Key points
This is a graphQl query method used in Administration panel only.
Only authenticated and authorized NHS employee with appropriate scope can get person’s information related to unzr.
The method gets result of a Job triggered by [NEW] (GraphQL) Sync UNZR info mutation, that stored in unzr_info table (MIMIR db)
Specification
Expand | |||||
---|---|---|---|---|---|
| |||||
|
Expand | |||||
---|---|---|---|---|---|
| |||||
|
Authorize
Verify the validity of access token
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 = 'unzr:read')
Return (403, 'Your scope does not allow to access this resource. Missing allowances: person:read') in case of invalid scope(s)
Validate legal entity
Extract client_id from token.
Check legal entity status (status = ACTIVE)
In case of error - return 409 ('client_id refers to legal entity that is not active')
Validate request
1. unzr
Validate value in the field unzr
, string, required
Check it is submitted
in case of error - return 422 ('required property <property name> was not present')
Service logic
Get unzr_info record (MIMIR DB)
Render and return
UnzrInfo
node in response