Table of Contents | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
...
Method to create declaration request via patient information system
Specification
Validations
Authorization
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 = 'declaration_request:write_pis')
Return (403, 'Your scope does not allow to access this resource. Missing allowances: declaration_request:write_pis ') in case of invalid scope(s)
...
Prepare data for declaration request printout form
Call MAN service to render printout form
Get template id from config
(DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_ID)(PIS_DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_ID
)Prepare printout content based on declaration request data
Render printout form and save to declaration request
If confidant person is required (see https://e-health-ua.atlassian.net/wiki/spaces/EHPCAB/pages/1762866018917513447465/PIS.+Create+Declaration+request#Validaterequest_EN#Validate-confidant-person-and-relationship-(optional) ) then preload Confidant person object from MPI in the following structure
...