3. Search
Search for appointments
POST /{id}/search
Searches for available appointments based on date, timeslot type, and practitioner.
Parameters
id: Clinic ID (required)
apikey: API Key (required)
selectedDateForDetails: Date for which to search for appointments. Default today.
dateRange: Date range for the search (required)
from: Start date of the range
to: End date of the range
calendarIds: Array of calendar IDs (optional)
timeslotTypeIds: Array of timeslot type IDs (optional)
Returns
Json-response containing search results, including calendars, dateSlots, timeslotTypes and timeslots.
Example
Request:
POST https://psno-portal.svc.pasientsky.no/partner-api/92fef17c-cd48-11ed-bc1f-fa4d0633c42f/search
{
"calendarIds":null,
"timeslotTypeIds":null,
"dateRange":{
"from":"2023-04-28",
"to":"2023-10-28"
},
"selectedDateForDetails":"2023-04-28",
"apikey":"hello"
}
Response:
{
"data":{
"calendars":[
{
"id":"8952d712-cd50-11ed-aa27-1e93d635cf44",
"containsSelectedTimeslotTypes":true,
"name":"ThomasClinic",
"sortingPosition":1000,
"ownedByDepartment":"935132e8-cd48-11ed-b5ca-fa4d0633c42f"
}
],
"dateSlots":[
{
"date":"2023-04-24",
"availableSlots":12
},
{
"date":"2023-05-22",
"availableSlots":12
}
],
"timeslotTypes":[
{
"id":"04558f18-cd51-11ed-a515-1e93d635cf44",
"name":"GroupAppointment",
"isContainedInSelectedCalendars":true,
"estimatedPrice":"800",
"extraInformation":"",
"appointmentType":"groupAppointment",
"mediums":[
"FACE_TO_FACE"
],
"location":null,
"calendarsWithClientListIds":[],
"durationInMinutes":60
},
{
"id":"b24eedae-cd50-11ed-914e-1e93d635cf44",
"name":"RegularAppointment",
"isContainedInSelectedCalendars":true,
"estimatedPrice":"400",
"extraInformation":"",
"appointmentType":"appointment",
"mediums":[
"FACE_TO_FACE"
],
"location":null,
"calendarsWithClientListIds":[],
"durationInMinutes":30
}
],
"timeslots":[
{
"id":"8952d712-cd50-11ed-aa27-1e93d635cf44_2_2023-04-19T09:00_7e6d8332-cd51-11ed-82e8-1e93d635cf44",
"timeslotTypeId":"b24eedae-cd50-11ed-914e-1e93d635cf44",
"calendarId":"8952d712-cd50-11ed-aa27-1e93d635cf44",
"start":"2023-04-19T09:00:00+02:00",
"end":"2023-04-19T09:30:00+02:00"
},
{
"id":"8952d712-cd50-11ed-aa27-1e93d635cf44_2_2023-04-19T09:30_7e6d8332-cd51-11ed-82e8-1e93d635cf44",
"timeslotTypeId":"b24eedae-cd50-11ed-914e-1e93d635cf44",
"calendarId":"8952d712-cd50-11ed-aa27-1e93d635cf44",
"start":"2023-04-19T09:30:00+02:00",
"end":"2023-04-19T10:00:00+02:00"
}
]
}
}
Last updated