Table of Contents |
---|
Version compatibility
For test used "Legal entity: Version compatibility" postman collection.
# | Test | Preconditions | Input | Expected result | Actual result | Realised Path in Postman collection | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | Create Legal Entity (LE) with api v1 | LE added to EDR. req.edrpou != prm.legal_entities.edrpou | Valid data for v1 req.type = MSP | 200 | 200 | Create LE / v1 / PUT MSP type v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
2 | LE added to EDR. req.edrpou != prm.legal_entities.edrpou | Valid data for v1 req.type = PHARMACY | 200 | 200 | Create LE /v1 / PUT PHARMACY type v1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
3 | LE added to EDR. req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type=MSP | 422 | 422 | Create LE /v1 / MSP MSP1 type v2 payload format - validation failed | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
4 | LE added to EDR. req.edrpou != prm.legal_entities.edrpou | Valid data for v1 req.type = PRIMARY_CARE | 422 | 200422 | Create LE /v1 / PRIMARY_CARE type v1 | 5 | req.- invalid type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
4.1 | LE added to EDR. req.edrpou != prm.legal_entities.edrpoureq.data doesn`t correspond to EDR data within EDRPOU property | Valid data for v1 req.edr-data-id.edrpou != req.edrpoureq.type = PRIMARYMSP_CAREPHARMACY | 409422 | 6 | req.edrpou != prm.legal_entities.edrpou req.data doesn`t correspond to EDR data within legal form property | Valid data for v1 req.edr-data-id.olf_code != req.legal_form req.type = PRIMARY_CARE | 409 | 7 | req.422 | Create LE /v1 / MSP_PHARMACY type v1 - invalid type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
5 | LE is not added to EDR. req.edrpou != prm.legal_entities.edrpou | req.data doesn`t correspond Valid data for v1 | 422 | 422 | Create LE /v1 / MSP3 type v1 - EDR data is absent | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
6 | req.edrpou != prm.legal_entities.edrpou req.data doesn`t correspond to EDR data within name legal form property | Valid data for v1 req.edr-data-id.name olf_code != req.namelegal_form req.type = PRIMARY_CAREMSP | 409422 | 8 | req.edrpou 422 | Create LE /v1 / MSP3 type v1 - legal form differs from EDR data | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
7 | req.edrpou != prm.legal_entities.edrpou EDR identifier exists in eHealth and linked to another LE | Valid data for v1 req.edr_data.id = prm.edr_data.id | 409 req.data doesn`t correspond to EDR data within name property | Valid req v1 req.type = MSP | 422 | 422 | Create LE /v1 / MSP3 type v1 - name differs from EDR data | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
8 | LE is not added to EDR, state is not active | Valid req v1 | 422 | 422 | Create LE /v1 / MSP3 type v1 - state is not active in EDR | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
9 | Create LE api v2 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type = MSP | 409422 | 422 | Create LE /v2 / PUT MSP PUT MSP type v2 -invalid typeformat | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
10 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type = PHARMACY | 200 | 200 | Create LE /v2 / PUT PHARMACY type v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
11 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type = PRIMARY_CARE | 200 | 200 | Create LE /v2 / PUT PRIMARY_CARE type v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
12 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type = OUTPATIENT | 200 | 200 | Create LE /v2 / PUT OUTPATIENT type v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
13 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v1 req.type = MSP | 422 | 422 | Create LE /v2 / MSP type v1 payload format - validation failed | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
14 | LE added to EDR req.edrpou != prm.legal_entities.edrpou | Valid data for v2 req.type = MSP_PHARMACY | 409422 | 422 | Create LE /v2 / MSP_PHARMACY type v2 - invalid type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
15 | LE added to EDR, state is not active req.edrpou != prm.legal_entities.edrpou req.data doesn`t correspond to EDR data within EDRPOU property | Valid Valid data for v2 req.edr-data-id.edrpou != req.edrpou req.type = PRIMARY_CARE | 409 | 16 | 422 | 422 | Create LE /v2 / PRIMARY_CARE3 type v2 - state not active in EDR | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
16 | LE added to EDR req.edrpou != prm.legal_entities.edrpou req.data doesn`t correspond to EDR data within legal form property | Valid data for v2 req.edr-data-id.olf_code != req.legal_form req.type = PRIMARY_CARE | 409 | 17 license is empty | 422 | 422 | Create LE /v2 / PRIMARY_CARE3 type v2 - empty license | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
17 | LE added to EDR req.edrpou != prm.legal_entities.edrpou req.data doesn`t correspond to EDR data within name property | Valid data for v2 req.edr-data-id.name != req.name req.type = PRIMARY_CARE | 409 | 18 type = PRIMARY_CARE req.license.type = PHARMACY | 409 | 409 | Create LE /v2 / PRIMARY_CARE3 type v2 - wrong license type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
18 | LE added to EDR req.edrpou != prm.legal_entities.edrpou EDR identifier prm.license.id exists in eHealth and linked to for another LE | Valid data for v1 req.edr_datalicense.id = prm.edr_datalicense.id | 409 | 19409 | Update LE api v1 | req.edrpouCreate LE /v2 / PRIMARY_CARE3 type v2 - wrong license id | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req.edrpou != prm.legal_entities.edrpou | prm.legal_entityreq.type = | MSP and created with v1 apiValid data for v1.PHARMACY | eq.license.type = MSP | 200 | Update LE /v1 / MSP type v1 | 20409 | 409 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req. | edrpou edrpou != prm.legal_entities.edrpou | prm.legal_entityreq.type = | MSP and created with v1 apiValid req for v1 req.type = PRIMARY_CARE | 200 | Update LE /v1 / MSP1 to PRIMARY_CARE v1 | 21PRIMARY_CARE | req.license parameter is null or absent | 422 | 422 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
19 | Update LE api | v2v1 | req.edrpou = prm.legal_entities.edrpou prm.legal_entity.type=MSP and created with v1 api | Valid req data for v2v1. req.type = PRIMARY_CAREMSP | 200 | 200 | Update LE /v2 / MSP2 to PRIMARY_CARE2 v2 | 22v1 / MSP type v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
20 | req.edrpou = prm.legal_entities.edrpou prm.legal_entity.type= | PRIMARY_CARE MSP and created with | v2v1 api | Valid | datareq for | v2v1 req.type = PRIMARY_CARE | 422 | 200422 | Update LE / | v2 v1 / MSP1 v1 to PRIMARY_CARE v1 - invalid type | v223||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req. | edrpou edrpou = prm.legal_entities.edrpou prm.legal_ | entityentities. | type=MSP created with v2status = ACTIVE | Valid data for | v2409 | Update LE /v2 / MSP type v2 - incorrect type | 24 | req.edrpouv1 | 200 status = SUSPENDED | 200 status= ACTIVE | Update LE /v1 / MSP3 type v1 - not active in EDR | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req.edrpou = prm.legal_entities.edrpou | req.license id is empty req.license.type=MSP | 409 | Update LE /v2 / PRIMARY_CARE type v2 - license type duplication | 25 | EDR has 2 entries - first with not active state, last - with active state | Valid data for v1 | 200 Parameters updated from new active EDR entry | 200 | MSP3 type v1 - update with new EDR data | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
21 | Update LE api v2 | req.edrpou = prm.legal_entities.edrpouLE updates another LE license. prm.license.id exists in eHealthlegal_entity.type=MSP created with v1 | Valid req for v2 req.license id != prm.license.id409type = PRIMARY_CARE | 200 | 200 | Update LE /v2 / MSP2 to PRIMARY_CARE type v2 - license id from another LE | 26 | Find LE with api v1CARE2 v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
27 | prm.legal_entity created with v1req.edrpou = prm.legal_entities.edrpou prm.legal_entity.type=MSP created with v1 | edrpou | 200 One LE v1 was found | Find LE /v1 / LE v1 by edrpou | req.license data is absent, expect id. | Valid req for v2 req.license.id | 200 | 200 | Update LE /v2 / MSP2 v1 to PRIMARY_CARE - send license id only | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
22 | req.edrpou = prm.legal_entities.edrpou prm.legal_entity.type=PRIMARY_CARE (created with v2 | settlement_id && type && status && nhs_verified | 200 Result set includes LE v1 and v2 | Find LE/v1 / LE v1 and v2 by params | 28 | Find LE with api v2) req.license contains id only | Valid data for v2 req.type = PRIMARY_CARE req.license.id = prm.license.id (linked to this LE) | 200 | 200 | Update LE /v2 / PRIMARY_CARE type v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
23 | req.edrpou = prm.legal_entities.edrpou prm.legal_entity.type=MSP created with v2 | Valid data for v2 | edrpou | 200 One LE v1 was found | Find req.type = MSP | 422 | 422 | Update LE /v2 / | LE v1 by edrpou29 | MSP type v2 - incorrect type | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
24 | req.edrpou = prm.legal_ entity created with v1prm.legal_entity created with v2 | settlement_id && type && status && nhs_verified | 200 Result set includes LE v1 and v2 | Find LE/v2 / LE v1 and v2 by params | 30 | Get LE with api v1 | prm.legal_entity created with v1 | legal_entity_id | 200 One LE v1 was returned | Get LE/v1 / LE v1 | 31 | prm.legal_entity created with v2 | legal_entity_id | 200 One LE v2 was returned | Get LE/v1 / LE v2 | 32 | Get LE with api v2 | prm.legal_entity created with v1 | legal_entity_id | 200 One LE v1 was returned | Get LE/v2 / LE v1 | 33 | prm.legal_entity created with v2 | legal_entity_id | 200 One LE v2 was returned | Get LE/v2 / LE v2 | 34 | Verify LE by MIS with api v1 | prm.legal_entity created with v1 prm.legal_entity.mis_verified=NOT_VERIFIED | legal_entity_id | 200 OK LE updated with mis_verified=VERIFIED | Verify LE by MIS / not verified MSP v1 | 35 | prm.legal_entity created with v1 prm.legal_entity.mis_verified=VERIFIED | legal_entity_id | 409 LE wasn`t updated | Verify LE by MIS / verified MSP v1 | 36 | prm.legal_entity created with v2 prm.legal_entity.mis_verified=NOT_VERIFIED | legal_entity_id | 405 | Verify LE by MIS / not verified MSP v2 | 37 | Verify LE by NHSentities.edrpou LE has already assigned licenses.type=MSP | req.license id is empty req.license.type=MSP | 200 | 200 | Update LE /v2 / PRIMARY_CARE type v2 - license update w/o id | ||||||||||||||||||||||||||||||||||||||||
25 | req.edrpou = prm.legal_entities.edrpou LE updates another LE license. | req.license id != prm.license.id | 409 | 409 | Update LE /v2 / PRIMARY_CARE type v2 - license id from another LE | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Add new license prm.legal_entity.type=PRIMARY_CARE created with v2 | Valid data for v2 req.license.id is absent req.license.type=MSP | 409 | 409 | Update LE /v2 / PRIMARY_CARE type v2 - add new PHARMACY license | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
EDR data changed (names, legal form, kveds, atu_code) prm.legal_entity.type=PRIMARY_CARE created with v2 | Valid data for v2 | 200 | 200 | Update LE /v2 / PRIMARY_CARE type v2 - EDR data changed | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
EDR data state is not active prm.legal_entity.type=PRIMARY_CARE created with v2 LE status=ACTIVE | Valid data for v2 | 200 status=SUSPENDED | 200 status=ACTIVE | Update LE /v2 / PRIMARY_CARE2 type v2 - EDR not active | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req.edrpou = prm.legal_entities.edrpou req.type=prm.legal_entity.type=PRIMARY_CARE req.license data is empty | Valid data for v2 req.license = { } | 422 | 422 | Update LE /v2 / PRIMARY_CARE type v2 - license with empty object | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
req.edrpou = prm.legal_entities.edrpou req.license id belongs to another LE | Valid data for v2 req.license.id | 409 | 409 | Update LE /v2 / PRIMARY_CARE type v2 - license id from another LE | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
PHARMACY was created with api v1 | Valid data for v2 req.type=PHARMACY | 200 | 200 | Update LE /v2 / PHARMACY type v1 updated with v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
26 | Find LE with api v1 | prm.legal_entity created with v1 | prm.legal_entity.nhs_verified=falselegal_entity_id | 200 OK LE updated with nhs_verified=true | Virify by NHS / not verified MSP v1 | 38Auth with LE owner's token | edrpou | 200 One LE v1 was found | 200 | Find LE /v1 / LE v1 by edrpou | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
27 | prm.legal_entity created with v1 | .nhs_verified=truelegal_entity_id | 409 LE not updated | Virify by NHS / verified MSP v1 | 39created with v2 Auth with mis token | settlement_id && type && status && nhs_verified | 200 Result set includes LE v1 and v2 | 200 | Find LE/v1 / LE v1 and v2 by params | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
prm.legal_entity created with v2prm.legal_entity.nhs_verified=false prm.legal_entity.status=ACTIVE | legal_entity_id | 200 OK LE updated with nhs_verified=true | Virify by NHS / not verified MSP v2 | 40 | Create Division with api v1 | Owner`s employee already exists. v1 Searched edrpou exists in eHealth, but doesn't belong to this owner. Auth with LE owner's token | edrpou | 200 empty data in resp. | 200 empty data in resp. | Find LE/v1 / LE v1 by edrpo (owner token) - LE doesnt belong to this owner | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
28 | Find LE with api v2 | prm.legal_entity created with v2 Auth with LE owner's token | edrpou | 200 One LE v1 was found | 200 | Find LE/v2 / LE v1 by edrpou | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
29 | prm.legal_entity | .type=MSP created with v1 | req.type=CLINIC | 200 Division was created | Create divisions \ CLINIC for MSP v1 | 41 | Owner`s access token is valid.prm.legal_entity | .type=PRIMARY_CARE created with v2 | req.type=FAP | 200 Division was created | Create divisions \ FAP for PRIMARY_CARE v2 | 42 | Owner`s access token is valid.Auth with mis token | settlement_id && type && status && nhs_verified | 200 Result set includes LE v1 and v2 | 200 | Find LE/v2 / LE v1 and v2 by params | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
prm.legal_entity .type=PRIMARY_CAREcreated with v2 | req.type=DRUGSTORE | 422 Division wasn`t created | Create divisions \ DRUGSTORE for PRIMARY_CARE v2 - invalid division type | 43 | Create Employee Request api v1 | Owner`s employee already exists. prm.legal_entity.type=MSP created with v1 | req.type=DOCTOR | 200 OK Employee request was created, status=new | Create Employee /v1 / DOCTOR for MSP v1 | 44 | Owner`s employee already exists. Searched edrpou exists in eHealth, but doesn't belong to this owner. Auth with LE owner's token | edrpou | 200 empty data in resp. | 200 empty data in resp. | Find LE/ v2 / LE v2 by edrpo (owner token) - LE doesnt belong to this owner | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
30 | Get LE with api v1 | prm.legal_entity .type=PRIMARY_CAREcreated with v2 | req.type=PHARMACIST | 404 Employee request wasn`t created | Create Employee /v1 /PHARMACIST for PRIMARY_CARE v2 - invalid employee type | 45 | Owner`s access token is valid. v1 Auth with LE owner's token | legal_entity_id | 200 One LE v1 was returned | 200 | Get LE/v1 / LE v1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
31 | prm.legal_entity .type=PRIMARY_CAREcreated with v2 req.type=DOCTORAuth with LE owner's token | legal_entity_id | 200 OK Employee request was created, status=newCreate Employee One LE v2 was returned | 200 | Get LE/v1 / DOCTOR for PRIMARY_CARE LE v2 | 46 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Owner`s employee already exists.32 | Get LE with api v2 | prm.legal_entity .type=PRIMARY_CAREcreated with v2reqv1 prm.legal_entity.type = DOCTORreq.doctor.specialities.speciality = PHARMACIST (only) | 409 | Create Employee /v1 / DOCTOR for PRIMARY_CARE v2 - wrong speciality PHARMACIST | 47 | Approve Employee api v1 | Employee req created for LE v1 Emplotee request exists in status=new | employee_requests.id | 200 OK employee_requests.status=APPROVED, employee created, user created, party created, | Approve Employee / DOCTOR of MSP v1 | 48 | Employee req created for LE v2 Emplotee request exists in status=new | employee_requests.id | 200 OK employee_requests.status=APPROVED, employee created, user created, party created, | Approve Employee / DOCTOR of PRIMARY_CARE v2 | 49 | Create Contract api v1 | LE created with api v1 | Valid req data | 200 | Create contract request/ Create contract request - MSP v1 | 50 | LE created with api v2 | Valid req data | 200 | Create contract request/ Create contract request - MSP v2 | 51 | Create Declaration Request | LE created with api v1 | Valid data | 200 | Create and Approve Declaration / Create Declaration Request Auth OTP v2 - for MSP v1 | 52 | LE created with api v2 | Valid data | 200 | Create and Approve Declaration / Create Declaration Request Auth OTP v2 - for PRIMARY_CARE v2 | 53 | Approve Declaration Request | LE created with api v1 | Valid data | 200 | Create and Approve Declaration / Approve declaration request - for MSP v1 | 55 | LE created with api v2 | Valid data | 200 | Create and Approve Declaration / Approve declaration request - for PRIMARY_CARE v2 | 55 | Sign Declaration Request | LE created with api v1 | Valid data | 200 | Create and Approve Declaration / Sign declaration request - MSP v1 | 56 | LE created with api v2 | Valid data | 200 | Create and Approve Declaration / Sign declaration request - PRIMARY_CARE v2 | 57 | Create Medication Request Request | LE created with api v1 | Valid data | 200 | Create and approve Medication request / Create Medication_request_request - MSP v1 | 58 | LE created with api v2 | Valid data | 200 | Create and approve Medication request / Create Medication_request_request - PRIMARY_CARE v2 | 59 | Sign Medication Request Request | LE created with api v1 | Valid data | 200 | Create and approve Medication request / Medication_request_request Sign - MSP v1 | 60 | LE created with api v2 | Valid data | 200 | Create and approve Medication request / Medication_request_request Sign - PRIMARY_CARE v2 | 61 | Deactivate LE api v1 | LE created with api v1. prm.legal_entity.is_active = true & MSP Auth with LE owner's token | legal_entity_id | 200 One LE v1 was returned | 200 | Get LE/v2 / LE v1 |
33 | prm.legal_entity created with v2 prm.legal_entity.type = PRIMARY_CARE Auth with LE owner's token | legal_entity_id | 200 One LE v2 was returned | 200 | Get LE/v2 / LE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
prm.legal_entity created with v2 prm.legal_entity.type = PHARMACY Auth with LE owner's token | legal_entity_id | 200 One LE v2 was returned | 200 | Get LE/v2 / LE v2 PHARMACY | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
prm.legal_entity created with v2 prm.legal_entity.type = PHARMACY, that doesn't belong to this owner Auth with LE owner's token | legal_entity_id | 403 forbidden | 403 forbidden | Get LE/v2 / LE v2 PHARMACY - LE doesnt belong to this owner | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
34 | Verify LE by MIS with api v1 | prm.legal_entity created with v1 | legal_entity_id | 404 | 404 | Verify LE by MIS / not verified MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
37 | Verify LE by NHS with api v1 | prm.legal_entity created with v1 Auth with NHS token | legal_entity_id | 200 OK LE updated with nhs_verified=true | 200 nhs_verified=true | Virify by NHS / not verified MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
38 | prm.legal_entity created with v1 Auth with NHS token | legal_entity_id | 409 LE not updated | 409 | Virify by NHS / verified MSP v1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Review and Verify LE by NHS with GraphQL api | prm.legal_entity created with v2 prm.legal_entity.nhs_reviewed=false prm.legal_entity.status=ACTIVE | legal_entity_id | 200 OK LE updated with nhs_reviewed=true | 200 | Virify by NHS / Review by NHS - PRIMARY_CARE v2 (GRAPHql) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
39 | prm.legal_entity created with v2 prm.legal_entity.nhs_reviewed=true ACTIVE or SUSPENDED)LE has active employees | req.legal_entity_id | 200 OK prm.legal_entity.status=CLOSED & is_active=false, related owner has is_active = false, related other employees has status=DISMISSED, related contracts has is_suspended=true & status=TERMINATED & reason=auto_deactivation_legal_entity related contract requests has status=TERMINATED & reason=auto_deactivation_legal_entity | Deactivate LE / MSP v1 | 62 | LE created with api v2LE updated with nhs_verified=true | 200 | Virify by NHS / Verify by NHS - PRIMARY_CARE v2 (GRAPHql) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
40 | Create Division with api v1 | Owner`s employee already exists. prm.legal_entity.type=MSP created with v1 | req.type=CLINIC | 201 Division was created | 201 | Create divisions \ CLINIC for MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
41 | Owner`s access token is valid. prm.legal_entity.is_active = true & prm.legal_entity.status = (ACTIVE or SUSPENDED) LE has active employees | req.legal_entity_id | 200 OKtype=PRIMARY_CARE created with v2 | req.type=FAP | 201 Division was created | 201 | Create divisions \ FAP for PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
42 | Owner`s access token is valid. prm.legal_entity.status=CLOSED & is_active=false, related owner has is_active = false, related other employees has status=DISMISSED, related contracts has is_suspended=true & status=TERMINATED & reason=auto_deactivation_legal_entity related contract requests has status=TERMINATED & reason=auto_deactivation_legal_entityDeactivate LE / PRIMARY_CARE v2type=PRIMARY_CARE created with v2 | req.type=DRUGSTORE | 422 Division wasn`t created | 422 | Create divisions \ DRUGSTORE for PRIMARY_CARE v2 - invalid division type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Owner`s access token is valid. prm.legal_entity.type=PHARMACY created with v1 | req.type=DRUGSTORE | 201 | 201 | Create divisions \ DRUGSTORE for PHARMACY v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Owner`s access token is valid. prm.legal_entity.type=PHARMACY created with v2 | req.type=DRUGSTORE | 201 | 201 | Create divisions \ DRUGSTORE for PHARMACY v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
43 | Create Employee Request api v1 | Owner`s employee already exists. prm.legal_entity.type=MSP created with v1 | req.type=DOCTOR | 200 OK Employee request was created, status=new | 200 | Create Employee /v1 / DOCTOR for MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
44 | Owner`s employee already exists. prm.legal_entity.type=PRIMARY_CARE created with v2 | req.type=PHARMACIST | 422 Employee request wasn`t created | 422 | Create Employee /v1 /PHARMACIST for PRIMARY_CARE v2 - invalid employee type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
45 | Owner`s access token is valid. prm.legal_entity.type=PRIMARY_CARE created with v2 | req.type=DOCTOR | 200 OK Employee request was created, status=new | 200 | Create Employee /v1 / DOCTOR for PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
46 | Owner employee exists and has valid access token. prm.legal_entity.type=PHARMACY created with v1 | req.type = PHARMACIST | 200 | 200 | Create Employee /v1 / PHARMACIST for PHARMACY v1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Owner employee exists and has valid access token. prm.legal_entity.type=PHARMACY created with v2 | req.type = PHARMACIST | 200 | 200 | Create Employee /v1 / PHARMACIST for PHARMACY v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
47 | Approve Employee api v1 | Employee req created for MSP Emplotee request exists in status=new | employee_requests.id | 200 OK employee_requests.status=APPROVED, employee created, user created, party created, | 200 | Approve Employee / DOCTOR of MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
48 | Employee req created for PRIMARY_CARE Emplotee request exists in status=new | employee_requests.id | 200 OK employee_requests.status=APPROVED, employee created, user created, party created, | 200 | Approve Employee / DOCTOR of PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Employee req created for PHARMACY v1 Emplotee request exists in status=new | employee_requests.id | 200 | 200 | PHARMACIST of PHARMACY v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Employee req created for PHARMACY v2 Emplotee request exists in status=new | employee_requests.id | 200 | 200 | PHARMACIST of PHARMACY v2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
51 | Create Declaration Request | LE created with api v1 Exists active employee in LE | Valid data | 200 | 200 | Create and Approve Declaration / Create Declaration Request Auth OTP v2 - for MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
52 | LE created with api v2 Exists active employee in LE | Valid data | 200 | 200 | Create and Approve Declaration / Create Declaration Request Auth OTP v2 - for PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
53 | Approve Declaration Request | LE created with api v1 Employee has access token | Valid data | 200 | 200 | Create and Approve Declaration / Approve declaration request - for MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
55 | LE created with api v2 Employee has access token | Valid data | 200 | 200 | Create and Approve Declaration / Approve declaration request - for PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
55 | Sign Declaration Request | LE created with api v1 Declaration has approved by employee | Valid data | 200 | 200 | Create and Approve Declaration / Sign declaration request - MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
56 | LE created with api v2 Declaration has approved by employee | Valid data | 200 | 200 | Create and Approve Declaration / Sign declaration request - PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
57 | Create Medication Request Request | LE created with api v1 Program medication and signed declaration exists | Valid data | 200 | 200 | Create and approve Medication request / Create Medication_request_request - MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
58 | LE created with api v2 Program medication and signed declaration exists | Valid data | 200 | 200 | Create and approve Medication request / Create Medication_request_request - PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
59 | Sign Medication Request Request | LE created with api v1 Medication request request created | Valid data | 200 | 200 | Create and approve Medication request / Medication_request_request Sign - MSP v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
60 | LE created with api v2 Medication request request created | Valid data | 200 | 200 | Create and approve Medication request / Medication_request_request Sign - PRIMARY_CARE v2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Create Contract Request (capitation) | Initializing contract req MSP created with api v1 | MSP owner's token | 200 | 200 | Create Contract Request (capitation) / Initialize Contract Request - MSP v1 (capitation) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Initializing contract req PRIMARY_CARE created with api v2 | PRIMARY_CARE owner's token | 200 | 200 | Create Contract Request (capitation) / Initialize Contract Request - PRIMARY_CARE v2 (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Contract request for MSP v1 initialized Employee of MSP v1 exists | Valid contract request data | 201 | 201 | Create Contract Request (capitation) / Create contract request - MSP v1 (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Contract request for PRIMARY_CARE v2 initialized Employee of PRIMARY_CARE v2 exists | Valid contract request data | 201 | 201 | Create Contract Request (capitation) / Create contract request - PRIMARY_CARE v2 (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Create Contract Request (reimbursement) | Initializing contract req PHARMACY created with api v1 | PHARMACY v1 owner's token | 200 | 200 | Create Contract Request (reimbursement) / Initialize Contract Request - PHARMACY v1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Initializing contract req PHARMACY created with api v2 | PHARMACY v2 owner's token | 200 | 200 | Create Contract Request (reimbursement) / | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Contract request for PHARMACY v1 initialized Employee of PHARMACY v1 exists | Valid contract request data | 201 | 201 | Create Contract Request (reimbursement) / Create contract request - PHARMACY v1 (reimbursement) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Contract request for PHARMACY v2 initialized Employee of PHARMACY v2 exists | Valid contract request data | 201 | 201 | Create Contract Request (reimbursement) / Create contract request - PHARMACY v2 (reimbursement) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get Contract request | Get Reimbursement Contract request list for LE v1 and v2 | NHS auth token | 200 Result set contains LE v1 and v2 reimbursement contract req data | 200 Result set contains LE v1 and v2 reimbursement contract req data | Get Contract request / Get Contract request list (reimbursement) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get Capitation Contract request list for LE v1 and v2 | NHS auth token | 200 Result set contains LE v1 and v2 capitation contract req data | 200 Result set contains LE v1 and v2 capitation contract req data | Get Contract request / Get Contract request list (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get contract request by Id for MSP (capitation) | MSP owner access token | 200 | 200 | Get Contract request / Get contract request by Id for MSP (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get contract request by Id for PRIMARY_CARE (capitation) | PRIMARY_CARE owner access token | 200 | 200 | Get Contract request / Get contract request by Id for PRIMARY_CARE (capitation) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get contract request by Id for PHARMACY v1 (reimbursement) | PHARMACY v1 owners access token | 200 | 200 | Get Contract request / Get contract request by Id for PHARMACY v1 (reimbursement) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get contract request by Id for PHARMACY v2 (reimbursement) | PHARMACY v2 owners access token | 200 | 200 | Get Contract request / Get contract request by Id for PHARMACY v2 (reimbursement) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get reimbursement contract id with API for capitation | id of reimbursement contract request | 404 | 404 | Get Contract request / Get reimbursement contract id with API for capitation - fail | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get capitation contract id with API for reimbursement | id of capitation contract request | 404 | 404 | Get Contract request / Get capitation contract id with API for reimbursement - fail | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Get reimbursement contract req by id with another owner token - fail | Owner's token from another LE | 403 | 403 | Get Contract request / Get reimbursement contract req by id with another owner token - fail | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||