I am creating an application with FastAPI and so far it goes like this:
But I'm having a problem with the endpoints. The /api/items/filter route has two query parameters: name and category. However, it gives me the impression that it is being taken as if it were api/items/{user_id}/filter, since when I do the validation in the documentation it throws me an error saying that I have not passed a value for user_id. (Also, previously it asked me to be authenticated (the only route that needed authentication was api/items/{user_id}. The problems are fixed when I define this endpoint first as shown below:
Why is this happening? Is there a concept that I am not clear?