We're designing a rest endpoint for retreiving name autocompletion suggestions for hotel names.Currently it's defined like this: GET /suggest/:term, so that if you queried `/suggest/hil' you would get responses like Hilton Paris, Hilton New York, etc.One of our colleagues argues that this is against REST API design best practices, and that the search term should instead be a query parameter, i.e. /suggest?term=hilt.Looking around other famous APIs, it seems that they all use a query parameter:https://developers.google.com/places/webservice/autocompletehttps://swiftype.com/documentation/autocompletebut I'd like to know why; whether the former is actually bad design and what guidelines would get me to make it a query parameter in the first place.
REST autocomplete endpoint design
rest