I have a controller endpoint and I need help with the naming convention.
Basically, the endpoint is supposed to find a customer by their Id/Email (which is sent in the url of the request). Thus I need to have two endpoints, one for users/{id}
and one for users/{email}
.
The issue is, the above wouldn't work as the routes are exactly the same.
What I have done is I have replaces the users/{email}
route with:
users/get-by-email/{email}
and kept the get by id route as: users/{id}
Thanks