...
This WS allows to get a list of licenses for a legal entity. Used by legal entity employees to receive full information about primary and additional licenses of legal entity.
Key points
This REST method is used by MIS.
Only authenticated and authorized user with appropriate scope can get licenses list.
Specification
Page Properties |
---|
Link | https://ehealthmisapi1.docs.apiary.io/#reference/public.-medical-service-provider-integration-layer/licenses/get-licenses | Посилання на Apiary або Swagger | Resource | /api/licenses | Посилання на ресурс, наприклад: /api/persons/create | Scope | license:read | Scope для доступу | Components | ePrescriptionLegal Entities | Зазначається перелік бізнес компонентів, які використовують цей метод, наприклад: ePrescription | Microservices | API paragraph not found | Перелік мікросервісів, які використовує метод API, наприклад: Auth, ABAC | Protocol type | REST | Тип протоколу, який використовується запитом, наприклад: SOAP | REST | Request type | GET | Тип запиту API, наприклад: GET, POST, PATCH… | Sync/Async | Sync | Метод є синхронним чи асинхронним? |
|
Logic
Extract client_id from token.
Filter active licenses:
for current legal entity from token (licenses.legal_entity_id=$.client_id).
by search params.
Render found licenses with all fields from DB.
Preconditions
API paragraph not found
...
API paragraph not found
Request data validation
API paragraph not found
Parameters that are used when processing the request
Configuration parameters
Access to the method is defined by the scope license:read. Permission for this scope is determined by the System administrator by configuring scopes in the context of clients and roles.
...
API paragraph not found
Processing
API paragraph not found
Response structure
See on Apiary
Example:
Expand |
---|
|
Code Block |
---|
{
"meta": {
"code": 200,
"url": "https://example.com/resource",
"type": "object",
"request_id": "req-adasdoijasdojsda"
},
"data": [
{
"id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
"type": "MSP",
"license_number": "fd123443",
"issued_by": "Кваліфікацйна комісія",
"issued_date": "2022-02-28",
"expiry_date": "2026-02-28",
"active_from_date": "2022-02-28",
"what_licensed": "реалізація наркотичних засобів",
"order_no": "ВА43234",
"legal_entity_id": "28d9c1be-08f0-403b-aa76-bff228c9904f",
"is_primary": true
}
],
"paging": {
"page_number": 2,
"page_size": 50,
"total_entries": 1000,
"total_pages": 23
}
} |
|
...