Table of Contents |
---|
Purpose
Use this end-point This method is designed to obtain all Employees of the legal entity specified by the legal_entity_id
.
Specification
...
id
...
String
...
Required
...
d290f1ee-6c54-4b01-90e6-d701748f0851
Filters
API paragraph not found
Dictionaries
API paragraph not found
Request structure
...
Page Properties | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Logic
API paragraph not found
Preconditions
API paragraph not found
Global and configurable parameters
No
Input parameters
...
Input parameter
...
Values
...
Type
...
Description
...
Example
|
Input parameters
See on Apiary
Filters
See on Apiary
Search employees by filters in ws url:
required filters
legal_entity_id (MSP id),
optional filters:
status (employees status APPROVED, DISMISSED, REORGANIZED). By default used APPROVED
employee_type (employees type DOCTOR, HR, ACCOUNTANT, PHARMACIST, etc). By default returned all types of employees.
no_tax_id (filer employees with or w/o tax_id).
tax_id (filter employees by tax_id)
party_id (filter employees by party)
edrpou (filter employees by legal_entity edrpou)
division_id (filter employees by division)
page (Page number)
page_size (A limit on the number of objects to be returned, between 1 and 300. Default: 50)
If according to filters employees are not found, WS returns empty data array.
WS returns shortened details, which consist of:
employee and party objects
for DOCTOR and PHARMACIST - additional returns specialities information
pagination data - for tecnical info.
Dictionaries
EMPLOYEE_TYPE
SPECIALITY_TYPE
SPECIALITY_LEVEL
SPEC_QUALIFICATION_TYPE
POSITION
+DIVISION_TYPE
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 = 'employee:read')
Return (403, 'Your scope does not allow to access this resource. Missing allowances: employee:read') in case of invalid scope(s)
Headers
Content-Type:application/json
Authorization:Bearer c2778f3064753ea70de870a53795f5c9
Request data validation
Validate transition
Validate transitionю Allowed transitions:
pending_verification → closed
Check is_active = true
If not passed, Return Error 403 message "Invalid transition"
Processing
Update Declaration status
$declaration.status = closed
$declaration.updated_by = user_id
$declaration.updated_at = timestamp
Response structure
See on Apiary
-
Processing
Service returns specified Employees related to the legal entity from token:
Get Employees from
prm.employees
Filter by medication_request_id and patient_id and status (optional)
Filter list above by submitted search parameters
Render a response according to specification with found Employees
Return empty array if no data found.
Response structure
Example:
Expand | ||
---|---|---|
| ||
|
Post-processing processes
...
|
HTTP status codes
Page Properties | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
Backward compatibility
API paragraph not found
This WS is designed to search employees by legal_entity_id.
Verify the validity of access token
Check user scopes in order to perform this action
Search employees by filters in ws url:
required filters
legal_entity_id (MSP id),
optional filters:
status (employees status APPROVED, DISMISSED). By default used APPROVED
type (employees type DOCTOR, HR, ACCOUNTANT, PHARMACIST, etc). By default returned all types of employees.
limit (limit response size - quantity of employee objects). By default returned 50 objects.
starting_after (cursor to fetch next page)
ending_before (cursor to fetch previous page)
If according to filters employees are not found, WS returns empty data array.
WS returns shortened details, which consist of:
...
employee and party objects
...
for DOCTOR and PHARMACIST - additional returns specialities information
...
|