updated the api contracts for users filters api#116
Conversation
heyrandhir
commented
Apr 3, 2023
- Update api contracts for /users/filter.
- with this API Users can be filtered based on their skills and status i.e idle, active, or OOO.
| | [GET /users/:userId/badges](#get-usersidbadges) | Returns badges assigned to the user | | ||
| | [POST /users](#post-users) | Creates a new User | | ||
| | [PATCH /users/self](#patch-usersself) | Updates data of the User | | ||
| | [GET /users/filter](#get-usersfilter) | Returns user data based on a filter | |
There was a problem hiding this comment.
This should be ?filter. (Since filter is not a resource)
There was a problem hiding this comment.
In another issue here, /users/userId is being modified to /users?userId=.. .As this change also accepts query parameters directly after /users. Adding query parameters here as well after /users will cause a collision.
can we rename this endpoint to /users/search?....
There was a problem hiding this comment.
@heyrandhir are we going with /users/filter or /users/search for this API?
There was a problem hiding this comment.
@vikhyat187 as of now going with /users/search .also waiting for @ankushdharkar comment on this one.
There was a problem hiding this comment.
Can we just give the results based on the key provided in the query parameters?
If asked for the filter, we filter and give, if asked for ?userId, we give user details.