XUND API Documentation

SpecializationFilter

SpecializationFilter extends FilterBase

SpecializationFilter is a filter type that can be used to filter Medical Services by specialization.

SpecializationFilter describes a multiselect input, where user can select the searched specializations. Its values are of type SpecializationFilterValue.

Property name

Property type

Property description

text

string

Localised text of the Filter

type

FilterType = ‘MULTISELECT’

Type of the Filter

values

SpecializationFilterValue[]

Values to select the specializations(s) from

selectionLimit

number

The maximal selectable specializations.

If the sent parameter count exceed this limit, an INVALID_REQUEST error will be returned.

Example response

An example of a SpecializationFilter retreived from GET /v1/services/filters endpoint looks like:

JSON
{
   specializations": {
        "type": "MULTISELECT",
        "text": "Specializations",
        "values": [
            {
                "text": "Orthopaedics and traumatology",
                "value": "035a9ca0-cxf6-4ea5-8c69-12312fae78ed",
                "code": "DOCTOR"
            },
            {
                "text": "Neuropaediatrics",
                "value": "053011b1-6xfc-4796-8e9a-2b91ee3e9215",
                "code": "DOCTOR"
            },
            {
                "text": "Thoracic surgery",
                "value": "064e469a-exd5-40fd-925f-570dd1d2d550",
                "code": "DOCTOR"
            }
        ]
    }
}

Example request

After the filter was rendered, filled and submitted by the user, its value should be sent to POST /v1/services/filters/apply endpoint.

Location filter is always mandatory

The request body would look like this:

JSON
{
    "specializations": [
      "035a9ca0-cxf6-4ea5-8c69-12312fae78ed"
    ],
    "location": {
        "latitude": 48.218323, 
        "longitude": 16.324020
    }
}

The specialization value sent is the value of Orthopaedics and traumatology in the response above.

This will return the Medical Services that have the specializations orthopedics and traumatology, restricted by the endpoint’s limits.