I am using Restify for creating REST APIs. I have created the route in such format /ConfigDetails/:name/:id where name and id are optional.
If none of the two params is given, all configdetails will be fetched;
If name is given, config details for that name will be returned;
If id is given, config details for that id will be returned;
My question is, how do I make them optional? With the current route I've defined, unless all two parameters are present, it will not be able to be resolved and will fall into the default route. As per my understanding restify don't support '?' Can anyone help me on this.