ЕСОЗ - публічна документація

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 8 Current »

Purpose

This API is designed to search parties (doctors) on public portal and patient cabinet

Key features:

  • Returns only parties who have at least one employee with type DOCTOR, SPECIALIST or ASSISTANT

Specification

Link

https://uaehealthapi.docs.apiary.io/#reference/internal.-portal-and-reports/parties/search-parties

Посилання на Apiary або Swagger

Resource

/api/stats/parties

Посилання на ресурс, наприклад: /api/persons/create

Scope

API paragraph not found

Scope для доступу

Components

Employees

Зазначається перелік бізнес компонентів, які використовують цей метод, наприклад: ePrescription

Microservices

il/api

Перелік мікросервісів, які використовує метод API, наприклад: Auth, ABAC

Protocol type

REST

Тип протоколу, який використовується запитом, наприклад: SOAP | REST

Request type

GET

Тип запиту API, наприклад: GET, POST, PATCH…

Sync/Async

Sync

Метод є синхронним чи асинхронним?

Public/Private/Internal

Internal

Потрібно зазначити тип методу за ступенем доступності

Input parameters

See on Apiary

Filters

See on Apiary

Dictionaries

https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1300529210/EMPLOYEE+TYPE COUNTRY EDUCATION_DEGREE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1195278373/SPEC+QUALIFICATION+TYPE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1195114505/SPECIALITY+TYPE

https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1194852386/SPECIALITY+LEVEL https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1195278373/SPEC+QUALIFICATION+TYPE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1194328146/PROVIDING+CONDITION https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1190887576/DIVISION+TYPE

/wiki/spaces/EBT/pages/1191149607 https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1199734785/SETTLEMENT+TYPE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1199898644/STREET+TYPE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1307344919/LEGAL+ENTITY+TYPE+V2

https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1321467905/OWNER+PROPERTY+TYPE https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1306296336/LEGAL+FORM https://e-health-ua.atlassian.net/wiki/spaces/EBT/pages/1321533446/PHONE+TYPE

Authorize

Request to process the request using a token in the headers

Request structure

See on Apiary

Headers

Наприклад:

Content-Type:application/json

Request data validation

Validate query params

  1. Validate location - must be provided none of them or all four (location_north, location_south, location_west, location_east)

    1. In case of error - generate 422 error

Prepare response

  1. Get parties who has at least one employee with type DOCTOR, SPECIALIST or ASSISTANT

  2. Outer join employee roles, healthcare services and divisions on (employees.id = employee_roles.employee_id and employee_roles.healthcare_service_id = healthcare_service.id and healthcare_service.division_id = divisions.id)

  3. Filter result by query params

Query param

Source

employee_type

employees.employee_type

full_name

parties.first_name + parties.second_name + parties.last_name

(The same way as it works on search employees)

speciality

healthcare_services.speciality_type

division_id

healthcare_services.division_id

division_name

divisions.name

area

division_addresses

region

division_addresses

settlement

division_addresses

location_*

divisions.location

Must be within the given coordinates

Response structure

Example:

 Response example
{
  "meta": {
    "code": 200,
    "url": "https://example.com/resource",
    "type": "object",
    "request_id": "6617aeec-15e2-4d6f-b9bd-53559c358f97#17810"
  },
  "data": [
    {
      "id": "7d23bebb-1cf3-4221-bf21-18aada444756",
      "first_name": "Петро",
      "second_name": "Миколайович",
      "last_name": "Іванов",
      "educations": [
        {
          "country": "UA",
          "city": "Київ",
          "institution_name": "Академія Богомольця",
          "issued_date": "2017-02-28",
          "diploma_number": "DD123543",
          "degree": "MASTER",
          "speciality": "Педіатр"
        }
      ],
      "qualifications": [
        {
          "type": "SPECIALIZATION",
          "institution_name": "Академія Богомольця",
          "speciality": "Педіатр",
          "issued_date": "2017",
          "certificate_number": "2017",
          "valid_to": "2017",
          "additional_info": "додаткова інофрмація"
        }
      ],
      "specialities": [
        {
          "speciality": "THERAPIST",
          "speciality_officio": true,
          "level": "FIRST",
          "qualification_type": "AWARDING",
          "attestation_name": "Академія Богомольця",
          "attestation_date": "2017-02-28",
          "valid_to_date": "2020-02-28",
          "certificate_number": "AB/21331"
        }
      ],
      "is_available": true,
      "science_degree": {
        "country": "UA",
        "city": "Київ",
        "degree": "",
        "institution_name": "Академія Богомольця",
        "diploma_number": "DD123543",
        "speciality": "Педіатр",
        "issued_date": "2017"
      },
      "working_experience": 10,
      "about_myself": "Закінчив всі можливі курси",
      "employees": [
        {
          "id": "7d23bebb-1cf3-4221-bf21-18aada444756",
          "position": "P1",
          "employee_type": "DOCTOR",
          "healthcare_services": [
            {
              "id": "7c3da506-804d-4550-8993-bf17f9ee0402",
              "division": {
                "id": "asSbcy12sYs8c",
                "name": "Aдоніс",
                "type": "CLINIC",
                "addresses": {
                  "type": "RESIDENCE",
                  "country": "UA",
                  "area": "Житомирська",
                  "region": "Бердичівський",
                  "settlement": "Київ",
                  "settlement_type": "CITY",
                  "settlement_id": "b075f148",
                  "street_type": "STREET",
                  "street": "вул. Ніжинська",
                  "building": "15",
                  "apartment": "23",
                  "zip": "02090"
                },
                "contacts": {
                  "email": "email@example.com",
                  "phones": [
                    {
                      "type": "MOBILE",
                      "number": "+380503410870"
                    }
                  ]
                },
                "coordinates": {
                  "latitude": 30.1233,
                  "longitude": 50.32423
                },
                "legal_entity": {
                  "name": "Заклад Ноунейм",
                  "short_name": "Ноунейм",
                  "public_name": "Ноунейм",
                  "type": "PRIMARY_CARE",
                  "owner_property_type": "STATE",
                  "legal_form": "140",
                  "edrpou": "5432345432",
                  "kveds": "[\"86.10\", \"47.73\"]",
                  "addresses": [
                    {
                      "type": "RESIDENCE",
                      "country": "UA",
                      "area": "Житомирська",
                      "region": "Бердичівський",
                      "settlement": "Київ",
                      "settlement_type": "CITY",
                      "settlement_id": "b075f148",
                      "street_type": "STREET",
                      "street": "вул. Ніжинська",
                      "building": "15",
                      "apartment": "23",
                      "zip": "02090"
                    }
                  ],
                  "phones": [
                    {
                      "type": "MOBILE",
                      "number": "+380503410870"
                    }
                  ],
                  "email": "email@example.com",
                  "nhs_verified": "false",
                  "owner": {
                    "id": "7d23bebb-1cf3-4221-bf21-18aada444756",
                    "position": "P1",
                    "employee_type": "OWNER",
                    "party": {
                      "id": "7d23bebb-1cf3-4221-bf21-18aada444756",
                      "first_name": "Петро",
                      "second_name": "Миколайович",
                      "last_name": "Іванов"
                    }
                  }
                }
              },
              "speciality_type": "FAMILY_DOCTOR",
              "providing_condition": "OUTPATIENT",
              "category": [
                "0742d949-1492-4864-9494-60fd7102abfd"
              ],
              "type": [
                "2c0110a9-0bea-4b16-af8e-6e2e149a5bfc"
              ],
              "status": "ACTIVE",
              "comment": "Заведено помилково",
              "coverage_area": [
                "2c0110a9-0bea-4b16-af8e-6e2e149a5bfc"
              ],
              "available_time": [
                {
                  "days_of_week": [
                    "mon"
                  ],
                  "all_day": true,
                  "available_start_time": "08:30:00",
                  "available_end_time": "19:00:00"
                }
              ],
              "not_available": [
                {
                  "description": "Санітарний день",
                  "during": {
                    "start": "2018-08-02T10:45:16.000Z",
                    "end": "2018-08-02T11:00:00.000Z"
                  }
                }
              ]
            }
          ]
        }
      ]
    }
  ],
  "paging": {
    "page_number": 2,
    "page_size": 50,
    "total_entries": 1000,
    "total_pages": 23
  }
}

HTTP status codes

HTTP status code

Message

What caused the error

 200

 Response

 

422

Validation failed

  • No labels