redguava / cliniko-api

The API for Cliniko
73 stars 39 forks source link

Bookings API appointment type filter not working #376

Closed briandestura closed 1 year ago

briandestura commented 1 year ago

Hello!

The Bookings API doc says that appointment type id is filterable: https://docs.api.cliniko.com/openapi/reference/tag/Booking/#tag/Booking/operation/ListBookings-Get

But hitting this API:

https://api.au1.cliniko.com/v1/bookings?q[]=appointment_type_id:=1039424726251865516

Gives back a 400 with response:

{
    "message": "appointment_type_id is not filterable"
}

Are the docs updated or is this a planned future release?

JohnColvin commented 1 year ago

Hi Brian,

Listing appointment_type_id as filterable there was a mistake in our API doc generator, which has been fixed now. But while looking at that, we realized there's no good reason that the bookings endpoint was missing this filter. So we'll be adding it soon. When we do, the docs will automatically update to list it again.

Thanks for pointing this out!

loumarven commented 1 year ago

Hi Brian,

The bookings endpoint should now be filterable by appointment_type_id. Thanks!