Let's say I have a method that returns a list of customers and as input has a list of states and list of sizes, something like
return customers where state in (NY, CA, TX) and size in (Small, Medium)
What would the best RESTFul URL that I should use? The problem that it is a query and does not point to a specific 'resource'. Here are some options that I am mulling over.
- somesite.com/customers?state=NY,CA,TX&size=small,medium (old style)
- somesite.com/customers/state/NY,CA,TX/size/small,medium
- somesite.com/customers/state=NY,CA,TX/size=small,medium
- somesite.com/customers/state(NY,CA,TX)/size(small,medium)