sails.config.routes
Configuration for custom (aka “explicit”) routes. sails.config.routes
consists of a single Javascript object whose keys are URL paths (the “address”) and whose values are one of several types of route handler configurations (the “target”), for example:
module.exports.routes = {
"GET /": {view: "homepage"},
"POST /foo/bar": {controller: "FooController", action: "bar"}
}
Please see the routes concept overview for a full discussion of Sails routes, and the custom routes documentation for a detailed description of the available configurations for both the route address and target.