Info |
---|
REST API method / Метод REST API (настанова) (/wiki/spaces/EN/pages/17591304241 (remove the link block before publishing the document) |
...
Page Properties | |||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||
|
...
Request has a similar structure as in Public. Create Contract Request
. For Create contract request by NHS, the contract_number
in the request is required, it is used to change the existing contract by the NHS.
Configuration parameters
Description of the configuration parameters that are used when processing a request in the system
Dictionaries
Provides a list of links to dictionaries that are available in Confluence
Input parameters
Description of input parameters
Input parameter | Mandatory | Type | Description | Example | |
---|---|---|---|---|---|
1 | contract_type | CAPITATION REIMBURSEMENT | String | Required |
|
2 | id |
| String | Contract_request ID. Required | 09106b70-18b0-4726-b0ed-6bda1369fd52 |
Request structure
See on API-specification (посилання на сторінку з API-специфікацією)
Description of the REST API request structure, example
Expand | ||
---|---|---|
| ||
|
...
contract request number structure XXXX-1234-5678-C , where:
XXXX - series: numbers + only some letters (A, E, H, K, M, P, T, X)
1234-5678 - randomly generated numbers and letters A, E, H, K, M, P, T, X.
contract_number is in request
in case error return 409, "Contract number should be in payload"
check there is a contract with such contract_number
in case of error return 422 error ('Contract with such contract number does not exist')
contrat status = VARIFIED
in case of error return 409 error ('Can not update terminated contract')
Contract.is_suspended = false
in case error 409, "suspended contract should be updated by contractor_owner"
Check only next fields are different from contract
nhs_signer_id
nhs_signer_base
nhs_contract_price (for capitation contracts only)
nhs_payment_method
issue_city
Misc
assignee_id
in case error return 422, "Not allowed to change field $.field"
Validate end_date:
if $contract_number and $end_date is passed in request:
the year of $end_date must be greater or equal then the $start_date
in case of error return 422 ('The year of end_date should be one year greater or equal to start_date')
the $end_date should be equal or greater than today and less than or equal to three month from $end_date the previous contract
in case of error return 422 ('The end_date may be equal or greater than today and less than or equal to three month from end_date the previous contract')
if $contract_number w/o $end_date is passed in request:
$end_date is taken from the previous contract
Processing
Search pending contract requests
...
Response structure examples
See on API-specification (посилання на сторінку з API-специфікацією)
Description of the REST API response structure, example
...
Response code | HTTP Status code | Message | Internal name | Description | |
---|---|---|---|---|---|
1 | Базові | ||||
2 | 201 | Response |
| ||
3 | 401 | Access denied |
| ||
4 | 401 | Invalid scopes | |||
5 | 401 | Unauthorized | Помилка підтвердження | ||
6 | 403 | Client is blocked | |||
7 | 403 | Client is not active | |||
8 | 403 | Error | |||
9 | 403 | forbidden | |||
10 | 1000 | 404 | Composition not found | COMPOSITION_NOT_FOUND_404 | Не знайдено медичний висновок |
11 | 409 |
| Validation failed | ||
12 | 422 |
| Validation failed | ||
13 | 422 | Invalid EDRPOU in DS | |||
14 | 422 | Not allowed to change field $.field | |||
15 | 422 | The year of end_date should be one year greater or equal to start_date | |||
16 | 422 | The end_date may be equal or greater than today and less than or equal to three month from end_date the previous contract | |||
17 | Специфічні | ||||
18 | 422 | Only for active MPI record can be created medication request! |
Post-processing processes
Description of actions performed on data after processing
Technical modules where the method is used
List of pages describing technical modules where the method is used
Page Properties Report | ||||
---|---|---|---|---|
|
...