req.method

The request method (aka "verb".)

Usage

req.method;

Example

If a client sends a POST request to /product:

req.method;
// -> "POST"

Notes

  • All requests to a Sails server have a "method", even via WebSockets (this is thanks to the request interpreter)