Using ICollection in Rest API Controllers to get specific Data

103 views Asked by At

So I'm building my first Rest API and I have those 3 Model classes. Desk Model

Person Model

Booking Model

And here is my DbContext

DbContext

Now I want to do this: I want to create a GET Method in the DeskController that shows me every Desk where bookings = null. I tried to construct it myself but I have problems with the error message "Unsupported Media Type" when I try to reach the route.

DeskController

0

There are 0 answers